diff --git a/front/src/api/personalCenter.js b/front/src/api/personalCenter.js index 67079961..892ff59d 100644 --- a/front/src/api/personalCenter.js +++ b/front/src/api/personalCenter.js @@ -231,3 +231,11 @@ export function queryResourceRelByKeyId(params) { params, }) } +// 文件上传接口 +export function filesUpload(data) { + return request({ + url: window.SITE_CONFIG.apiURL + '/upload', + method: 'post', + data, + }) +} diff --git a/front/src/views/capacityOnTheShelf/Application.vue b/front/src/views/capacityOnTheShelf/Application.vue index d2483801..38d71e39 100644 --- a/front/src/views/capacityOnTheShelf/Application.vue +++ b/front/src/views/capacityOnTheShelf/Application.vue @@ -99,6 +99,7 @@ import mybus from '@/myplugins/mybus' const showView = ref('基本信息') const router = useRouter() + let shiyongshouce = ref({}) const navList = ref([]) const navList2 = ref([]) const fileList = ref({}) @@ -285,7 +286,9 @@ } init() mybus.on('chageDataFrom', (obj) => { - console.log(obj, dataFrom.value.infoList) + if (obj.attrType == '使用手册' && obj.attrValue != null) { + shiyongshouce.value = obj + } dataFrom.value.infoList = dataFrom.value.infoList.filter( (item) => item.attrType !== obj.attrType ) @@ -293,6 +296,14 @@ obj.attrValue = '' } dataFrom.value.infoList.push(obj) + if (shiyongshouce.value.attrValue) { + dataFrom.value.infoList.map((syscitem, syscindex) => { + if (syscitem.attrType == '使用手册') { + dataFrom.value.infoList[syscindex] = shiyongshouce.value + } + }) + } + console.log('数据变更=================》', obj, dataFrom.value.infoList) }) mybus.on('chageFileList', (obj) => { fileList.value = obj diff --git a/front/src/views/capacityOnTheShelf/BusinessComponent.vue b/front/src/views/capacityOnTheShelf/BusinessComponent.vue index 8a515f72..42f6ceba 100644 --- a/front/src/views/capacityOnTheShelf/BusinessComponent.vue +++ b/front/src/views/capacityOnTheShelf/BusinessComponent.vue @@ -173,6 +173,7 @@ ], }, ]) + let shiyongshouce = ref({}) const navList = ref([]) const navList2 = ref([]) const fileList = ref({}) @@ -297,6 +298,9 @@ } init() mybus.on('chageDataFrom', (obj) => { + if (obj.attrType == '使用手册' && obj.attrValue != null) { + shiyongshouce.value = obj + } dataFrom.value.infoList = dataFrom.value.infoList.filter( (item) => item.attrType !== obj.attrType ) @@ -304,6 +308,13 @@ obj.attrValue = '' } dataFrom.value.infoList.push(obj) + if (shiyongshouce.value.attrValue) { + dataFrom.value.infoList.map((syscitem, syscindex) => { + if (syscitem.attrType == '使用手册') { + dataFrom.value.infoList[syscindex] = shiyongshouce.value + } + }) + } console.log('数据变更=================》', obj, dataFrom.value.infoList) }) mybus.on('chageFileList', (obj) => { diff --git a/front/src/views/capacityOnTheShelf/DevelopmentComponents.vue b/front/src/views/capacityOnTheShelf/DevelopmentComponents.vue index 1f43e8ce..135e5e0f 100644 --- a/front/src/views/capacityOnTheShelf/DevelopmentComponents.vue +++ b/front/src/views/capacityOnTheShelf/DevelopmentComponents.vue @@ -173,6 +173,7 @@ ], }, ]) + let shiyongshouce = ref({}) const navList = ref([]) const navList2 = ref([]) const fileList = ref({}) @@ -297,6 +298,9 @@ } init() mybus.on('chageDataFrom', (obj) => { + if (obj.attrType == '使用手册' && obj.attrValue != null) { + shiyongshouce.value = obj + } dataFrom.value.infoList = dataFrom.value.infoList.filter( (item) => item.attrType !== obj.attrType ) @@ -304,6 +308,13 @@ obj.attrValue = '' } dataFrom.value.infoList.push(obj) + if (shiyongshouce.value.attrValue) { + dataFrom.value.infoList.map((syscitem, syscindex) => { + if (syscitem.attrType == '使用手册') { + dataFrom.value.infoList[syscindex] = shiyongshouce.value + } + }) + } console.log('数据变更=================》', obj, dataFrom.value.infoList) }) mybus.on('chageFileList', (obj) => { diff --git a/front/src/views/capacityOnTheShelf/FilesUpload.vue b/front/src/views/capacityOnTheShelf/FilesUpload.vue new file mode 100644 index 00000000..ce675fe4 --- /dev/null +++ b/front/src/views/capacityOnTheShelf/FilesUpload.vue @@ -0,0 +1,68 @@ + + + + + + + diff --git a/front/src/views/capacityOnTheShelf/LayerServices.vue b/front/src/views/capacityOnTheShelf/LayerServices.vue index c6a7ae55..507eba4a 100644 --- a/front/src/views/capacityOnTheShelf/LayerServices.vue +++ b/front/src/views/capacityOnTheShelf/LayerServices.vue @@ -121,6 +121,7 @@ ], }, ]) + let shiyongshouce = ref({}) const navList = ref([]) const navList2 = ref([]) const fileList = ref({}) @@ -245,6 +246,9 @@ } init() mybus.on('chageDataFrom', (obj) => { + if (obj.attrType == '使用手册' && obj.attrValue != null) { + shiyongshouce.value = obj + } dataFrom.value.infoList = dataFrom.value.infoList.filter( (item) => item.attrType !== obj.attrType ) @@ -252,6 +256,13 @@ obj.attrValue = '' } dataFrom.value.infoList.push(obj) + if (shiyongshouce.value.attrValue) { + dataFrom.value.infoList.map((syscitem, syscindex) => { + if (syscitem.attrType == '使用手册') { + dataFrom.value.infoList[syscindex] = shiyongshouce.value + } + }) + } console.log('数据变更=================》', obj, dataFrom.value.infoList) }) mybus.on('chageFileList', (obj) => { diff --git a/front/src/views/capacityOnTheShelf/components/PutOnTheShelf.vue b/front/src/views/capacityOnTheShelf/components/PutOnTheShelf.vue index 96eae8fe..9cbd5f94 100644 --- a/front/src/views/capacityOnTheShelf/components/PutOnTheShelf.vue +++ b/front/src/views/capacityOnTheShelf/components/PutOnTheShelf.vue @@ -16,14 +16,21 @@ - + {{ title.name }}-{{ index + 1 }} - + {{ attr.name }} @@ -37,19 +44,51 @@ 添加更多{{ title.name }} - + {{ val.name }} - - - - - + + + + + 提交 @@ -60,613 +99,708 @@ {{ item.name }} - - - - - - - - - + + + + + + + + + 上传附件 + + 请选择来源应用 - + 请选择关联组件 - - + + {{ itemSelect.dictLabel }} - - + + " + > {{ itemson.dictLabel }} - + - + + + +
{{ title.name }}-{{ index + 1 }}
+
{{ attr.name }} @@ -37,19 +44,51 @@