From 622f2f645b7715b0eeb16f066cc057b41c71a647 Mon Sep 17 00:00:00 2001 From: a0049873 <79py69t9wb@privaterelay.appleid.com> Date: Fri, 15 Jul 2022 11:07:08 +0800 Subject: [PATCH] =?UTF-8?q?BUG=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/views/modules/ability/bsabilityai.vue | 80 +++++++++---------- .../components/inputSelectCheckbox.vue | 3 + .../components/PutOnTheShelf.vue | 13 +-- 3 files changed, 51 insertions(+), 45 deletions(-) diff --git a/back/src/views/modules/ability/bsabilityai.vue b/back/src/views/modules/ability/bsabilityai.vue index e5900aae..513a0fc3 100644 --- a/back/src/views/modules/ability/bsabilityai.vue +++ b/back/src/views/modules/ability/bsabilityai.vue @@ -424,7 +424,7 @@ export default { this.submitFrom.infoList.push(obj) }, submitData () { - console.log('编辑11111111111===============>', this.putOnTheShelfList) + console.log('提交11111111111===============>', this.putOnTheShelfList) const arr = [] this.putOnTheShelfList.map(item => { item.children.map(child => { @@ -510,45 +510,45 @@ export default { }) }) this.submitFrom.infoList = this.submitFrom.infoList.sort((a, b) => arr.indexOf(a.attrType) - arr.indexOf(b.attrType)) - if (this.submitFrom.id) { - // 解决编辑无组件类型 - this.submitFrom.infoList.map(val => { - if (val.attrType === '组件类型') { - val.attrValue = this.radio - } - }) - console.log('编辑===============>', this.submitFrom) - console.log(this.submitFrom.infoList, '===============abc') - // 去重 - const newArr = this.submitFrom.infoList.filter((element, index, self) => { - return self.findIndex(x => x.attrType === element.attrType) === index - }) - this.submitFrom.infoList = newArr - console.log(this.submitFrom.infoList, '====================================wpwpwp') - this.$http - .put('/resource/update', this.submitFrom) - .then(({ data: res }) => { - if (res.code !== 0) { - this.$message.error('修改失败!') - } else { - this.$message.success('修改成功!') - this.clear() - } - }) - .catch(() => {}) - } else { - this.$http - .post('/resource/insert?source= b', this.submitFrom) - .then(({ data: res }) => { - if (res.code !== 0) { - this.$message.error('上架失败!') - } else { - this.$message.success('上架成功!') - this.clear() - } - }) - .catch(() => {}) - } + // if (this.submitFrom.id) { + // // 解决编辑无组件类型 + // this.submitFrom.infoList.map(val => { + // if (val.attrType === '组件类型') { + // val.attrValue = this.radio + // } + // }) + // console.log('编辑===============>', this.submitFrom) + // console.log(this.submitFrom.infoList, '===============abc') + // // 去重 + // const newArr = this.submitFrom.infoList.filter((element, index, self) => { + // return self.findIndex(x => x.attrType === element.attrType) === index + // }) + // this.submitFrom.infoList = newArr + // console.log(this.submitFrom.infoList, '====================================wpwpwp') + // this.$http + // .put('/resource/update', this.submitFrom) + // .then(({ data: res }) => { + // if (res.code !== 0) { + // this.$message.error('修改失败!') + // } else { + // this.$message.success('修改成功!') + // this.clear() + // } + // }) + // .catch(() => {}) + // } else { + // this.$http + // .post('/resource/insert?source= b', this.submitFrom) + // .then(({ data: res }) => { + // if (res.code !== 0) { + // this.$message.error('上架失败!') + // } else { + // this.$message.success('上架成功!') + // this.clear() + // } + // }) + // .catch(() => {}) + // } }, // 新修改 UpdateData (item) { diff --git a/back/src/views/modules/putOnTheShelf/components/inputSelectCheckbox.vue b/back/src/views/modules/putOnTheShelf/components/inputSelectCheckbox.vue index e87ccf59..d6dafd7c 100644 --- a/back/src/views/modules/putOnTheShelf/components/inputSelectCheckbox.vue +++ b/back/src/views/modules/putOnTheShelf/components/inputSelectCheckbox.vue @@ -114,6 +114,9 @@ export default { if (!this.data.note1) { this.$http.get('/sys/user/info').then(({ data: res }) => { this.data.note1 = res.data.deptId + this.$http.get('/sys/dept/' + res.data.deptId).then(res => { + console.log(res.data.data, '部门信息=============================') + }) }) } }) diff --git a/front/src/views/capacityOnTheShelf/components/PutOnTheShelf.vue b/front/src/views/capacityOnTheShelf/components/PutOnTheShelf.vue index cc5b9b78..3ab54b83 100644 --- a/front/src/views/capacityOnTheShelf/components/PutOnTheShelf.vue +++ b/front/src/views/capacityOnTheShelf/components/PutOnTheShelf.vue @@ -2,7 +2,7 @@ * @Author: hisense.liangjunhua * @Date: 2022-06-17 14:11:08 * @LastEditors: hisense.liangjunhua - * @LastEditTime: 2022-07-13 18:14:42 + * @LastEditTime: 2022-07-15 11:06:55 * @Description: 上架 -->