From f05b9e79dbbcc423087e3b6930880dc25945118c Mon Sep 17 00:00:00 2001 From: zhuo <2089219845@qq.com> Date: 星期一, 17 三月 2025 11:21:45 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/dev' into dev --- src/components/Table/lims-table.vue | 16 +++-- src/assets/styles/sidebar.scss | 24 +++++++- src/views/business/materialOrder/copperOrder.vue | 3 + src/views/business/materialOrder/customsInspection.vue | 4 + src/views/business/inspectionReview/index.vue | 48 +++++++++------ src/views/business/productOrder/components/add.vue | 15 ++-- src/views/business/productOrder/components/cable-config.vue | 4 src/views/business/productOrder/components/auxiliaryWireCore.vue | 9 +-- 8 files changed, 76 insertions(+), 47 deletions(-) diff --git a/src/assets/styles/sidebar.scss b/src/assets/styles/sidebar.scss index 8e69993..0f43008 100644 --- a/src/assets/styles/sidebar.scss +++ b/src/assets/styles/sidebar.scss @@ -71,9 +71,27 @@ } .el-menu-item, .el-submenu__title { - overflow: hidden !important; - text-overflow: ellipsis !important; - white-space: nowrap !important; + display: flex; + align-items: center; + } + .el-submenu__title span { + white-space: normal; + word-break: break-all; + line-height: 20px; + flex: 1; + padding-right: 20px; + } + + .el-menu-item { + display: flex; + align-items: center; + padding-right: 20px !important; + } + .el-menu-item span { + white-space: normal; + word-break: break-all; + line-height: 20px; + flex: 1; } // menu hover diff --git a/src/components/Table/lims-table.vue b/src/components/Table/lims-table.vue index d71bc90..f3d7795 100644 --- a/src/components/Table/lims-table.vue +++ b/src/components/Table/lims-table.vue @@ -13,7 +13,7 @@ :filter-method="item.filterHandler" :filter-multiple="item.filterMultiple" :filtered-value="item.filteredValue" :filters="item.filters" :fixed="item.fixed" :label="item.label" :min-width="item.minWidth" :prop="item.prop" :show-overflow-tooltip="item.dataType === 'action' || item.dataType === 'slot' ? false : true" - :sortable="item.sortable ? true : false" :type="item.type" :width="item.dataType === 'action' ? getWidth(item.operation) : item.width" align="center"> + :sortable="item.sortable ? true : false" :type="item.type" :width="item.dataType == 'action' ? btnWidth : item.width" align="center"> <!-- <div class="123" v-if="item.type == ''"> --> <template v-if="item.hasOwnProperty('colunmTemplate')" :slot="item.colunmTemplate" slot-scope="scope"> <slot v-if="item.theadSlot" :index="index" :name="item.theadSlot" :row="scope.row" /> @@ -62,7 +62,8 @@ </div> <!-- 鎸夐挳 --> - <div v-else-if="item.dataType == 'action'"> + <div v-else-if="item.dataType == 'action'" + :style="`width:${getWidth(item.operation, scope.row)}`"> <template v-for="(o, key) in item.operation"> <el-button v-show="o.type != 'upload'" size="mini" v-if="o.showHide ? o.showHide(scope.row) : true" :disabled="o.disabled ? o.disabled(scope.row) : false" :icon="iconFn(o)" :plain="o.plain" @@ -257,6 +258,7 @@ data() { return { spanList: [], + btnWidth: "120px", }; }, mounted() { @@ -266,16 +268,17 @@ }); }, methods: { - getWidth(row) { + getWidth(row, row0) { let count = 0; row.forEach((a) => { - if (a.showHide!==undefined && a.showHide()) { + if (a.showHide !== undefined && a.showHide(row0)) { count += a.name.length; - } else if(!a.showHide) { + } else if (!a.showHide) { count += a.name.length; } }); - return count * 15 + 70 + "px"; + this.btnWidth = count * 15 + 50 + "px"; + return count * 15 + 50 + "px"; }, iconFn(row) { if (row.name === "缂栬緫" || row.name === "淇敼") { @@ -327,7 +330,6 @@ this.$emit("pagination", { page: page, limit: limit }); }, indexMethod(index) { - // return index * 2; return (this.page.current - 1) * this.page.size + index + 1; }, // 鐐瑰嚮鍗曞厓鏍糽ink浜嬩欢 diff --git a/src/views/business/inspectionReview/index.vue b/src/views/business/inspectionReview/index.vue index 8b979dc..98861dd 100644 --- a/src/views/business/inspectionReview/index.vue +++ b/src/views/business/inspectionReview/index.vue @@ -23,8 +23,8 @@ </div> <div> <lims-table :tableData="tableData" :column="column" :page="page" :tableLoading="tableLoading" - :rowClassName="rowClassName" :height="'calc(100vh - 270px)'" @pagination="pagination" - key="tableData0"></lims-table> + :rowClassName="rowClassName" :height="'calc(100vh - 270px)'" @pagination="pagination" + key="tableData0"></lims-table> </div> <!--鎶ュ憡鏌ョ湅--> <el-dialog title="鎶ュ憡鏌ョ湅" :visible.sync="issuedVisible" width="80vw" :modal-append-to-body="false" @@ -108,7 +108,18 @@ prop: "type", dataType: "tag", formatData: (params) => { - return this.urgencyLevel.find((m) => m.value == params).label; + if (this.urgencyLevel.find((m) => m.value == params)) { + return this.urgencyLevel.find((m) => m.value == params).label; + } else { + return null + } + }, + formatType: (params) => { + if (this.urgencyLevel.find((m) => m.value == params)) { + return this.urgencyLevel.find((m) => m.value == params).type; + } else { + return null + } }, }, { @@ -128,11 +139,18 @@ prop: "insState", dataType: "tag", formatData: (params) => { - return this.inspectionTaskState.find((m) => m.value == params) - .label; + if (this.inspectionTaskState.find((m) => m.value == params)) { + return this.inspectionTaskState.find((m) => m.value == params).label; + } else { + return null + } }, formatType: (params) => { - return this.inspectionTaskState.find((m) => m.value == params).type; + if (this.inspectionTaskState.find((m) => m.value == params)) { + return this.inspectionTaskState.find((m) => m.value == params).type; + } else { + return null + } }, }, { label: "妫�楠屼汉", prop: "userName" }, @@ -229,10 +247,10 @@ fullscreen: false, option: null, orderTypeList: [ - { label: '濮旀墭璇曢獙', value: 'Customer-ordered test' }, - { label: '鎶芥', value: '鎶芥' }, - { label: '杩涘巶妫�楠�', value: '杩涘巶妫�楠�' }, - { label: '瀛e害妫�楠�', value: 'Quarterly inspection' }, + { label: '濮旀墭璇曢獙', value: 'Customer-ordered test', type: 'success' }, + { label: '鎶芥', value: '鎶芥', type: 'danger' }, + { label: '杩涘巶妫�楠�', value: '杩涘巶妫�楠�', type: 'info' }, + { label: '瀛e害妫�楠�', value: 'Quarterly inspection', type: '' }, ], urgencyLevel: [], inspectionTaskState: [], @@ -286,13 +304,6 @@ } return ""; }, - // 鏌ョ湅浜т笟閾句俊鎭� - // openInfoDialog (row) { - // this.showInfoDialog = true - // this.$nextTick(() => { - // this.$refs.showInfoDialog.getInfo(row.ifsInventoryId) - // }) - // }, selectAllByOne(row) { this.isCopper = row.isCopper this.customsInspection = row @@ -373,9 +384,6 @@ // 鏌ョ湅鎶ュ憡 handleIssued(row) { // todo: 鏌ョ湅鎶ュ憡缁勪欢 -/* if (!row.tempUrlPdf) return this.$message.warning('鏂囦欢鏈笂浼�') - this.currentInfo = row - this.lookDialogVisible = true*/ console.log(this.javaApi) this.currentInfo = row; let fileName = row.url diff --git a/src/views/business/materialOrder/copperOrder.vue b/src/views/business/materialOrder/copperOrder.vue index 1f76b7c..d837345 100644 --- a/src/views/business/materialOrder/copperOrder.vue +++ b/src/views/business/materialOrder/copperOrder.vue @@ -1808,4 +1808,7 @@ justify-content: space-between; margin-bottom: 10px; } +>>>.warning-row { + color: #1890FF; +} </style> diff --git a/src/views/business/materialOrder/customsInspection.vue b/src/views/business/materialOrder/customsInspection.vue index b7af486..e9a28fa 100644 --- a/src/views/business/materialOrder/customsInspection.vue +++ b/src/views/business/materialOrder/customsInspection.vue @@ -1897,5 +1897,7 @@ background-color: #ffffff; } - +>>>.warning-row { + color: #1890FF; +} </style> diff --git a/src/views/business/productOrder/components/add.vue b/src/views/business/productOrder/components/add.vue index 5da2477..e03d881 100644 --- a/src/views/business/productOrder/components/add.vue +++ b/src/views/business/productOrder/components/add.vue @@ -1648,14 +1648,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 => { @@ -2214,7 +2213,7 @@ </script> <style scoped> -.el-table .warning-row .cell { - color: #3A7BFA; +>>>.warning-row { + color: #1890FF; } </style> diff --git a/src/views/business/productOrder/components/auxiliaryWireCore.vue b/src/views/business/productOrder/components/auxiliaryWireCore.vue index 7545392..5e7898e 100644 --- a/src/views/business/productOrder/components/auxiliaryWireCore.vue +++ b/src/views/business/productOrder/components/auxiliaryWireCore.vue @@ -250,10 +250,7 @@ this.$refs.productTable.doLayout() }) }, - tableRowClassName({ - row, - rowIndex - }) { + tableRowClassName({row, rowIndex}) { if (row.state === 0) { return ''; } @@ -397,7 +394,7 @@ font-size: 12px; } -.ins_order_config .el-table .warning-row .cell { - color: #3A7BFA; +>>>.warning-row { + color: #1890FF; } </style> diff --git a/src/views/business/productOrder/components/cable-config.vue b/src/views/business/productOrder/components/cable-config.vue index e0f5de1..46c3e9e 100644 --- a/src/views/business/productOrder/components/cable-config.vue +++ b/src/views/business/productOrder/components/cable-config.vue @@ -384,7 +384,7 @@ display: flex; justify-content: space-between; } -.el-table .warning-row .cell { - color: #3A7BFA; +>>>.warning-row { + color: #1890FF; } </style> -- Gitblit v1.9.3