zhangafei 2 周之前
父節點
當前提交
aa6e7f3661
共有 2 個文件被更改,包括 31 次插入14 次删除
  1. 26 13
      src/views/billet/operator/components/heatList.vue
  2. 5 1
      src/views/billet/operator/index.vue

+ 26 - 13
src/views/billet/operator/components/heatList.vue

@@ -1,5 +1,5 @@
 <template>
-  <div class="cc-heatList">
+  <div class="cc-heatList flex flex-col">
     <div class="tips-title flex" v-if="showAction">
       <div class="left-tip">当班浇铸炉次</div>
       <div class="flex flex-1 items-center" style="display: none">
@@ -21,15 +21,17 @@
         </div>
       </div>
     </div>
-    <!--引用表格-->
-    <BasicTable @register="registerTable">
-      <!--操作栏-->
-      <template #action="{ record }">
-        <TableAction class="flex flex-col" style="gap: 4px" :actions="getTableAction(record)" />
-      </template>
-      <!--字段回显插槽-->
-      <!-- <template v-slot:bodyCell="{ column, record, index, text }"> </template> -->
-    </BasicTable>
+    <div class="current-table-list flex-1">
+      <!--引用表格-->
+      <BasicTable @register="registerTable">
+        <!--操作栏-->
+        <template #action="{ record }">
+          <TableAction class="flex flex-col" style="gap: 4px" :actions="getTableAction(record)" />
+        </template>
+        <!--字段回显插槽-->
+        <!-- <template v-slot:bodyCell="{ column, record, index, text }"> </template> -->
+      </BasicTable>
+    </div>
     <BasicTable @register="registerExtraTable" v-if="otherShiftTableData.length > 0" :dataSource="otherShiftTableData">
       <!--操作栏-->
       <template #action="{ record }">
@@ -131,10 +133,14 @@
         let cunShift: any[] = [],
           otherShift: any[] = [];
         data.forEach((item) => {
-          if (item.shift === props.curShiftInfo.shift && item.shiftGroup === props.curShiftInfo.shiftGroup) {
+          if (!props.curShiftInfo.shift && !props.curShiftInfo.shiftGroup) {
             cunShift.push(item);
           } else {
-            otherShift.push(item);
+            if (item.shift === props.curShiftInfo.shift && item.shiftGroup === props.curShiftInfo.shiftGroup) {
+              cunShift.push(item);
+            } else {
+              otherShift.push(item);
+            }
           }
         });
 
@@ -155,7 +161,7 @@
       },
       columns,
       showIndexColumn: false,
-      canResize: props.canResize,
+      canResize: false,
       striped: true,
       showTableSetting: false,
       pagination: false,
@@ -453,6 +459,9 @@
 
 <style scoped lang="less">
   .cc-heatList {
+    height: 100%;
+    overflow: hidden;
+
     .tips-title {
       color: #fff;
       font-size: 18px;
@@ -466,6 +475,10 @@
       }
     }
 
+    .current-table-list {
+      overflow: auto;
+    }
+
     .jeecg-basic-table {
       padding: 0;
     }

+ 5 - 1
src/views/billet/operator/index.vue

@@ -20,6 +20,7 @@
         <div class="operator-content-wrapper flex">
           <div class="operator-content-left">
             <heat-list
+              v-if="curShiftInfo.shift != undefined && curShiftInfo.shiftGroup != undefined"
               :ccmNo="ccmNo"
               :carRef="carRef"
               :lengthList="lengthList"
@@ -52,7 +53,10 @@
   const headTopRef = ref();
   // 班次信息
   const shiftText = ref('');
-  const curShiftInfo = ref({});
+  const curShiftInfo = ref({
+    shift: undefined,
+    shiftGroup: undefined,
+  });
   // 时钟
   const clockObj = ref({
     date: '',