liqh 3 месяцев назад
Родитель
Сommit
62bca59221

+ 49 - 40
src/views/project/cost-manage/loan-manage/index.vue

@@ -17,44 +17,52 @@
     showIndexColumn: true,
     search: [
       {
-        label: '项目名称',
-        field: 'deliveryName',
+        label: '申请人',
+        field: 'applicant',
         type: 'input',
         attrs: {},
       },
-      {
-        label: '客户名称',
-        field: 'customerName',
-        type: 'input',
-        attrs: {},
-      },
-      {
-        label: '项目状态',
-        field: 'deliveryStatus',
-        type: 'select',
-        options: useDict.type.MATE_DELIVERY_STATUS,
-        attrs: {},
-      },
     ],
     columns: [
       {
-        title: '借款人',
-        dataIndex: 'applicant',
+        title: '状态',
+        dataIndex: 'state',
         align: 'center',
-        width: '150px',
+        width: '80px',
         ellipsis: true,
+        customRender: ({ text, record, index, column }) => {
+          const { state } = record;
+          let stateName;
+          switch (state) {
+            case '2':
+              stateName = '进行中';
+              break;
+            case '4':
+              stateName = '办结';
+              break;
+            default:
+              stateName = 'default';
+          }
+          return (
+            <div class='smart-table-operate'>
+              <a-tag>{stateName}</a-tag>
+            </div>
+          );
+        },
       },
       {
-        title: '借款金额',
-        dataIndex: 'loanAmount',
+        title: '申请人',
+        dataIndex: 'applicant',
         align: 'center',
         width: '100px',
         ellipsis: true,
+        customRender: ({ text, record, index, column }) => {
+          return <div class='smart-table-operate'>{record.applicant.actualName}</div>;
+        },
       },
-
       {
-        title: '借款支付日期',
-        dataIndex: 'loanPurpose',
+        title: '借款金额',
+        dataIndex: 'loanAmount',
         align: 'center',
         width: '100px',
         ellipsis: true,
@@ -92,6 +100,9 @@
         dataIndex: 'createBy',
         align: 'center',
         width: '60px',
+        customRender: ({ text, record, index, column }) => {
+          return <div class='smart-table-operate'>{record.createBy.actualName}</div>;
+        },
       },
       {
         title: '发起日期',
@@ -102,7 +113,6 @@
       },
       {
         title: '操作',
-        dataIndex: 'createDate',
         align: 'center',
         width: '50px',
         ellipsis: true,
@@ -133,7 +143,6 @@
   const router = useRouter();
 
   function goDetailPage(record) {
-    sessionStorage.setItem('SessionStorageProjectId', record.id);
     router.push({
       path: '/project/project-manage/single-project',
     });
@@ -151,21 +160,21 @@
   }
 
   .smart-table-operate {
-  display: flex;
-  justify-content: center;
-  align-items: center;
-  gap: 8px;
-}
+    display: flex;
+    justify-content: center;
+    align-items: center;
+    gap: 8px;
+  }
 
-.smart-table-operate a {
-  color: #1890ff;
-  text-decoration: none;
-  font-size: 14px;
-  cursor: pointer;
-}
+  .smart-table-operate a {
+    color: #1890ff;
+    text-decoration: none;
+    font-size: 14px;
+    cursor: pointer;
+  }
 
-.smart-table-operate span {
-  color: #ccc;
-  margin: 0 5px;
-}
+  .smart-table-operate span {
+    color: #ccc;
+    margin: 0 5px;
+  }
 </style>

+ 33 - 28
src/views/project/cost-manage/reimburse-manage/index.vue

@@ -17,41 +17,37 @@
     showIndexColumn: true,
     search: [
       {
-        label: '项目名称',
-        field: 'deliveryName',
+        label: '申请人',
+        field: 'applicant',
         type: 'input',
         attrs: {},
       },
-      {
-        label: '客户名称',
-        field: 'customerName',
-        type: 'input',
-        attrs: {},
-      },
-      {
-        label: '项目状态',
-        field: 'deliveryStatus',
-        type: 'select',
-        options: useDict.type.MATE_DELIVERY_STATUS,
-        attrs: {},
-      },
     ],
     columns: [
-     {
-        title: '收款人',
+      {
+        title: '申请人',
         dataIndex: 'applicant',
         align: 'center',
-        width: '150px',
+        width: '100px',
+        ellipsis: true,
+        customRender: ({ text, record, index, column }) => {
+          return <div class='smart-table-operate'>{record.applicant.actualName}</div>;
+        },
+      },
+      {
+        title: '归属项目',
+        dataIndex: 'belongProjectName',
+        align: 'center',
+        width: '100px',
         ellipsis: true,
       },
       {
-        title: '报销总金额',
+        title: '报销金额',
         dataIndex: 'expenseAmount',
         align: 'center',
         width: '100px',
         ellipsis: true,
       },
-     
       {
         title: '冲抵借款金额',
         dataIndex: 'offsetLoanAmount',
@@ -59,25 +55,26 @@
         width: '100px',
         ellipsis: true,
       },
+
       {
-        title: '本次付款金额',
+        title: '付款金额',
         dataIndex: 'payAmount',
         align: 'center',
         width: '50px',
         ellipsis: true,
       },
       {
-        title: '是否付款',
-        dataIndex: 'belongProjectName',
+        title: '付款日期',
+        dataIndex: 'payDate',
         align: 'center',
         width: '50px',
         ellipsis: true,
       },
       {
-        title: '报销付款日期',
-        dataIndex: 'payDate',
+        title: '报销说明',
+        dataIndex: 'statementDescribe',
         align: 'center',
-        width: '50px',
+        width: '100px',
         ellipsis: true,
       },
       {
@@ -85,6 +82,9 @@
         dataIndex: 'createBy',
         align: 'center',
         width: '60px',
+         customRender: ({ text, record, index, column }) => {
+          return <div class='smart-table-operate'>{record.createBy?.actualName}</div>;
+        },
       },
       {
         title: '发起日期',
@@ -92,6 +92,12 @@
         align: 'center',
         width: '50px',
         ellipsis: true,
+      },
+      {
+        title: '操作',
+        align: 'center',
+        width: '50px',
+        ellipsis: true,
         customRender: ({ text, record, index, column }) => {
           return (
             <div class='smart-table-operate'>
@@ -102,9 +108,8 @@
           );
         },
       },
-      
     ],
-  
+
     beforeFetch({ params }) {
       return {
         ...params,