From 3c456949b70671cc2ad95ad5395dfaceda519f17 Mon Sep 17 00:00:00 2001
From: k94314517 <8417338+k94314517@user.noreply.gitee.com>
Date: 星期五, 23 二月 2024 10:12:19 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'

---
 company/src/components/enterprise/additionSubtractionApplication.vue |   30 +++++++++++++++++++++---------
 1 files changed, 21 insertions(+), 9 deletions(-)

diff --git a/company/src/components/enterprise/additionSubtractionApplication.vue b/company/src/components/enterprise/additionSubtractionApplication.vue
index 9a62700..623e54c 100644
--- a/company/src/components/enterprise/additionSubtractionApplication.vue
+++ b/company/src/components/enterprise/additionSubtractionApplication.vue
@@ -148,7 +148,7 @@
                 label="璐圭敤">
                 <template slot-scope="{row}">
                     <span v-if="activeName === '0'">{{row.fee}}</span>
-                    <span v-else>-{{row.fee}}</span>
+                    <span v-else>{{row.fee ? '-' + row.fee : ''}}</span>
                 </template>
             </el-table-column>
             <el-table-column
@@ -184,6 +184,7 @@
     import { all } from '@/api/business/solutions'
     import { getDetail } from '@/api/business/insuranceApply'
     import { create, getChangeCountCyclePriceVO } from '@/api/business/applyChange'
+    import { getDate } from '@/utils/util'
     export default {
         name: 'additionSubtractionApplication',
         extends: BaseOpera,
@@ -279,16 +280,20 @@
                 getDetail(this.form.id)
                     .then(res => {
                         this.list.push(res)
+                        this.item = res
                         this.endTime = res.endTime
                         this.form.solutionId = res.solutionId
                         this.form.solutionsName = res.solutionsName
                         this.pickerOptions = {
                             disabledDate(time) {
                                 // - 8.64e7
-                                return time.getTime() > new Date(res.endTime).getTime() || time.getTime() < new Date().getTime()
+                                if (getDate()) {
+
+                                }
+                                return time.getTime() > new Date(res.endTime).getTime() || time.getTime() < new Date(res.lastChangeDate ? res.lastChangeDate : res.startTime).getTime()
                             }
                         };
-                        this.changeSolution1(res.solutionId)
+                        // this.changeSolution1(res.solutionId)
                     })
             },
             getSummaries(param) {
@@ -304,13 +309,15 @@
                             this.form.addDetailList.forEach(item => {
                                 total += item.fee
                             })
+                            sums[index] = total
+                            return
                         } else {
                             this.form.delDetailList.forEach(item => {
                                 total += item.fee
                             })
+                            sums[index] = '-' + total
+                            return
                         }
-                        sums[index] = '-' + total
-                        return
                     }
                 })
                 return sums
@@ -391,10 +398,14 @@
                     this.$message.warning('璇峰厛閫夋嫨淇濋櫓鏂规')
                     return
                 }
+                if (!this.form.applyStartTime) {
+                    this.$message.warning('璇峰厛閫夋嫨鎵瑰崟鐢熸晥璧锋湡')
+                    return
+                }
                 if (this.activeName === '0') {
-                    this.$refs.selectEmployees.open('閫夊彇鍛樺伐', { arr: this.form.addDetailList, price: this.price, notInInsuranceApplyId: this.form.id })
+                    this.$refs.selectEmployees.open('閫夊彇鍛樺伐', { arr: this.form.addDetailList, price: this.price, notInInsuranceApplyId: this.form.id, validTime: this.form.applyStartTime })
                 } else {
-                    this.$refs.selectEmployees.open('閫夊彇鍛樺伐', { arr: this.form.delDetailList, price: this.price, insuranceApplyId: this.form.id })
+                    this.$refs.selectEmployees.open('閫夊彇鍛樺伐', { arr: this.form.delDetailList, price: this.price, insuranceApplyId: this.form.id, validTime: this.form.applyStartTime })
                 }
             },
             addUser() {
@@ -422,7 +433,9 @@
             // 鍒囨崲鏂规
             changeSolution1(e) {
                 this.company.forEach(item => {
+                    console.log(item.id + '-----' + e)
                     if (item.id === e) {
+                        console.log(item)
                         this.item = item
                     }
                 })
@@ -476,7 +489,7 @@
             },
             // 鏌ヨ鍏ㄩ儴鏂规
             getCompany() {
-                all({})
+                all({ dataType: 2 })
                     .then(res => {
                         this.company = res
                     })
@@ -509,7 +522,6 @@
                 this.seleData = e.map(item => item.name)
             },
             getValue(list) {
-                console.log(list)
                 if (this.activeName === '0') {
                     this.form.addDetailList.push(...list)
                 } else {

--
Gitblit v1.9.3