浏览代码

bug和新需求实现

cz 1 年之前
父节点
当前提交
d21cfc476d

文件差异内容过多而无法显示
+ 700 - 103
src/components/process/SendFunds.vue


+ 120 - 14
src/views/finance/fundManage/accountStatement/index.vue

@@ -110,6 +110,75 @@
         :rules="rules3"
         ref="submit3"
       >
+        <template #details>
+          <div style="width: 100%">
+            <el-button
+              type="primary"
+              @click="handleAddRow(true)"
+              style="margin: 10px 0"
+            >
+              添加
+            </el-button>
+            <el-table
+              :data="formData3.data.exchangeSettlementDetailList"
+              show-summary
+            >
+              <el-table-column prop="count" label="合同编号" min-width="150">
+                <template #default="{ row, $index }">
+                  <el-form-item
+                    :prop="
+                      'exchangeSettlementDetailList.' + $index + '.contractId'
+                    "
+                    :rules="rulesOne.contractId"
+                    :inline-message="true"
+                  >
+                    <el-select
+                      v-model="row.contractId"
+                      placeholder="请选择"
+                      filterable
+                      style="width: 100%"
+                    >
+                      <el-option
+                        v-for="item in contractList2"
+                        :label="item.code"
+                        :value="item.id"
+                      >
+                      </el-option>
+                    </el-select>
+                  </el-form-item>
+                </template>
+              </el-table-column>
+              <el-table-column prop="amount" label="关联金额" min-width="150">
+                <template #default="{ row, $index }">
+                  <el-form-item
+                    :prop="'exchangeSettlementDetailList.' + $index + '.amount'"
+                    :rules="rulesOne.amount"
+                    :inline-message="true"
+                  >
+                    <el-input-number
+                      onmousewheel="return false;"
+                      v-model="row.amount"
+                      :precision="2"
+                      :controls="false"
+                      :min="0"
+                      style="width: 100%"
+                    />
+                  </el-form-item>
+                </template>
+              </el-table-column>
+              <el-table-column prop="zip" label="操作" width="80">
+                <template #default="{ $index }">
+                  <el-button
+                    type="primary"
+                    link
+                    @click="handleRemove($index, true)"
+                    >删除</el-button
+                  >
+                </template>
+              </el-table-column>
+            </el-table>
+          </div>
+        </template>
       </byForm>
       <template #footer>
         <el-button @click="settlementModal = false" size="large"
@@ -334,7 +403,7 @@
         <template #loanUserName>
           <div style="width: 100%">
             <el-autocomplete
-              v-model="formData.data.loanUserName"
+              v-model="formData.loanData.loanUserName"
               :fetch-suggestions="querySearch"
               :disabled="submitType == 'edit'"
               clearable
@@ -360,7 +429,7 @@
   </div>
 </template>
 
-<script setup>
+<script setup name="AccountStatement">
 import { computed, ref } from "vue";
 import byTable from "@/components/byTable/index";
 import byForm from "@/components/byForm/index";
@@ -826,6 +895,7 @@ const openSettlementModal = (type, row) => {
     commissionCurrency: null,
     remarks: null,
     businessId: null,
+    exchangeSettlementDetailList: [],
   };
   settlementModal.value = true;
 };
@@ -848,6 +918,32 @@ const formData3 = reactive({
 const submit3 = ref(null);
 const settlementSubmitForm = () => {
   submit3.value.handleSubmit(() => {
+    if (!formData3.data.exchangeSettlementDetailList.length > 0) {
+      ElMessage({
+        message: "请添加关联合同",
+        type: "info",
+      });
+      return;
+    }
+    const list = formData3.data.exchangeSettlementDetailList;
+    for (let i = 0; i < list.length; i++) {
+      const e = list[i];
+      if (!(e.amount > 0)) {
+        return ElMessage({
+          message: "关联金额不能为0!",
+          type: "info",
+        });
+      }
+    }
+    const total = list.reduce((total, x) => (total += Number(x.amount)), 0);
+    if (
+      Number(parseFloat(total).toFixed(2)) !== Number(formData3.data.amount)
+    ) {
+      return ElMessage({
+        message: "关联合同金额总合必须等于汇出金额",
+        type: "info",
+      });
+    }
     //汇出汇入账号不能相同
     if (
       formData3.data.accountManagementId ===
@@ -985,12 +1081,11 @@ const settlementFormConfig = computed(() => {
       type: "title",
       title: "关联合同",
     },
+
     {
-      type: "select",
-      prop: "businessId",
-      label: "选择合同",
-      filterable: true,
-      data: contractList2.value,
+      type: "slot",
+      slotName: "details",
+      label: "",
     },
   ];
 });
@@ -1375,14 +1470,25 @@ const submitForm = () => {
   });
 };
 
-const handleAddRow = () => {
-  formData.dataOne.taxRefundDetailsList.push({
-    contractId: "",
-    amount: null,
-  });
+const handleAddRow = (flag) => {
+  if (flag) {
+    formData3.data.exchangeSettlementDetailList.push({
+      contractId: "",
+      amount: null,
+    });
+  } else {
+    formData.dataOne.taxRefundDetailsList.push({
+      contractId: "",
+      amount: null,
+    });
+  }
 };
-const handleRemove = (index) => {
-  formData.dataOne.taxRefundDetailsList.splice(index, 1);
+const handleRemove = (index, flag) => {
+  if (flag) {
+    formData3.data.exchangeSettlementDetailList.splice(index, 1);
+  } else {
+    formData.dataOne.taxRefundDetailsList.splice(index, 1);
+  }
 };
 
 const submitFormOne = () => {

+ 1 - 1
src/views/finance/fundManage/flow/index.vue

@@ -292,7 +292,7 @@
         <template #loanUserName>
           <div style="width: 100%">
             <el-autocomplete
-              v-model="formData.data.loanUserName"
+              v-model="formData.loanData.loanUserName"
               :fetch-suggestions="querySearch"
               :disabled="submitType == 'edit'"
               clearable

+ 29 - 22
src/views/process/processApproval/index.vue

@@ -160,17 +160,17 @@
       </div>
     </div>
     <div class="right-card">
-      
       <el-tabs v-model="activeName" class="demo-tabs">
         <el-tab-pane label="审批记录" name="first">
-          
           <ul class="flow-chart">
             <li
-              v-for="(item,index) in recordList"
+              v-for="(item, index) in recordList"
               :key="item.id"
               :class="
                 !route.query.id
-                  ? (index == 0) ? '' : 'flow-grey'
+                  ? index == 0
+                    ? ''
+                    : 'flow-grey'
                   : item.status == 2
                   ? 'flow-orange'
                   : item.status == 3 && !route.query.id
@@ -185,7 +185,10 @@
                 <i class="iconfont icon-icomx_quertj1 right-btm-status"></i>
               </div>
               <div class="right-conetnt">
-                <div class="name">{{ item.nodeName }} <span style="float: right;">{{ item.handleTypeName }}</span></div>
+                <div class="name">
+                  {{ item.nodeName }}
+                  <span style="float: right">{{ item.handleTypeName }}</span>
+                </div>
                 <div class="remark">
                   <div class="label">
                     <span v-if="item.status != 3">办理人:</span
@@ -205,17 +208,15 @@
                     >
                   </div>
                 </div>
-                
               </div>
               <div class="line"></div>
             </li>
-            
           </ul>
           <div>
             <el-button
               type="primary"
               :loading="btnLoading"
-              style="margin: 20px 150px;"
+              style="margin: 20px 150px"
               v-if="isRevocation"
               @click="handleSubmit(3)"
               >撤回</el-button
@@ -234,7 +235,15 @@
       </el-tabs>
     </div>
 
-    <el-dialog title="下一处理人" width="400" v-model="dialogVisible">
+    <el-dialog
+      title="下一处理人"
+      width="400"
+      v-model="dialogVisible"
+      v-if="dialogVisible"
+      :show-close="false"
+      :close-on-click-modal="false"
+      :close-on-press-escape="false"
+    >
       <el-form :model="flowForm">
         <el-form-item prop="remark" label="处理人">
           <el-select
@@ -245,8 +254,8 @@
           >
             <el-option
               v-for="item in nextHandleUser"
-              :label="item.name"
-              :value="item.id"
+              :label="item.nickName"
+              :value="item.userId"
             >
             </el-option>
           </el-select>
@@ -349,11 +358,11 @@ const flowForm = reactive({
 });
 //获取当前用户id
 const userStore = useUserStore();
-let userId = ''
+let userId = "";
 userStore.getInfo().then((res) => {
-  console.log(res)
-  userId = res.user.userId
-})
+  console.log(res);
+  userId = res.user.userId;
+});
 const uploadData = ref({});
 const flowRules = reactive({
   // remark: [{ required: true, message: "请输入处理意见", trigger: "blur" }],
@@ -754,9 +763,9 @@ const getRecords = (_id) => {
         });
         for (let i = 0; i < res.recordList.length; i++) {
           const element = res.recordList[i];
-          if(element.status == 2) {
+          if (element.status == 2) {
             // 2为审批中
-            if(res.recordList[i - 1].processedUserId == userId) {
+            if (res.recordList[i - 1].processedUserId == userId) {
               // 当前审批人和上一条审批人相同,开启撤回开关
               isRevocation.value = true;
             }
@@ -788,18 +797,17 @@ onMounted(async () => {
     route.query.processType == 20 ||
     route.query.processType == 30
   ) {
-    if(route.query.flowKey == "account_request_funds_flow") {
+    if (route.query.flowKey == "account_request_funds_flow") {
       await proxy
         .post("/accountRequestFunds/detail", { id: route.query.businessId })
         .then((res) => {
-          queryData.data = { ...res };                          
+          queryData.data = { ...res };
         });
     } else {
-
       await proxy
         .post("/flowProcess/getStartData", { flowId: route.query.id })
         .then((res) => {
-          queryData.data = { ...res };                          
+          queryData.data = { ...res };
         });
     }
   } else {
@@ -816,7 +824,6 @@ onMounted(async () => {
   margin: 0 !important;
 }
 .el-upload-list li {
-  
   margin-left: 10px;
 }
 .el-upload--text {

+ 21 - 1
src/views/salesMange/shipmentMange/document/index.vue

@@ -1022,7 +1022,8 @@
                       :rowspan="item.documentsProductList.length"
                       v-if="sonIndex === 0"
                     >
-                      {{ index + 1 }}
+                      <!-- {{ index + 1 }} -->
+                      {{ getIndexInterval(index, item.packQuantity) }}
                     </td>
                     <td>
                       <div style="text-align: center">
@@ -3320,6 +3321,25 @@ const getChineseDate = (date) => {
     return year + "年" + month + "月" + day + "日 ";
   }
 };
+
+const getIndexInterval = (index, packQuantity) => {
+  if (index === 0) {
+    return `1 ~ ${packQuantity}`;
+  } else {
+    let s = -1;
+    let e = -1;
+    if (
+      printDetails.value.packDetailList[index - 1] &&
+      printDetails.value.packDetailList[index - 1].packQuantity != undefined
+    ) {
+      s = printDetails.value.packDetailList[index - 1].packQuantity + 1;
+      e =
+        packQuantity +
+        printDetails.value.packDetailList[index - 1].packQuantity;
+    }
+    return `${s} ~ ${e}`;
+  }
+};
 </script>
 
 <style lang="scss" scoped>

部分文件因为文件数量过多而无法显示