From 6c67a924e87f74a07a74c6f953b69e8bcc109015 Mon Sep 17 00:00:00 2001
From: lkk <364857242@qq.com>
Date: 星期一, 16 十二月 2024 10:59:47 +0800
Subject: [PATCH] jujiao

---
 src/views/hosp/order/index.vue |  168 +++++++++++++++++++++++++++++++++++++++++++++++++------
 1 files changed, 149 insertions(+), 19 deletions(-)

diff --git a/src/views/hosp/order/index.vue b/src/views/hosp/order/index.vue
index 504fde3..47a4a1f 100644
--- a/src/views/hosp/order/index.vue
+++ b/src/views/hosp/order/index.vue
@@ -13,7 +13,7 @@
           ref="inputName"
           v-model="queryParams.name"
           placeholder="璇疯緭鍏ュ鍚�"
-          style="width: 120px"
+          style="width: 200px"
           clearable
           @keyup.enter.native="handleQuery"
         />
@@ -23,7 +23,7 @@
           ref="inputName"
           v-model="queryParams.tjNum"
           placeholder="璇疯緭鍏ヤ綋妫�鍙�"
-          style="width: 170px"
+          style="width: 200px"
           clearable
           @keyup.enter.native="handleQuery"
           @blur="hb"
@@ -34,10 +34,35 @@
           ref="inputName"
           v-model="queryParams.xmmc"
           placeholder="璇疯緭鍏ヤ綋妫�椤圭洰"
-          style="width: 120px"
+          style="width: 300px"
           clearable
           @keyup.enter.native="handleQuery"
         />
+      </el-form-item>
+      <el-form-item
+        label="鍗曚綅鍚嶇О"
+        prop="tjCompName"
+        style="margin-left: 20px"
+      >
+        <el-select
+          :remote-method="getRemoteData"
+          v-model="queryParams.tjCompName"
+          value-key="drugManufacturerId"
+          style="width: 300px"
+          remote
+          filterable
+          placeholder="璇烽�夋嫨鍗曚綅鍚嶇О"
+          clearable
+          @change="searchSelect"
+          
+        >
+          <el-option
+            v-for="dict in CompanyList"
+            :key="dict.drugManufacturerId"
+            :label="dict.cnName"
+            :value="dict"
+          />
+        </el-select>
       </el-form-item>
       <el-form-item label="鐧昏鏃堕棿" prop="createTimeList">
         <el-date-picker
@@ -268,6 +293,18 @@
           :show-overflow-tooltip="true"
           width="160px"
         />
+        <el-table-column
+          label="鍗曚綅鍚嶇О"
+          align="center"
+          prop="dictCompName"
+          :show-overflow-tooltip="true"
+        />
+        <el-table-column
+          label="鐘舵��"
+          align="center"
+          prop="zt"
+          :show-overflow-tooltip="true"
+        />
         <!-- <el-table-column label="娴佹按鍙�" align="center" prop="tjSerialNumber" /> -->
         <el-table-column
           label="鎵�閫夊椁�"
@@ -276,6 +313,18 @@
           :formatter="driver"
           :show-overflow-tooltip="true"
         />
+        <el-table-column
+          label="瀵艰瘖鎵撳嵃娆℃暟"
+          align="center"
+          prop="dycs"
+          width="110px"
+          :formatter="driver"
+          :show-overflow-tooltip="true"
+        >
+          <template slot-scope="scope">
+            {{ scope.row.dycs === null ? 0 : scope.row.dycs }}
+          </template>
+        </el-table-column>
         <el-table-column
           label="鐧昏鏃堕棿"
           align="center"
@@ -317,19 +366,14 @@
         </el-table-column>
         <!-- <el-table-column label="鍒涘缓浜�" align="center" prop="createBy" /> -->
         <!-- <el-table-column label="鏇存柊浜�" align="center" prop="updateBy" /> -->
-        <el-table-column
+       <!--  <el-table-column
           label="鍗曚綅宸ュ彿"
           align="center"
           prop="firmWorkId"
           width="100px"
           :show-overflow-tooltip="true"
-        />
-        <el-table-column
-          label="鍗曚綅鍚嶇О"
-          align="center"
-          prop="dictCompName"
-          :show-overflow-tooltip="true"
-        />
+        /> -->
+        
         <!-- <el-table-column label="閮ㄩ棬鍚�" align="center" prop="firmDeptName" /> -->
 
         <!-- <el-table-column label="瀹㈡埛鐓х墖" align="center" prop="photo" /> -->
@@ -1434,6 +1478,12 @@
   getProParentIdDxList,
   getProSonDxList,
 } from "@/api/system/tijian";
