lilei 5 月之前
父节点
当前提交
9009cfdbbe

+ 1 - 1
public/version.json

@@ -1,5 +1,5 @@
 {
   "message": "发现有新版本发布,确定更新系统?",
   "vendorJsVersion": "",
-  "version": 1734511158046
+  "version": 1736736054861
 }

+ 6 - 6
src/views/purchasingManagement/purchaseOrder/basicInfoModal.vue

@@ -27,13 +27,13 @@
           </a-radio-group>
           <span v-else>没有可选择的供应商</span>
         </a-form-model-item>
-        <a-form-model-item label="产品类型" prop="orderType" v-if="systemFlag==1">
+        <a-form-model-item label="订单类型" prop="orderType" v-if="systemFlag==1">
           <v-select
             code="ORDER_TYPE"
             id="purchaseOrder-basicInfo-orderType"
             v-model="form.orderType"
             allowClear
-            placeholder="请选择产品类型"
+            placeholder="请选择订单类型"
             showType="radio"
           ></v-select>
         </a-form-model-item>
@@ -99,13 +99,13 @@ export default {
         settleStyleSn: undefined, //  支付方式
         purchaseTargetSn: undefined, // 供应商
         purchaseTargetName: '', // 供应商名称
-        orderType: undefined // 产品类型
+        orderType: undefined // 订单类型
       },
       rules: {
         purchaseTargetSn: [
           { required: true, message: '请选择供应商', trigger: 'change' }
         ],
-        orderType: [{ required: true, message: '请选择产品类型', trigger: 'change' }],
+        orderType: [{ required: true, message: '请选择订单类型', trigger: 'change' }],
         settleStyleSn: [
           { required: true, message: '请选择支付方式', trigger: 'change' }
         ],
@@ -118,7 +118,7 @@ export default {
       chooseAddr: '', //  当前已选地址信息
       addressId: undefined, // 地址id
       openAddrModal: false, // 选择地址弹框是否显示
-      systemFlag: null// 产品类型显示不显示
+      systemFlag: null// 订单类型显示不显示
     }
   },
   methods: {
@@ -238,7 +238,7 @@ export default {
         }
       })
     },
