事件上报
This commit is contained in:
@@ -78,7 +78,7 @@ export default {
|
||||
})
|
||||
},
|
||||
onShow() {
|
||||
console.log(this.titleList[this.status])
|
||||
// console.log(this.titleList[this.status])
|
||||
document.title = this.titleList[this.status]
|
||||
},
|
||||
methods: {
|
||||
|
||||
@@ -102,7 +102,7 @@ export default {
|
||||
},
|
||||
|
||||
itemClick(row) {
|
||||
console.log(row)
|
||||
// console.log(row)
|
||||
var obj = {
|
||||
girdName: row.girdName,
|
||||
id: row.id,
|
||||
|
||||
@@ -75,12 +75,41 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="flow-option">
|
||||
<div class="byself">自己结办</div>
|
||||
<div class="report">上报处理</div>
|
||||
<div class="byself" :class="!form.opts? 'current': ''" @click="form.opts = 0">自己结办</div>
|
||||
<div class="report" :class="form.opts? 'current': ''" @click="form.opts = 1">上报处理</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div v-if="this.form.opts == 0">
|
||||
<div class="form-item__group">
|
||||
<div class="form-item form-item__textarea">
|
||||
<div class="form-item__wrapper">
|
||||
<div class="form-item__title">
|
||||
<i>*</i>
|
||||
<h2>办理结果</h2>
|
||||
</div>
|
||||
<div class="form-item__right">
|
||||
<textarea v-model="form.result" :maxlength="500" placeholder="请简要描述事件…"></textarea>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-item__group">
|
||||
<div class="form-item form-item__imgs">
|
||||
<div class="form-item__wrapper">
|
||||
<div class="form-item__title">
|
||||
<i style="opacity: 0;">*</i>
|
||||
<h2>图片上传</h2>
|
||||
<span>(最多9张)</span>
|
||||
</div>
|
||||
<div class="form-item__right">
|
||||
<AiUploader v-model="form.resultFiles" :limit="9"></AiUploader>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="btn" @click="submit">上报</div>
|
||||
|
||||
</div>
|
||||
@@ -101,11 +130,18 @@
|
||||
girdName: '',
|
||||
flow: '',
|
||||
girdId: '',
|
||||
lat: '114.138292',
|
||||
lng: '30.623843',
|
||||
flag: false,
|
||||
result: '',
|
||||
resultFiles: [],
|
||||
opts: 1,
|
||||
name: ''
|
||||
},
|
||||
dictList: [],
|
||||
arr: [],
|
||||
gridList: [[], []],
|
||||
flag: false
|
||||
|
||||
}
|
||||
},
|
||||
|
||||
@@ -116,7 +152,7 @@
|
||||
onLoad () {
|
||||
this.getDict()
|
||||
this.form.phone = this.user.phone
|
||||
this.form.name = this.user.realName || ''
|
||||
this.form.name = this.user.name || ''
|
||||
this.getGirdList()
|
||||
},
|
||||
|
||||
@@ -155,7 +191,8 @@
|
||||
},
|
||||
|
||||
getDict () {
|
||||
this.$instance.post(`/app/appclapeventgroup/list?current=1&size=100000`).then(res => {
|
||||
this.$http.post(`/app/appclapeventgroup/list`).then(res => {
|
||||
console.log(res);
|
||||
if (res.code == 0) {
|
||||
this.dictList = res.data.records.map(v => {
|
||||
return {
|
||||
@@ -174,7 +211,7 @@
|
||||
},
|
||||
|
||||
getGirdList () {
|
||||
this.$instance.post(`/app/appgirdinfo/listAllByTop`).then(res => {
|
||||
this.$http.post(`/app/appgirdinfo/y`).then(res => {
|
||||
if (res.code == 0) {
|
||||
this.arr = res.data
|
||||
this.gridList[0] = res.data[0].girdList
|
||||
@@ -187,17 +224,13 @@
|
||||
const column = e.detail.column
|
||||
const value = e.detail.value
|
||||
|
||||
|
||||
|
||||
if (column === column) {
|
||||
this.getGirdData(value)
|
||||
}
|
||||
},
|
||||
|
||||
onChange (e) {
|
||||
console.log(e)
|
||||
const v = e.detail.value[1]
|
||||
console.log(v)
|
||||
if (this.gridList[1][v]) {
|
||||
this.form.girdName = this.gridList[1][v].girdName
|
||||
this.form.girdId = this.gridList[1][v].id
|
||||
@@ -215,24 +248,29 @@
|
||||
if (!this.form.groupId) {
|
||||
return this.$u.toast('请选择事件类型')
|
||||
}
|
||||
if (!this.form.address) {
|
||||
return this.$u.toast('请选择发生地点')
|
||||
}
|
||||
// if (!this.form.address) {
|
||||
// return this.$u.toast('请选择发生地点')
|
||||
// }
|
||||
if (!this.form.girdName) {
|
||||
return this.$u.toast('请选择上报网格')
|
||||
}
|
||||
if (!this.form.flow) {
|
||||
return this.$u.toast('请选择处理流程')
|
||||
// if (!this.form.flow) {
|
||||
// return this.$u.toast('请选择处理流程')
|
||||
// }
|
||||
if (this.form.opts == false) {
|
||||
if (!this.form.result) {
|
||||
return this.$u.toast('请输入事件办理结果')
|
||||
}
|
||||
}
|
||||
|
||||
if(this.flag) return
|
||||
this.flag = true
|
||||
|
||||
this.$loading()
|
||||
this.$instance.post(`/app/appclapeventinfo/addOrUpdate`, {
|
||||
this.$http.post(`/app/appclapeventinfo/addOrUpdate`, {
|
||||
...this.form,
|
||||
openid: this.user.openid,
|
||||
portrait: this.user.avatarUrl,
|
||||
// openid: this.user.openid,
|
||||
// portrait: this.user.avatarUrl,
|
||||
files: this.form.files,
|
||||
groupName: this.dictList.filter(v => v.value === this.form.groupId)[0].label
|
||||
}).then(res => {
|
||||
@@ -242,7 +280,7 @@
|
||||
uni.$emit('update')
|
||||
setTimeout(() => {
|
||||
uni.redirectTo({
|
||||
url: '/service/photoReport/PhotoResult?id=' + res.data.id
|
||||
url: './detail'
|
||||
})
|
||||
}, 400)
|
||||
}
|
||||
@@ -373,6 +411,11 @@
|
||||
font-size: 30px;
|
||||
color: #333333;
|
||||
}
|
||||
.current {
|
||||
color: #1174fe;
|
||||
background: #e7f1fe !important;
|
||||
position: relative;
|
||||
}
|
||||
}
|
||||
|
||||
.btn {
|
||||
|
||||
Reference in New Issue
Block a user