From 6636b48aab02c10b261562abd5dcb6f2c1566a86 Mon Sep 17 00:00:00 2001
From: qx <1084500556@qq.com>
Date: 星期二, 15 七月 2025 15:56:09 +0800
Subject: [PATCH] qx

---
 src/api/system/info.js                |   12 +
 src/views/system/comp/index.vue       |   16 +-
 src/views/hosp/commonAdvice/index.vue |   13 +
 src/views/system/info/index.vue       |  319 ++++++++++++++++++++++++++------------------
 src/api/advice/advice.js              |   14 +
 5 files changed, 229 insertions(+), 145 deletions(-)

diff --git a/src/api/advice/advice.js b/src/api/advice/advice.js
index 55d74e7..5f33bec 100644
--- a/src/api/advice/advice.js
+++ b/src/api/advice/advice.js
@@ -5,7 +5,7 @@
   return request({
     url: '/advice/advice/list',
     method: 'get',
-    params:query
+    params: query
   })
 }
 
@@ -42,3 +42,15 @@
     method: 'delete'
   })
 }
+
+
+// 鍒犻櫎advice
+export function delCyremove(ids) {
+  return request({
+    url: '/advice/advice/delCyremove',
+    method: 'delete',
+    params: {
+      ids:ids
+    }
+  })
+}
diff --git a/src/api/system/info.js b/src/api/system/info.js
index 1027b76..e942418 100644
--- a/src/api/system/info.js
+++ b/src/api/system/info.js
@@ -45,3 +45,15 @@
         method: 'delete'
     })
 }
+
+
+
+
+// 鏍规嵁鍥㈤槦浣撴缂栧彿鍜屽椁恑d鑾峰彇缁撹处淇℃伅
+export function getTjCompPay(data) {
+  return request({
+    url: '/team/pay/getTjCompPay',
+    method: 'get',
+    params:data
+  })
+}
diff --git a/src/views/hosp/commonAdvice/index.vue b/src/views/hosp/commonAdvice/index.vue
index f7f4059..e5769c8 100644
--- a/src/views/hosp/commonAdvice/index.vue
+++ b/src/views/hosp/commonAdvice/index.vue
@@ -18,6 +18,9 @@
       <el-col :span="1.5">
         <el-button type="primary" size="mini" @click="proposalChange">鏂板</el-button>
       </el-col>
+      <el-col :span="1.5">
+        <el-button type="primary" size="mini" @click="handleDelete">鎵归噺鍒犻櫎</el-button>
+      </el-col>
 
     </el-row>
 
@@ -62,7 +65,8 @@
   updateAdvice,
   addAdvice,
   getAdvice,
-  delAdvice
+  delAdvice,
+  delCyremove
 } from "@/api/advice/advice";
 import {
   addCyTjAdvice,
@@ -141,6 +145,7 @@
       this.reset();
     },
     proposalChange() {
+        this.reset();
       this.open = true;
     },
     // 琛ㄥ崟閲嶇疆
