From f49106c0e22fdfca082743a610ffb4e1f24090a0 Mon Sep 17 00:00:00 2001
From: dytyqx <1342948614@qq.com>
Date: 星期二, 24 三月 2026 22:58:32 +0800
Subject: [PATCH] 增加车辆列表组织过滤供应商过滤
---
src/views/basic/gyCar/gyCarList.vue | 113 ++++++++++++++++++++++++++++++++++++++++++++++++++++++--
1 files changed, 109 insertions(+), 4 deletions(-)
diff --git a/src/views/basic/gyCar/gyCarList.vue b/src/views/basic/gyCar/gyCarList.vue
index 895bb27..7f00298 100644
--- a/src/views/basic/gyCar/gyCarList.vue
+++ b/src/views/basic/gyCar/gyCarList.vue
@@ -112,11 +112,11 @@
</el-collapse-item>
</el-collapse>
- <!-- <el-form-item label-width="78px">
+ <el-form-item label-width="78px">
<el-button type="primary" size="small" icon="el-icon-search" @click="handleQuery">
鎼� 绱�</el-button>
<el-button icon="el-icon-circle-close" size="small" @click="searchOpen = false">鍙� 娑�</el-button>
- </el-form-item> -->
+ </el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
@@ -207,12 +207,12 @@
<el-col :span="1.5">
<el-button type="primary" icon="el-icon-download" size="mini" @click="handleRowHide">闅愯棌鍒楄缃�</el-button>
</el-col>
- <el-col :span="1.5">
+ <!-- <el-col :span="1.5">
<el-button type="primary" icon="el-icon-help" size="mini" @click="handleSearch">鎼� 绱�</el-button>
</el-col>
<el-col :span="1.5">
<el-button type="primary" icon="el-icon-refresh" size="mini" @click="resetQuery">閲� 缃�</el-button>
- </el-col>
+ </el-col> -->
<!-- <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> -->
</el-row>
<div class="tableBox" v-loading="loading">
@@ -513,6 +513,109 @@
return sums;
},
+ //#region 鏉冮檺鍒ゆ柇
+ async set_ModCheck(ModRightNameCheck)
+ {
+ var Permission = false;
+ const res=await axios.get(this.$baseUrl + '/LMES/getReportByModRightNameCheck', {
+ params: {
+ "ModRightNameCheck": ModRightNameCheck,
+ "user": sessionStorage["HUserName"],
+
+ },
+ }).then(result=>{
+ if (result.data.count != 1) {
+ Permission = true;
+ this.sWhere=this.sWhere+"and HCompID ="+sessionStorage["HSupID"]
+ }
+ }).catch(error => {
+ this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+ });
+ },
+ //#endregion
+ //#region 蹇�熻繃婊�
+ async handleQuery() {
+ this.sWhere = ''
+ if (this.queryParams.ColName && this.queryParams.Comparator) {
+ var com = "";
+ switch (this.queryParams.Comparator) {
+ case "7":
+ com = "like'%" + this.queryParams.ColContent + "%'";
+ break;
+ case "8":
+ com = "like'%" + this.queryParams.ColContent + "'";
+ break;
+ case "9":
+ com = "like'" + this.queryParams.ColContent + "%'";
+ break;
+ case "10":
+ com = "not like'%" + this.queryParams.ColContent + "%'";
+ break;
+ default:
+ com = "" + this.queryParams.Comparator + "'" + this.queryParams.ColContent + "'";
+ break;
+ }
+ this.sWhere += " and " + this.queryParams.ColName + " " + com;
+ }
+ if (this.queryParams.ColName1 && this.queryParams.Comparator1) {
+ var com1 = "";
+ switch (this.queryParams.Comparator1) {
+ case "7":
+ com1 = "like'%" + this.queryParams.ColContent1 + "%'";
+ break;
+ case "8":
+ com1 = "like'%" + this.queryParams.ColContent1 + "'";
+ break;
+ case "9":
+ com1 = "like'" + this.queryParams.ColContent1 + "%'";
+ break;
+ case "10":
+ com1 = "not like'%" + this.queryParams.ColContent1 + "%'";
+ break;
+ default:
+ com1 = "" + this.queryParams.Comparator1 + "'" + this.queryParams.ColContent1 + "'";
+ break;
+ }
+ this.sWhere += " and " + this.queryParams.ColName1 + " " + com1;
+ }
+ if (this.queryParams.ColName2 && this.queryParams.Comparator2) {
+ var com2 = "";
+ switch (this.queryParams.Comparator2) {
+ case "7":
+ com2 = "like'%" + this.queryParams.ColContent2 + "%'";
+ break;
+ case "8":
+ com2 = "like'%" + this.queryParams.ColContent2 + "'";
+ break;
+ case "9":
+ com2 = "like'" + this.queryParams.ColContent2 + "%'";
+ break;
+ case "10":
+ com2 = "not like'%" + this.queryParams.ColContent2 + "%'";
+ break;
+ default:
+ com2 = "" + this.queryParams.Comparator + "'" + this.queryParams.ColContent + "'";
+ break;
+ }
+ this.sWhere += " and " + this.queryParams.ColName2 + " " + com2;
+ }
+ if (this.queryParams.sTime) {
+ this.queryParams.sTime = moment(this.queryParams.sTime).format('YYYY-MM-DD')
+ this.queryParams.eTime = moment(this.queryParams.eTime).format('YYYY-MM-DD')
+ this.sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) >= '" + this.queryParams.sTime + "'" + " and CONVERT(varchar(100),鏃ユ湡, 23) <= '" + this.queryParams.eTime + "'";
+ }
+ if (this.queryParams.HBillNo) {
+ this.sWhere += " and 鍗曟嵁鍙� like '%" + this.queryParams.HBillNo + "%'";
+ }
+ // if (this.queryParams.HOrgID) {
+ // this.sWhere += " and HOrgID = '" + this.queryParams.HOrgID + "'";
+ // }
+ console.log("swhere",this.sWhere)
+ this.clearData()
+ this.getList()
+ },
+ //#endregion
+
//#region 鑾峰彇鍏徃鍚嶏紝鏍规嵁鍏徃杩涜瀹氬埗鍖栧紑鍙�
defaintOperationByCompanyName() {
var result = false;
@@ -607,6 +710,7 @@
this.deptform = {};
},
async getList() {
+ await this.set_ModCheck("Gy_Car_SUBQuery");
this.tableShow = false;
this.loading = true;
if (this.pageSize == 0) {
@@ -865,6 +969,7 @@
document.body.removeChild(span);
return h(span, column.label);
},
+
//鐐瑰嚮琛�
handleRowClick(row, column, event) {
this.lastSelectedRow = this.selectedRow; // 璁板綍涓婁竴娆¢�変腑鐨勮
--
Gitblit v1.9.1