diff --git a/src/apps/AppWalkask/AppWalkask.vue b/src/apps/AppWalkask/AppWalkask.vue index b950d988..90e02357 100644 --- a/src/apps/AppWalkask/AppWalkask.vue +++ b/src/apps/AppWalkask/AppWalkask.vue @@ -166,6 +166,8 @@ export default { size: 6, current: this.current, areaId: this.areaId, + createUserId: this.currentTabs == 1 ? this.user.id : '', + title: this.keyword, }, }) .then((res) => { @@ -192,7 +194,10 @@ export default { }, change(index) { + this.areaId = this.user.areaId + this.keyword = '' this.currentTabs = index + this.getList() }, goDetail(item, hint) { @@ -225,11 +230,13 @@ export default { handerSearch(e) { this.keyword = e this.current = 1 + this.getList() }, handerClear() { this.keyword = '' this.current = 1 + this.getList() }, previewImage(images, img) { diff --git a/src/apps/AppWalkask/add.vue b/src/apps/AppWalkask/add.vue index 433508cb..2ca6f341 100644 --- a/src/apps/AppWalkask/add.vue +++ b/src/apps/AppWalkask/add.vue @@ -9,19 +9,15 @@ - - - - - + + - + - @@ -48,7 +44,7 @@ - + @@ -72,7 +68,8 @@ export default { show: false, forms: { areaId: '', - application: '', + optionId: '', + create_user_name: '', reality: '', realityValue: '', title: '', @@ -80,7 +77,6 @@ export default { images: [], }, showAreaId: false, - showObject: false, showStstus: false, flag: false, addList: true, @@ -95,11 +91,7 @@ export default { this.getDetail() }) }, - mounted() { - this.$on('black', (data) => { - console.log(data) - }) - }, + mounted() {}, methods: { getDetail() { this.$http.post(`/app/appvisitvondolence/queryDetailById?id=${this.params.id}`).then((res) => { @@ -107,7 +99,6 @@ export default { this.forms = res.data this.forms.realityValue = res.data.reality this.forms.reality = this.$dict.getLabel('realityStatus', res.data.reality) - if (res.data.images) { this.forms.images = JSON.parse(res.data.images || '[]') } @@ -121,9 +112,9 @@ export default { this.$refs.uForm.validate((valid) => { if (valid) { - // if (!this.forms.application) { - // return this.$u.toast('请选择走访对象') - // } + if (!this.forms.create_user_name) { + return this.$u.toast('请选择走访慰问对象') + } if (!this.forms.title) { return this.$u.toast('请输入入户走访事项') } @@ -140,8 +131,9 @@ export default { this.$http .post(`/app/appvisitvondolence/addOrUpdate`, { areaId: this.forms.areaId, - applicationId: '02fcf19c81154f6ea9560d9a9deee9f4', - optionId: '4703806718f842a98a28df554c6aa6b2', + applicationId: this.forms.applicationId, + name: this.forms.create_user_name, + optionId: this.forms.applicationId, reality: this.forms.realityValue ? this.forms.realityValue : this.forms.reality, title: this.forms.title, description: this.forms.description, @@ -174,6 +166,14 @@ export default { } }, + backlist(e) { + console.log(e.item) + this.forms.create_user_name = e.item.create_user_name + this.forms.applicationId = e.appId + this.forms.optionId = e.item.id + this.addList = true + }, + realityStstus(e) { this.forms.reality = e[0].label this.forms.realityValue = e[0].value @@ -182,7 +182,7 @@ export default { toWalkObject() { this.addList = false this.comp = 'walkObject' - this.params = 111 + this.paramss = 111 }, }, } diff --git a/src/apps/AppWalkask/walkObject.vue b/src/apps/AppWalkask/walkObject.vue index ac9e5c1b..f4be9bc8 100644 --- a/src/apps/AppWalkask/walkObject.vue +++ b/src/apps/AppWalkask/walkObject.vue @@ -15,9 +15,15 @@
- - {{ e.name00 }} - + + + {{ item.create_user_name }} + + + +
@@ -64,6 +70,8 @@ export default { ], nameList: [], current: 1, + appId: '', + value: '', } }, computed: {}, @@ -81,7 +89,8 @@ export default { }, selectUser(item) { - console.log(item) + console.log(item.id) + this.appId = item.id this.$http.post(`/app/appapplicationinfo/list?appId=${item.id}¤t=${this.current}&size=${99}`, { searchParam: this.keyword }).then((res) => { if (res.code == 0) { this.userList = res.data.records @@ -89,19 +98,10 @@ export default { }) }, - checkboxGroupChange(a) { - console.log(a) - }, - - checkboxChange(e) { - console.log(e) - }, - submit() { this.userList.map((item) => { - if (item.checked == true) { - console.log(11, 'back', 'item') - this.$emit('back', item) + if (item.create_user_name == this.value) { + this.$emit('back', { item: item, appId: this.appId }) } }) }, @@ -134,19 +134,15 @@ export default { } .Checkbox { padding: 0 20px 0 30px; - ::v-deep .u-checkbox-group { - .u-checkbox { - // position: relative; - height: 112px; - } - } + ::v-deep .u-collapse { .u-collapse-item { .u-collapse-body { - display: inline; - .u-checkbox-group { - display: flex; - flex-direction: column; + // display: inline; + .u-radio-group { + .u-radio { + line-height: 0; + } } } } @@ -171,7 +167,6 @@ export default { color: #ffffff; } .typeName { - // margin: 48px 0 44px 0; margin: 36px 0 22px 0; .typeName-box { padding: 16px 14px;