@@ -202,7 +207,6 @@
       const id = row.id || this.ids;
       this.kjbq = [];
       getAdvice(id).then((response) => {
-        console.log(response, 55566);
         this.form = response.data;
         this.open = true;
         // this.form.deptId = this.queryParams.deptId;
@@ -210,11 +214,12 @@
       });
     },
     handleDelete(row) {
-      const ids = row.id || this.ids; // 鑾峰彇涓婚敭鍊硷紝濡傛灉row涓病鏈変富閿�硷紝鍒欎娇鐢╰his.ids
+      let idss = this.ids + ''
+      const ids = row.id || idss; // 鑾峰彇涓婚敭鍊硷紝濡傛灉row涓病鏈変富閿�硷紝鍒欎娇鐢╰his.ids
       this.$modal
         .confirm(`鏄惁纭鍒犻櫎"${ids}"鐨勬暟鎹」锛焋)
         .then(() => {
-          return delAdvice(ids); // 璋冪敤鍒犻櫎鎺ュ彛锛屼紶鍏ヤ富閿��
+          return delCyremove(ids); // 璋冪敤鍒犻櫎鎺ュ彛锛屼紶鍏ヤ富閿��
         })
         .then(() => {
           this.getList(); // 鍒犻櫎鎴愬姛鍚庡埛鏂板垪琛�
diff --git a/src/views/system/comp/index.vue b/src/views/system/comp/index.vue
index 22d57ae..6dfc31d 100644
--- a/src/views/system/comp/index.vue
+++ b/src/views/system/comp/index.vue
@@ -1626,14 +1626,14 @@
     handleGroup() {
       // 濡傛灉娌℃湁閫変腑浠讳綍閮ㄩ棬锛堝嵆娌℃湁 selectionList锛夛紝鍙互鐩存帴浠� OnenewpacName 鑾峰彇鏁版嵁
       let mapList = [];
-      this.OnenewpacName.forEach((item) => {
-        mapList.push({
-          proName: item.proName,
-          proId: item.proId,
-          proPrice: item.proPrice,
-        });
-      });
-
+      // this.OnenewpacName.forEach((item) => {
+      //   mapList.push({
+      //     proName: item.proName,
+      //     proId: item.proId,
+      //     proPrice: item.proPrice,
+      //   });
+      // });
+      console.log(this.groupList)
       let data = {
         groupingName: this.forms.groupingName,
         gtAge: this.forms.gtAge,
diff --git a/src/views/system/info/index.vue b/src/views/system/info/index.vue
index de56ed4..4367b0b 100644
--- a/src/views/system/info/index.vue
+++ b/src/views/system/info/index.vue
@@ -72,7 +72,7 @@
       <el-table-column label="閮ㄩ棬" align="center" prop="pacName" />
       <el-table-column label="棰勬浜烘暟" align="center" prop="count" />
       <el-table-column label="瀹炴浜烘暟" align="center" prop="sjCount" />
-        <el-table-column label="宸茬粨浜烘暟" align="center" prop="yjsrs" />
+      <el-table-column label="宸茬粨浜烘暟" align="center" prop="yjsrs" />
       <el-table-column label="搴旀敹閲戦" align="center" prop="copeWith" />
       <el-table-column label="绛剧害閲戦" align="center" prop="signingPrice">
       </el-table-column>
@@ -82,40 +82,40 @@
       <el-table-column label="棰勭害鏃堕棿" align="center" prop="createTime" :formatter="formatDate" />
     </el-table>
 
-   
-    <div >
+
+    <div>
       <el-radio-group v-model="jcStatus" @change="radioChange" style="margin-left: 20px; margin-top: 20px">
-        <el-radio-button label="0">宸叉鏈粨璐︿汉鍛�</el-radio-button>
-        <el-radio-button label="1">鏈浜哄憳</el-radio-button>
+        <el-radio-button label="0">绛惧埌鏈粨璐︿汉鍛�</el-radio-button>
+        <el-radio-button label="1">鏈鍒颁汉鍛�</el-radio-button>
         <el-radio-button label="2">鍏ㄩ儴浜哄憳</el-radio-button>
       </el-radio-group>
 
-       <el-form :inline="true" :model="formInline" class="demo-form-inline" style="margin: 12px 6px" label-width="100px">
-      <el-row>
-        <el-col :span="5">
-          <el-form-item label="璐熻矗浜�" style="display: flex">
-            <el-input v-model="formInline.payer" placeholder="鍗曚綅璐熻矗浜�"></el-input>
-          </el-form-item>
-        </el-col>
-        <el-col :span="6">
-          <el-form-item label="浜ゆ槗閲戦" style="display: flex">
-            <el-input v-model="formInline.price" placeholder="閲戦"></el-input>
-          </el-form-item>
-        </el-col>
-        <el-col :span="6">
-          <el-form-item label="浜ゆ槗绫诲瀷" prop="payType" style="display: flex">
-            <el-select v-model="formInline.payType" placeholder="璇烽�夋嫨浜ゆ槗绫诲瀷">
-              <el-option v-for="dict in dict.type.dict_pay_type" :key="dict.value" :label="dict.label"
-                :value="dict.value"></el-option>
-            </el-select>
-          </el-form-item>
-        </el-col>
-        <el-col :span="4">
-          <el-form-item style="display: flex">
-            <el-button type="primary" size="mini" @click="SubmitEvent" style="margin: 0 15px">缁撹处</el-button>
-          </el-form-item>
-        </el-col>
-        <!-- <el-col :span="7">
+      <el-form :inline="true" :model="formInline" class="demo-form-inline" style="margin: 12px 6px" label-width="100px">
+        <el-row>
+          <el-col :span="5">
+            <el-form-item label="璐熻矗浜�" style="display: flex">
+              <el-input v-model="formInline.payer" placeholder="鍗曚綅璐熻矗浜�"></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :span="6">
+            <el-form-item label="浜ゆ槗閲戦" style="display: flex">
+              <el-input v-model="formInline.price" placeholder="閲戦"></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :span="6">
+            <el-form-item label="浜ゆ槗绫诲瀷" prop="payType" style="display: flex">
+              <el-select v-model="formInline.payType" placeholder="璇烽�夋嫨浜ゆ槗绫诲瀷">
+                <el-option v-for="dict in dict.type.dict_pay_type" :key="dict.value" :label="dict.label"
+                  :value="dict.value"></el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
+          <el-col :span="4">
+            <el-form-item style="display: flex">
+              <el-button type="primary" size="mini" @click="SubmitEvent" style="margin: 0 15px">缁撹处</el-button>
+            </el-form-item>
+          </el-col>
+          <!-- <el-col :span="7">
           <el-form-item>
             <el-button
               type="primary"
@@ -129,15 +129,15 @@
             >
           </el-form-item>
         </el-col> -->
-      </el-row>
-    </el-form>
+        </el-row>
+      </el-form>
 
 
-     
+
     </div>
 
     <el-row :gutter="20">
-       <!-- <el-form :model="queryParams1" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px"
+      <!-- <el-form :model="queryParams1" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px"
         style="margin-top: 20px; margin-right: 22%;">
         <el-form-item label="缁撹处鏃堕棿">
           <el-date-picker clearable v-model="queryParams1.reservationTime" type="date" value-format="yyyy-MM-dd"
@@ -155,12 +155,17 @@
           <span class="tj_txt">浣撴浜哄憳鎯呭喌琛�</span>
         </div>
 
-        <el-table v-loading="loadings" :data="peopleList" border max-height="260px" @selection-change="handlepeopleListChange">
+        <el-table v-loading="loadings" :data="peopleList" border max-height="260px"
+          @selection-change="handlepeopleListChange">
           <el-table-column type="selection" width="55" align="center" />
           <el-table-column label="濮撳悕" align="center" prop="name" width="100" />
-          <el-table-column label="鎬у埆" align="center" prop="xb" width="80" />
+          <el-table-column label="鎬у埆" align="center" prop="xb" width="80">
+            <template slot-scope="scope">
+              <dict-tag :options="dict.type.sys_user_sex" :value="scope.row.xb" />
+            </template>
+          </el-table-column>
           <el-table-column label="鐢佃瘽" align="center" prop="dh" width="120" />
-                    <el-table-column label="閲戦" align="center" prop="tjf" width="120" />
+          <el-table-column label="閲戦" align="center" prop="tjf" width="120" />
 
           <el-table-column label="鐘舵��" align="center" prop="tjStatus" width="80" />
           <el-table-column label="浣撴鏃堕棿" align="center" prop="tjTime">
@@ -174,20 +179,58 @@
         </div>
 
         <el-table v-loading="loading" :data="dataList" border max-height="260px">
-          <el-table-column label="浜ゆ槗閲戦" align="center" prop="transactionAmount" />
-          <el-table-column label="浜ゆ槗鏂瑰紡" align="center" prop="paymentMethod" />
-          <el-table-column label="浜ゆ槗浜哄憳" align="center" prop="payer" />
+          <el-table-column label="浜ゆ槗閲戦" align="center" prop="paidIn" />
+          <el-table-column label="浜ゆ槗鏂瑰紡" align="center" prop="paymentMethod" width="90px">
+            <template slot-scope="scope">
+              <dict-tag :options="dict.type.dict_pay_type" :value="scope.row.paymentMethod" />
+            </template>
+
+          </el-table-column>
+          <el-table-column label="浜ゆ槗浜哄憳" align="center" prop="payer" width="90px" />
           <el-table-column label="鎿嶄綔浜哄憳" align="center" prop="payee">
           </el-table-column>
-          <el-table-column label="缁撹处鏃堕棿" align="center" prop="createTime" />
+          <el-table-column label="缁撹处鏃堕棿" align="center" prop="createTime">
+            <template slot-scope="scope">
+              <span>{{ parseTime(scope.row.createTime, "{y}-{m}-{d}") }}</span>
+            </template>
+          </el-table-column>
           <el-table-column label="鎿嶄綔" align="center">
-            <template>
-              <el-button type="primary">鎾ら攢缁撹处</el-button>
+            <template slot-scope="scope">
+              <el-button type="text" size="mini" title="鎾ら攢" @click.stop="handleDelete(scope.row)"
+                icon="el-icon-refresh-left"></el-button>
+              <el-button size="mini" title="璇︽儏" type="text" @click.stop="handleClick(scope.row)"
+                icon="el-icon-document-copy"></el-button>
             </template>
           </el-table-column>
         </el-table>
       </el-col>
     </el-row>
+
+
+    <el-dialog title="璇︽儏" :visible.sync="dialogVisible" width="40%" append-to-body>
+      <el-table id="sig" v-loading="loading" :data="dialogList" border ref="tb" max-height="260px">
+        <el-table-column label="濮撳悕" align="center" prop="name" width="100" />
+        <el-table-column label="浣撴鍙�" align="center" prop="tjh" width="120" />
+        <el-table-column label="璐熻矗浜�" align="center" prop="payer" width="120" />
+        <el-table-column label="閲戦" align="center" prop="transactionAmount" width="120" />
+
+        <el-table-column label="浜ゆ槗鏂瑰紡" align="center" prop="paymentMethod" width="90px">
+          <template slot-scope="scope">
+            <dict-tag :options="dict.type.dict_pay_type" :value="scope.row.paymentMethod" />
+          </template>
+
+        </el-table-column>
+        <el-table-column label="缁撹处鏃堕棿" align="center" prop="createTime">
+          <template slot-scope="scope">
+            <span>{{ parseTime(scope.row.createTime, "{y}-{m}-{d}") }}</span>
+          </template>
+        </el-table-column>
+      </el-table>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisible = false">鍙� 娑�</el-button>
+        <!-- <el-button type="primary" @click="dialogVisible = false">纭� 瀹�</el-button> -->
+      </span>
+    </el-dialog>
   </div>
 </template>
 
@@ -204,12 +247,12 @@
   getpay,
   delInfo,
   addInfo,
-  updateInfo,
+  getTjCompPay,
 } from "@/api/system/info";
 
 export default {
   name: "Info",
-  dicts: ["dict_pay_type"],
+  dicts: ["dict_pay_type", "sys_user_sex"],
   data() {
     let checkPhoneNum = (rule, value, callback) => {
       let patter = new RegExp(/^1\s*[3456789]\s*(\d\s*){9}$/);
@@ -227,12 +270,13 @@
       jcStatus: 0,
       formInline: {
         payer: "",
-        price: "",
+        price: null,
       },
       // 閬僵灞�
       loading: true,
-       // 閬僵灞�
+      // 閬僵灞�
       loadings: false,
+      dialogVisible: false,
       // 閫変腑鏁扮粍
       ids: [],
       // 闈炲崟涓鐢�
@@ -252,6 +296,7 @@
       dataList: [],
       tableList: [],
       peopleList: [],
+      dialogList: [],
       // 寮瑰嚭灞傛爣棰�
       title: "",
       CompanyList: [],
@@ -261,6 +306,7 @@
       teamNo: "",
       // 鐧婚檰浜哄悕瀛�
       tollCollectorName: "",
+      tjhs: [],
       // 鏌ヨ鍙傛暟
       queryParams: {
         pageNum: 1,
@@ -322,32 +368,38 @@
       this.compId = val;
     },
 
-    radioChange(val) { 
+    radioChange(val) {
       this.peopleList = []
       this.loadings = true
-       let data = {
-          teamNo: this.teamNo,
-          pacId: this.pacIds
-        }
-        getTeamTjPeopleList(data).then((res) => {
-          if (res.data) {
-            if (this.jcStatus == 0) {
-              this.peopleList = res.data.yjwjzList;
-               
-            } else if (this.jcStatus == 1) {
-              this.peopleList = res.data.wjList;
-            } else {
-              this.peopleList = res.data.syList;
-            }
-           
+      let data = {
+        teamNo: this.teamNo,
+        pacId: this.pacIds
+      }
+      getTeamTjPeopleList(data).then((res) => {
+        if (res.data) {
+          if (this.jcStatus == 0) {
+            this.peopleList = res.data.yjwjzList;
+
+          } else if (this.jcStatus == 1) {
+            this.peopleList = res.data.wjList;
+          } else {
+            this.peopleList = res.data.syList;
           }
-           this.loadings = false
-        });
+
+        }
+        this.loadings = false
+      });
     },
 
 
-    handlepeopleListChange(selection){
-      console.log(selection)
+    handlepeopleListChange(selection) {
+      this.formInline.price = null
+      this.tjhs = []
+      selection.forEach(item => {
+        this.formInline.price += item.tjf
+        this.tjhs.push(item.tjh)
+      })
+
     },
 
     // 浣撴鍏徃鎷奸煶鎼滅储
@@ -391,32 +443,6 @@
         } else {
           this.$refs.tb.clearSelection();
         }
-        this.infoList.forEach((item) => {
-          this.copeWith = item.copeWith;
-          this.transactionAmount = item.transactionAmount;
-          
-          if (item.payInfo != null) {
-            this.tjCompPayId = item.payInfo.tjCompPayId;
-          }
-
-          this.formInline.payer = item.payer;
-          if (item.payInfoList != null) {
-            this.dataList = item.payInfoList;
-            this.dataList.forEach((item) => {
-              if (item.paymentMethod === 0) {
-                item.paymentMethod = "鐜伴噾鏀粯";
-              } else if (item.paymentMethod === 1) {
-                item.paymentMethod = "鍒峰崱鏀粯";
-              } else if (item.paymentMethod === 2) {
-                item.paymentMethod = "鏀粯瀹�";
-              } else if (item.paymentMethod === 3) {
-                item.paymentMethod = "寰俊";
-              } else if (item.paymentMethod === 4) {
-                item.paymentMethod = "浜戦棯浠�";
-              }
-            });
-          }
-        });
         this.loading = false;
       });
     },
@@ -448,27 +474,32 @@
         this.teamNo = item.teamNo;
         this.pacIds = item.pacId
         this.copeWith = item.copeWith;
+        this.difference = item.difference;
         this.transactionAmount = item.transactionAmount;
         if (item.payInfo != null) {
           this.tjCompPayId = item.payInfo.tjCompPayId;
         }
-        if (item.payInfoList != null) {
-          this.dataList = item.payInfoList;
-          this.dataList.forEach((item) => {
-            if (item.paymentMethod === 0) {
-              item.paymentMethod = "鐜伴噾鏀粯";
-            } else if (item.paymentMethod === 1) {
-              item.paymentMethod = "鍒峰崱鏀粯";
-            } else if (item.paymentMethod === 2) {
-              item.paymentMethod = "鏀粯瀹�";
-            } else if (item.paymentMethod === 3) {
-              item.paymentMethod = "寰俊";
-            } else if (item.paymentMethod === 4) {
-              item.paymentMethod = "浜戦棯浠�";
-            }
-          });
-        }
+        // if (item.payInfoList != null) {
+        //   this.dataList = item.payInfoList;
+        //   this.dataList.forEach((item) => {
+        //     if (item.paymentMethod === 0) {
+        //       item.paymentMethod = "鐜伴噾鏀粯";
+        //     } else if (item.paymentMethod === 1) {
+        //       item.paymentMethod = "鍒峰崱鏀粯";
+        //     } else if (item.paymentMethod === 2) {
+        //       item.paymentMethod = "鏀粯瀹�";
+        //     } else if (item.paymentMethod === 3) {
+        //       item.paymentMethod = "寰俊";
+        //     } else if (item.paymentMethod === 4) {
+        //       item.paymentMethod = "浜戦棯浠�";
+        //     }
+        //   });
+        // }
       });
+      this.tongyong()
+    },
+
+    tongyong() {
       this.loadings = true
       if (this.teamNo) {
         let data = {
@@ -486,7 +517,12 @@
                 ;
             }
           }
-           this.loadings = false
+          this.loadings = false
+        }).catch(error => {
+          this.loadings = false
+        });
+        getTjCompPay(data).then((res) => {
+          this.dataList = res.data
         });
       }
     },
@@ -502,14 +538,21 @@
       if (this.formInline.price != 0) {
         let data = {
           paymentMethod: this.formInline.payType,
-          transactionAmount: this.formInline.price,
+          copeWith: this.formInline.price,
+          paidIn: this.formInline.price,
           payee: this.tollCollectorName, // 鏀舵浜�
           tjCompPayId: this.tjCompPayId,
           payer: this.formInline.payer,
+          tjhs: this.tjhs,
+          compId: this.compId,
+          pacId: this.pacIds,
+          teamNo: this.teamNo,
+          difference: this.difference
         };
         getpay(data).then((response) => {
           this.$modal.msgSuccess("鎿嶄綔鎴愬姛");
-          this.handleQuery();
+          this.formInline.price = null
+          this.handleQuery()
           const tjnumber = this.waterId;
           const viewNum = this.mobanId;
           const params = { viewNum, tjnumber };
@@ -521,26 +564,38 @@
     },
 
     /** 閫�璐规寜閽搷浣� */
-    handleDelete() {
-      if (this.formInline.price != 0) {
-        if (this.formInline.price < this.transactionAmount) {
-          let data = {
-            paymentMethod: this.formInline.payType,
-            transactionAmount: this.formInline.price,
-            payee: this.tollCollectorName, // 鏀舵浜�
-            tjCompPayId: this.tjCompPayId,
-            payer: this.formInline.payer,
-          };
-          addInfo(data).then((response) => {
-            this.$modal.msgSuccess("鎿嶄綔鎴愬姛");
-            this.handleQuery();
-          });
-        } else {
-          this.$message.error("瓒呭嚭宸蹭粯閲戦,閫�璐瑰け璐�");
-        }
-      } else {
-        this.$message.error("閫�璐归噾棰濅笉鑳戒负0");
+    handleDelete(row) {
+      this.tjhs = []
+      if (row.payInfo.length != 0) {
+        row.payInfo.forEach(item => {
+          this.tjhs.push(item.tjh)
+        })
       }
+
+      let data = {
+        paymentMethod: row.paymentMethod,
+        copeWith: row.copeWith,
+        paidIn: row.paidIn,
+        payee: row.payee, // 鏀舵浜�
+        payer: row.payer,
+        tjhs: this.tjhs,
+        compId: row.compId,
+        pacId: row.pacId,
+        teamNo: row.teamNo,
+        difference: row.difference,
+        serialNumber: row.serialNumber,
+        id: row.id
+      };
+      addInfo(data).then((response) => {
+        this.$modal.msgSuccess("鎿嶄綔鎴愬姛");
+        this.loadings = true
+        this.handleQuery()
+      });
+    },
+
+    handleClick(row) {
+      this.dialogVisible = true
+      this.dialogList = row.payInfo
     },
     /** 瀵煎嚭鎸夐挳鎿嶄綔 */
     handleExport() { },

--
Gitblit v1.8.0