From b3ebb6f99f647a08cac70ebd9cf1baabdffc6852 Mon Sep 17 00:00:00 2001 From: 王震 <10952869+daywangzhen@user.noreply.gitee.com> Date: 星期三, 20 十二月 2023 14:55:56 +0800 Subject: [PATCH] Merge branch 'master' of http://114.132.189.42:9002/r/mes-ocea-before --- src/views/plan/customerorder/customerorder-form.vue | 224 ++++++++++++++++++++++++++++++++++--------------------- 1 files changed, 137 insertions(+), 87 deletions(-) diff --git a/src/views/plan/customerorder/customerorder-form.vue b/src/views/plan/customerorder/customerorder-form.vue index bbe1d58..47ad1d9 100644 --- a/src/views/plan/customerorder/customerorder-form.vue +++ b/src/views/plan/customerorder/customerorder-form.vue @@ -26,7 +26,7 @@ class="l-mes" :disabled="!editable" > - <el-tabs type="border-card" ref="tabs"> + <el-tabs type="border-card" ref="tabs" @tab-click="tabsClick"> <el-tab-pane label="涓昏" type="card"> <el-row> <el-col :span="6"> @@ -72,7 +72,13 @@ <el-row> <el-col :span="6"> <el-form-item label="瀹㈡埛璁㈠崟鐘舵��" prop="returnStatus"> - <el-select + <el-input + v-model="dataForm.returnStatus" + placeholder="" + filterable + style="width: 100%" + disabled></el-input> + <!-- <el-select v-model="dataForm.returnStatus" placeholder="" filterable @@ -86,7 +92,7 @@ :value="item.value" :disabled="!ediSource" /> - </el-select> + </el-select> --> </el-form-item> </el-col> <el-col :span="6"> @@ -181,16 +187,18 @@ </el-col> <el-col :span="6"> <el-form-item label="浜у搧鍚嶇О" prop="productName"> + <el-tooltip class="item" effect="dark" :content="dataForm.productName" > <el-input v-model="dataForm.productName" placeholder="" disabled > </el-input> + </el-tooltip> </el-form-item> </el-col> <el-col :span="6"> - <el-form-item label="浜у搧绫诲瀷" prop="productType"> + <el-form-item label="闅跺睘鍝佺墝" prop="productType"> <el-input v-model="dataForm.productType" placeholder="" @@ -203,13 +211,12 @@ <el-input v-model="dataForm.partNo" placeholder="" - disabled > <el-button slot="append" icon="el-icon-search" - @click="openSalesPartDialog()" - v-show="dataForm.id" + @click="openPartDialog()" + ></el-button> </el-input> </el-form-item> @@ -242,35 +249,44 @@ </el-form-item> </el-col> <el-col :span="6"> - <el-form-item label="鏀惰揣鍦板潃" prop="shippingAddress"> + <el-form-item label="宸ヨ壓鏂囦欢鍚嶇О" prop="docName"> <el-input - v-model="dataForm.shippingAddress" + v-model="dataForm.docName" placeholder="" + disabled ></el-input> + </el-form-item> + </el-col> + <el-col :span="6"> + <el-form-item label="鍗曚綅" prop="otcUnit"> + <el-select + v-model="dataForm.otcUnit" + placeholder="" + filterable + style="width: 100%" + > + <el-option + v-for="item in units" + :key="item.id" + :label="item.label" + :value="item.value" + /> + </el-select> + </el-form-item> + </el-col> + <el-col :span="6"> + <el-form-item label="浜у搧鍨嬪彿" prop="customerPartSpec"> + <el-tooltip class="item" effect="dark" :content="dataForm.customerPartSpec" > + <el-input + v-model="dataForm.customerPartSpec" + placeholder="" + disabled + ></el-input> + </el-tooltip> </el-form-item> </el-col> </el-row> <el-row> - </el-row> - <el-row> - <!-- <el-col :span="6"> - <el-form-item label="璐ㄩ噺瑕佹眰" prop="qualityRequire"> - <el-input - v-model="dataForm.qualityRequire" - placeholder="" - disabled - ></el-input> - </el-form-item> - </el-col> --> - <!-- <el-col :span="6"> - <el-form-item label="鐢熶骇闇�姹傝鏄�" prop="otherProductRequire"> - <el-input - v-model="dataForm.otherProductRequire" - placeholder="" - disabled - ></el-input> - </el-form-item> - </el-col> --> <!-- <el-col :span="6"> <el-form-item label="绯荤粺" prop="divisionSystem"> <el-input @@ -311,6 +327,16 @@ </el-col> --> </el-row> <el-row> + <el-col :span="6"> + <el-form-item label="鏀惰揣鍦板潃" prop="shippingAddress"> + <el-tooltip class="item" effect="dark" :content="dataForm.shippingAddress" > + <el-input + v-model="dataForm.shippingAddress" + placeholder="" + ></el-input> + </el-tooltip> + </el-form-item> + </el-col> <!-- <el-col :span="6"> <el-form-item label="OTC鎺ㄩ�佺姸鎬�" prop="remark"> <span>{{ @@ -325,7 +351,22 @@ </el-row> <el-row> <el-col :span="24"> - <el-form-item label="璁㈠崟璇存槑" prop="remark"> + <el-form-item label="璁㈠崟澶囨敞" prop="comment"> + <el-input + type="textarea" + :rows="3" + placeholder="" + v-model="dataForm.comment" + maxlength="500" + show-word-limit + > + </el-input> + </el-form-item> + </el-col> + </el-row> + <el-row> + <el-col :span="24"> + <el-form-item label="浜у搧澶囨敞" prop="remark"> <el-input type="textarea" :rows="3" @@ -608,15 +649,16 @@ show-overflow-tooltip > </el-table-column> - <el-table-column prop="lineNumber" align="center" label="琛屽彿"> - </el-table-column> + <!-- <el-table-column prop="lineNumber" align="center" label="琛屽彿"> --> + <!-- </el-table-column> --> <el-table-column prop="originalFileName" align="center" label="鍘熸枃浠跺悕" + width="200" > </el-table-column> - <el-table-column prop="fileName" align="center" label="鏂囦欢鍚�"> + <el-table-column prop="fileName" align="center" label="鏂囦欢鍚庣紑"> </el-table-column> <el-table-column prop="createUser" align="center" label="涓婁紶浜�"> </el-table-column> @@ -649,18 +691,18 @@ <!-- </el-table-column>--> <el-table-column fixed="right" align="center" label="鎿嶄綔"> <template slot-scope="scope"> - <el-button + <!-- <el-button @click="synchronizeFile(scope.row)" type="text" size="small" - :disabled="scope.row.lineNumber !== dataForm.otcLineNo" + :disabled="scope.row.lineNumber !== dataForm.customerNo" >鍚屾</el-button - > + > --> <el-button @click="delProcessConfigFile(scope.row)" type="text" size="small" - :disabled="scope.row.lineNumber !== dataForm.otcLineNo" + :disabled="scope.row.lineNumber !== dataForm.customerNo" >鍒犻櫎</el-button > <el-button @@ -721,6 +763,7 @@ getCustomerOrder, addCustomerOrder, putCustomerOrder, + updateCustomerOrderById, download, getOtcCustomerOrderFileList, otcDownload, @@ -779,17 +822,36 @@ id: 0, sourceId: '', contractNo: '', - customerOrderNo: '', - returnStatus: '', - deliveryDate: '', customerNo: '', customerName: '', - coState: '', - coLineNo: '', + returnStatus: '', + deliveryDate: '', + salesMan: '', + salerWorkCode: '', + manufactureAttr: '', + buyQtyDue: 0, + productName: '', + productType: '', partNo: '', + technologyDocumentId: '', + docNumber: '', + docName: '', + shippingAddress: '', + remark: '', + otcUnit: '', + coState: '', + customerPartSpec: '', + entityName: '', + factoryPlaceOrderDate: '', + isCp: '', + originalContractStatus: '', + placeOrderDate: '', + province: '', + + customerOrderNo: '', + coLineNo: '', customerPartName: '', otcQuantity: '', - buyQtyDue: '', wantedDeliveryDate: '', plannedDeliveryDate: '', customerPoNo: '', @@ -805,11 +867,7 @@ ifsSalesUnit: null, ifsConvFactor: null, unit: null, - otcUnit: null, otcQuantity: null, - docNumber: null, - manufactureAttr: 'N', - customerPartSpec: null, division: null, printType: null, printingRequirements: null, @@ -818,14 +876,10 @@ qualityRequire: null, otherProductRequire: null, divisionSystem: null, - shippingAddress: null, - salesMan: null, lengthRequirement: null, - remark: null, otcPartSync: null, finalCustomerName: null, productGroup: null, - productType: null, centralizedMiningProperty: null, orderDescription: null, otcLineNo: null, @@ -973,6 +1027,11 @@ this.getManufactureAttrs('manufacture_attr_type') }, methods: { + tabsClick(tab,even){ + if(tab.index == 2){ + this.getConfigFiles(); + } + }, init(id) { this.orderParamList = [] this.dataForm.id = id || 0 @@ -985,9 +1044,7 @@ // if (response.data.data.customerOrderList != null) { // this.dataForm = response.data.data.customerOrderList // - // console.log('0') // if (this.dataForm.OrderOrContract) { - // console.log('1') // // 灏嗚鍗曡繕鏄悎鍚岃浆涔� // if (this.dataForm.OrderOrContract == '0') { // this.dataForm.OrderOrContract = '鍚堝悓' @@ -996,11 +1053,10 @@ // } // } // } else { - // console.log('2') this.dataForm = response.data.data + // } // this.fileList = response.data.data.customerOrderAttachmentList - console.log(response.data.data.sourceId); const sourceId = response.data.data.sourceId if(sourceId === '0'){ this.getFileList() @@ -1016,7 +1072,6 @@ // this.this.configContent.modelType = '01' // this.configContent.orderId = this.dataForm.id // this.configContent.orderId = response.data.data.customerOrderNo - console.log(response.data.data) if (response.data.data.processConfigDTO) { // 鏈変繚瀛樼殑鏁版嵁 this.configContent = response.data.data.processConfigDTO @@ -1114,7 +1169,7 @@ this.$refs.dataForm.validate((valid) => { if (valid) { if (this.dataForm.id) { - putCustomerOrder(this.dataForm) + updateCustomerOrderById(this.dataForm) .then((data) => { this.$message.success('淇敼鎴愬姛') this.visible = false @@ -1141,25 +1196,34 @@ } }) }, - // 闆朵欢閫夋嫨 + // 闆朵欢閫夋嫨 openPartDialog() { - if ( - this.dataForm.coState === '01partUnCheck' || - this.dataForm.coState === '02technologyUnCheck' - ) { - this.showPart = true - } else { - this.$message.warning( - '璁㈠崟鍙湁鍦ㄣ�愰浂浠跺緟閫夈�戙�併�愬伐鑹烘枃浠跺緟閫夈�戠姸鎬佷笅锛屾墠鑳借繘琛岄浂浠朵慨鏀�' - ) - } + this.showPart = true }, selectPart(part) { if (part) { this.dataForm.partNo = part.partNo - this.$refs.dataForm.validateField('partNo', (valid) => {}) } }, + // 闆朵欢閫夋嫨 + // openPartDialog() { + // if ( + // this.dataForm.coState === '01partUnCheck' || + // this.dataForm.coState === '02technologyUnCheck' + // ) { + // this.showPart = true + // } else { + // this.$message.warning( + // '璁㈠崟鍙湁鍦ㄣ�愰浂浠跺緟閫夈�戙�併�愬伐鑹烘枃浠跺緟閫夈�戠姸鎬佷笅锛屾墠鑳借繘琛岄浂浠朵慨鏀�' + // ) + // } + // }, + // selectPart(part) { + // if (part) { + // this.dataForm.partNo = part.partNo + // this.$refs.dataForm.validateField('partNo', (valid) => {}) + // } + // }, // 鍏ㄥ睆 fullscreen() { this.isFullScreen = !this.isFullScreen @@ -1216,8 +1280,8 @@ delOutPutBatch(row) {}, addOutPutBatch() {}, submitUpload() { - this.paramData.orderNumber = this.dataForm.customerOrderNo - this.paramData.lineNumber = this.dataForm.otcLineNo + this.paramData.orderNumber = this.dataForm.contractNo + this.paramData.lineNumber = this.dataForm.customerNo this.progrecessFileLoading = true }, uploadSuccess() { @@ -1226,8 +1290,8 @@ }, getConfigFiles() { const param = { - orderNumber: this.dataForm.customerOrderNo, - lineNumber: this.dataForm.otcLineNo + orderNumber: this.dataForm.contractNo, + lineNumber: this.dataForm.customerNo } getProcessConfigFiles(param).then((res) => { this.processConfigFileTableData = res.data.data @@ -1246,9 +1310,6 @@ this.getConfigFiles() }, delProcessConfigFile(row) { - if (row.lineNumber !== this.dataForm.otcLineNo) { - this.$message.error('涓婁紶鏂囦欢琛屽彿涓庡綋鍓嶉攢鍞鍗曡鍙蜂笉涓�鑷达紝涓嶅厑璁稿垹闄�') - } else { this.$confirm('鏄惁鍒犻櫎宸ヨ壓閰嶇疆鏂囦欢', '鎻愮ず', { confirmButtonText: '纭畾', cancelButtonText: '鍙栨秷', @@ -1261,7 +1322,6 @@ .then((data) => { this.getConfigFiles() }) - } }, downloadProcessConfigFile(row) { downloadProcessConfigFile( @@ -1294,7 +1354,6 @@ // 淇濆瓨閰嶇疆鍗� saveConfig() { const configId = this.configContent.id - console.log(this.configContent) for ( let i = this.configContent.processConfigDataList.length - 1; i >= 0; @@ -1310,7 +1369,6 @@ } if (configId) { newProcessConfigEditOne(this.configContent).then((res) => { - console.log(res) if (res.data.code === 0) { this.$message.success('淇濆瓨鎴愬姛') this.init(this.configContent.orderId) @@ -1320,7 +1378,6 @@ }) } else { newProcessConfigAddOne(this.configContent).then((res) => { - console.log(res) if (res.data.code === 0) { this.$message.success('淇濆瓨鎴愬姛') this.init(this.configContent.orderId) @@ -1345,7 +1402,6 @@ } else { this.$message.error('璇ラ攢鍞鍗曞彿涓嬶紝娌℃湁鍏朵粬璁㈠崟琛�') /* const configId = this.configContent.id - console.log(this.configContent) for ( let i = this.configContent.processConfigDataList.length - 1; i >= 0; @@ -1361,7 +1417,6 @@ } if (configId) { newProcessConfigEdit(this.configContent).then((res) => { - console.log(res) if (res.data.code === 0) { this.$message.success('淇濆瓨鎴愬姛') this.init(this.configContent.orderId) @@ -1371,7 +1426,6 @@ }) } else { newProcessConfigAdd(this.configContent).then((res) => { - console.log(res) if (res.data.code === 0) { this.$message.success('淇濆瓨鎴愬姛') this.init(this.configContent.orderId) @@ -1383,7 +1437,6 @@ } }) /* const configId = this.configContent.id - console.log(this.configContent) for ( let i = this.configContent.processConfigDataList.length - 1; i >= 0; @@ -1399,7 +1452,6 @@ } if (configId) { newProcessConfigEdit(this.configContent).then((res) => { - console.log(res) if (res.data.code === 0) { this.$message.success('淇濆瓨鎴愬姛') this.init(this.configContent.orderId) @@ -1409,7 +1461,6 @@ }) } else { newProcessConfigAdd(this.configContent).then((res) => { - console.log(res) if (res.data.code === 0) { this.$message.success('淇濆瓨鎴愬姛') this.init(this.configContent.orderId) @@ -1471,7 +1522,6 @@ // var param = Object.assign({ current: 1, size: 20 }) // getProcessConfigPage(param).then((res) => { // const list = res.data.data.records - // console.log(list) // }) }, // 鑾峰彇纭 -- Gitblit v1.9.3