xiaodai2017 il y a 2 ans
Parent
commit
9c2b96fc1a

+ 1 - 1
src/views/InvoiceSales/capitalClaim/claim.vue

@@ -4,7 +4,7 @@ import ClaimDetail from "./components/claim-detail/index.vue";
 
 <template>
   <div class="invoice__content" bg-white>
-    <h1 mb-2 font-bold>认领详情</h1>
+    <h1 mb-2 font-bold>资金详情</h1>
     <ClaimDetail />
   </div>
 </template>

+ 27 - 8
src/views/InvoiceSales/capitalClaim/components/basic-claim/receipt-payment.vue

@@ -13,17 +13,36 @@ defineProps<{
 <template>
   <div flex gap-10>
     <el-descriptions :column="1" border flex-1 size="small">
-      <el-descriptions-item title="  " v-for="(item, index) in public_columns" :key="index" :label="item.label">{{
-      tradeInfo[item.field] }}</el-descriptions-item>
+      <el-descriptions-item
+        title="  "
+        v-for="(item, index) in public_columns"
+        :key="index"
+        :label="item.label"
+      >
+        <template>
+          <slot v-if="item.slot" />
+        </template>
+        <template>
+          {{ tradeInfo[item.field] }}
+        </template>
+      </el-descriptions-item>
     </el-descriptions>
-    <el-descriptions title="付款方" :column="1" border flex-1 size="small">
-      <el-descriptions-item v-for="(item, index) in description_columns_out" :key="index" :label="item.label">{{
-      tradeInfo[item.field] }}</el-descriptions-item>
+    <el-descriptions :column="1" border flex-1 size="small">
+      <el-descriptions-item
+        v-for="(item, index) in description_columns_out"
+        :key="index"
+        :label="item.label"
+        >{{ tradeInfo[item.field] }}</el-descriptions-item
+      >
     </el-descriptions>
 
-    <el-descriptions title="收款方" :column="1" border flex-1 size="small">
-      <el-descriptions-item v-for="(item, index) in description_columns_in" :key="index" :label="item.label">{{
-      tradeInfo[item.field] }}</el-descriptions-item>
+    <el-descriptions :column="1" border flex-1 size="small">
+      <el-descriptions-item
+        v-for="(item, index) in description_columns_in"
+        :key="index"
+        :label="item.label"
+        >{{ tradeInfo[item.field] }}</el-descriptions-item
+      >
     </el-descriptions>
   </div>
 </template>

+ 73 - 16
src/views/InvoiceSales/capitalClaim/config/configs.ts

@@ -1,3 +1,5 @@
+import { ElTag } from "element-plus";
+import { h } from "vue";
 export const order_columns = [
   {
     label: "订单编号",
@@ -83,32 +85,40 @@ export const order_status = [
 //收款方
 export const description_columns_in = [
   {
-    label: "编号",
+    label: "收款公司编码",
     field: "companyNo"
   },
   {
-    label: "公司名称",
-    field: "trade_in"
+    label: "收款公司名称",
+    field: "companyName"
   },
   {
-    label: "账户",
+    label: "收款公司账户",
     field: "trade_in_account"
-  },
-  {
-    label: "省市",
-    field: ""
   }
 ];
 
 //付款方
 export const description_columns_out = [
   {
-    label: "公司名称",
+    label: "付款单位名称",
     field: "trade_out"
   },
   {
     label: "账户",
     field: "trade_account"
+  },
+  {
+    label: "交易时间",
+    field: "trade_time"
+  },
+  {
+    label: "交易行名",
+    field: "trade_bank"
+  },
+  {
+    label: "省市",
+    field: ""
   }
 ];
 
@@ -118,17 +128,64 @@ export const public_columns = [
     field: "tradNo"
   },
   {
-    label: "交易银行",
-    field: "trade_bank"
-  },
-  {
-    label: "交易时间",
-    field: "trade_time"
-  },
+    label: "状态",
+    field: "status",
+    slot: "status",
+    render(status) {
+      return h(ElTag, null, {
+        default: () =>
+          status_options.find(s => s.value === String(status))?.label
+      });
+    }
+    // cellRenderer: ({ row, props }) =>
+    //   h(
+    //     ElTag,
+    //     {
+    //       size: "small"
+    //     },
+    //     {
+    //       default: () => {
+    //         return (
+    //           status_options.find(s => String(row.status) === String(s.value))
+    //             ?.label || "--"
+    //         );
+    //       }
+    //     }
+    //   )
+  },
+  {
+    label: "收入金额",
+    field: "total_fee"
+  },
+  {
+    label: "未认领金额",
+    field: "balance"
+  },
+  {
+    label: "已认领金额",
+    field: "used_fee"
+  },
+  // {
+  //   label: "收款公司账户",
+  //   field: "trade_in_account"
+  // },
+
   {
     label: "交易用途",
     field: "trade_used"
+  },
+  {
+    label: "新建时间",
+    field: "addtime"
   }
+  // {
+  //   label: "收款公司编码",
+  //   field: "companyNo"
+  // },
+  // {
+  //   label: "收款公司名称",
+  //   field: "companyName"
+  // }
 ];
 
 export const status_options = [

+ 3 - 2
src/views/InvoiceSales/capitalClaim/config/content.config.ts

@@ -1,7 +1,6 @@
 import { ContentConfig } from "/@/components/PageContent";
 import { httpList } from "/@/api/InvoiceSales/capitalClaim";
 
-import dayjs from "dayjs";
 import { h } from "vue";
 import { ElTag } from "element-plus";
 import { capital_status } from "./configs";
@@ -21,11 +20,13 @@ const columns = [
   // },
   {
     type: "expand",
-    slot: "expand"
+    slot: "expand",
+    fixed: "left"
   },
   {
     label: "资金编号",
     prop: "tradNo",
+    fixed: "left",
     width: 140
   },
   {

+ 1 - 1
src/views/InvoiceSales/capitalClaim/detail.vue

@@ -12,7 +12,7 @@ const id = computed(() => query.id as string);
 
 <template>
   <div class="invoice__content" bg-white>
-    <h1 mb-2 font-bold>资金详情</h1>
+    <h1 mb-2 font-bold>认领详情</h1>
     <CapitalClaim :id="id" />
   </div>
 </template>

+ 2 - 0
src/views/InvoiceSales/capitalClaim/index.vue

@@ -108,6 +108,7 @@ async function onDownloadOpenInv() {
         >
           <template #expand="row">
             <el-table
+              style="width: 100%"
               v-if="row.child.length > 0"
               size="small"
               :data="row.child"
@@ -117,6 +118,7 @@ async function onDownloadOpenInv() {
                 label="资金认领编号"
                 prop="logNo"
                 width="188"
+                fixed="left"
                 show-overflow-tooltip
               />
               <el-table-column