Quellcode durchsuchen

Merge branch 'dev' of http://www.baoxianzhanggui.com:8090/sxzgd/vue-insagent-pc into dev

lihongxiao vor 2 Jahren
Ursprung
Commit
ff83890622

+ 9 - 1
src/http/moudules/insCompany.js

@@ -572,7 +572,7 @@ export const deleteDrivingInsurance = (data) => {
     data
   })
 }
-//非车规则删除
+//批量修改
 export const endDateBatch = (data) => {
   return axios({
     url: '/plt/new/agreement/costs/endDateBatch',
@@ -580,3 +580,11 @@ export const endDateBatch = (data) => {
     data
   })
 }
+//批量删除
+export const deleteBatch = (data) => {
+  return axios({
+    url: '/plt/new/agreement/costs/deleteBatch',
+    method: "post",
+    data
+  })
+}

+ 36 - 13
src/views/AgreementManage/CarInsurance/AgreementEntry.vue

@@ -432,11 +432,12 @@
         </el-form-item>
       </el-form>
       <kt-common-table :tableHeights="600" :SerialShow="false" :operationWidth="250" :showOperation="true"
-        :showBatchDelete="true" :showBatchSettled="false" :showBatchPrint="false" :data="productPageResult"
-        :columns="productColumns" @findPage="productCostFindPage" button2Name="编辑"
+        :showBatchDelete="true" :showBatchSettled="false" :showBatchPrint="false" :customToolseletted="true"
+        :data="productPageResult" :columns="productColumns" @findPage="productCostFindPage" button2Name="编辑"
         permsButton2="agreement:input:productCost" @handleButton2="productUpdate" deleteName="批量修改"
-        @handleDelete="batchUpdate" button3Name="删除" permsButton3="agreement:input:productCost"
-        @handleButton3="productDelete" button5Name="轨迹" @handleButton5="trajectory" button3Icon="">
+        @handleDelete="batchUpdate" @customTool="batchDelete" customToolName="批量删除" button3Name="删除"
+        permsButton3="agreement:input:productCost" @handleButton3="productDelete" button5Name="轨迹"
+        @handleButton5="trajectory" button3Icon="">
       </kt-common-table>
     </el-dialog>
     <!-- 订单轨迹 -->
@@ -880,7 +881,8 @@
         </el-form-item>
         <el-form-item label="费用止期">
           <el-date-picker style="width: 100%" v-model="productcopyItemPageRequest.costsEndDate" type="date"
-            placeholder="选择费用结束日期" @change="costsEndDateChange1" value-format="yyyy-MM-dd">
+            placeholder="选择费用结束日期" @change="costsEndDateChange1" :picker-options="productcopypickerOptions"
+            value-format="yyyy-MM-dd">
           </el-date-picker>
         </el-form-item>
         <el-form-item label="费用描述">
@@ -1258,6 +1260,7 @@ export default {
   },
   data() {
     return {
+
       insuranceCompanyId: "",
       productUpdateObj: {
         productId: "",
@@ -1377,6 +1380,8 @@ export default {
       ],
       underwritingRulesColumns: [
         { prop: "validInd", label: " 是否有效", minWidth: 160, formatter: this.validIndFormatter, },
+        { prop: "rulesStartDate", label: " 规则起期", minWidth: 160 },
+        { prop: "rulesEndDate", label: " 规则止期", minWidth: 160 },
         { prop: "ruleDescription", label: " 规则描述", minWidth: 160 },
         { prop: "desc", label: " 规则因子描述", minWidth: 660 },
       ],
@@ -2230,6 +2235,11 @@ export default {
         disabledDate: this.disabledDate,
       };
     },
+    productcopypickerOptions() {
+      return {
+        disabledDate: this.disabledDate1,
+      };
+    },
   },
   created() {
     this.peopleid = Cookies.get("user");
@@ -2466,14 +2476,6 @@ export default {
           type: "error",
         });
       }
-      if (!this.validateEndDate(tempStartDate, tempEndDate)) {
-        this.productcopyItemPageRequest.costsEndDate = null;
-        this.$message({
-          message: "止期不能小于/等于起期!",
-          type: "error",
-        });
-      }
-
     },
     productcopyItemQuery() {
       this.productcopyItemFindPage();
@@ -2884,6 +2886,22 @@ export default {
       this.batchUpdateForm.ids = data;
       this.batchdialogVisible = true;
     },
+    batchDelete(data) {
+      this.$api.insCompany.deleteBatch( data).then((res) => {
+        if (res.code == '200') {
+          this.productCostFindPage();
+          this.$message({
+            type: 'success',
+            message: res.msg,
+          });
+        } else {
+          this.$message({
+            type: 'error',
+            message: res.msg,
+          });
+        }
+      });
+    },
     batchCostsubmit() {
       this.$api.insCompany.endDateBatch(this.batchUpdateForm).then((res) => {
         if (res.code == '200') {
@@ -3088,6 +3106,11 @@ export default {
         return time.getTime() < Date.now() - 8.64e7;
       }
     },
+    disabledDate1(time) {
+      let datetime = this.productcopyItemPageRequest.costStartDate;
+      const disabledTime = new Date(datetime).getTime() - 8.64e7;
+      return time.getTime() < disabledTime;
+    },
     validateEndDate(startDateStr, endDateStr) {
       const startDate = new Date(startDateStr);
       const endDate = new Date(endDateStr);

+ 8 - 7
src/views/FinancialManagement/CarInsurance/DeptSettlement/UnsettledCommissionListExamine.vue

@@ -21,14 +21,13 @@
 
       <kt-common-table :operationWidth="240" :showBatchDelete="false" :showBatchPrint="false"
         permsButton3="sys:unsettledCommissionListExamine:audit" :data="pageResult" :columns="columns" @findPage="findPage"
-        button3Name="审核驳回" button3Type="text"  @handleButton3="handleButton3" 
+        button3Name="审核驳回" button3Type="text"  @handleButton3="handleButton3"
         button4Type="text"  button4Name="审核通过"  @handleButton4="handleButton4" @handlePrint="handlePrint">
       </kt-common-table>
     </el-main>
     <el-dialog
       :visible.sync="dialogVisibleBatch"
-      width="35%"
-      :before-close="handleCloseBatch">
+      width="35%" @close="BatchClose">
       <p >凭证号 :<el-input style="width: 200px;" v-model="voucherId" placeholder="请输入凭证号"></el-input></p>
       <div style="display: flex">上传图片:  <el-upload
                 action="#"
@@ -92,6 +91,10 @@ export default {
 
   },
   methods: {
+    BatchClose(){
+      this.voucherId="";
+      this.qrCodeImage="";
+    },
     handlePrint() {
       this.$api.task.excelExport(this.pageRequest).then(res => {
         console.log(res)
@@ -191,9 +194,7 @@ export default {
         }
       });
     },
-    handleCloseBatch() {
-      this.dialogVisibleBatch=false
-    },
+
     handleButton4({ row, index }) {
       this.rowlist=row
       this.dialogVisibleBatch=true
@@ -201,12 +202,12 @@ export default {
     handleSumbit(){
       this.$api.task.withdraAaudit({ ...this.rowlist, status: '1',picId:this.picId,voucherId:this.voucherId }).then(res => {
           if (res.code == 200) {
-            this.dialogVisibleBatch = false
             this.findPage(null);
             this.$message({
               type: 'success',
               message: '审核通过'
             });
+            this.dialogVisibleBatch = false
           }
           else {
             this.$message.error(res.msg)