+import {
+  SubmitCompany,
+  getCompany,
+  queryCompany,
+  addbatch,
+} from "@/api/team/tuanti";
 import { createLogger } from "vuex";
 export default {
   components: {
@@ -1450,6 +1500,7 @@
       DataLists: [],
       infoList: [],
       bldhs: [],
+      CompanyList: [],
       filterage: "",
       activeName1: "second",
       filterText: "",
@@ -1507,6 +1558,7 @@
       TotalPrice7: 0,
       numberList: [],
       dialogVisible: false,
+      CheckBox: {},
       // 閬僵灞�
       loading: true,
       // 閫変腑鏁扮粍
@@ -1543,6 +1595,8 @@
         bgbeginTime: null,
         bgendTime: null,
         xmmc: null,
+        tjCompName:'',
+        dw:null
       },
       startTime: "",
       startTime1: "",
@@ -1605,13 +1659,32 @@
     });
   },
   methods: {
+    // 鎼滅储
+    getRemoteData(query) {
+      if (query) {
+        let compName = query;
+        queryCompany(compName).then((response) => {
+          this.CompanyList = response.data;
+          this.CompanyList.forEach((item) => {
+            this.queryParams = item;
+          });
+        });
+      }
+    },
+    // 閫夋鏁版嵁
+    searchSelect(val) {
+      this.CheckBox = val;
+      this.queryParams.dw = this.CheckBox.cnName;
+      console.log(this.CheckBox,9999);
+      
+    },
     onPayTypeChange() {
       if (this.payType === "6" && this.form.tjType !== 3) {
-        this.cannotSelectPayType = true; 
-        this.$message.warning("璇ヤ粯娆剧被鍨嬪湪姝や綋妫�绫诲瀷涓嬩笉鍏佽閫夋嫨锛�"); 
-        this.payType = this.dict.type.dict_pay_type[0]?.value || null; 
+        this.cannotSelectPayType = true;
+        this.$message.warning("璇ヤ粯娆剧被鍨嬪湪姝や綋妫�绫诲瀷涓嬩笉鍏佽閫夋嫨锛�");
+        this.payType = this.dict.type.dict_pay_type[0]?.value || null;
       } else {
-        this.cannotSelectPayType = false; 
+        this.cannotSelectPayType = false;
       }
     },
     getdate() {
@@ -1673,6 +1746,47 @@
     },
     /** 鏌ヨ浣撴璁板綍鍒楄〃 */
     getList() {
+      this.queryParams.compId = this.CheckBox.drugManufacturerId;
+      if (this.startTime) {
+        this.queryParams.djbeginTime = this.startTime[0];
+        this.queryParams.djendTime = this.startTime[1];
+      } else if (this.createTimeList) {
+        this.queryParams.djbeginTime = this.createTimeList[0];
+        this.queryParams.djendTime = this.createTimeList[1];
+      } else if (this.createTimeList == null) {
+        this.queryParams.djbeginTime = null;
+        this.queryParams.djendTime = null;
+      }
+      if (this.startTime1) {
+        this.queryParams.bgbeginTime = this.startTime1[0];
+        this.queryParams.bgendTime = this.startTime1[1];
+      }
+
+      this.loading = true;
+      getOrderList(this.queryParams).then((response) => {
+        this.orderList = response.data.list;
+        if (this.orderList) {
+          this.orderList.forEach((item, index) => {
+            item.newID =
+              (this.queryParams.pageNum - 1) * this.queryParams.pageSize +
+              index +
+              1;
+          });
+        }
+        this.total = response.data.total;
+        this.loading = false;
+      });
+       // 鑾峰彇鍗曚綅淇℃伅闆嗗悎
+       getCompany(this.queryParams).then((response) => {
+        this.CompanyList = response.data;
+        console.log( this.CompanyList,555);
+        
+        this.loading = false;
+      });
+    },
+
+    sub() {
+      this.queryParams.compId = this.CheckBox.drugManufacturerId;
       if (this.startTime) {
         this.queryParams.djbeginTime = this.startTime[0];
         this.queryParams.djendTime = this.startTime[1];
@@ -1770,7 +1884,7 @@
       })
         .then(() => {
           revokeTjOrderByTjNum(this.tjnumbers).then((res) => {
-            this.$modal.msgSuccess(res.msg);
+            this.$modal.msgSuccess("鎾ら攢鎴愬姛");
             this.getList();
           });
         })
@@ -1864,6 +1978,7 @@
         djendTime: null,
         bgbeginTime: null,
         bgendTime: null,
+        dw: null
       };
       this.resetForm("form");
     },
@@ -1875,7 +1990,8 @@
     /** 鎼滅储鎸夐挳鎿嶄綔 */
     handleQuery() {
       this.queryParams.pageNum = 1;
-      this.getList();
+      // this.getList();
+      this.sub();
     },
     renderContents(h, { node, data, store }) {
       return (
@@ -1930,6 +2046,18 @@
       this.startTime1 = [];
       this.createTimeList = [];
       this.resetForm("queryForm");
+      this.queryParams = {
+        pageNum: 1,
+        pageSize: 10,
+        djbeginTime: null,
+        djendTime: null,
+        tjNum: null,
+        bgbeginTime: null,
+        bgendTime: null,
+        xmmc: null,
+        tjCompName:'',
+        dw:null
+      }
       this.handleQuery();
     },
     // 澶氶�夋閫変腑鏁版嵁
@@ -1945,6 +2073,7 @@
         this.cusSex = item.tjCustomerSex;
         this.form.tjType = parseInt(item.tjType);
       });
+
       this.ids = selection.map((item) => item.orderId);
       // this.tjNumbers = selection.map((item) => item.tjNumber);
       this.single = selection.length !== 1;
@@ -2170,7 +2299,7 @@
 
     // 琛ュ綍椤圭洰
     handleProject(row) {
-      this.payType = "0"
+      this.payType = "0";
       this.loading = true;
       this.DataList = [];
       this.DataList3 = [];
@@ -2240,7 +2369,7 @@
     },
     // 琛ュ綍椤圭洰
     handleProject1() {
-      this.payType = "0"
+      this.payType = "0";
       this.loading = true;
       this.DataList = [];
       this.DataList3 = [];
@@ -2726,4 +2855,5 @@
   display: flex;
   flex-direction: column;
 }
+
 </style>

--
Gitblit v1.8.0