Browse Source

Merge remote-tracking branch 'origin/xq'

13660505945 1 week ago
parent
commit
6b1bab0f45

+ 43 - 3
jshERP-web/src/views/system/VendorList.vue

@@ -77,6 +77,12 @@
               <a-tag v-if="enabled" color="green">启用</a-tag>
               <a-tag v-if="!enabled" color="orange">禁用</a-tag>
             </template>
+            <template slot="settlementMethod" slot-scope="text, record">
+              {{ formateSettle(record.settlementMethod) }}
+            </template>
+            <template slot="invoiceType" slot-scope="text, record">
+              {{ formateInVoiceType(record.invoiceType) }}
+            </template>
           </a-table>
         </div>
         <!-- table区域-end -->
@@ -146,13 +152,25 @@ export default {
         { title: '联系电话', dataIndex: 'phoneNum', width: 100, align: 'left' },
         { title: '电子邮箱', dataIndex: 'email', width: 150, align: 'left' },
         { title: '税率(%)', dataIndex: 'taxRate', width: 80, align: 'left' },
-        { title: '排序', dataIndex: 'sort', width: 60, align: 'left' },
         { title: '供应商分级', dataIndex: 'supplierLevel', width: 100, align: 'left' },
-        { title: '结算方式', dataIndex: 'settlementMethod', width: 80, align: 'left' },
+        {
+          title: '结算方式',
+          dataIndex: 'settlementMethod',
+          width: 80,
+          align: 'left',
+          scopedSlots: { customRender: 'settlementMethod' },
+        },
         { title: '账单周期', dataIndex: 'billingCycleDays', width: 80, align: 'left' },
         { title: '采购对接人', dataIndex: 'procurementContact', width: 100, align: 'left' },
         { title: '到货天数', dataIndex: 'deliverydays', width: 80, align: 'left' },
-        { title: '发票类型', dataIndex: 'invoiceType', width: 80, align: 'left' },
+        {
+          title: '发票类型',
+          dataIndex: 'invoiceType',
+          width: 80,
+          align: 'left',
+          scopedSlots: { customRender: 'invoiceType' },
+        },
+        { title: '排序', dataIndex: 'sort', width: 60, align: 'left' },
         {
           title: '状态',
           dataIndex: 'enabled',
@@ -199,6 +217,28 @@ export default {
         this.$refs.modalForm.isReadOnly = true
       }
     },
+    formateSettle(val) {
+      switch (val) {
+        case '0':
+          return '周结'
+        case '1':
+          return '现结/按单'
+        case '2':
+          return '预付款'
+        case '3':
+          return '月结'
+      }
+    },
+    formateInVoiceType(val) {
+      switch (val) {
+        case '1':
+          return '增值税专用发票'
+        case '0':
+          return '普通发票'
+        default:
+          return ''
+      }
+    },
   },
 }
 </script>

+ 3 - 7
jshERP-web/src/views/system/modules/VendorModal.vue

@@ -206,16 +206,12 @@ export default {
       ],
       invoiceOptions: [
         {
-          value: '0',
-          label: '不开具发票',
-        },
-        {
           value: '1',
-          label: '开具增值税专用发票',
+          label: '增值税专用发票',
         },
         {
-          value: '2',
-          label: '开具增值税普通发票',
+          value: '0',
+          label: '普通发票',
         },
       ],
     }