Sfoglia il codice sorgente

森语-搬运工详情

jbb 2 anni fa
parent
commit
be55d10b6b
1 ha cambiato i file con 44 aggiunte e 48 eliminazioni
  1. 44 48
      src/views/oa/modules/SyCarryDetailModal.vue

+ 44 - 48
src/views/oa/modules/SyCarryDetailModal.vue

@@ -76,7 +76,7 @@
         :columns="syCarryBTable.columns"
         :data-source="syCarryBTable.dataSource"
         :loading="syCarryBTable.loading"
-        :scroll="{x: 2000, y:300}"
+        :scroll="{x: 2500, y:300}"
         :pagination="false"
       >
         <!-- 操作 -->
@@ -127,14 +127,17 @@
   import { JEditableTableMixin } from '@/mixins/JEditableTableMixin'
   import { getAction } from '@/api/manage'
    import {fileDetail} from '@api/oa/cd-sy-carry'
+   import JEllipsis from '@/components/jeecg/JEllipsis'
 
   export default {
     name: 'SyCarryDetailModa',
     mixins: [JEditableTableMixin],
     components: {
         moment,
+        JEllipsis
     },
     data() {
+      let ellipsis = (v, l) => <j-ellipsis value={v} length={l} /> // 省略
       return {
         // 新增时子表默认添加几行空数据
         addDefaultRowNum: 1,
@@ -151,117 +154,106 @@
           loading: false,
           dataSource: [],
           columns: [
-            {
+          {
             title: '日期',
             align: "center",
             dataIndex: 'orderDate',
-            width: 140,
-            // scopedSlots: { customRender: 'orderDate' },
+            width: '6%',
+            ellipsis: true,
           },
           {
             title: '入库单号/发票号',
             align: "center",
             dataIndex: 'invoiceNo',
-            width: 140,
-            scopedSlots: { customRender: 'invoiceNo' },
+            width: '6%',
+            ellipsis: true,
           },
            {
             title: '总件数',
             dataIndex: 'allNum',
-            width: 100,
-            //  scopedSlots: { customRender: 'allNum' },
-             className: 'replacecolor'
+            width:  '5%',
+            ellipsis: true,
+             className: 'replacecolor',
            },
            {
             title: '柜子数量',
             dataIndex: 'cabinets',
-             width: 100,
+             width:  '5%',
              ellipsis: true,
-             scopedSlots: { customRender: 'cabinets' },
              className: 'replacecolor'
            },
            {
             title: '明细',
             dataIndex: 'detailedNum',
-           width: 100,
+             width:  '5%',
              ellipsis: true,
-            //  scopedSlots: { customRender: 'detailedNum' },
-             className: 'replacecolor'
+             className: 'replacecolor',
+            //  slots:{title:'detailedNumTitle'}
            },
            {
             title: '衣架/吨数',
             dataIndex: 'coatHanger',
-           width: 120,
+           width:'6%',
              ellipsis: true,
-            //  scopedSlots: { customRender: 'coatHanger' },
              className: 'replacecolor'
            },
            {
             title: '集装箱号',
             dataIndex: 'containerNo',
-           width: 160,
-             ellipsis: true,
-            //  scopedSlots: { customRender: 'containerNo' },
-             className: 'replacecolor'
+             width: '15%',
+             className: 'replacecolor',
+             customRender: (t) => ellipsis(t,40),
            },
            {
-            title: '单价',
-            dataIndex: 'price',
-           width: 100,
+             title: '单价',
+             dataIndex: 'price',
+             width: '5%',
              ellipsis: true,
-            //  scopedSlots: { customRender: 'price' },
-             className: 'replacecolor'
+             className: 'replacecolor',
            },
              {
             title: '总价',
             dataIndex: 'totalPrice',
-            width: 100,
+            width: '5%',
              ellipsis: true,
-             scopedSlots: { customRender: 'totalPrice' },
              className: 'replacecolor',
-            //  slots:{title:'totalPriceTitle'}
            },
            {
             title: '计划员',
-            dataIndex: 'jhyNameData',
-           width: 140,
-              ellipsis: true,
-            //  scopedSlots: { customRender: 'jhyName' },
-             className: 'replacecolor'
+            dataIndex: 'jhyByData',
+             width: '7%',
+             ellipsis: true,
+             className: 'replacecolor',
            },
-           
            {
             title: '签名',
             dataIndex: 'jhyName',
-            width: 100,
+            width: '5',
              ellipsis: true,
              className: 'replacecolor'
            },
-           {
-            title: '备注',
-            dataIndex: 'demo',
-           width: 200,
-             ellipsis: true,
-            //  scopedSlots: { customRender: 'demo' },
-             className: 'replacecolor'
-           },
            {
             title: '原因',
             dataIndex: 'reason',
-            width: 200,
+            width: '10%',
              ellipsis: true,
-             scopedSlots: { customRender: 'reason' },
              className: 'replacecolor',
-            //  slots:{title:'reasonTitle'}
            },
-            {
+           {
+            title: '备注',
+            dataIndex: 'demo',
+             width: '12%',
+             ellipsis: true,
+             className: 'replacecolor'
+           } ,
+           {
             title: '操作',
             dataIndex: 'option',
              width: 120,
              ellipsis: true,
              scopedSlots: { customRender: 'option' },
              className: 'replacecolor'
-           }           
+           }                     
           ]
         },
         url: {
@@ -396,4 +388,8 @@
 /deep/ .ant-table-tbody {
   text-align: center;
 }
+/deep/.ant-table-tbody>tr>td{
+  white-space: break-spaces;
+}
+
 </style>