24282 11 mēneši atpakaļ
vecāks
revīzija
9b7f8e70b8

+ 8 - 0
jy-business/src/main/java/com/jy/business/payment/controller/PaymentRequestsController.java

@@ -68,4 +68,12 @@ public class PaymentRequestsController {
         paymentRequestsService.delete(dto.getIdList());
     }
 
+    /**
+     * 打款分页
+     */
+    @GetMapping("/getRemitPage")
+    public Page<PaymentRequestsVo> getRemitPage(PaymentRequestsSelectDto dto) {
+        return paymentRequestsService.getRemitPage(dto);
+    }
+
 }

+ 49 - 0
jy-business/src/main/java/com/jy/business/payment/dao/PaymentRequestsDao.java

@@ -8,16 +8,22 @@ import com.jy.business.payment.model.dto.PaymentRequestsSelectDto;
 import com.jy.business.payment.model.entity.PaymentRequests;
 import com.jy.business.payment.model.table.PaymentRequestsTable;
 import com.jy.business.payment.model.vo.PaymentRequestsVo;
+import com.jy.flow.model.enums.FlowStatusEnum;
 import com.jy.framework.model.base.BaseDao;
 import com.jy.framework.model.base.BaseIdPo;
 import com.jy.framework.satoken.LoginContext;
 import com.jy.system.model.table.SysDeptTable;
 import com.jy.system.model.table.SysUserTable;
+import com.jy.system.service.AuthService;
+import jakarta.annotation.Resource;
 import org.springframework.stereotype.Service;
 
 @Service
 public class PaymentRequestsDao extends BaseDao<PaymentRequestsMapper, PaymentRequests> {
 
+    @Resource
+    private AuthService authService;
+
     /**
      * 请款分页
      */
@@ -85,4 +91,47 @@ public class PaymentRequestsDao extends BaseDao<PaymentRequestsMapper, PaymentRe
         lambdaUpdate().eq(BaseIdPo::getId, businessId).set(PaymentRequests::getApprovalStatus, flowStatus).update();
     }
 
+    /**
+     * 打款分页
+     */
+    public Page<PaymentRequestsVo> getRemitPage(PaymentRequestsSelectDto dto) {
+        PaymentRequestsTable pr = PaymentRequestsTable.pr;
+
+        // 公司信息
+        CorporationTable c = CorporationTable.c;
+        // 部门
+        SysDeptTable sd = SysDeptTable.sd;
+        // 用户
+        SysUserTable su = SysUserTable.su;
+        // 资金账户
+        CapitalAccountTable ca = CapitalAccountTable.ca;
+
+        return sql(PaymentRequestsVo.class)
+                .select(
+                        pr.all,
+                        c.name.as(PaymentRequestsVo::getCorporationName),
+                        sd.name.as(PaymentRequestsVo::getDeptName),
+                        su.nickname.as(PaymentRequestsVo::getUserName),
+                        ca.accountAlias.as(PaymentRequestsVo::getCapitalAccountName)
+                )
+                .from(pr)
+                .leftJoin(c).on(pr.corporationId.eq(c.id))
+                .leftJoin(sd).on(pr.deptId.eq(sd.id))
+                .leftJoin(su).on(pr.createUser.eq(su.id))
+                .leftJoin(ca).on(pr.capitalAccountId.eq(ca.id))
+                .where(
+                        pr.createUser.in(authService.getUserPermissionSet()),
+                        pr.approvalStatus.eq(FlowStatusEnum.COMPLETED.getKey()),
+                        pr.corporationId.eq(dto.getCorporationId()),
+                        pr.deptId.eq(dto.getDeptId()),
+                        pr.type.eq(dto.getType()),
+                        pr.payType.eq(dto.getPayType()),
+                        pr.paymentStatus.eq(dto.getPaymentStatus())
+                )
+                .orderBy(
+                        pr.id.desc()
+                )
+                .page(dto.getPage());
+    }
+
 }

+ 5 - 0
jy-business/src/main/java/com/jy/business/payment/service/PaymentRequestsService.java

@@ -42,4 +42,9 @@ public interface PaymentRequestsService {
      */
     void delete(List<Long> idList);
 
+    /**
+     * 打款分页
+     */
+    Page<PaymentRequestsVo> getRemitPage(PaymentRequestsSelectDto dto);
+
 }

