diff --git a/src/apps/AppGridManagement/AddGird.vue b/src/apps/AppGridManagement/AddGird.vue index 805a4c5d..3f326322 100644 --- a/src/apps/AppGridManagement/AddGird.vue +++ b/src/apps/AppGridManagement/AddGird.vue @@ -14,7 +14,7 @@
- + ,{{item.name}} 请选择 @@ -25,7 +25,7 @@ 网格员
- + ,{{item.name}} 请选择 @@ -93,10 +93,20 @@ export default { if(!this.form.girdName){ return this.$u.toast('请输入网格名称') } + if(this.fromType == 'add') { + this.form.parentGirdId = this.detailInfo.id + this.form.parentGirdName = this.detailInfo.girdName + this.form.girdLevel = Number(this.detailInfo.girdLevel)+1 + this.form.girdType = Number(this.detailInfo.girdType)+1 + this.form.isLastLevel = this.form.girdLevel == 2 ? '1' : '0' + } this.$http.post(`/app/appgirdinfo/addOrUpdate`, this.form).then((res) => { if (res.code == 0) { - this. - uni.navigateBack() + this.$u.toast('提交成功') + uni.$emit('update') + setTimeout(() => { + uni.navigateBack() + }, 600) } }) diff --git a/src/apps/AppGridManagement/SetGird.vue b/src/apps/AppGridManagement/SetGird.vue index 073cdb8e..26207a1c 100644 --- a/src/apps/AppGridManagement/SetGird.vue +++ b/src/apps/AppGridManagement/SetGird.vue @@ -60,6 +60,7 @@
+
删除网格 编辑网格 @@ -88,6 +89,10 @@ export default { onLoad() { this.$dict.load('girdType', 'girdLevel') this.isGirdUser() + uni.$on('update', () => { + this.show = false + this.getTree() + }) }, methods: { isGirdUser() { @@ -408,9 +413,14 @@ export default { border-bottom: 0; } .btn{ - padding: 32px 0; + width: 100%; + padding: 32px; + box-sizing: border-box; background-color: #fff; display: flex; + position: fixed; + bottom: 0; + left: 0; span{ display: inline-block; height: 92px;