| | |
| | | ); |
| | | if (userRes.data.data && userRes.data.data[0]) { |
| | | const userData = userRes.data.data[0]; |
| | | this.user = userData.Czymc || "admin"; |
| | | this.user = sessionStorage["HUserName"] ; |
| | | this.Organization = userData.HUSEORGID; |
| | | this.queryParams.HUSEORGID = userData.HUSEORGID; |
| | | const orgId = sessionStorage["OrganizationID"]; |
| | | this.queryParams.HUSEORGID = orgId ? Number(orgId) : null; |
| | | this.$forceUpdate(); |
| | | } |
| | | |
| | | const orgRes = await axios.get(`${this.$baseUrl}/Web/GetOrganizations`); |
| | |
| | | async getList() { |
| | | this.tableShow = false; |
| | | this.loading = true; |
| | | console.log("获取列表数据...", this.sWhere); |
| | | this.sWhere=this.sWhere+"and 使用组织 ="+sessionStorage["OrganizationID"] |
| | | await this.set_ModCheck("GyDriver_SUPQuery") |
| | | try { |
| | | const params = { |
| | | sWhere: this.sWhere || "", |
| | |
| | | console.error("加载列配置失败:", error); |
| | | } |
| | | }, |
| | | 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 所属公司ID ="+sessionStorage["HSupID"] |
| | | } |
| | | }).catch(error => { |
| | | this.$modal.msgError("接口请求失败!"); |
| | | }); |
| | | }, |
| | | |
| | | handleQuery() { |
| | | async handleQuery() { |
| | | |
| | | this.sWhere = ""; |
| | | const conditions = []; |
| | | |
| | |
| | | if (this.queryParams.HName) { |
| | | conditions.push(`驾驶员名称 like '%${this.queryParams.HName}%'`); |
| | | } |
| | | // if (this.queryParams.HUSEORGID) { |
| | | // conditions.push(`HUSEORGID = '${this.queryParams.HUSEORGID}'`); |
| | | // } |
| | | if (this.queryParams.HUSEORGID) { |
| | | conditions.push(`使用组织 = '${this.queryParams.HUSEORGID}'`); |
| | | } |
| | | |
| | | |
| | | if (this.queryParams.ColName !== "0" && this.queryParams.Comparator !== "0") { |
| | |
| | | |
| | | resetQuery() { |
| | | this.queryParams = { |
| | | HUSEORGID: this.Organization, |
| | | HUSEORGID: sessionStorage["OrganizationID"], |
| | | HName: "", |
| | | HNumber: "", |
| | | HSyncNumber: "", |