事件上报
This commit is contained in:
@@ -2,10 +2,8 @@
|
|||||||
<div class="Transfer">
|
<div class="Transfer">
|
||||||
<div class="contents">
|
<div class="contents">
|
||||||
<u-form :model="forms" ref="uForm" label-width="auto" :border-bottom="false">
|
<u-form :model="forms" ref="uForm" label-width="auto" :border-bottom="false">
|
||||||
<u-form-item label="转交给" prop="status" required :border-bottom="false" class="first-form" v-if="status == 1">
|
<u-form-item label="转交给" prop="status" required :border-bottom="false" class="first-form" right-icon="arrow-right" v-if="status == 1">
|
||||||
<AiPagePicker type="gridUser" :id="forms.girdId" @select="handleSelectGrid" nodeKey="girdId">
|
<u-input v-model="forms.name" placeholder="请选择转交人员" disabled @click="toSelectUser" />
|
||||||
<AiMore v-model="forms.name"/>
|
|
||||||
</AiPagePicker>
|
|
||||||
</u-form-item>
|
</u-form-item>
|
||||||
<u-form-item label="事件分类" prop="groupName" required :border-bottom="false" right-icon="arrow-right" v-if="status != 1">
|
<u-form-item label="事件分类" prop="groupName" required :border-bottom="false" right-icon="arrow-right" v-if="status != 1">
|
||||||
<!-- <u-input v-model="forms.groupName" placeholder="请选择事件分类" /> -->
|
<!-- <u-input v-model="forms.groupName" placeholder="请选择事件分类" /> -->
|
||||||
@@ -71,30 +69,19 @@ export default {
|
|||||||
this.forms.groupId = option.groupId
|
this.forms.groupId = option.groupId
|
||||||
this.forms.groupName = option.groupName
|
this.forms.groupName = option.groupName
|
||||||
this.typeList()
|
this.typeList()
|
||||||
// uni.$on('pagePicker:custom', (res) => {
|
uni.$on('goback', (res) => {
|
||||||
// this.selectUser = res
|
this.selectUser = res
|
||||||
// if (res.name) {
|
this.forms.girdId = res.girdId
|
||||||
// this.forms.name = res.name
|
this.forms.girdName = res.girdName
|
||||||
// } else {
|
this.forms.girdMemberId = res.id
|
||||||
// this.forms.name = res.girdName
|
this.forms.girdMemberName = res.name
|
||||||
// }
|
this.forms.name = `${res.girdName}${res.name ? '-' + res.name : ''}`
|
||||||
// })
|
})
|
||||||
},
|
},
|
||||||
onShow() {
|
onShow() {
|
||||||
document.title = this.titleList[this.status]
|
document.title = this.titleList[this.status]
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
handleSelectGrid(v) {
|
|
||||||
// this.forms.name = v.girdName
|
|
||||||
// this.forms.girdId = v.girdId
|
|
||||||
// this.selectUser = v
|
|
||||||
this.forms.girdId = v.girdId
|
|
||||||
this.forms.girdName = v.girdName
|
|
||||||
this.forms.girdMemberId = v.id
|
|
||||||
this.forms.girdMemberName = v.name
|
|
||||||
this.forms.name = `${v.girdName}${v.name ? '-' + v.name : ''}`
|
|
||||||
this.selectUser = {...v}
|
|
||||||
},
|
|
||||||
typeList() {
|
typeList() {
|
||||||
this.$http.post(`/app/appclapeventgroup/list`, null, {
|
this.$http.post(`/app/appclapeventgroup/list`, null, {
|
||||||
params: {
|
params: {
|
||||||
@@ -167,9 +154,9 @@ export default {
|
|||||||
this.forms.groupName = e[0].label
|
this.forms.groupName = e[0].label
|
||||||
this.forms.groupId = e[0].value
|
this.forms.groupId = e[0].value
|
||||||
},
|
},
|
||||||
// toSelectUser() {
|
toSelectUser() {
|
||||||
// uni.navigateTo({url: '../AppGridManagement/selectGridMember'})
|
uni.navigateTo({url: `./SelectUser?detailId=${this.id}`})
|
||||||
// },
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -207,6 +207,7 @@ export default {
|
|||||||
<style scoped lang="scss">
|
<style scoped lang="scss">
|
||||||
uni-page-body {
|
uni-page-body {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
|
padding-top: 26px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.Detail {
|
.Detail {
|
||||||
@@ -215,8 +216,8 @@ uni-page-body {
|
|||||||
|
|
||||||
.header-top {
|
.header-top {
|
||||||
display: flex;
|
display: flex;
|
||||||
margin: 26px 0 14px 0;
|
margin-bottom: 14px;
|
||||||
padding: 0 32px;
|
padding: 32px 32px 0;
|
||||||
|
|
||||||
.avatars {
|
.avatars {
|
||||||
width: 80px;
|
width: 80px;
|
||||||
|
|||||||
@@ -4,15 +4,14 @@
|
|||||||
<div class="hint">
|
<div class="hint">
|
||||||
<span v-for="(item, index) in slectList" :key="index"><span v-if="index" style="margin:0 4px;">/</span><span style="color:#3F8DF5" @click="girdNameClick(item, index)">{{item.girdName}}</span></span>
|
<span v-for="(item, index) in slectList" :key="index"><span v-if="index" style="margin:0 4px;">/</span><span style="color:#3F8DF5" @click="girdNameClick(item, index)">{{item.girdName}}</span></span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="showTypes" v-if="!userList.length">
|
<div class="showTypes" v-if="!userList.length">
|
||||||
<div v-if="treeList.length > 0">
|
<div v-if="treeList.length > 0">
|
||||||
<div class="cards" v-for="(item, index) in treeList" :key="index" @click="itemClick(item)">
|
<div class="cards" v-for="(item, index) in treeList" :key="index" @click="itemClick(item, index)">
|
||||||
<div class="imges">
|
<div class="imges">
|
||||||
<span v-if="item.girdLevel == 2">
|
<!-- <span>
|
||||||
<img src="./components/img/xzh.png" alt="" class="imgselect" v-if="item.isChecked" @click.stop="girdClick(item, index)" />
|
<img src="./components/img/xzh.png" alt="" class="imgselect" v-if="item.isChecked" @click.stop="girdClick(item, index)" />
|
||||||
<img src="./components/img/xz.png" alt="" class="imgselect" v-else @click.stop="girdClick(item, index)" />
|
<img src="./components/img/xz.png" alt="" class="imgselect" v-else @click.stop="girdClick(item, index)" />
|
||||||
</span>
|
</span> -->
|
||||||
<img src="./components/img/gird--select-icon.png" alt="" class="avatras" />
|
<img src="./components/img/gird--select-icon.png" alt="" class="avatras" />
|
||||||
</div>
|
</div>
|
||||||
<div class="rightes">
|
<div class="rightes">
|
||||||
@@ -63,9 +62,11 @@ export default {
|
|||||||
treeList: [],
|
treeList: [],
|
||||||
slectList: [],
|
slectList: [],
|
||||||
userList: [],
|
userList: [],
|
||||||
|
detailId: ''
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad() {
|
onLoad(option) {
|
||||||
|
this.detailId = option.detailId
|
||||||
this.getTree()
|
this.getTree()
|
||||||
},
|
},
|
||||||
onShow() {
|
onShow() {
|
||||||
@@ -74,7 +75,7 @@ export default {
|
|||||||
methods: {
|
methods: {
|
||||||
getTree() {
|
getTree() {
|
||||||
this.slectList = []
|
this.slectList = []
|
||||||
this.$http.post('/app/appgirdinfo/listAllByTop').then((res) => {
|
this.$http.post(`/app/appresidentreportinfo/listGirdInfoByTransfer?id=${this.detailId}`).then((res) => {
|
||||||
if (res?.data) {
|
if (res?.data) {
|
||||||
this.allData = res.data
|
this.allData = res.data
|
||||||
this.treeInit()
|
this.treeInit()
|
||||||
@@ -83,54 +84,38 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
treeInit() {
|
treeInit() {
|
||||||
if(this.allData[0].girdLevel == 2) {
|
// if(this.allData[0].girdLevel == 2) {
|
||||||
if(this.allData[0].girdMemberList && this.allData[0].girdMemberList.length) {
|
// if(this.allData[0].girdMemberList && this.allData[0].girdMemberList.length) {
|
||||||
this.userList = this.allData[0].girdMemberList
|
// this.userList = this.allData[0].girdMemberList
|
||||||
this.userList.map((item) => {
|
// this.userList.map((item) => {
|
||||||
item.isChecked = false
|
// item.isChecked = false
|
||||||
})
|
// })
|
||||||
}
|
// }
|
||||||
}else {
|
// }else {
|
||||||
this.treeList = this.allData[0].girdList
|
// this.treeList = this.allData[0].girdList
|
||||||
}
|
// }
|
||||||
var obj = {
|
var obj = {
|
||||||
girdName: this.allData[0].girdName,
|
girdName: '可选范围',
|
||||||
id: this.allData[0].id,
|
id: '',
|
||||||
girdLevel: this.allData[0].girdLevel
|
|
||||||
}
|
}
|
||||||
this.slectList.push(obj)
|
this.slectList.push(obj)
|
||||||
|
this.treeList = this.allData
|
||||||
},
|
},
|
||||||
|
|
||||||
itemClick(row) {
|
itemClick(row, index) {
|
||||||
console.log(row)
|
if(!this.treeList[index].girdMemberList.length) {
|
||||||
|
return this.$u.toast('该网格下暂无网格员')
|
||||||
|
}
|
||||||
var obj = {
|
var obj = {
|
||||||
girdName: row.girdName,
|
girdName: row.girdName,
|
||||||
id: row.id,
|
id: row.id,
|
||||||
girdLevel: row.girdLevel
|
|
||||||
}
|
}
|
||||||
this.slectList.push(obj)
|
this.slectList.push(obj)
|
||||||
this.searckGird(row)
|
this.searckGird(index)
|
||||||
},
|
},
|
||||||
|
|
||||||
searckGird(row) {
|
searckGird(index) {
|
||||||
this.treeList = []
|
this.userList = this.treeList[index].girdMemberList
|
||||||
if(row.girdLevel != 2) { //查网格
|
|
||||||
this.$http.post(`/app/appgirdinfo/list?parentGirdId=${row.id}&size=999`).then((res) => {
|
|
||||||
if (res?.data) {
|
|
||||||
this.treeList = res.data.records
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}else { //查网格员
|
|
||||||
this.userList = []
|
|
||||||
this.$http.post(`/app/appgirdmemberinfo/listByGirdIdByThree?girdId=${row.id}`).then((res) => {
|
|
||||||
if (res?.data) {
|
|
||||||
this.userList = res.data
|
|
||||||
this.userList.map((item) => {
|
|
||||||
item.isChecked = false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
|
|
||||||
girdNameClick(row, index) {
|
girdNameClick(row, index) {
|
||||||
|
|||||||
Reference in New Issue
Block a user