浏览代码

表格样式调整

chenrui 3 年之前
父节点
当前提交
eee863d9cf

+ 1 - 0
src/components/index.less

@@ -354,6 +354,7 @@
         font-weight: bold;
         color: #000!important;
         padding: 5px!important;
+        text-align: center!important;
       }
     }
   }

+ 14 - 14
src/views/salesManagement/examineVerify/list.vue

@@ -97,7 +97,7 @@
         :rowKey="(record) => record.id"
         :columns="columns"
         :data="loadData"
-        :scroll="{ x: 1570, y:tableHeight }"
+        :scroll="{ y:tableHeight }"
         :defaultLoadData="false"
         bordered>
         <!-- 下推单号 -->
@@ -158,19 +158,19 @@ export default {
       },
       disabled: false, //  查询、重置按钮是否可操作
       columns: [
-        { title: '序号', dataIndex: 'no', width: 70, align: 'center' },
-        { title: '创建时间', dataIndex: 'createDate', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '单据来源', dataIndex: 'salesBillEntity.salesBillSourceDictValue', width: 80, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '销售单号', dataIndex: 'salesBillNo', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '备货单号', scopedSlots: { customRender: 'dispatchBillNo' }, align: 'center' },
-        { title: '出库单号', dataIndex: 'stockOutNo', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '客户名称', dataIndex: 'buyerName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '数量', dataIndex: 'totalQty', width: 80, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '售价', dataIndex: 'totalAmount', width: 80, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '备货时间', dataIndex: 'stockUpDate', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '业务状态', dataIndex: 'billStatusDictValue', width: 80, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '打印次数', dataIndex: 'stockUpPrintTimes', width: 80, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '操作', scopedSlots: { customRender: 'action' }, width: 100, align: 'center', fixed: 'right' }
+        { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
+        { title: '创建时间', dataIndex: 'createDate', width: '7%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '单据来源', dataIndex: 'salesBillEntity.salesBillSourceDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '销售单号', dataIndex: 'salesBillNo', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '备货单号', scopedSlots: { customRender: 'dispatchBillNo' }, width: '12%', align: 'center' },
+        { title: '出库单号', dataIndex: 'stockOutNo', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '客户名称', dataIndex: 'buyerName', width: '11%', align: 'left', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '数量', dataIndex: 'totalQty', width: '5%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '售价', dataIndex: 'totalAmount', width: '5%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '备货时间', dataIndex: 'stockUpDate', width: '7%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '业务状态', dataIndex: 'billStatusDictValue', width: '5%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '打印次数', dataIndex: 'stockUpPrintTimes', width: '5%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '操作', scopedSlots: { customRender: 'action' }, width: '8%', align: 'center' }
       ],
       selectedRowKeys: [], // Check here to configure the default column
       loading: false,

+ 12 - 12
src/views/salesManagement/outboundOrder/list.vue

@@ -90,7 +90,7 @@
         :rowKey="(record) => record.stockOutSn"
         :columns="columns"
         :data="loadData"
-        :scroll="{ x: 1440, y: tableHeight }"
+        :scroll="{ y: tableHeight }"
         :defaultLoadData="false"
         bordered>
         <!-- 单号 -->
@@ -158,17 +158,17 @@ export default {
       },
       disabled: false, //  查询、重置按钮是否可操作
       columns: [
-        { title: '创建时间', dataIndex: 'createDate', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '审核时间', dataIndex: 'auditTime', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '出库单号', scopedSlots: { customRender: 'stockOutNo' }, width: 180, align: 'center' },
-        { title: '业务单号', dataIndex: 'outBizNo', width: 180, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '出库类型', dataIndex: 'outBizTypeDictValue', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '客户名称', dataIndex: 'demanderName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '数量', dataIndex: 'productTotalQty', width: 80, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '售价', dataIndex: 'productTotalPrice', width: 80, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '出库时间', dataIndex: 'outTime', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '出库状态', dataIndex: 'stateDictValue', width: 80, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '操作', scopedSlots: { customRender: 'action' }, width: 80, align: 'center', fixed: 'right' }
+        { title: '创建时间', dataIndex: 'createDate', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '审核时间', dataIndex: 'auditTime', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '出库单号', scopedSlots: { customRender: 'stockOutNo' }, width: '15%', align: 'center' },
+        { title: '业务单号', dataIndex: 'outBizNo', width: '15%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '出库类型', dataIndex: 'outBizTypeDictValue', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '客户名称', dataIndex: 'demanderName', width: '12%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '数量', dataIndex: 'productTotalQty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '售价', dataIndex: 'productTotalPrice', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '出库时间', dataIndex: 'outTime', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '出库状态', dataIndex: 'stateDictValue', width: '7%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '操作', scopedSlots: { customRender: 'action' }, width: '7%', align: 'center' }
       ],
       selectedRowKeys: [], // Check here to configure the default column
       selectedRows: [],

+ 17 - 17
src/views/salesManagement/pushOrderManagement/detail.vue

@@ -71,7 +71,7 @@
           :rowKey="(record) => record.id"
           :columns="($route.params.type=='stockOut' || outBizSubSn) ? outColumns : columns"
           :data="loadData"
-          :scroll="{ x: 1030, y: 500 }"
+          :scroll="{ y: 500 }"
           :defaultLoadData="false"
           bordered>
           <!-- 产品编码 -->
@@ -114,23 +114,23 @@ export default {
       spinning: false,
       // 表头
       columns: [
-        { title: '序号', dataIndex: 'no', width: 70, align: 'center' },
-        { title: '产品编码', dataIndex: 'productCode', width: 180, scopedSlots: { customRender: 'productCode' }, align: 'center' },
-        { title: '产品名称', dataIndex: 'productName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '原厂编码', dataIndex: 'productOrigCode', width: 180, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '单位', dataIndex: 'productOrigUnit', width: 60, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '销售价格', dataIndex: 'price', width: 80, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '销售数量', dataIndex: 'salesQty', width: 80, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '本次下推数', dataIndex: 'qty', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '本次下推金额', dataIndex: 'totalAmount', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } }
+        { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
+        { title: '产品编码', dataIndex: 'productCode', width: '19%', scopedSlots: { customRender: 'productCode' }, align: 'center' },
+        { title: '产品名称', dataIndex: 'productName', width: '10%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '原厂编码', dataIndex: 'productOrigCode', width: '19%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '单位', dataIndex: 'productOrigUnit', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '销售价格', dataIndex: 'price', width: '8%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '销售数量', dataIndex: 'salesQty', width: '8%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '本次下推数', dataIndex: 'qty', width: '8%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '本次下推金额', dataIndex: 'totalAmount', width: '8%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } }
       ],
       outColumns: [
-        { title: '序号', dataIndex: 'no', width: 70, align: 'center' },
-        { title: '产品编码', dataIndex: 'productCode', width: 180, scopedSlots: { customRender: 'productCode' }, align: 'center' },
-        { title: '产品名称', dataIndex: 'productName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '原厂编码', dataIndex: 'productOrigCode', width: 180, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '单位', dataIndex: 'productOrigUnit', width: 60, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '本次出库数', dataIndex: 'qty', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } }
+        { title: '序号', dataIndex: 'no', width: '6%', align: 'center' },
+        { title: '产品编码', dataIndex: 'productCode', width: '25%', scopedSlots: { customRender: 'productCode' }, align: 'center' },
+        { title: '产品名称', dataIndex: 'productName', width: '33%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '原厂编码', dataIndex: 'productOrigCode', width: '20%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '单位', dataIndex: 'productOrigUnit', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '本次出库数', dataIndex: 'qty', width: '10%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } }
       ],
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
@@ -177,7 +177,7 @@ export default {
       })
     },
     // 导出Excel
-    handleExcelOk(priceType){
+    handleExcelOk (priceType) {
       const _this = this
       const params = {
         dispatchBillSn: this.outBizSubSn || this.$route.params.sn,

+ 11 - 11
src/views/salesManagement/pushOrderManagement/list.vue

@@ -82,7 +82,7 @@
         :rowKey="(record) => record.id"
         :columns="columns"
         :data="loadData"
-        :scroll="{ x: 1270, y:tableHeight }"
+        :scroll="{ y:tableHeight }"
         :defaultLoadData="false"
         bordered>
         <!-- 销售单号 -->
@@ -134,18 +134,18 @@ export default {
       },
       // 表头
       columns: [
-        { title: '序号', dataIndex: 'no', width: 70, align: 'center' },
+        { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
         // { title: '区域', dataIndex: 'shippingAddrCountyName', width: 120, align: 'center' },
         // { title: '省份', dataIndex: 'shippingAddrProvinceName', width: 120, align: 'center' },
-        { title: '创建时间', dataIndex: 'createDate', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '备货单号', scopedSlots: { customRender: 'dispatchBillNo' }, width: 180, align: 'center' },
-        { title: '关联销售单号', scopedSlots: { customRender: 'salesBillNo' }, width: 180, align: 'center' },
-        { title: '客户名称', dataIndex: 'buyerName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '下推数量', dataIndex: 'totalQty', width: 80, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '下推金额', dataIndex: 'totalAmount', width: 80, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '备货时间', dataIndex: 'stockUpDate', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '出库时间', dataIndex: 'stockOutDate', width: 140, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '业务状态', dataIndex: 'billStatusDictValue', width: 80, align: 'center' }
+        { title: '创建时间', dataIndex: 'createDate', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '备货单号', scopedSlots: { customRender: 'dispatchBillNo' }, width: '14%', align: 'center' },
+        { title: '关联销售单号', scopedSlots: { customRender: 'salesBillNo' }, width: '14%', align: 'center' },
+        { title: '客户名称', dataIndex: 'buyerName', width: '14%', align: 'left', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '下推数量', dataIndex: 'totalQty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '下推金额', dataIndex: 'totalAmount', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '备货时间', dataIndex: 'stockUpDate', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '出库时间', dataIndex: 'stockOutDate', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '业务状态', dataIndex: 'billStatusDictValue', width: '6%', align: 'center' }
       ],
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {