Bladeren bron

去掉费用管理、添加和编辑费用时入口比例不能小于手续费的校验

@dongkboy 2 maanden geleden
bovenliggende
commit
498ee90794

+ 25 - 26
src/views/quoteConfig/agreement/agreementDetails.vue

@@ -785,33 +785,31 @@ const ruleFeeSave = (data: object) => {
   });
 }
 const ruleFeeEditSave = (data: object) => {
-  // 检查入口比例是否小于入口手续费比例
-  const hasInvalidItem = data.ptlAgreementCostTypeList.some((item: any) => {
-    // 获取当前险种对应的入口手续费比例
-    let entranceFeeRatio = 0;
-    if (item.costType == '交强险') {
-      entranceFeeRatio = handlingFeeInfo.value?.jqEntranceFeeRatio || 0;
-    } else if (item.costType == '商业险') {
-      entranceFeeRatio = handlingFeeInfo.value?.syEntranceFeeRatio || 0;
-    } else if (item.costType == '驾意险') {
-      entranceFeeRatio = handlingFeeInfo.value?.jyEntranceFeeRatio || 0;
-    }
+  // const hasInvalidItem = data.ptlAgreementCostTypeList.some((item: any) => {
+  //   let entranceFeeRatio = 0;
+  //   if (item.costType == '交强险') {
+  //     entranceFeeRatio = handlingFeeInfo.value?.jqEntranceFeeRatio || 0;
+  //   } else if (item.costType == '商业险') {
+  //     entranceFeeRatio = handlingFeeInfo.value?.syEntranceFeeRatio || 0;
+  //   } else if (item.costType == '驾意险') {
+  //     entranceFeeRatio = handlingFeeInfo.value?.jyEntranceFeeRatio || 0;
+  //   }
 
-    // 检查入口比例是否小于入口手续费比例(转换为数字比较)
-    if (Number(item.inlet) < Number(entranceFeeRatio)) {
-      ElMessage({
-        type: 'warning',
-        message: `${item.costType}入口比例不能小于入口手续费比例(${entranceFeeRatio}%)`,
-        plain: true,
-      });
-      return true; // 找到不符合条件的项,中断循环
-    }
-    return false;
-  });
+  //   // 检查入口比例是否小于入口手续费比例(转换为数字比较)
+  //   if (Number(item.inlet) < Number(entranceFeeRatio)) {
+  //     ElMessage({
+  //       type: 'warning',
+  //       message: `${item.costType}入口比例不能小于入口手续费比例(${entranceFeeRatio}%)`,
+  //       plain: true,
+  //     });
+  //     return true; // 找到不符合条件的项,中断循环
+  //   }
+  //   return false;
+  // });
 
-  if (hasInvalidItem) {
-    return;
-  }
+  // if (hasInvalidItem) {
+  //   return;
+  // }
   api.agreementApi.AgreementFeeupdate(data).then((res: any) => {
     if (res.code == '200') {
       ElMessage({
@@ -1016,9 +1014,10 @@ const uploadImage = (file: any) => {
 }
 
 :deep(.ruleFee .el-tabs__item) {
-  height: 40px;
   font-size: 14px;
   font-weight: 500 !important;
+  align-items: center;
+
 }
 
 :deep(.agreement .p-5) {

+ 44 - 44
src/views/quoteConfig/agreement/components/ruleFeeDialog.vue

@@ -330,32 +330,32 @@ const save = async (formEl: FormInstance | undefined | any) => {
               });
               return;
             }
-            // 检查入口比例是否小于入口手续费比例
-            const hasInvalidItem = formRef.ptlAgreementCostTypeList.some((item: any) => {
-              // 获取当前险种对应的入口手续费比例
-              let entranceFeeRatio = 0;
-              if (item.costType == '交强险') {
-                entranceFeeRatio = props.handlingFee?.jqEntranceFeeRatio || 0;
-              } else if (item.costType == '商业险') {
-                entranceFeeRatio = props.handlingFee?.syEntranceFeeRatio || 0;
-              } else if (item.costType == '驾意险') {
-                entranceFeeRatio = props.handlingFee?.jyEntranceFeeRatio || 0;
-              }
+            // // 检查入口比例是否小于入口手续费比例
+            // const hasInvalidItem = formRef.ptlAgreementCostTypeList.some((item: any) => {
+            //   // 获取当前险种对应的入口手续费比例
+            //   let entranceFeeRatio = 0;
+            //   if (item.costType == '交强险') {
+            //     entranceFeeRatio = props.handlingFee?.jqEntranceFeeRatio || 0;
+            //   } else if (item.costType == '商业险') {
+            //     entranceFeeRatio = props.handlingFee?.syEntranceFeeRatio || 0;
+            //   } else if (item.costType == '驾意险') {
+            //     entranceFeeRatio = props.handlingFee?.jyEntranceFeeRatio || 0;
+            //   }
 
-              // 检查入口比例是否小于入口手续费比例(转换为数字比较)
-              if (Number(item.inlet) < Number(entranceFeeRatio)) {
-                ElMessage({
-                  type: 'warning',
-                  message: `${item.costType}入口比例不能小于入口手续费比例(${entranceFeeRatio}%)`,
-                  plain: true,
-                });
-                return true; // 找到不符合条件的项,中断循环
-              }
-              return false;
-            });
-            if (hasInvalidItem) {
-              return;
-            }
+            //   // 检查入口比例是否小于入口手续费比例(转换为数字比较)
+            //   if (Number(item.inlet) < Number(entranceFeeRatio)) {
+            //     ElMessage({
+            //       type: 'warning',
+            //       message: `${item.costType}入口比例不能小于入口手续费比例(${entranceFeeRatio}%)`,
+            //       plain: true,
+            //     });
+            //     return true; // 找到不符合条件的项,中断循环
+            //   }
+            //   return false;
+            // });
+            // if (hasInvalidItem) {
+            //   return;
+            // }
             if (ruleFeeinfo.value[insuranceTypeIndex.value].ptlAgreementCostAddList[index].ruleConditions.length && result) {
               resolve(true);
             }
@@ -440,26 +440,26 @@ const addRuleCondition = (index: number, Costindex: number) => {
 }
 
 const handelRK = (scope) => {
-  // 获取当前险种对应的入口手续费比例
-  let entranceFeeRatio = 0;
-  if (scope.row.costType == '交强险') {
-    entranceFeeRatio = props.handlingFee?.jqEntranceFeeRatio || 0;
-  } else if (scope.row.costType == '商业险') {
-    entranceFeeRatio = props.handlingFee?.syEntranceFeeRatio || 0;
-  } else if (scope.row.costType == '驾意险') {
-    entranceFeeRatio = props.handlingFee?.jyEntranceFeeRatio || 0;
-  }
+  // // 获取当前险种对应的入口手续费比例
+  // let entranceFeeRatio = 0;
+  // if (scope.row.costType == '交强险') {
+  //   entranceFeeRatio = props.handlingFee?.jqEntranceFeeRatio || 0;
+  // } else if (scope.row.costType == '商业险') {
+  //   entranceFeeRatio = props.handlingFee?.syEntranceFeeRatio || 0;
+  // } else if (scope.row.costType == '驾意险') {
+  //   entranceFeeRatio = props.handlingFee?.jyEntranceFeeRatio || 0;
+  // }
 
-  // 检查入口比例是否小于入口手续费比例
-  if (scope.row.inlet < entranceFeeRatio) {
-    ElMessage({
-      type: 'warning',
-      message: `入口比例不能小于入口手续费比例(${entranceFeeRatio}%)`,
-      plain: true,
-    });
-    scope.row.inlet = entranceFeeRatio;
-    return;
-  }
+  // // 检查入口比例是否小于入口手续费比例
+  // if (scope.row.inlet < entranceFeeRatio) {
+  //   ElMessage({
+  //     type: 'warning',
+  //     message: `入口比例不能小于入口手续费比例(${entranceFeeRatio}%)`,
+  //     plain: true,
+  //   });
+  //   scope.row.inlet = entranceFeeRatio;
+  //   return;
+  // }
 
   console.log(scope.row)
   if (scope.row.export && scope.row.addThrow || scope.row.export && scope.row.addThrow === 0) {

+ 19 - 19
src/views/quoteConfig/agreement/components/ruleFeeDialogEdit.vue

@@ -241,26 +241,26 @@ const addRules = () => {
 }
 
 const handelRK = (scope) => {
- // 获取当前险种对应的入口手续费比例
- let entranceFeeRatio = 0;
-  if (scope.row.costType == '交强险') {
-    entranceFeeRatio = costitemEditInfo.value?.jqEntranceFeeRatio || 0;
-  } else if (scope.row.costType == '商业险') {
-    entranceFeeRatio = costitemEditInfo.value?.syEntranceFeeRatio || 0;
-  } else if (scope.row.costType == '驾意险') {
-    entranceFeeRatio = costitemEditInfo.value?.jyEntranceFeeRatio || 0;
-  }
+//  // 获取当前险种对应的入口手续费比例
+//  let entranceFeeRatio = 0;
+//   if (scope.row.costType == '交强险') {
+//     entranceFeeRatio = costitemEditInfo.value?.jqEntranceFeeRatio || 0;
+//   } else if (scope.row.costType == '商业险') {
+//     entranceFeeRatio = costitemEditInfo.value?.syEntranceFeeRatio || 0;
+//   } else if (scope.row.costType == '驾意险') {
+//     entranceFeeRatio = costitemEditInfo.value?.jyEntranceFeeRatio || 0;
+//   }
 
-  // 检查入口比例是否小于入口手续费比例
-  if (scope.row.inlet < entranceFeeRatio) {
-    ElMessage({
-      type: 'warning',
-      message: `入口比例不能小于入口手续费比例(${entranceFeeRatio}%)`,
-      plain: true,
-    });
-    scope.row.inlet = entranceFeeRatio;
-    return;
-  }
+//   // 检查入口比例是否小于入口手续费比例
+//   if (scope.row.inlet < entranceFeeRatio) {
+//     ElMessage({
+//       type: 'warning',
+//       message: `入口比例不能小于入口手续费比例(${entranceFeeRatio}%)`,
+//       plain: true,
+//     });
+//     scope.row.inlet = entranceFeeRatio;
+//     return;
+//   }
 
     if(scope.row.export&&scope.row.addThrow || scope.row.export&&scope.row.addThrow === 0) {
         scope.row.keepPointRatio = scope.row.inlet + scope.row.addThrow - scope.row.export

+ 2 - 2
src/views/receivable/documentary/documentaryRecord.vue

@@ -111,9 +111,9 @@
         <el-form-item prop="receivableAmount" label="应收金额">
           <el-input v-model="countForm.receivableAmount" disabled placeholder="请输入"></el-input>
         </el-form-item>
-        <el-form-item prop="overinflatedAmount" label="虚增金额">
+        <!-- <el-form-item prop="overinflatedAmount" label="虚增金额">
           <el-input v-model="countForm.overinflatedAmount" disabled placeholder="请输入"></el-input>
-        </el-form-item>
+        </el-form-item> -->
         <el-form-item prop="taxPoint" label="税点">
           <el-input v-model="countForm.taxPoint" disabled placeholder="请输入"></el-input>
         </el-form-item>