From 5aeed1756422239fb106bf2d9168133ea76f1e6c Mon Sep 17 00:00:00 2001 From: zhouzy062 Date: Sat, 23 Dec 2023 19:42:57 +0800 Subject: [PATCH] =?UTF-8?q?=E5=89=8D=E7=AB=AF=E9=97=AE=E9=A2=98=E4=BF=AE?= =?UTF-8?q?=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sgzb-ui/package.json | 2 +- sgzb-ui/src/api/store/tools.js | 9 + .../claimAndRefund/receive/agreement.vue | 4 +- .../newBuy/newDevices/newDevicesAccept.vue | 51 +++-- .../newBuy/newDevices/newDevicesArrival.vue | 1 + .../newBuy/newDevices/newDevicesCode.vue | 30 +-- sgzb-ui/src/views/store/tools/devices.vue | 180 ++++++++++++++---- .../src/views/store/tools/toolsSupplier.vue | 22 +-- sgzb-ui/src/views/store/tools/toolsType.vue | 30 ++- sgzb-ui/vue.config.js | 4 +- 10 files changed, 245 insertions(+), 88 deletions(-) diff --git a/sgzb-ui/package.json b/sgzb-ui/package.json index 680f403b..983fed2a 100644 --- a/sgzb-ui/package.json +++ b/sgzb-ui/package.json @@ -5,7 +5,7 @@ "author": "机具", "license": "MIT", "scripts": { - "dev": "vue-cli-service serve", + "dev": "set NODE_OPTIONS=--openssl-legacy-provider && vue-cli-service serve", "build": "set NODE_OPTIONS=--openssl-legacy-provider && vue-cli-service build", "build:stage": "vue-cli-service build --mode staging", "preview": "node build/index.js --preview", diff --git a/sgzb-ui/src/api/store/tools.js b/sgzb-ui/src/api/store/tools.js index e9b78a67..5a0c5cac 100644 --- a/sgzb-ui/src/api/store/tools.js +++ b/sgzb-ui/src/api/store/tools.js @@ -280,6 +280,15 @@ export function delRepairer(data) { }) } +//机具厂家-下拉数据 +export function getDeviceFactoryCbx(data) { + return request({ + url: '/base/select/getDeviceFactoryCbx', + method: 'post', + data: data + }) +} + diff --git a/sgzb-ui/src/views/claimAndRefund/receive/agreement.vue b/sgzb-ui/src/views/claimAndRefund/receive/agreement.vue index 50890816..aaf11c7a 100644 --- a/sgzb-ui/src/views/claimAndRefund/receive/agreement.vue +++ b/sgzb-ui/src/views/claimAndRefund/receive/agreement.vue @@ -276,7 +276,9 @@ export default { dialogImageUrl: '', dialogVisible: false, //上传地址 - uploadUrl:'http://192.168.0.14:21624/system',//线上服务器地址+system + // uploadUrl:'http://192.168.0.14:21624/system',//线上服务器地址+system + uploadUrl:'http://112.29.103.165:21624/system',//线上服务器地址+system + // 表单校验 rules: { contractCode: [ diff --git a/sgzb-ui/src/views/store/newBuy/newDevices/newDevicesAccept.vue b/sgzb-ui/src/views/store/newBuy/newDevices/newDevicesAccept.vue index e2c22588..76d5a147 100644 --- a/sgzb-ui/src/views/store/newBuy/newDevices/newDevicesAccept.vue +++ b/sgzb-ui/src/views/store/newBuy/newDevices/newDevicesAccept.vue @@ -126,13 +126,15 @@ - - + accept=".png,.jpg,.jpeg" + :on-success="handleAvatarSuccess" + :on-preview="handlePictureCardPreview" + :on-remove="handleRemove"> + @@ -153,13 +155,15 @@ - - + accept=".png,.jpg,.jpeg" + :on-success="handleAvatarSuccess" + :on-preview="handlePictureCardPreview" + :on-remove="handleRemove"> + @@ -240,7 +244,7 @@ - + @@ -300,7 +304,8 @@ export default { fileList:[], field101fileList:[], //上传地址 - uploadUrl:'http://192.168.0.14:21624/system',//线上服务器地址+system + // uploadUrl:'http://192.168.0.14:21624/system',//线上服务器地址+system + uploadUrl:'http://112.29.103.165:21624/system',//线上服务器地址+system // uploadUrl:'http://10.40.92.140:9201',//本地测试 dialogImageUrl: '', dialogVisible: false, @@ -587,8 +592,6 @@ export default { this.aform.checkUrl = res.data.fileUrl; this.aform.checkUrlName = res.data.fileName; } - this.imageUrl = res.data.fileUrl; - this.imageName = res.data.fileName; }else{ // this.$msgError(res.msg) this.$modal.msgError(res.msg); @@ -598,6 +601,26 @@ export default { this.$modal.msgError(error); }) }, + handleAvatarSuccess(res,file) { + console.log("success") + }, + handleRemove(file, fileList) { + console.log(file, fileList); + if(this.open){ + this.form.checkUrl = ''; + this.form.checkUrlName = ''; + } + if(this.openAll){ + this.aform.checkUrl = ''; + this.aform.checkUrlName = ''; + } + }, + //图片点击查看 + handlePictureCardPreview(file) { + console.log(file) + this.dialogImageUrl = file.url; + this.dialogVisible = true; + }, //图片查看 openImg(url){ this.dialogImageUrl = this.uploadUrl + url; diff --git a/sgzb-ui/src/views/store/newBuy/newDevices/newDevicesArrival.vue b/sgzb-ui/src/views/store/newBuy/newDevices/newDevicesArrival.vue index 25b22bf3..bbfdb0b5 100644 --- a/sgzb-ui/src/views/store/newBuy/newDevices/newDevicesArrival.vue +++ b/sgzb-ui/src/views/store/newBuy/newDevices/newDevicesArrival.vue @@ -67,6 +67,7 @@ + --> - + @@ -114,8 +114,8 @@ - - + + @@ -142,8 +142,8 @@ - - + + + \ No newline at end of file diff --git a/sgzb-ui/src/views/store/tools/toolsSupplier.vue b/sgzb-ui/src/views/store/tools/toolsSupplier.vue index 0e755b32..5bf6e231 100644 --- a/sgzb-ui/src/views/store/tools/toolsSupplier.vue +++ b/sgzb-ui/src/views/store/tools/toolsSupplier.vue @@ -148,18 +148,16 @@ - - - + - @@ -170,7 +168,7 @@ - + @@ -218,6 +216,10 @@ export default { imageName:'', fileList:[], field101fileList:[], + //上传地址 + // uploadUrl:'http://192.168.0.14:21624/system',//线上服务器地址+system + uploadUrl:'http://112.29.103.165:21624/system',//线上服务器地址+system + // uploadUrl:'http://192.168.4.2:9201',//本地测试 // 表单校验 rules: { dictName: [ @@ -326,9 +328,7 @@ export default { imgUpLoad(param).then(res => { if(res.code == 200) { this.form.businessLicense = res.data.fileUrl; - // this.form.photoName = res.data.fileName; this.imageUrl = res.data.fileUrl; - // this.imageName = res.data.fileName; }else{ // this.$msgError(res.msg) this.$modal.msgError(res.msg); @@ -340,7 +340,6 @@ export default { }, handleAvatarSuccess(res,file) { console.log("success") - // this.imageUrl = URL.createObjectURL(file.raw); // console.log(this.imageUrl) }, @@ -357,8 +356,7 @@ export default { }, //图片查看 openImg(url){ - this.dialogImageUrl = "http://192.168.0.14:21624/system" + url;//线上 - // this.dialogImageUrl = "http://10.40.92.140:9201" + url;//本地 + this.dialogImageUrl = this.uploadUrl + url; this.dialogVisible = true; }, /** 删除按钮操作 */ diff --git a/sgzb-ui/src/views/store/tools/toolsType.vue b/sgzb-ui/src/views/store/tools/toolsType.vue index 2e84dd11..93527037 100644 --- a/sgzb-ui/src/views/store/tools/toolsType.vue +++ b/sgzb-ui/src/views/store/tools/toolsType.vue @@ -273,16 +273,18 @@ - + 上传 + + + @@ -452,8 +454,9 @@ export default { fileList:[], field101fileList:[], //上传地址 - uploadUrl:'http://192.168.0.14:21624/system',//线上服务器地址+system - // uploadUrl:'http://10.40.92.140:9201',//本地测试 + // uploadUrl:'http://192.168.0.14:21624/system',//线上服务器地址+system + // uploadUrl:'http://112.29.103.165:21624/system',//线上服务器地址+system + uploadUrl:'http://192.168.5.12:9201',//本地测试 defaultProps: { children: "children", label: "label" @@ -636,6 +639,17 @@ export default { const typeId = row.typeId || this.ids; getMaType(typeId).then(response => { this.form = response.data; + // let file = { + // name:this.form.documentName, + // type:this.form.documentUrl, + // } + // this.field101fileList.push(file) + // let img = { + // name:this.form.photoName, + // type:this.uploadUrl+this.form.photoUrl, + // } + // this.fileList.push(img) + this.open = true; this.title = "修改"; }); @@ -747,14 +761,14 @@ export default { }, //文件上传 fileUpLoad(param,name,index) { - // // console.log(param) + console.log(param,'fileUpLoad') param.type = 'ma' imgUpLoad(param).then(res => { if(res.code == 200) { this.form.documentUrl = res.data.fileUrl; this.form.documentName = res.data.fileName; this.field101fileList[0] = param.file - console.log(this.form) + console.log(this.field101fileList) }else{ // this.$msgError(res.msg) this.$modal.msgError(res.msg); diff --git a/sgzb-ui/vue.config.js b/sgzb-ui/vue.config.js index 7bad4fdc..25879ff8 100644 --- a/sgzb-ui/vue.config.js +++ b/sgzb-ui/vue.config.js @@ -37,8 +37,8 @@ module.exports = { [process.env.VUE_APP_BASE_API]: { //192.168.0.14 // target: `http://112.29.103.165:21624`,//线上环境 - target: `http://192.168.0.14:21624`,//线上环境 - // target: `http://192.168.4.2:8080`,//丁 + // target: `http://192.168.0.14:21624`,//线上环境 + target: `http://192.168.5.12:8080`,//丁 // target: `http://10.40.92.138:8080`,//丁/ // target: `http://10.40.92.126:8080`,//高 // target: `http://10.40.92.111:8080`,//亮