+ 5 - 0
jy-business/src/main/java/com/jy/business/payment/service/impl/PaymentRequestsServiceImpl.java

@@ -84,4 +84,9 @@ public class PaymentRequestsServiceImpl implements PaymentRequestsService {
         paymentRequestsDao.removeBatchByIds(idList);
     }
 
+    @Override
+    public Page<PaymentRequestsVo> getRemitPage(PaymentRequestsSelectDto dto) {
+        return paymentRequestsDao.getRemitPage(dto);
+    }
+
 }

+ 3 - 2
jy-flow/src/main/java/com/jy/flow/model/enums/FlowStatusEnum.java

@@ -9,8 +9,9 @@ public enum FlowStatusEnum {
 
     PRIMED_FOR_ACTION(0, "待发起"),
     UNDER_WAY(1, "进行中"),
-    COMPLETED(2, "已完成"),
-    DECLINED(3, "已驳回");
+    COMPLETED(2, "已通过"),
+    DECLINED(3, "已驳回"),
+    CANCELLED(4, "已撤销");
 
     private final int key;
     private final String desc;

+ 5 - 0
jy-ui/src/api/business/payment/requests.ts

@@ -25,3 +25,8 @@ export function editApi(data: StrAnyObj): Promise<void> {
 export function deleteApi(data: StrAnyObj): Promise<void> {
   return request.post('/paymentRequests/delete', data)
 }
+
+// 请款分页
+export function getRemitPageApi(params: StrAnyObj): Promise<PageType<StrAnyObj>> {
+  return request.get('/paymentRequests/getRemitPage', params)
+}

+ 355 - 0
jy-ui/src/views/business/payment/remit/index.vue

@@ -0,0 +1,355 @@
+<script setup lang="ts">
+import AForm from '@/components/AForm/index.vue'
+import { FormConfigType } from '@/components/AForm/type'
+import { ToolbarConfigType } from '@/components/AToolbar/type'
+import { ColumnConfigType } from '@/components/ATable/type'
+import { StrAnyObj, StrAnyObjArr } from '@/typings'
+import { addApi, editApi, getDetailApi, getRemitPageApi } from '@/api/business/payment/requests'
+import { getPageApi as getCorporationPageApi } from '@/api/business/corporation/corporation'
+import DeptTreeSelect from '@/views/components/DeptTreeSelect/index.vue'
+import { getPageApi as getCapitalAccountPageApi } from '@/api/business/capital/account'
+import FileUpload from '@/components/FlieUpload/index.vue'
+
+const queryRef = ref<InstanceType<typeof AForm>>()
+const formRef = ref<InstanceType<typeof AForm>>()
+
+const showQuery = ref<boolean>(true)
+const selectKeys = ref<string[]>([])
+const pageTotal = ref<number>(0)
+
+const queryData = ref<StrAnyObj>({ pageNum: 1, pageSize: 10 })
+const tableData = ref<StrAnyObjArr>([])
+const formData = ref<StrAnyObj>({ paymentRequestsDetailList: [{}] })
+
+const dialogTitle = ref<string>('')
+const dialogVisible = ref<boolean>(false)
+
+const selectDeptIdRef = ref<InstanceType<typeof DeptTreeSelect>>()
+
+const disabled = ref(false)
+
+const queryConfig: FormConfigType[] = [
+  {
+    type: 'select',
+    prop: 'corporationId',
+    label: '归属公司',
+    keyName: 'id',
+    labelName: 'name',
+    async option() {
+      const data = await getCorporationPageApi({ searchAll: true })
+      return data.records
+    }
+  },
+  {
+    type: 'slot',
+    prop: 'deptId',
+    label: '归属部门'
+  },
+  {
+    type: 'select',
+    prop: 'type',
+    label: '请款类型',
+    dict: 'payment_requests_type'
+  },
+  {
+    type: 'select',
+    prop: 'payType',
+    label: '付款方式',
+    dict: 'pay_type'
+  },
+  {
+    type: 'select',
+    prop: 'paymentStatus',
+    label: '放款状态',
+    option: [
+      {
+        key: 0,
+        label: '未放款'
+      },
+      {
+        key: 1,
+        label: '已放款'
+      }
+    ]
+  }
+]
+
+const toolbarConfig: ToolbarConfigType[] = [
+  {
+    common: 'search',
+    click() {
+      queryData.value.pageNum = 1
+      getPage()
+    }
+  },
+  {
+    common: 'reset',
+    click() {
+      queryRef.value?.resetFields()
+      getPage()
+    }
+  },
+  {
+    common: 'add',
+    click() {
+      dialogVisible.value = true
+      dialogTitle.value = '新增'
+    }
+  }
+]
+
+const columnConfig: ColumnConfigType[] = [
+  {
+    prop: 'corporationName',
+    label: '归属公司'
+  },
+  {
+    prop: 'deptName',
+    label: '归属部门'
+  },
+  {
+    prop: 'type',
+    label: '请款类型',
+    dict: 'payment_requests_type'
+  },
+  {
+    prop: 'userName',
+    label: '请款人'
+  },
+  {
+    prop: 'createTime',
+    label: '请款时间'
+  },
+  {
+    prop: 'useTime',
+    label: '用款时间'
+  },
+  {
+    prop: 'useRemark',
+    label: '用款说明',
+    showOverflowTooltip: true
+  },
+  {
+    prop: 'totalAmount',
+    label: '请款金额'
+  },
+  {
+    prop: 'payType',
+    label: '付款方式',
+    dict: 'pay_type'
+  },
+  {
+    prop: 'capitalAccountName',
+    label: '付款账户'
+  },
+  {
+    prop: 'paymentStatus',
+    label: '放款状态',
+    formatter(row) {
+      switch (row.paymentStatus) {
+        case 0:
+          return '未放款'
+        case 1:
+          return '已放款'
+      }
+    }
+  },
+  {
+    width: 250,
+    handleConfig: [
+      {
+        common: 'detail',
+        click(row) {
+          dialogVisible.value = true
+          dialogTitle.value = '详情'
+          disabled.value = true
+          getDetailApi({ id: row.id }).then((resp: StrAnyObj) => {
+            formData.value = resp
+          })
+        }
+      }
+    ]
+  }
+]
+
+const formConfig: FormConfigType[] = [
+  {
+    type: 'select',
+    prop: 'type',
+    label: '请款类型',
+    dict: 'payment_requests_type',
+    placeholder: '',
+    disabled: true
+  },
+  {
+    type: 'input',
+    prop: 'totalAmount',
+    label: '请款金额',
+    placeholder: '',
+    disabled: true
+  },
+  {
+    type: 'select',
+    prop: 'payType',
+    label: '付款方式',
+    dict: 'pay_type',
+    placeholder: '',
+    disabled: true
+  },
+  {
+    type: 'select',
+    prop: 'capitalAccountId',
+    label: '付款账户',
+    keyName: 'id',
+    labelName: 'accountAlias',
+    placeholder: '',
+    async option() {
+      const data = await getCapitalAccountPageApi({ searchAll: true })
+      return data.records
+    },
+    disabled: true
+  },
+  {
+    type: 'input',
+    prop: 'accountName',
+    label: '户名',
+    placeholder: '',
+    disabled: true
+  },
+  {
+    type: 'input',
+    prop: 'account',
+    label: '银行账号',
+    placeholder: '',
+    disabled: true
+  },
+  {
+    type: 'input',
+    prop: 'depositBank',
+    label: '开户银行',
+    placeholder: '',
+    disabled: true
+  },
+  {
+    type: 'input',
+    prop: 'correspondentNumber',
+    label: '联行号/SWIFT Code',
+    placeholder: '',
+    disabled: true
+  },
+  {
+    type: 'input',
+    itemType: 'textarea',
+    prop: 'useRemark',
+    label: '用款说明',
+    rows: 3,
+    span: 24,
+    placeholder: '',
+    disabled: true
+  },
+  {
+    type: 'slot',
+    prop: 'atts',
+    label: '上传附件',
+    span: 24
+  }
+]
+
+onMounted(() => {
+  getPage()
+  selectDeptIdRef.value?.load()
+})
+
+function getPage() {
+  getRemitPageApi(queryData.value).then((resp) => {
+    tableData.value = resp.records
+    pageTotal.value = resp.total
+  })
+}
+
+function tableSelectionChange(item: StrAnyObjArr) {
+  selectKeys.value = item.map((item) => item.id)
+}
+
+function formSubmit() {
+  formRef.value?.validate(() => {
+    if (formData.value.paymentRequestsDetailList.length === 0) {
+      ElMessage.error('请款明细为空,无法提交')
+      return
+    }
+
+    for (const item of formData.value.paymentRequestsDetailList) {
+      if (!item.expenseType) {
+        ElMessage.error('请款明细存在费用类型为空,无法提交')
+        return
+      }
+      if (!item.remark) {
+        ElMessage.error('请款明细存在款项说明为空,无法提交')
+        return
+      }
+      if (!item.amount) {
+        ElMessage.error('请款明细存在请款金额为空,无法提交')
+        return
+      }
+    }
+
+    if (formData.value.id) {
+      editApi(formData.value).then(() => {
+        dialogVisible.value = false
+        ElMessage.success('修改成功')
+        getPage()
+      })
+    } else {
+      addApi(formData.value).then(() => {
+        dialogVisible.value = false
+        ElMessage.success('新增成功')
+        getPage()
+      })
+    }
+  })
+}
+
+function formClosed() {
+  formRef.value?.resetFields()
+}
+</script>
+
+<template>
+  <div>
+    <el-card v-if="showQuery">
+      <a-form ref="queryRef" v-model="queryData" :config="queryConfig" :span="6">
+        <template #deptId>
+          <dept-tree-select ref="selectDeptIdRef" v-model="formData.deptId" />
+        </template>
+      </a-form>
+    </el-card>
+
+    <a-table
+      :data="tableData"
+      :page-total="pageTotal"
+      :toolbar-config="toolbarConfig"
+      :column-config="columnConfig"
+      v-model:showQuery="showQuery"
+      v-model:page-num="queryData.pageNum"
+      v-model:page-size="queryData.pageSize"
+      @page-num-change="getPage"
+      @page-size-change="getPage"
+      @selection-change="tableSelectionChange"
+    >
+    </a-table>
+
+    <a-dialog
+      v-model="dialogVisible"
+      :title="dialogTitle"
+      @submit="formSubmit"
+      @closed="formClosed"
+      width="1400px"
+    >
+      <a-form ref="formRef" v-model="formData" :config="formConfig" :span="12" :disabled="disabled">
+        <template #atts>
+          <file-upload v-model="formData.atts" :disabled="disabled" />
+        </template>
+      </a-form>
+    </a-dialog>
+  </div>
+</template>

+ 88 - 71
jy-ui/src/views/business/payment/requests/index.vue

@@ -1,15 +1,22 @@
 <script setup lang="ts">
 import AForm from '@/components/AForm/index.vue'
-import {FormConfigType} from '@/components/AForm/type'
-import {ToolbarConfigType} from '@/components/AToolbar/type'
-import {ColumnConfigType} from '@/components/ATable/type'
-import {StrAnyObj, StrAnyObjArr} from '@/typings'
-import {useHandleData} from '@/utils/useHandleData'
-import {addApi, deleteApi, editApi, getDetailApi, getPageApi} from '@/api/business/payment/requests'
-import {getPageApi as getCorporationPageApi} from '@/api/business/corporation/corporation'
+import { FormConfigType } from '@/components/AForm/type'
+import { ToolbarConfigType } from '@/components/AToolbar/type'
+import { ColumnConfigType } from '@/components/ATable/type'
+import { StrAnyObj, StrAnyObjArr } from '@/typings'
+import { useHandleData } from '@/utils/useHandleData'
+import {
+  addApi,
+  deleteApi,
+  editApi,
+  getDetailApi,
+  getPageApi
+} from '@/api/business/payment/requests'
+import { getPageApi as getCorporationPageApi } from '@/api/business/corporation/corporation'
 import DeptTreeSelect from '@/views/components/DeptTreeSelect/index.vue'
-import {getPageApi as getCapitalAccountPageApi} from '@/api/business/capital/account'
+import { getPageApi as getCapitalAccountPageApi } from '@/api/business/capital/account'
 import FileUpload from '@/components/FlieUpload/index.vue'
+import { getDictByCode } from '@/utils/dict'
 
 const queryRef = ref<InstanceType<typeof AForm>>()
 const formRef = ref<InstanceType<typeof AForm>>()
@@ -18,9 +25,9 @@ const showQuery = ref<boolean>(true)
 const selectKeys = ref<string[]>([])
 const pageTotal = ref<number>(0)
 
-const queryData = ref<StrAnyObj>({pageNum: 1, pageSize: 10})
+const queryData = ref<StrAnyObj>({ pageNum: 1, pageSize: 10 })
 const tableData = ref<StrAnyObjArr>([])
-const formData = ref<StrAnyObj>({paymentRequestsDetailList: [{}]})
+const formData = ref<StrAnyObj>({ paymentRequestsDetailList: [{}] })
 
 const dialogTitle = ref<string>('')
 const dialogVisible = ref<boolean>(false)
@@ -40,12 +47,12 @@ const queryConfig: FormConfigType[] = [
     async option() {
       const data = await getCorporationPageApi({ searchAll: true })
       return data.records
-    },
+    }
   },
   {
     type: 'slot',
     prop: 'deptId',
-    label: '归属部门',
+    label: '归属部门'
   },
   {
     type: 'select',
@@ -79,7 +86,7 @@ const queryConfig: FormConfigType[] = [
       {
         key: 3,
         label: '已驳回'
-      },
+      }
     ]
   },
   {
@@ -208,7 +215,7 @@ const columnConfig: ColumnConfigType[] = [
           dialogVisible.value = true
           dialogTitle.value = '重新发起'
           disabled.value = false
-          getDetailApi({id: row.id}).then((resp: StrAnyObj) => {
+          getDetailApi({ id: row.id }).then((resp: StrAnyObj) => {
             formData.value = resp
           })
           nextTick(() => deptIdRef.value?.load())
@@ -223,8 +230,6 @@ const columnConfig: ColumnConfigType[] = [
           nextTick(() => deptIdRef.value?.load())
           getDetailApi({ id: row.id }).then((resp: StrAnyObj) => {
             formData.value = resp
-            updateAmount()
-            updateDetailRemark()
           })
         }
       }
@@ -240,23 +245,23 @@ const formConfig: FormConfigType[] = [
     keyName: 'id',
     labelName: 'name',
     async option() {
-      const data = await getCorporationPageApi({searchAll: true})
+      const data = await getCorporationPageApi({ searchAll: true })
       return data.records
     },
-    rule: [{required: true, message: '归属公司id不能为空', trigger: 'blur'}]
+    rule: [{ required: true, message: '归属公司id不能为空', trigger: 'blur' }]
   },
   {
     type: 'slot',
     prop: 'deptId',
     label: '归属部门',
-    rule: [{required: true, message: '部门id不能为空', trigger: 'blur'}]
+    rule: [{ required: true, message: '部门id不能为空', trigger: 'blur' }]
   },
   {
     type: 'select',
     prop: 'type',
     label: '请款类型',
     dict: 'payment_requests_type',
-    rule: [{required: true, message: '请款类型不能为空', trigger: 'blur'}]
+    rule: [{ required: true, message: '请款类型不能为空', trigger: 'blur' }]
   },
   {
     type: 'datePicker',
@@ -301,14 +306,14 @@ const formConfig: FormConfigType[] = [
     label: '单据数量',
     min: 0,
     precision: 0,
-    rule: [{required: true, message: '单据数量不能为空', trigger: 'blur'}]
+    rule: [{ required: true, message: '单据数量不能为空', trigger: 'blur' }]
   },
   {
     type: 'select',
     prop: 'payType',
     label: '付款方式',
     dict: 'pay_type',
-    rule: [{required: true, message: '付款方式不能为空', trigger: 'blur'}]
+    rule: [{ required: true, message: '付款方式不能为空', trigger: 'blur' }]
   },
   {
     type: 'select',
@@ -317,7 +322,7 @@ const formConfig: FormConfigType[] = [
     keyName: 'id',
     labelName: 'accountAlias',
     async option() {
-      const data = await getCapitalAccountPageApi({searchAll: true})
+      const data = await getCapitalAccountPageApi({ searchAll: true })
       return data.records
     }
   },
@@ -366,7 +371,6 @@ const detailTableColumnConfig: ColumnConfigType[] = [
         common: 'delete',
         click(row, index) {
           formData.value.paymentRequestsDetailList.splice(index, 1)
-          updateDetailRemark()
           updateAmount()
         }
       }
@@ -434,7 +438,7 @@ function formClosed() {
 
 function handleRemove(idList: string[]) {
   useHandleData('是否确认删除?', () => {
-    deleteApi({idList}).then(() => {
+    deleteApi({ idList }).then(() => {
       ElMessage.success('删除成功')
       getPage()
     })
@@ -445,18 +449,27 @@ function addPaymentRequestsDetailList() {
   formData.value.paymentRequestsDetailList.push({})
 }
 
-function updateDetailRemark() {
+async function updateDetailRemark() {
+  const expenseTypes = await getDictByCode('expense_type')
+  const expenseMap = new Map<number, string>()
+  for (const item of expenseTypes) {
+    expenseMap.set(item.value, item.label)
+  }
   formData.value.useRemark = formData.value.paymentRequestsDetailList
-      .map((item) => item.remark)
-      .filter((item) => item !== '' && item !== null && item !== undefined)
-      .join(' - \n')
+    .map(
+      (item) =>
+        `【${expenseMap.get(item.expenseType) ?? ''}】 - ${item.remark ?? ''} - ${item.amount ?? ''}`
+    )
+    .join('\n')
 }
 
 function updateAmount() {
   formData.value.totalAmount = formData.value.paymentRequestsDetailList
-      .map((item) => item.amount)
-      .filter((item) => item !== '' && item !== null && item !== undefined)
-      .reduce((pre, next) => pre + next, 0)
+    .map((item) => item.amount)
+    .filter((item) => item !== '' && item !== null && item !== undefined)
+    .reduce((pre, next) => pre + next, 0)
+
+  updateDetailRemark()
 }
 </script>
 
@@ -471,69 +484,73 @@ function updateAmount() {
     </el-card>
 
     <a-table
-        selection
-        :data="tableData"
-        :page-total="pageTotal"
-        :toolbar-config="toolbarConfig"
-        :column-config="columnConfig"
-        v-model:showQuery="showQuery"
-        v-model:page-num="queryData.pageNum"
-        v-model:page-size="queryData.pageSize"
-        @page-num-change="getPage"
-        @page-size-change="getPage"
-        @selection-change="tableSelectionChange"
+      :data="tableData"
+      :page-total="pageTotal"
+      :toolbar-config="toolbarConfig"
+      :column-config="columnConfig"
+      v-model:showQuery="showQuery"
+      v-model:page-num="queryData.pageNum"
+      v-model:page-size="queryData.pageSize"
+      @page-num-change="getPage"
+      @page-size-change="getPage"
+      @selection-change="tableSelectionChange"
     >
     </a-table>
 
     <a-dialog
-        v-model="dialogVisible"
-        :title="dialogTitle"
-        @submit="formSubmit"
-        @closed="formClosed"
-        width="1400px"
-        height="200px"
+      v-model="dialogVisible"
+      :title="dialogTitle"
+      @submit="formSubmit"
+      @closed="formClosed"
+      width="1400px"
+      height="200px"
     >
-      <a-form ref="formRef" v-model="formData" :config="formConfig" :span="12"  :disabled="disabled">
+      <a-form ref="formRef" v-model="formData" :config="formConfig" :span="12" :disabled="disabled">
         <template #deptId>
-          <dept-tree-select ref="deptIdRef" v-model="formData.deptId"  :disabled="disabled"/>
+          <dept-tree-select ref="deptIdRef" v-model="formData.deptId" :disabled="disabled" />
         </template>
         <template #atts>
-          <file-upload v-model="formData.atts"  :disabled="disabled"/>
+          <file-upload v-model="formData.atts" :disabled="disabled" />
         </template>
         <template #detailTable>
           <a-table
-              :data="formData.paymentRequestsDetailList"
-              :columnConfig="detailTableColumnConfig"
-              style="width: 100%"
-              :card="false"
+            :data="formData.paymentRequestsDetailList"
+            :columnConfig="detailTableColumnConfig"
+            style="width: 100%"
+            :card="false"
           >
             <template #expenseType="scope">
-              <a-select v-model="scope.row.expenseType" dict="expense_type"  :disabled="disabled"/>
+              <a-select
+                v-model="scope.row.expenseType"
+                dict="expense_type"
+                :disabled="disabled"
+                @change="updateDetailRemark"
+              />
             </template>
             <template #remark="scope">
               <a-input
-                  v-model="scope.row.remark"
-                  type="textarea"
-                  :rows="2"
-                  @change="updateDetailRemark"
-                  :disabled="disabled"
+                v-model="scope.row.remark"
+                type="textarea"
+                :rows="2"
+                @change="updateDetailRemark"
+                :disabled="disabled"
               />
             </template>
             <template #amount="scope">
               <a-inputNumber
-                  v-model="scope.row.amount"
-                  :min="0.01"
-                  :precision="2"
-                  @change="updateAmount"
-                  :disabled="disabled"
+                v-model="scope.row.amount"
+                :min="0.01"
+                :precision="2"
+                @change="updateAmount"
+                :disabled="disabled"
               />
             </template>
           </a-table>
           <el-button
-              v-if="!disabled"
-              style="width: 100%; margin-bottom: 20px"
-              type="primary"
-              @click="addPaymentRequestsDetailList"
+            v-if="!disabled"
+            style="width: 100%; margin-bottom: 20px"
+            type="primary"
+            @click="addPaymentRequestsDetailList"
           >
             添加行
           </el-button>

+ 18 - 18
jy-ui/src/views/flow/taskDone/index.vue

@@ -1,11 +1,11 @@
 <script setup lang="ts">
 import AForm from '@/components/AForm/index.vue'
-import {FormConfigType} from '@/components/AForm/type'
-import {ToolbarConfigType} from '@/components/AToolbar/type'
-import {ColumnConfigType} from '@/components/ATable/type'
-import {StrAnyObj, StrAnyObjArr} from '@/typings'
-import {getDoneListApi, getDonePageApi} from '@/api/flow/execute'
-import {getChartApi} from '@/api/flow/definition'
+import { FormConfigType } from '@/components/AForm/type'
+import { ToolbarConfigType } from '@/components/AToolbar/type'
+import { ColumnConfigType } from '@/components/ATable/type'
+import { StrAnyObj, StrAnyObjArr } from '@/typings'
+import { getDoneListApi, getDonePageApi } from '@/api/flow/execute'
+import { getChartApi } from '@/api/flow/definition'
 
 const modules = import.meta.glob('@/views/**/*.vue')
 
@@ -14,7 +14,7 @@ const queryRef = ref<InstanceType<typeof AForm>>()
 const showQuery = ref<boolean>(true)
 const pageTotal = ref<number>(0)
 
-const queryData = ref<StrAnyObj>({pageNum: 1, pageSize: 10})
+const queryData = ref<StrAnyObj>({ pageNum: 1, pageSize: 10 })
 const tableData = ref<StrAnyObjArr>([])
 
 const chartVisible = ref(false)
@@ -217,24 +217,24 @@ function getPage() {
     </el-card>
 
     <a-table
-        :data="tableData"
-        :page-total="pageTotal"
-        :toolbar-config="toolbarConfig"
-        :column-config="columnConfig"
-        v-model:showQuery="showQuery"
-        v-model:page-num="queryData.pageNum"
-        v-model:page-size="queryData.pageSize"
-        @page-num-change="getPage"
-        @page-size-change="getPage"
+      :data="tableData"
+      :page-total="pageTotal"
+      :toolbar-config="toolbarConfig"
+      :column-config="columnConfig"
+      v-model:showQuery="showQuery"
+      v-model:page-num="queryData.pageNum"
+      v-model:page-size="queryData.pageSize"
+      @page-num-change="getPage"
+      @page-size-change="getPage"
     >
     </a-table>
 
     <a-dialog title="" v-model="handleVisible" width="1200px" :footer="false">
-      <component :is="handleComponent" :businessId="businessId"/>
+      <component :is="handleComponent" :businessId="businessId" />
     </a-dialog>
 
     <a-dialog title="流程图" v-model="chartVisible" width="1200px" :footer="false">
-      <img :src="imgUrl" width="100%" style="margin: 0 auto" alt=""/>
+      <img :src="imgUrl" width="100%" style="margin: 0 auto" alt="" />
     </a-dialog>
 
     <a-dialog title="审批记录" v-model="doneListVisible" width="1000px" :footer="false">

+ 19 - 19
jy-ui/src/views/flow/taskTodo/index.vue

@@ -1,11 +1,11 @@
 <script setup lang="ts">
 import AForm from '@/components/AForm/index.vue'
-import {FormConfigType} from '@/components/AForm/type'
-import {ToolbarConfigType} from '@/components/AToolbar/type'
-import {ColumnConfigType} from '@/components/ATable/type'
-import {StrAnyObj, StrAnyObjArr} from '@/typings'
-import {getDoneListApi, getToDoPageApi, handleApi} from '@/api/flow/execute'
-import {getChartApi} from '@/api/flow/definition'
+import { FormConfigType } from '@/components/AForm/type'
+import { ToolbarConfigType } from '@/components/AToolbar/type'
+import { ColumnConfigType } from '@/components/ATable/type'
+import { StrAnyObj, StrAnyObjArr } from '@/typings'
+import { getDoneListApi, getToDoPageApi, handleApi } from '@/api/flow/execute'
+import { getChartApi } from '@/api/flow/definition'
 
 const modules = import.meta.glob('@/views/**/*.vue')
 
@@ -14,7 +14,7 @@ const queryRef = ref<InstanceType<typeof AForm>>()
 const showQuery = ref<boolean>(true)
 const pageTotal = ref<number>(0)
 
-const queryData = ref<StrAnyObj>({pageNum: 1, pageSize: 10})
+const queryData = ref<StrAnyObj>({ pageNum: 1, pageSize: 10 })
 const tableData = ref<StrAnyObjArr>([])
 
 const chartVisible = ref(false)
@@ -232,7 +232,7 @@ function getPage() {
 
 function handle(handleType) {
   const message = handleData.value.message
-  handleApi({taskId: taskId.value, handleType, message}).then(() => {
+  handleApi({ taskId: taskId.value, handleType, message }).then(() => {
     getPage()
     ElMessage.success('办理成功')
     this.handleVisible = false
@@ -247,22 +247,22 @@ function handle(handleType) {
     </el-card>
 
     <a-table
-        :data="tableData"
-        :page-total="pageTotal"
-        :toolbar-config="toolbarConfig"
-        :column-config="columnConfig"
-        v-model:showQuery="showQuery"
-        v-model:page-num="queryData.pageNum"
-        v-model:page-size="queryData.pageSize"
-        @page-num-change="getPage"
-        @page-size-change="getPage"
+      :data="tableData"
+      :page-total="pageTotal"
+      :toolbar-config="toolbarConfig"
+      :column-config="columnConfig"
+      v-model:showQuery="showQuery"
+      v-model:page-num="queryData.pageNum"
+      v-model:page-size="queryData.pageSize"
+      @page-num-change="getPage"
+      @page-size-change="getPage"
     >
     </a-table>
 
     <a-dialog title="" v-model="handleVisible" width="1200px" :footer="false">
       <el-card shadow="always">
         <template #header>流程明细</template>
-        <component :is="handleComponent" :businessId="businessId"/>
+        <component :is="handleComponent" :businessId="businessId" />
       </el-card>
 
       <el-card shadow="always" style="margin-top: 20px">
@@ -279,7 +279,7 @@ function handle(handleType) {
     </a-dialog>
 
     <a-dialog title="流程图" v-model="chartVisible" width="1200px" :footer="false">
-      <img :src="imgUrl" width="100%" style="margin: 0 auto" alt=""/>
+      <img :src="imgUrl" width="100%" style="margin: 0 auto" alt="" />
     </a-dialog>
 
     <a-dialog title="审批记录" v-model="doneListVisible" width="1000px" :footer="false">