-    // 获取系统参数  判断是否显示产品类型
+    // 获取系统参数  判断是否显示订单类型
     getSystemInfo () {
       getParamValue({ code: 'TIRE_OPEN' }).then(res => {
         if (res.status == 200) {

+ 1 - 0
src/views/purchasingManagement/purchaseOrder/detail.vue

@@ -29,6 +29,7 @@
           <a-collapse-panel key="1" header="基础信息">
             <a-descriptions :column="3">
               <a-descriptions-item label="供应商">{{ (detail&&detail.purchaseTargetName) || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="订单类型">{{ detail&&detail.orderTypeDictValue || '--' }}</a-descriptions-item>
               <a-descriptions-item label="支付方式">{{ (detail&&detail.settleStyleSnDictValue) || '--' }}</a-descriptions-item>
               <a-descriptions-item label="采购员工" v-if="detail&&detail.purchaseBillSource=='PURCHASE'">{{ detail&&detail.operatorName || '--' }}</a-descriptions-item>
               <a-descriptions-item label="收货人">{{ detail&&detail.consigneeName || '--' }}<span v-if="detail&&detail.consigneeTel">({{ detail&&detail.consigneeTel }})</span></a-descriptions-item>

+ 42 - 21
src/views/purchasingManagement/purchaseOrder/list.vue

@@ -90,8 +90,20 @@
         </a-form>
       </div>
       <!-- 操作按钮 -->
-      <div class="table-operator">
-        <a-button id="purchaseOrderList-add" type="primary" v-if="$hasPermissions('B_purchaseNew')&&($hasPermissions('B_SUPPLIER_SJ')||$hasPermissions('B_SUPPLIER_ZB'))" class="button-error" @click="handleAdd">新增</a-button>
+      <div class="table-operator" style="display:flex;align-items: center;justify-content: space-between;">
+        <div>
+          <a-button id="purchaseOrderList-add" type="primary" v-if="$hasPermissions('B_purchaseNew')&&($hasPermissions('B_SUPPLIER_SJ')||$hasPermissions('B_SUPPLIER_ZB'))" class="button-error" @click="handleAdd">新增</a-button>
+        </div>
+        <div>
+          <a-dropdown v-model="showCell">
+            <a-button type="link" class="button-default" id="purchaseOrderList-showCell"> <a-icon type="setting" />  显示</a-button>
+            <a-menu slot="overlay">
+              <a-menu-item>
+                <a-checkbox v-model="showOrderType" id="purchaseOrderList-orderType">订单类型</a-checkbox>
+              </a-menu-item>
+            </a-menu>
+          </a-dropdown>
+        </div>
       </div>
       <!-- alert -->
       <a-alert type="info" style="margin-bottom:10px">
@@ -176,7 +188,6 @@ export default {
   components: { STable, VSelect, basicInfoModal, rangeDate, stateIcon },
   mixins: [commonMixin],
   data () {
-    const _this = this
     return {
       spinning: false,
       advanced: true, //  高级搜索 展开/关闭
@@ -206,24 +217,8 @@ export default {
         totalQty: 0, // 总数量
         totalAmount: 0// 总金额
       },
-      // 表头
-      columns: [
-        { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
-        { title: '采购单号', scopedSlots: { customRender: 'purchaseBillNo' }, width: '13%', align: 'center' },
-        { title: '创建时间', dataIndex: 'createDate', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '供应商', dataIndex: 'purchaseTargetName', width: '10%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '产品款数', dataIndex: 'totalCategory', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '采购数量', dataIndex: 'totalQty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '采购金额', dataIndex: 'discountedAmount', width: '6%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } },
-        { title: '审核数量', dataIndex: 'totalPushedQty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '审核金额', dataIndex: 'totalPushedAmount', width: '6%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } },
-        { title: '已取消数量', dataIndex: 'totalCancelQty', width: '7%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '采购状态', dataIndex: 'billStatusDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '审核', scopedSlots: { customRender: 'audit' }, width: '3%', align: 'center' },
-        { title: '入库', scopedSlots: { customRender: 'waitOut' }, width: '3%', align: 'center' },
-        { title: '付款', scopedSlots: { customRender: 'financial' }, width: '3%', align: 'center' },
-        { title: '操作', scopedSlots: { customRender: 'action' }, width: '9%', align: 'center' }
-      ],
+      showCell: false, // 是否显示自定义列
+      showOrderType: false, // 是否显示订单类型
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
@@ -250,6 +245,32 @@ export default {
       }
     }
   },
+  computed: {
+    columns () {
+      const _this = this
+      const arr = [
+        { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
+        { title: '采购单号', scopedSlots: { customRender: 'purchaseBillNo' }, width: '13%', align: 'center' },
+        { title: '创建时间', dataIndex: 'createDate', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '供应商', dataIndex: 'purchaseTargetName', width: '10%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '产品款数', dataIndex: 'totalCategory', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '采购数量', dataIndex: 'totalQty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '采购金额', dataIndex: 'discountedAmount', width: '6%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } },
+        { title: '审核数量', dataIndex: 'totalPushedQty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '审核金额', dataIndex: 'totalPushedAmount', width: '6%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } },
+        { title: '已取消数量', dataIndex: 'totalCancelQty', width: '7%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '采购状态', dataIndex: 'billStatusDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '审核', scopedSlots: { customRender: 'audit' }, width: '3%', align: 'center' },
+        { title: '入库', scopedSlots: { customRender: 'waitOut' }, width: '3%', align: 'center' },
+        { title: '付款', scopedSlots: { customRender: 'financial' }, width: '3%', align: 'center' },
+        { title: '操作', scopedSlots: { customRender: 'action' }, width: '9%', align: 'center' }
+      ]
+      if (this.showOrderType) {
+        arr.splice(4, 0, { title: '订单类型', dataIndex: 'orderTypeDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } })
+      }
+      return arr
+    }
+  },
   methods: {
     // 统计信息
     getTotalData (params) {

+ 6 - 6
src/views/purchasingManagement/purchaseOrderNew/basicInfoModal.vue

@@ -27,13 +27,13 @@
           </a-radio-group>
           <span v-else>没有可选择的供应商</span>
         </a-form-model-item>
-        <a-form-model-item label="产品类型" prop="orderType" v-if="systemFlag==1">
+        <a-form-model-item label="订单类型" prop="orderType" v-if="systemFlag==1">
           <v-select
             code="ORDER_TYPE"
             id="purchaseOrder-basicInfo-orderType"
             v-model="form.orderType"
             allowClear
-            placeholder="请选择产品类型"
+            placeholder="请选择订单类型"
             showType="radio"
           ></v-select>
         </a-form-model-item>
@@ -99,13 +99,13 @@ export default {
         settleStyleSn: undefined, //  支付方式
         purchaseTargetSn: undefined, // 供应商sn
         purchaseTargetName: '', // 供应商名称
-        orderType: undefined // 产品类型
+        orderType: undefined // 订单类型
       },
       rules: {
         purchaseTargetSn: [
           { required: true, message: '请选择供应商', trigger: 'change' }
         ],
-        orderType: [{ required: true, message: '请选择产品类型', trigger: 'change' }],
+        orderType: [{ required: true, message: '请选择订单类型', trigger: 'change' }],
         settleStyleSn: [
           { required: true, message: '请选择支付方式', trigger: 'change' }
         ],
@@ -118,7 +118,7 @@ export default {
       chooseAddr: '', //  当前已选地址信息
       addressId: undefined, // 地址id
       openAddrModal: false, // 选择地址弹框是否显示
-      systemFlag: null// 产品类型显示不显示
+      systemFlag: null// 订单类型显示不显示
     }
   },
   methods: {
@@ -238,7 +238,7 @@ export default {
         }
       })
     },
-    // 获取系统参数  判断是否显示产品类型
+    // 获取系统参数  判断是否显示订单类型
     getSystemInfo () {
       getParamValue({ code: 'TIRE_OPEN' }).then(res => {
         if (res.status == 200) {

+ 1 - 0
src/views/purchasingManagement/purchaseOrderNew/detail.vue

@@ -37,6 +37,7 @@
         <a-descriptions :column="3" size="small">
           <div slot="title">基础信息</div>
           <a-descriptions-item label="供应商">{{ (detail&&detail.purchaseTargetName) || '--' }}</a-descriptions-item>
+          <a-descriptions-item label="订单类型">{{ detail&&detail.orderTypeDictValue || '--' }}</a-descriptions-item>
           <a-descriptions-item label="支付方式">{{ (detail&&detail.settleStyleSnDictValue) || '--' }}</a-descriptions-item>
           <a-descriptions-item label="采购员工" v-if="detail&&detail.purchaseBillSource=='PURCHASE'">{{ detail&&detail.operatorName || '--' }}</a-descriptions-item>
           <a-descriptions-item label="收货人">{{ detail&&detail.consigneeName || '--' }}<span v-if="detail&&detail.consigneeTel">({{ detail&&detail.consigneeTel }})</span></a-descriptions-item>

+ 36 - 19
src/views/purchasingManagement/purchaseOrderNew/list.vue

@@ -97,6 +97,14 @@
           </div>
           <div class="action-buttons">
             <a-button id="purchaseOrderList-add" type="primary" v-if="$hasPermissions('B_purchaseNew')&&($hasPermissions('B_SUPPLIER_SJ')||$hasPermissions('B_SUPPLIER_ZB'))" @click="handleAdd"><a-icon type="plus" />新增</a-button>
+            <a-dropdown v-model="showCell">
+              <a-button type="link" class="button-default" id="purchaseOrderList-showCell"> <a-icon type="setting" />  显示</a-button>
+              <a-menu slot="overlay">
+                <a-menu-item>
+                  <a-checkbox v-model="showOrderType" id="purchaseOrderList-orderType">订单类型</a-checkbox>
+                </a-menu-item>
+              </a-menu>
+            </a-dropdown>
           </div>
         </div>
         <!-- 列表 -->
@@ -171,7 +179,6 @@ export default {
   components: { STable, VSelect, basicInfoModal, rangeDate, stateIcon },
   mixins: [commonMixin],
   data () {
-    const _this = this
     return {
       spinning: false,
       advanced: true, //  高级搜索 展开/关闭
@@ -201,24 +208,8 @@ export default {
         totalQty: 0, // 总数量
         totalAmount: 0 // 总金额
       },
-      // 表头
-      columns: [
-        { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
-        { title: '采购单号', scopedSlots: { customRender: 'purchaseBillNo' }, width: '13%', align: 'center' },
-        { title: '创建时间', dataIndex: 'createDate', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '供应商', dataIndex: 'purchaseTargetName', width: '10%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '产品款数', dataIndex: 'totalCategory', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '采购数量', dataIndex: 'totalQty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '采购金额', dataIndex: 'discountedAmount', width: '6%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } },
-        { title: '审核数量', dataIndex: 'totalPushedQty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '审核金额', dataIndex: 'totalPushedAmount', width: '6%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } },
-        { title: '已取消数量', dataIndex: 'totalCancelQty', width: '7%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '采购状态', dataIndex: 'billStatusDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '审核', scopedSlots: { customRender: 'audit' }, width: '3%', align: 'center' },
-        { title: '入库', scopedSlots: { customRender: 'waitOut' }, width: '3%', align: 'center' },
-        { title: '付款', scopedSlots: { customRender: 'financial' }, width: '3%', align: 'center' },
-        { title: '操作', scopedSlots: { customRender: 'action' }, width: '9%', align: 'center' }
-      ],
+      showCell: false, // 是否显示自定义列
+      showOrderType: false, // 是否显示订单类型
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
@@ -245,6 +236,32 @@ export default {
       }
     }
   },
+  computed: {
+    columns () {
+      const _this = this
+      const arr = [
+        { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
+        { title: '采购单号', scopedSlots: { customRender: 'purchaseBillNo' }, width: '13%', align: 'center' },
+        { title: '创建时间', dataIndex: 'createDate', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '供应商', dataIndex: 'purchaseTargetName', width: '10%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '产品款数', dataIndex: 'totalCategory', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '采购数量', dataIndex: 'totalQty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '采购金额', dataIndex: 'discountedAmount', width: '6%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } },
+        { title: '审核数量', dataIndex: 'totalPushedQty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '审核金额', dataIndex: 'totalPushedAmount', width: '6%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text, 2) : '--') } },
+        { title: '已取消数量', dataIndex: 'totalCancelQty', width: '7%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '采购状态', dataIndex: 'billStatusDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '审核', scopedSlots: { customRender: 'audit' }, width: '3%', align: 'center' },
+        { title: '入库', scopedSlots: { customRender: 'waitOut' }, width: '3%', align: 'center' },
+        { title: '付款', scopedSlots: { customRender: 'financial' }, width: '3%', align: 'center' },
+        { title: '操作', scopedSlots: { customRender: 'action' }, width: '9%', align: 'center' }
+      ]
+      if (this.showOrderType) {
+        arr.splice(4, 0, { title: '订单类型', dataIndex: 'orderTypeDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } })
+      }
+      return arr
+    }
+  },
   methods: {
     // 统计信息
     getTotalData (params) {