Browse Source

检品机字体颜色优化

zck 1 year ago
parent
commit
854046d59e
1 changed files with 17 additions and 1 deletions
  1. 17 1
      src/view/yunyin/shengchanguanli/shebeiyunxing.vue

+ 17 - 1
src/view/yunyin/shengchanguanli/shebeiyunxing.vue

@@ -929,7 +929,7 @@
 			  						v-else
 			  						:show-overflow-tooltip="true"
 			  						@selection-change="selectionChange($event)"
-			  						:row-style="{ height: '20px' }" :row-class-name="totalClassName"
+			  						:row-style="{ height: '20px' }" :row-class-name="totalClassName" :cell-class-name="tableDataCellClass"
 			  						:cell-style="{ padding: '0px' }" :header-row-style="{ height: '20px' }"
 			  						:header-cell-style="{ padding: '0px' }" @row-click="getUid"
 			  						highlight-current-row="true" @row-dblclick="JPgytableDatadoubleClick"
@@ -2627,9 +2627,19 @@ if (sortedTotalB.length !== 0) {
 
 // 定义方法来确定合计行的CSS类名
 function totalClassName({ row }) {
+	console.log(row)
+	// if (row.计件箱数===	) {
+
+	// }
   return row.isTotal ? 'total-row' : '';
 }
 
+//表格文字颜色
+const tableDataCellClass = ({row, column, rowIndex, columnIndex}) =>{
+  if (column.property === '计件箱数'||column.property === '每箱数量') {
+    return 'plan-usage-low';
+  }
+}
 const hesuanVisible = ref(false)
 const MachineVisible = ref(false)
 const machineData = reactive([])
@@ -7973,6 +7983,12 @@ const sbzyqdsatusCellClass = ({row, column, rowIndex, columnIndex}) =>{
   background-color: yellow !important; /* 或者你想要的任何颜色 */
 }
 
+:deep(.plan-usage-low div) {
+  color: red !important;
+  font-size: 14px;
+  font-weight: normal;
+}
+
 /* tree组件背景高亮 */
 :deep(.el-tree-node:focus > .el-tree-node__content){
 		background: #ff80ff !important;