From 16b3368a6a44b380969b58609932c6d0c0e3332b Mon Sep 17 00:00:00 2001 From: gaoluyang <2820782392@qq.com> Date: 星期二, 18 三月 2025 13:35:46 +0800 Subject: [PATCH] 成品下单-退回可以重新提交 --- src/views/business/productOrder/components/add.vue | 40 +++++++++++++++++++--------------------- 1 files changed, 19 insertions(+), 21 deletions(-) diff --git a/src/views/business/productOrder/components/add.vue b/src/views/business/productOrder/components/add.vue index 2a65236..a8d1468 100644 --- a/src/views/business/productOrder/components/add.vue +++ b/src/views/business/productOrder/components/add.vue @@ -232,6 +232,7 @@ </div> </div> <el-table ref="sampleTable" :data="sampleList" border class="el-table sampleTable" highlight-current-row + :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" max-height="400px" tooltip-effect="dark" @selection-change="selectSample" @row-click="rowClick"> <el-table-column v-if="active==1" :selectable="selectable" type="selection" width="60"></el-table-column> <el-table-column align="center" label="搴忓彿" type="index" width="65"></el-table-column> @@ -295,8 +296,9 @@ </template> </el-table-column> </el-table> - <el-table ref="productTable" v-loading="getProductLoad" :data="productList" :row-class-name="tableRowClassName" border class="el-table" - :key="upIndex" + <el-table ref="productTable" v-loading="getProductLoad" :data="productList" + :row-class-name="tableRowClassName" border class="el-table" + :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" max-height="400px" style="margin-bottom: 10px;" tooltip-effect="dark" @select="selectOne" @selection-change="selectProduct" @select-all="handleAll"> <el-table-column v-if="active==1" :selectable="selectable0" type="selection" width="65"></el-table-column> @@ -596,7 +598,7 @@ } from "@/api/business/rawMaterialOrder"; import { addInsOrder, addInsOrderTemplate, delInsOrderTemplate, - getQuarterOnOrder, + getQuarterOnOrder, selectInsOrderTemplateById, selectOrderManDay, updateInsOrder, upInsOrder, @@ -606,6 +608,7 @@ import {selectsStandardMethodByFLSSM} from "@/api/standard/standardLibrary"; import limsTable from "@/components/Table/lims-table.vue"; import {selectCustomPageList} from "@/api/system/customer"; +import {mapGetters} from "vuex"; export default { name: 'Add', @@ -613,6 +616,9 @@ limsTable, cableConfig, AuxiliaryWireCore + }, + computed:{ + ...mapGetters(["nickName"]), }, dicts: ['check_type1', 'urgency_level', 'form_type', 'sample_status_list'], data() { @@ -899,7 +905,6 @@ this.isSpecial = true this.$nextTick(() => { this.$refs.productTable.doLayout(); - this.upIndex++ }); }, getQuarterOnOrderList () { @@ -980,7 +985,7 @@ }, // 鑾峰彇鐢ㄦ埛鍒楄〃 getAuthorizedPerson() { - selectUserCondition().then(res => { + selectUserCondition({ type: 1 }).then(res => { let data = [] res.data.forEach(a => { data.push({ @@ -1338,10 +1343,6 @@ userId: this.distributeData.userId, sonLaboratory:this.distributeData.sonLaboratory }).then(res => { - if (res.code === 201) { - this.upLoad = false - return - } this.$message.success('鎻愪氦鎴愬姛') this.upLoad = false this.issuedDialogVisible = false @@ -1651,14 +1652,13 @@ backtrack([], nums); return result; }, - tableRowClassName({ - row, - rowIndex - }) { - if (row.state === 0) { + tableRowClassName({row, rowIndex}) { + if (row.state == 1) { + console.log('row.state---', row.state) + return 'warning-row'; + } else { return ''; } - return 'warning-row'; }, selectInsOrderTemplate() { selectInsOrderTemplate({company: this.addObj.company}).then(res => { @@ -1675,9 +1675,6 @@ delInsOrderTemplate({ id: row.id }).then(res => { - if (res.code === 201) { - return - } this.$message.success('鍒犻櫎鎴愬姛') this.selectInsOrderTemplate() }).catch(e => { @@ -1714,12 +1711,13 @@ selectInsOrderTemplateById({id: e}).then(res => { let obj = JSON.parse(res.data) //鍒跺崟浜鸿缃负褰撳墠鐧诲綍鐢ㄦ埛 - let user = JSON.parse(localStorage.getItem('user')) + let user = this.nickName obj.addObj.custom = user.name obj.addObj.userId = user.userId this.addObj = obj.addObj; this.sampleList = obj.sampleList; this.selectTree = obj.selectTree + this.rowClick(this.sampleList[0]) }) }, delSampleAndProduct() { @@ -2220,7 +2218,7 @@ </script> <style scoped> -.el-table .warning-row .cell { - color: #3A7BFA; +>>>.warning-row { + color: #1890FF; } </style> -- Gitblit v1.9.3