diff --git a/config/index.js b/config/index.js index 83d2e65..45fc349 100644 --- a/config/index.js +++ b/config/index.js @@ -70,7 +70,7 @@ "/IotPc": { // 物联网平台端信息汇总 // 'target': 'http://192.168.16.115:8288', // 接口域名 - target: "http://192.168.16.100:8289", // 接口域名 + target: "http://132.232.115.20:8289", // 接口域名 changeOrigin: true, //是否跨域 pathRewrite: { "^/IotPc": "" //需要rewrite重写的, diff --git a/config/index.js b/config/index.js index 83d2e65..45fc349 100644 --- a/config/index.js +++ b/config/index.js @@ -70,7 +70,7 @@ "/IotPc": { // 物联网平台端信息汇总 // 'target': 'http://192.168.16.115:8288', // 接口域名 - target: "http://192.168.16.100:8289", // 接口域名 + target: "http://132.232.115.20:8289", // 接口域名 changeOrigin: true, //是否跨域 pathRewrite: { "^/IotPc": "" //需要rewrite重写的, diff --git a/src/assets/css/index.css b/src/assets/css/index.css index 2a68327..a2a46b0 100644 --- a/src/assets/css/index.css +++ b/src/assets/css/index.css @@ -11,9 +11,6 @@ --black: rgb(0, 0, 0); /* 原色为黑色,切换后的颜色为白色,设置边框时使用 */ - --lightgray: #c1c5cc; - --lightblue: rgb(102, 177, 255); - --dialogtitle: rgb(0, 255, 255); /* 弹框高亮标题颜色 */ @@ -78,6 +75,14 @@ --selectlist: transparent; /* 下拉框默认背景色为透明色 变为#f4f8ff*/ + + --shouselect: rgb(60, 57, 57); + /* 首页下拉框默认背景色 变为#f4f8ff */ + + --elmentbgc: rgb(58, 58, 60); + + --diagiobgc: #000; + /* 弹框默认背景色 变为206, 223, 255 */ } .form-cascader .el-cascader-panel .el-radio { diff --git a/config/index.js b/config/index.js index 83d2e65..45fc349 100644 --- a/config/index.js +++ b/config/index.js @@ -70,7 +70,7 @@ "/IotPc": { // 物联网平台端信息汇总 // 'target': 'http://192.168.16.115:8288', // 接口域名 - target: "http://192.168.16.100:8289", // 接口域名 + target: "http://132.232.115.20:8289", // 接口域名 changeOrigin: true, //是否跨域 pathRewrite: { "^/IotPc": "" //需要rewrite重写的, diff --git a/src/assets/css/index.css b/src/assets/css/index.css index 2a68327..a2a46b0 100644 --- a/src/assets/css/index.css +++ b/src/assets/css/index.css @@ -11,9 +11,6 @@ --black: rgb(0, 0, 0); /* 原色为黑色,切换后的颜色为白色,设置边框时使用 */ - --lightgray: #c1c5cc; - --lightblue: rgb(102, 177, 255); - --dialogtitle: rgb(0, 255, 255); /* 弹框高亮标题颜色 */ @@ -78,6 +75,14 @@ --selectlist: transparent; /* 下拉框默认背景色为透明色 变为#f4f8ff*/ + + --shouselect: rgb(60, 57, 57); + /* 首页下拉框默认背景色 变为#f4f8ff */ + + --elmentbgc: rgb(58, 58, 60); + + --diagiobgc: #000; + /* 弹框默认背景色 变为206, 223, 255 */ } .form-cascader .el-cascader-panel .el-radio { diff --git a/src/components/ConfigManager/SiteManagement.vue b/src/components/ConfigManager/SiteManagement.vue index 99f2424..f5013a7 100644 --- a/src/components/ConfigManager/SiteManagement.vue +++ b/src/components/ConfigManager/SiteManagement.vue @@ -154,7 +154,7 @@ v-loading="loading" element-loading-text="正在上传图片..." element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" :auto-upload="false" multiple action="#" diff --git a/config/index.js b/config/index.js index 83d2e65..45fc349 100644 --- a/config/index.js +++ b/config/index.js @@ -70,7 +70,7 @@ "/IotPc": { // 物联网平台端信息汇总 // 'target': 'http://192.168.16.115:8288', // 接口域名 - target: "http://192.168.16.100:8289", // 接口域名 + target: "http://132.232.115.20:8289", // 接口域名 changeOrigin: true, //是否跨域 pathRewrite: { "^/IotPc": "" //需要rewrite重写的, diff --git a/src/assets/css/index.css b/src/assets/css/index.css index 2a68327..a2a46b0 100644 --- a/src/assets/css/index.css +++ b/src/assets/css/index.css @@ -11,9 +11,6 @@ --black: rgb(0, 0, 0); /* 原色为黑色,切换后的颜色为白色,设置边框时使用 */ - --lightgray: #c1c5cc; - --lightblue: rgb(102, 177, 255); - --dialogtitle: rgb(0, 255, 255); /* 弹框高亮标题颜色 */ @@ -78,6 +75,14 @@ --selectlist: transparent; /* 下拉框默认背景色为透明色 变为#f4f8ff*/ + + --shouselect: rgb(60, 57, 57); + /* 首页下拉框默认背景色 变为#f4f8ff */ + + --elmentbgc: rgb(58, 58, 60); + + --diagiobgc: #000; + /* 弹框默认背景色 变为206, 223, 255 */ } .form-cascader .el-cascader-panel .el-radio { diff --git a/src/components/ConfigManager/SiteManagement.vue b/src/components/ConfigManager/SiteManagement.vue index 99f2424..f5013a7 100644 --- a/src/components/ConfigManager/SiteManagement.vue +++ b/src/components/ConfigManager/SiteManagement.vue @@ -154,7 +154,7 @@ v-loading="loading" element-loading-text="正在上传图片..." element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" :auto-upload="false" multiple action="#" diff --git a/src/components/ConfigManager/project.vue b/src/components/ConfigManager/project.vue index b4fb535..6e87663 100644 --- a/src/components/ConfigManager/project.vue +++ b/src/components/ConfigManager/project.vue @@ -122,6 +122,7 @@ :field-list="projectFormInfo.fieldList" :rules="projectFormInfo.rules" :list-type-info="listTypeInfo" + :limit-time="projectFormInfo.limitTime" :label-width="projectFormInfo.labelWidth" :need-clear-nodes="projectFormInfo.needClearNodes" :cascader-options="projectFormInfo.cascaderOptions" @@ -475,8 +476,11 @@ rules: {}, labelWidth: "110px", cascaderOptions: [], //区域级联数据源 - needClearNodes: false //是否清除级联上次数据高亮 - } + needClearNodes: false, //是否清除级联上次数据高亮 + limitTime: true, //是否开启选择时间区段限制 + }, + //保存当前选中城市信息以便获取经纬度 + currentCity: {}, }; }, watch: { @@ -632,6 +636,7 @@ this.dialogInfo.visible = true; this.projectFormInfo.needClearNodes = false; this.projectFormInfo.cascaderOptions = this.removeEmptyChild(this.allCity); + console.log(8888,this.removeEmptyChild(this.allCity)); for (let key in data) { if (key in this.projectFormInfo.data) { this.projectFormInfo.data[key] = data[key]; @@ -643,6 +648,30 @@ this.initRules(); }, 0); break; + //提交数据 + case "submit": + let submitType = this.dialogInfo.type; + let submitApi, submitParams; + this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); + const { lat, lon } = this.currentCity; + this.projectFormInfo.data.longitude = lon; + this.projectFormInfo.data.latitude = lat; + if(submitType === "update" || submitType === "create") { + this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); + this.projectFormInfo.ref.validate(valid => { + if (valid) { + this.btnLoading = true; + submitApi = this.nozzle.sysPlatformAddOrUpdate; + submitParams = { + data: this.projectFormInfo.data + }; + this.handleAjax(submitApi, submitParams); + }else{ + return false; + } + }); + } + break; //项目删除按钮 case "delete": this.$confirm("此操作将永久删除该数据, 是否继续?", "提示", { @@ -762,30 +791,6 @@ }) }).catch(() =>{}) break; - //提交数据 - case "submit": - let submitType = this.dialogInfo.type; - let submitApi, submitParams; - console.log(333,this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions)); - let {lat, lon} = this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); - this.projectFormInfo.data.lat = lat; - this.projectFormInfo.data.lon = lon; - if(submitType === "update" || submitType === "create") { - this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); - this.projectFormInfo.ref.validate(valid => { - if (valid) { - this.btnLoading = true; - submitApi = this.nozzle.sysPlatformAddOrUpdate; - submitParams = { - data: this.projectFormInfo.data - }; - this.handleAjax(submitApi, submitParams); - }else{ - return false; - } - }); - } - break; //添加站点到项目 case "insert": if (this.UnRelateSiteTableInfo.selectList.length) { @@ -991,23 +996,15 @@ }, //遍历城市数组取得选中城市的经纬度,arr城市数组,id当前所选城市id getCurrentCityJwd(id, arr) { - let currentCity; - let flag = arr.some(item => { + arr.forEach(item => { if (item.id === id) { - currentCity = item; - console.log(1111,currentCity); - return true; + this.currentCity = {...item}; }else{ if (item.children && item.children.length) { this.getCurrentCityJwd(id, item.children); } } }); - if(flag) { - console.log(currentCity); - return currentCity; - } - } } }; diff --git a/config/index.js b/config/index.js index 83d2e65..45fc349 100644 --- a/config/index.js +++ b/config/index.js @@ -70,7 +70,7 @@ "/IotPc": { // 物联网平台端信息汇总 // 'target': 'http://192.168.16.115:8288', // 接口域名 - target: "http://192.168.16.100:8289", // 接口域名 + target: "http://132.232.115.20:8289", // 接口域名 changeOrigin: true, //是否跨域 pathRewrite: { "^/IotPc": "" //需要rewrite重写的, diff --git a/src/assets/css/index.css b/src/assets/css/index.css index 2a68327..a2a46b0 100644 --- a/src/assets/css/index.css +++ b/src/assets/css/index.css @@ -11,9 +11,6 @@ --black: rgb(0, 0, 0); /* 原色为黑色,切换后的颜色为白色,设置边框时使用 */ - --lightgray: #c1c5cc; - --lightblue: rgb(102, 177, 255); - --dialogtitle: rgb(0, 255, 255); /* 弹框高亮标题颜色 */ @@ -78,6 +75,14 @@ --selectlist: transparent; /* 下拉框默认背景色为透明色 变为#f4f8ff*/ + + --shouselect: rgb(60, 57, 57); + /* 首页下拉框默认背景色 变为#f4f8ff */ + + --elmentbgc: rgb(58, 58, 60); + + --diagiobgc: #000; + /* 弹框默认背景色 变为206, 223, 255 */ } .form-cascader .el-cascader-panel .el-radio { diff --git a/src/components/ConfigManager/SiteManagement.vue b/src/components/ConfigManager/SiteManagement.vue index 99f2424..f5013a7 100644 --- a/src/components/ConfigManager/SiteManagement.vue +++ b/src/components/ConfigManager/SiteManagement.vue @@ -154,7 +154,7 @@ v-loading="loading" element-loading-text="正在上传图片..." element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" :auto-upload="false" multiple action="#" diff --git a/src/components/ConfigManager/project.vue b/src/components/ConfigManager/project.vue index b4fb535..6e87663 100644 --- a/src/components/ConfigManager/project.vue +++ b/src/components/ConfigManager/project.vue @@ -122,6 +122,7 @@ :field-list="projectFormInfo.fieldList" :rules="projectFormInfo.rules" :list-type-info="listTypeInfo" + :limit-time="projectFormInfo.limitTime" :label-width="projectFormInfo.labelWidth" :need-clear-nodes="projectFormInfo.needClearNodes" :cascader-options="projectFormInfo.cascaderOptions" @@ -475,8 +476,11 @@ rules: {}, labelWidth: "110px", cascaderOptions: [], //区域级联数据源 - needClearNodes: false //是否清除级联上次数据高亮 - } + needClearNodes: false, //是否清除级联上次数据高亮 + limitTime: true, //是否开启选择时间区段限制 + }, + //保存当前选中城市信息以便获取经纬度 + currentCity: {}, }; }, watch: { @@ -632,6 +636,7 @@ this.dialogInfo.visible = true; this.projectFormInfo.needClearNodes = false; this.projectFormInfo.cascaderOptions = this.removeEmptyChild(this.allCity); + console.log(8888,this.removeEmptyChild(this.allCity)); for (let key in data) { if (key in this.projectFormInfo.data) { this.projectFormInfo.data[key] = data[key]; @@ -643,6 +648,30 @@ this.initRules(); }, 0); break; + //提交数据 + case "submit": + let submitType = this.dialogInfo.type; + let submitApi, submitParams; + this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); + const { lat, lon } = this.currentCity; + this.projectFormInfo.data.longitude = lon; + this.projectFormInfo.data.latitude = lat; + if(submitType === "update" || submitType === "create") { + this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); + this.projectFormInfo.ref.validate(valid => { + if (valid) { + this.btnLoading = true; + submitApi = this.nozzle.sysPlatformAddOrUpdate; + submitParams = { + data: this.projectFormInfo.data + }; + this.handleAjax(submitApi, submitParams); + }else{ + return false; + } + }); + } + break; //项目删除按钮 case "delete": this.$confirm("此操作将永久删除该数据, 是否继续?", "提示", { @@ -762,30 +791,6 @@ }) }).catch(() =>{}) break; - //提交数据 - case "submit": - let submitType = this.dialogInfo.type; - let submitApi, submitParams; - console.log(333,this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions)); - let {lat, lon} = this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); - this.projectFormInfo.data.lat = lat; - this.projectFormInfo.data.lon = lon; - if(submitType === "update" || submitType === "create") { - this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); - this.projectFormInfo.ref.validate(valid => { - if (valid) { - this.btnLoading = true; - submitApi = this.nozzle.sysPlatformAddOrUpdate; - submitParams = { - data: this.projectFormInfo.data - }; - this.handleAjax(submitApi, submitParams); - }else{ - return false; - } - }); - } - break; //添加站点到项目 case "insert": if (this.UnRelateSiteTableInfo.selectList.length) { @@ -991,23 +996,15 @@ }, //遍历城市数组取得选中城市的经纬度,arr城市数组,id当前所选城市id getCurrentCityJwd(id, arr) { - let currentCity; - let flag = arr.some(item => { + arr.forEach(item => { if (item.id === id) { - currentCity = item; - console.log(1111,currentCity); - return true; + this.currentCity = {...item}; }else{ if (item.children && item.children.length) { this.getCurrentCityJwd(id, item.children); } } }); - if(flag) { - console.log(currentCity); - return currentCity; - } - } } }; diff --git a/src/components/DataAnalysis/StatisticalReport.vue b/src/components/DataAnalysis/StatisticalReport.vue index 3b7b097..6cea6d3 100644 --- a/src/components/DataAnalysis/StatisticalReport.vue +++ b/src/components/DataAnalysis/StatisticalReport.vue @@ -158,7 +158,7 @@ lock: true, text: "Loading", spinner: "el-icon-loading", - background: "rgba(0, 0, 0, 0.7)" + background: "rgba(255, 255, 255, 0.3)" }); this.getData1(); } diff --git a/config/index.js b/config/index.js index 83d2e65..45fc349 100644 --- a/config/index.js +++ b/config/index.js @@ -70,7 +70,7 @@ "/IotPc": { // 物联网平台端信息汇总 // 'target': 'http://192.168.16.115:8288', // 接口域名 - target: "http://192.168.16.100:8289", // 接口域名 + target: "http://132.232.115.20:8289", // 接口域名 changeOrigin: true, //是否跨域 pathRewrite: { "^/IotPc": "" //需要rewrite重写的, diff --git a/src/assets/css/index.css b/src/assets/css/index.css index 2a68327..a2a46b0 100644 --- a/src/assets/css/index.css +++ b/src/assets/css/index.css @@ -11,9 +11,6 @@ --black: rgb(0, 0, 0); /* 原色为黑色,切换后的颜色为白色,设置边框时使用 */ - --lightgray: #c1c5cc; - --lightblue: rgb(102, 177, 255); - --dialogtitle: rgb(0, 255, 255); /* 弹框高亮标题颜色 */ @@ -78,6 +75,14 @@ --selectlist: transparent; /* 下拉框默认背景色为透明色 变为#f4f8ff*/ + + --shouselect: rgb(60, 57, 57); + /* 首页下拉框默认背景色 变为#f4f8ff */ + + --elmentbgc: rgb(58, 58, 60); + + --diagiobgc: #000; + /* 弹框默认背景色 变为206, 223, 255 */ } .form-cascader .el-cascader-panel .el-radio { diff --git a/src/components/ConfigManager/SiteManagement.vue b/src/components/ConfigManager/SiteManagement.vue index 99f2424..f5013a7 100644 --- a/src/components/ConfigManager/SiteManagement.vue +++ b/src/components/ConfigManager/SiteManagement.vue @@ -154,7 +154,7 @@ v-loading="loading" element-loading-text="正在上传图片..." element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" :auto-upload="false" multiple action="#" diff --git a/src/components/ConfigManager/project.vue b/src/components/ConfigManager/project.vue index b4fb535..6e87663 100644 --- a/src/components/ConfigManager/project.vue +++ b/src/components/ConfigManager/project.vue @@ -122,6 +122,7 @@ :field-list="projectFormInfo.fieldList" :rules="projectFormInfo.rules" :list-type-info="listTypeInfo" + :limit-time="projectFormInfo.limitTime" :label-width="projectFormInfo.labelWidth" :need-clear-nodes="projectFormInfo.needClearNodes" :cascader-options="projectFormInfo.cascaderOptions" @@ -475,8 +476,11 @@ rules: {}, labelWidth: "110px", cascaderOptions: [], //区域级联数据源 - needClearNodes: false //是否清除级联上次数据高亮 - } + needClearNodes: false, //是否清除级联上次数据高亮 + limitTime: true, //是否开启选择时间区段限制 + }, + //保存当前选中城市信息以便获取经纬度 + currentCity: {}, }; }, watch: { @@ -632,6 +636,7 @@ this.dialogInfo.visible = true; this.projectFormInfo.needClearNodes = false; this.projectFormInfo.cascaderOptions = this.removeEmptyChild(this.allCity); + console.log(8888,this.removeEmptyChild(this.allCity)); for (let key in data) { if (key in this.projectFormInfo.data) { this.projectFormInfo.data[key] = data[key]; @@ -643,6 +648,30 @@ this.initRules(); }, 0); break; + //提交数据 + case "submit": + let submitType = this.dialogInfo.type; + let submitApi, submitParams; + this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); + const { lat, lon } = this.currentCity; + this.projectFormInfo.data.longitude = lon; + this.projectFormInfo.data.latitude = lat; + if(submitType === "update" || submitType === "create") { + this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); + this.projectFormInfo.ref.validate(valid => { + if (valid) { + this.btnLoading = true; + submitApi = this.nozzle.sysPlatformAddOrUpdate; + submitParams = { + data: this.projectFormInfo.data + }; + this.handleAjax(submitApi, submitParams); + }else{ + return false; + } + }); + } + break; //项目删除按钮 case "delete": this.$confirm("此操作将永久删除该数据, 是否继续?", "提示", { @@ -762,30 +791,6 @@ }) }).catch(() =>{}) break; - //提交数据 - case "submit": - let submitType = this.dialogInfo.type; - let submitApi, submitParams; - console.log(333,this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions)); - let {lat, lon} = this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); - this.projectFormInfo.data.lat = lat; - this.projectFormInfo.data.lon = lon; - if(submitType === "update" || submitType === "create") { - this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); - this.projectFormInfo.ref.validate(valid => { - if (valid) { - this.btnLoading = true; - submitApi = this.nozzle.sysPlatformAddOrUpdate; - submitParams = { - data: this.projectFormInfo.data - }; - this.handleAjax(submitApi, submitParams); - }else{ - return false; - } - }); - } - break; //添加站点到项目 case "insert": if (this.UnRelateSiteTableInfo.selectList.length) { @@ -991,23 +996,15 @@ }, //遍历城市数组取得选中城市的经纬度,arr城市数组,id当前所选城市id getCurrentCityJwd(id, arr) { - let currentCity; - let flag = arr.some(item => { + arr.forEach(item => { if (item.id === id) { - currentCity = item; - console.log(1111,currentCity); - return true; + this.currentCity = {...item}; }else{ if (item.children && item.children.length) { this.getCurrentCityJwd(id, item.children); } } }); - if(flag) { - console.log(currentCity); - return currentCity; - } - } } }; diff --git a/src/components/DataAnalysis/StatisticalReport.vue b/src/components/DataAnalysis/StatisticalReport.vue index 3b7b097..6cea6d3 100644 --- a/src/components/DataAnalysis/StatisticalReport.vue +++ b/src/components/DataAnalysis/StatisticalReport.vue @@ -158,7 +158,7 @@ lock: true, text: "Loading", spinner: "el-icon-loading", - background: "rgba(0, 0, 0, 0.7)" + background: "rgba(255, 255, 255, 0.3)" }); this.getData1(); } diff --git a/src/components/Engineering/HistoricalFault.vue b/src/components/Engineering/HistoricalFault.vue index 432342d..f78a850 100644 --- a/src/components/Engineering/HistoricalFault.vue +++ b/src/components/Engineering/HistoricalFault.vue @@ -51,7 +51,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/config/index.js b/config/index.js index 83d2e65..45fc349 100644 --- a/config/index.js +++ b/config/index.js @@ -70,7 +70,7 @@ "/IotPc": { // 物联网平台端信息汇总 // 'target': 'http://192.168.16.115:8288', // 接口域名 - target: "http://192.168.16.100:8289", // 接口域名 + target: "http://132.232.115.20:8289", // 接口域名 changeOrigin: true, //是否跨域 pathRewrite: { "^/IotPc": "" //需要rewrite重写的, diff --git a/src/assets/css/index.css b/src/assets/css/index.css index 2a68327..a2a46b0 100644 --- a/src/assets/css/index.css +++ b/src/assets/css/index.css @@ -11,9 +11,6 @@ --black: rgb(0, 0, 0); /* 原色为黑色,切换后的颜色为白色,设置边框时使用 */ - --lightgray: #c1c5cc; - --lightblue: rgb(102, 177, 255); - --dialogtitle: rgb(0, 255, 255); /* 弹框高亮标题颜色 */ @@ -78,6 +75,14 @@ --selectlist: transparent; /* 下拉框默认背景色为透明色 变为#f4f8ff*/ + + --shouselect: rgb(60, 57, 57); + /* 首页下拉框默认背景色 变为#f4f8ff */ + + --elmentbgc: rgb(58, 58, 60); + + --diagiobgc: #000; + /* 弹框默认背景色 变为206, 223, 255 */ } .form-cascader .el-cascader-panel .el-radio { diff --git a/src/components/ConfigManager/SiteManagement.vue b/src/components/ConfigManager/SiteManagement.vue index 99f2424..f5013a7 100644 --- a/src/components/ConfigManager/SiteManagement.vue +++ b/src/components/ConfigManager/SiteManagement.vue @@ -154,7 +154,7 @@ v-loading="loading" element-loading-text="正在上传图片..." element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" :auto-upload="false" multiple action="#" diff --git a/src/components/ConfigManager/project.vue b/src/components/ConfigManager/project.vue index b4fb535..6e87663 100644 --- a/src/components/ConfigManager/project.vue +++ b/src/components/ConfigManager/project.vue @@ -122,6 +122,7 @@ :field-list="projectFormInfo.fieldList" :rules="projectFormInfo.rules" :list-type-info="listTypeInfo" + :limit-time="projectFormInfo.limitTime" :label-width="projectFormInfo.labelWidth" :need-clear-nodes="projectFormInfo.needClearNodes" :cascader-options="projectFormInfo.cascaderOptions" @@ -475,8 +476,11 @@ rules: {}, labelWidth: "110px", cascaderOptions: [], //区域级联数据源 - needClearNodes: false //是否清除级联上次数据高亮 - } + needClearNodes: false, //是否清除级联上次数据高亮 + limitTime: true, //是否开启选择时间区段限制 + }, + //保存当前选中城市信息以便获取经纬度 + currentCity: {}, }; }, watch: { @@ -632,6 +636,7 @@ this.dialogInfo.visible = true; this.projectFormInfo.needClearNodes = false; this.projectFormInfo.cascaderOptions = this.removeEmptyChild(this.allCity); + console.log(8888,this.removeEmptyChild(this.allCity)); for (let key in data) { if (key in this.projectFormInfo.data) { this.projectFormInfo.data[key] = data[key]; @@ -643,6 +648,30 @@ this.initRules(); }, 0); break; + //提交数据 + case "submit": + let submitType = this.dialogInfo.type; + let submitApi, submitParams; + this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); + const { lat, lon } = this.currentCity; + this.projectFormInfo.data.longitude = lon; + this.projectFormInfo.data.latitude = lat; + if(submitType === "update" || submitType === "create") { + this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); + this.projectFormInfo.ref.validate(valid => { + if (valid) { + this.btnLoading = true; + submitApi = this.nozzle.sysPlatformAddOrUpdate; + submitParams = { + data: this.projectFormInfo.data + }; + this.handleAjax(submitApi, submitParams); + }else{ + return false; + } + }); + } + break; //项目删除按钮 case "delete": this.$confirm("此操作将永久删除该数据, 是否继续?", "提示", { @@ -762,30 +791,6 @@ }) }).catch(() =>{}) break; - //提交数据 - case "submit": - let submitType = this.dialogInfo.type; - let submitApi, submitParams; - console.log(333,this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions)); - let {lat, lon} = this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); - this.projectFormInfo.data.lat = lat; - this.projectFormInfo.data.lon = lon; - if(submitType === "update" || submitType === "create") { - this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); - this.projectFormInfo.ref.validate(valid => { - if (valid) { - this.btnLoading = true; - submitApi = this.nozzle.sysPlatformAddOrUpdate; - submitParams = { - data: this.projectFormInfo.data - }; - this.handleAjax(submitApi, submitParams); - }else{ - return false; - } - }); - } - break; //添加站点到项目 case "insert": if (this.UnRelateSiteTableInfo.selectList.length) { @@ -991,23 +996,15 @@ }, //遍历城市数组取得选中城市的经纬度,arr城市数组,id当前所选城市id getCurrentCityJwd(id, arr) { - let currentCity; - let flag = arr.some(item => { + arr.forEach(item => { if (item.id === id) { - currentCity = item; - console.log(1111,currentCity); - return true; + this.currentCity = {...item}; }else{ if (item.children && item.children.length) { this.getCurrentCityJwd(id, item.children); } } }); - if(flag) { - console.log(currentCity); - return currentCity; - } - } } }; diff --git a/src/components/DataAnalysis/StatisticalReport.vue b/src/components/DataAnalysis/StatisticalReport.vue index 3b7b097..6cea6d3 100644 --- a/src/components/DataAnalysis/StatisticalReport.vue +++ b/src/components/DataAnalysis/StatisticalReport.vue @@ -158,7 +158,7 @@ lock: true, text: "Loading", spinner: "el-icon-loading", - background: "rgba(0, 0, 0, 0.7)" + background: "rgba(255, 255, 255, 0.3)" }); this.getData1(); } diff --git a/src/components/Engineering/HistoricalFault.vue b/src/components/Engineering/HistoricalFault.vue index 432342d..f78a850 100644 --- a/src/components/Engineering/HistoricalFault.vue +++ b/src/components/Engineering/HistoricalFault.vue @@ -51,7 +51,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/Engineering/MyHomework_History.vue b/src/components/Engineering/MyHomework_History.vue index c177569..58b258f 100644 --- a/src/components/Engineering/MyHomework_History.vue +++ b/src/components/Engineering/MyHomework_History.vue @@ -33,7 +33,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > @@ -175,6 +175,7 @@ text-align: center; height: 60px; line-height: 60px; + color: var(--white); } /* 主体内容 */ #MH_HCertent { diff --git a/config/index.js b/config/index.js index 83d2e65..45fc349 100644 --- a/config/index.js +++ b/config/index.js @@ -70,7 +70,7 @@ "/IotPc": { // 物联网平台端信息汇总 // 'target': 'http://192.168.16.115:8288', // 接口域名 - target: "http://192.168.16.100:8289", // 接口域名 + target: "http://132.232.115.20:8289", // 接口域名 changeOrigin: true, //是否跨域 pathRewrite: { "^/IotPc": "" //需要rewrite重写的, diff --git a/src/assets/css/index.css b/src/assets/css/index.css index 2a68327..a2a46b0 100644 --- a/src/assets/css/index.css +++ b/src/assets/css/index.css @@ -11,9 +11,6 @@ --black: rgb(0, 0, 0); /* 原色为黑色,切换后的颜色为白色,设置边框时使用 */ - --lightgray: #c1c5cc; - --lightblue: rgb(102, 177, 255); - --dialogtitle: rgb(0, 255, 255); /* 弹框高亮标题颜色 */ @@ -78,6 +75,14 @@ --selectlist: transparent; /* 下拉框默认背景色为透明色 变为#f4f8ff*/ + + --shouselect: rgb(60, 57, 57); + /* 首页下拉框默认背景色 变为#f4f8ff */ + + --elmentbgc: rgb(58, 58, 60); + + --diagiobgc: #000; + /* 弹框默认背景色 变为206, 223, 255 */ } .form-cascader .el-cascader-panel .el-radio { diff --git a/src/components/ConfigManager/SiteManagement.vue b/src/components/ConfigManager/SiteManagement.vue index 99f2424..f5013a7 100644 --- a/src/components/ConfigManager/SiteManagement.vue +++ b/src/components/ConfigManager/SiteManagement.vue @@ -154,7 +154,7 @@ v-loading="loading" element-loading-text="正在上传图片..." element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" :auto-upload="false" multiple action="#" diff --git a/src/components/ConfigManager/project.vue b/src/components/ConfigManager/project.vue index b4fb535..6e87663 100644 --- a/src/components/ConfigManager/project.vue +++ b/src/components/ConfigManager/project.vue @@ -122,6 +122,7 @@ :field-list="projectFormInfo.fieldList" :rules="projectFormInfo.rules" :list-type-info="listTypeInfo" + :limit-time="projectFormInfo.limitTime" :label-width="projectFormInfo.labelWidth" :need-clear-nodes="projectFormInfo.needClearNodes" :cascader-options="projectFormInfo.cascaderOptions" @@ -475,8 +476,11 @@ rules: {}, labelWidth: "110px", cascaderOptions: [], //区域级联数据源 - needClearNodes: false //是否清除级联上次数据高亮 - } + needClearNodes: false, //是否清除级联上次数据高亮 + limitTime: true, //是否开启选择时间区段限制 + }, + //保存当前选中城市信息以便获取经纬度 + currentCity: {}, }; }, watch: { @@ -632,6 +636,7 @@ this.dialogInfo.visible = true; this.projectFormInfo.needClearNodes = false; this.projectFormInfo.cascaderOptions = this.removeEmptyChild(this.allCity); + console.log(8888,this.removeEmptyChild(this.allCity)); for (let key in data) { if (key in this.projectFormInfo.data) { this.projectFormInfo.data[key] = data[key]; @@ -643,6 +648,30 @@ this.initRules(); }, 0); break; + //提交数据 + case "submit": + let submitType = this.dialogInfo.type; + let submitApi, submitParams; + this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); + const { lat, lon } = this.currentCity; + this.projectFormInfo.data.longitude = lon; + this.projectFormInfo.data.latitude = lat; + if(submitType === "update" || submitType === "create") { + this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); + this.projectFormInfo.ref.validate(valid => { + if (valid) { + this.btnLoading = true; + submitApi = this.nozzle.sysPlatformAddOrUpdate; + submitParams = { + data: this.projectFormInfo.data + }; + this.handleAjax(submitApi, submitParams); + }else{ + return false; + } + }); + } + break; //项目删除按钮 case "delete": this.$confirm("此操作将永久删除该数据, 是否继续?", "提示", { @@ -762,30 +791,6 @@ }) }).catch(() =>{}) break; - //提交数据 - case "submit": - let submitType = this.dialogInfo.type; - let submitApi, submitParams; - console.log(333,this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions)); - let {lat, lon} = this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); - this.projectFormInfo.data.lat = lat; - this.projectFormInfo.data.lon = lon; - if(submitType === "update" || submitType === "create") { - this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); - this.projectFormInfo.ref.validate(valid => { - if (valid) { - this.btnLoading = true; - submitApi = this.nozzle.sysPlatformAddOrUpdate; - submitParams = { - data: this.projectFormInfo.data - }; - this.handleAjax(submitApi, submitParams); - }else{ - return false; - } - }); - } - break; //添加站点到项目 case "insert": if (this.UnRelateSiteTableInfo.selectList.length) { @@ -991,23 +996,15 @@ }, //遍历城市数组取得选中城市的经纬度,arr城市数组,id当前所选城市id getCurrentCityJwd(id, arr) { - let currentCity; - let flag = arr.some(item => { + arr.forEach(item => { if (item.id === id) { - currentCity = item; - console.log(1111,currentCity); - return true; + this.currentCity = {...item}; }else{ if (item.children && item.children.length) { this.getCurrentCityJwd(id, item.children); } } }); - if(flag) { - console.log(currentCity); - return currentCity; - } - } } }; diff --git a/src/components/DataAnalysis/StatisticalReport.vue b/src/components/DataAnalysis/StatisticalReport.vue index 3b7b097..6cea6d3 100644 --- a/src/components/DataAnalysis/StatisticalReport.vue +++ b/src/components/DataAnalysis/StatisticalReport.vue @@ -158,7 +158,7 @@ lock: true, text: "Loading", spinner: "el-icon-loading", - background: "rgba(0, 0, 0, 0.7)" + background: "rgba(255, 255, 255, 0.3)" }); this.getData1(); } diff --git a/src/components/Engineering/HistoricalFault.vue b/src/components/Engineering/HistoricalFault.vue index 432342d..f78a850 100644 --- a/src/components/Engineering/HistoricalFault.vue +++ b/src/components/Engineering/HistoricalFault.vue @@ -51,7 +51,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/Engineering/MyHomework_History.vue b/src/components/Engineering/MyHomework_History.vue index c177569..58b258f 100644 --- a/src/components/Engineering/MyHomework_History.vue +++ b/src/components/Engineering/MyHomework_History.vue @@ -33,7 +33,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > @@ -175,6 +175,7 @@ text-align: center; height: 60px; line-height: 60px; + color: var(--white); } /* 主体内容 */ #MH_HCertent { diff --git a/src/components/Engineering/MyHomework_Now.vue b/src/components/Engineering/MyHomework_Now.vue index 2905bba..d979e4e 100644 --- a/src/components/Engineering/MyHomework_Now.vue +++ b/src/components/Engineering/MyHomework_Now.vue @@ -22,7 +22,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > @@ -166,5 +166,6 @@ #YuLanImg { width: 100%; height: auto; + /* a */ } diff --git a/config/index.js b/config/index.js index 83d2e65..45fc349 100644 --- a/config/index.js +++ b/config/index.js @@ -70,7 +70,7 @@ "/IotPc": { // 物联网平台端信息汇总 // 'target': 'http://192.168.16.115:8288', // 接口域名 - target: "http://192.168.16.100:8289", // 接口域名 + target: "http://132.232.115.20:8289", // 接口域名 changeOrigin: true, //是否跨域 pathRewrite: { "^/IotPc": "" //需要rewrite重写的, diff --git a/src/assets/css/index.css b/src/assets/css/index.css index 2a68327..a2a46b0 100644 --- a/src/assets/css/index.css +++ b/src/assets/css/index.css @@ -11,9 +11,6 @@ --black: rgb(0, 0, 0); /* 原色为黑色,切换后的颜色为白色,设置边框时使用 */ - --lightgray: #c1c5cc; - --lightblue: rgb(102, 177, 255); - --dialogtitle: rgb(0, 255, 255); /* 弹框高亮标题颜色 */ @@ -78,6 +75,14 @@ --selectlist: transparent; /* 下拉框默认背景色为透明色 变为#f4f8ff*/ + + --shouselect: rgb(60, 57, 57); + /* 首页下拉框默认背景色 变为#f4f8ff */ + + --elmentbgc: rgb(58, 58, 60); + + --diagiobgc: #000; + /* 弹框默认背景色 变为206, 223, 255 */ } .form-cascader .el-cascader-panel .el-radio { diff --git a/src/components/ConfigManager/SiteManagement.vue b/src/components/ConfigManager/SiteManagement.vue index 99f2424..f5013a7 100644 --- a/src/components/ConfigManager/SiteManagement.vue +++ b/src/components/ConfigManager/SiteManagement.vue @@ -154,7 +154,7 @@ v-loading="loading" element-loading-text="正在上传图片..." element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" :auto-upload="false" multiple action="#" diff --git a/src/components/ConfigManager/project.vue b/src/components/ConfigManager/project.vue index b4fb535..6e87663 100644 --- a/src/components/ConfigManager/project.vue +++ b/src/components/ConfigManager/project.vue @@ -122,6 +122,7 @@ :field-list="projectFormInfo.fieldList" :rules="projectFormInfo.rules" :list-type-info="listTypeInfo" + :limit-time="projectFormInfo.limitTime" :label-width="projectFormInfo.labelWidth" :need-clear-nodes="projectFormInfo.needClearNodes" :cascader-options="projectFormInfo.cascaderOptions" @@ -475,8 +476,11 @@ rules: {}, labelWidth: "110px", cascaderOptions: [], //区域级联数据源 - needClearNodes: false //是否清除级联上次数据高亮 - } + needClearNodes: false, //是否清除级联上次数据高亮 + limitTime: true, //是否开启选择时间区段限制 + }, + //保存当前选中城市信息以便获取经纬度 + currentCity: {}, }; }, watch: { @@ -632,6 +636,7 @@ this.dialogInfo.visible = true; this.projectFormInfo.needClearNodes = false; this.projectFormInfo.cascaderOptions = this.removeEmptyChild(this.allCity); + console.log(8888,this.removeEmptyChild(this.allCity)); for (let key in data) { if (key in this.projectFormInfo.data) { this.projectFormInfo.data[key] = data[key]; @@ -643,6 +648,30 @@ this.initRules(); }, 0); break; + //提交数据 + case "submit": + let submitType = this.dialogInfo.type; + let submitApi, submitParams; + this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); + const { lat, lon } = this.currentCity; + this.projectFormInfo.data.longitude = lon; + this.projectFormInfo.data.latitude = lat; + if(submitType === "update" || submitType === "create") { + this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); + this.projectFormInfo.ref.validate(valid => { + if (valid) { + this.btnLoading = true; + submitApi = this.nozzle.sysPlatformAddOrUpdate; + submitParams = { + data: this.projectFormInfo.data + }; + this.handleAjax(submitApi, submitParams); + }else{ + return false; + } + }); + } + break; //项目删除按钮 case "delete": this.$confirm("此操作将永久删除该数据, 是否继续?", "提示", { @@ -762,30 +791,6 @@ }) }).catch(() =>{}) break; - //提交数据 - case "submit": - let submitType = this.dialogInfo.type; - let submitApi, submitParams; - console.log(333,this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions)); - let {lat, lon} = this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); - this.projectFormInfo.data.lat = lat; - this.projectFormInfo.data.lon = lon; - if(submitType === "update" || submitType === "create") { - this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); - this.projectFormInfo.ref.validate(valid => { - if (valid) { - this.btnLoading = true; - submitApi = this.nozzle.sysPlatformAddOrUpdate; - submitParams = { - data: this.projectFormInfo.data - }; - this.handleAjax(submitApi, submitParams); - }else{ - return false; - } - }); - } - break; //添加站点到项目 case "insert": if (this.UnRelateSiteTableInfo.selectList.length) { @@ -991,23 +996,15 @@ }, //遍历城市数组取得选中城市的经纬度,arr城市数组,id当前所选城市id getCurrentCityJwd(id, arr) { - let currentCity; - let flag = arr.some(item => { + arr.forEach(item => { if (item.id === id) { - currentCity = item; - console.log(1111,currentCity); - return true; + this.currentCity = {...item}; }else{ if (item.children && item.children.length) { this.getCurrentCityJwd(id, item.children); } } }); - if(flag) { - console.log(currentCity); - return currentCity; - } - } } }; diff --git a/src/components/DataAnalysis/StatisticalReport.vue b/src/components/DataAnalysis/StatisticalReport.vue index 3b7b097..6cea6d3 100644 --- a/src/components/DataAnalysis/StatisticalReport.vue +++ b/src/components/DataAnalysis/StatisticalReport.vue @@ -158,7 +158,7 @@ lock: true, text: "Loading", spinner: "el-icon-loading", - background: "rgba(0, 0, 0, 0.7)" + background: "rgba(255, 255, 255, 0.3)" }); this.getData1(); } diff --git a/src/components/Engineering/HistoricalFault.vue b/src/components/Engineering/HistoricalFault.vue index 432342d..f78a850 100644 --- a/src/components/Engineering/HistoricalFault.vue +++ b/src/components/Engineering/HistoricalFault.vue @@ -51,7 +51,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/Engineering/MyHomework_History.vue b/src/components/Engineering/MyHomework_History.vue index c177569..58b258f 100644 --- a/src/components/Engineering/MyHomework_History.vue +++ b/src/components/Engineering/MyHomework_History.vue @@ -33,7 +33,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > @@ -175,6 +175,7 @@ text-align: center; height: 60px; line-height: 60px; + color: var(--white); } /* 主体内容 */ #MH_HCertent { diff --git a/src/components/Engineering/MyHomework_Now.vue b/src/components/Engineering/MyHomework_Now.vue index 2905bba..d979e4e 100644 --- a/src/components/Engineering/MyHomework_Now.vue +++ b/src/components/Engineering/MyHomework_Now.vue @@ -22,7 +22,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > @@ -166,5 +166,6 @@ #YuLanImg { width: 100%; height: auto; + /* a */ } diff --git a/src/components/Engineering/Nowfault.vue b/src/components/Engineering/Nowfault.vue index 19d5a74..e2b4b89 100644 --- a/src/components/Engineering/Nowfault.vue +++ b/src/components/Engineering/Nowfault.vue @@ -21,7 +21,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/config/index.js b/config/index.js index 83d2e65..45fc349 100644 --- a/config/index.js +++ b/config/index.js @@ -70,7 +70,7 @@ "/IotPc": { // 物联网平台端信息汇总 // 'target': 'http://192.168.16.115:8288', // 接口域名 - target: "http://192.168.16.100:8289", // 接口域名 + target: "http://132.232.115.20:8289", // 接口域名 changeOrigin: true, //是否跨域 pathRewrite: { "^/IotPc": "" //需要rewrite重写的, diff --git a/src/assets/css/index.css b/src/assets/css/index.css index 2a68327..a2a46b0 100644 --- a/src/assets/css/index.css +++ b/src/assets/css/index.css @@ -11,9 +11,6 @@ --black: rgb(0, 0, 0); /* 原色为黑色,切换后的颜色为白色,设置边框时使用 */ - --lightgray: #c1c5cc; - --lightblue: rgb(102, 177, 255); - --dialogtitle: rgb(0, 255, 255); /* 弹框高亮标题颜色 */ @@ -78,6 +75,14 @@ --selectlist: transparent; /* 下拉框默认背景色为透明色 变为#f4f8ff*/ + + --shouselect: rgb(60, 57, 57); + /* 首页下拉框默认背景色 变为#f4f8ff */ + + --elmentbgc: rgb(58, 58, 60); + + --diagiobgc: #000; + /* 弹框默认背景色 变为206, 223, 255 */ } .form-cascader .el-cascader-panel .el-radio { diff --git a/src/components/ConfigManager/SiteManagement.vue b/src/components/ConfigManager/SiteManagement.vue index 99f2424..f5013a7 100644 --- a/src/components/ConfigManager/SiteManagement.vue +++ b/src/components/ConfigManager/SiteManagement.vue @@ -154,7 +154,7 @@ v-loading="loading" element-loading-text="正在上传图片..." element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" :auto-upload="false" multiple action="#" diff --git a/src/components/ConfigManager/project.vue b/src/components/ConfigManager/project.vue index b4fb535..6e87663 100644 --- a/src/components/ConfigManager/project.vue +++ b/src/components/ConfigManager/project.vue @@ -122,6 +122,7 @@ :field-list="projectFormInfo.fieldList" :rules="projectFormInfo.rules" :list-type-info="listTypeInfo" + :limit-time="projectFormInfo.limitTime" :label-width="projectFormInfo.labelWidth" :need-clear-nodes="projectFormInfo.needClearNodes" :cascader-options="projectFormInfo.cascaderOptions" @@ -475,8 +476,11 @@ rules: {}, labelWidth: "110px", cascaderOptions: [], //区域级联数据源 - needClearNodes: false //是否清除级联上次数据高亮 - } + needClearNodes: false, //是否清除级联上次数据高亮 + limitTime: true, //是否开启选择时间区段限制 + }, + //保存当前选中城市信息以便获取经纬度 + currentCity: {}, }; }, watch: { @@ -632,6 +636,7 @@ this.dialogInfo.visible = true; this.projectFormInfo.needClearNodes = false; this.projectFormInfo.cascaderOptions = this.removeEmptyChild(this.allCity); + console.log(8888,this.removeEmptyChild(this.allCity)); for (let key in data) { if (key in this.projectFormInfo.data) { this.projectFormInfo.data[key] = data[key]; @@ -643,6 +648,30 @@ this.initRules(); }, 0); break; + //提交数据 + case "submit": + let submitType = this.dialogInfo.type; + let submitApi, submitParams; + this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); + const { lat, lon } = this.currentCity; + this.projectFormInfo.data.longitude = lon; + this.projectFormInfo.data.latitude = lat; + if(submitType === "update" || submitType === "create") { + this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); + this.projectFormInfo.ref.validate(valid => { + if (valid) { + this.btnLoading = true; + submitApi = this.nozzle.sysPlatformAddOrUpdate; + submitParams = { + data: this.projectFormInfo.data + }; + this.handleAjax(submitApi, submitParams); + }else{ + return false; + } + }); + } + break; //项目删除按钮 case "delete": this.$confirm("此操作将永久删除该数据, 是否继续?", "提示", { @@ -762,30 +791,6 @@ }) }).catch(() =>{}) break; - //提交数据 - case "submit": - let submitType = this.dialogInfo.type; - let submitApi, submitParams; - console.log(333,this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions)); - let {lat, lon} = this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); - this.projectFormInfo.data.lat = lat; - this.projectFormInfo.data.lon = lon; - if(submitType === "update" || submitType === "create") { - this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); - this.projectFormInfo.ref.validate(valid => { - if (valid) { - this.btnLoading = true; - submitApi = this.nozzle.sysPlatformAddOrUpdate; - submitParams = { - data: this.projectFormInfo.data - }; - this.handleAjax(submitApi, submitParams); - }else{ - return false; - } - }); - } - break; //添加站点到项目 case "insert": if (this.UnRelateSiteTableInfo.selectList.length) { @@ -991,23 +996,15 @@ }, //遍历城市数组取得选中城市的经纬度,arr城市数组,id当前所选城市id getCurrentCityJwd(id, arr) { - let currentCity; - let flag = arr.some(item => { + arr.forEach(item => { if (item.id === id) { - currentCity = item; - console.log(1111,currentCity); - return true; + this.currentCity = {...item}; }else{ if (item.children && item.children.length) { this.getCurrentCityJwd(id, item.children); } } }); - if(flag) { - console.log(currentCity); - return currentCity; - } - } } }; diff --git a/src/components/DataAnalysis/StatisticalReport.vue b/src/components/DataAnalysis/StatisticalReport.vue index 3b7b097..6cea6d3 100644 --- a/src/components/DataAnalysis/StatisticalReport.vue +++ b/src/components/DataAnalysis/StatisticalReport.vue @@ -158,7 +158,7 @@ lock: true, text: "Loading", spinner: "el-icon-loading", - background: "rgba(0, 0, 0, 0.7)" + background: "rgba(255, 255, 255, 0.3)" }); this.getData1(); } diff --git a/src/components/Engineering/HistoricalFault.vue b/src/components/Engineering/HistoricalFault.vue index 432342d..f78a850 100644 --- a/src/components/Engineering/HistoricalFault.vue +++ b/src/components/Engineering/HistoricalFault.vue @@ -51,7 +51,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/Engineering/MyHomework_History.vue b/src/components/Engineering/MyHomework_History.vue index c177569..58b258f 100644 --- a/src/components/Engineering/MyHomework_History.vue +++ b/src/components/Engineering/MyHomework_History.vue @@ -33,7 +33,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > @@ -175,6 +175,7 @@ text-align: center; height: 60px; line-height: 60px; + color: var(--white); } /* 主体内容 */ #MH_HCertent { diff --git a/src/components/Engineering/MyHomework_Now.vue b/src/components/Engineering/MyHomework_Now.vue index 2905bba..d979e4e 100644 --- a/src/components/Engineering/MyHomework_Now.vue +++ b/src/components/Engineering/MyHomework_Now.vue @@ -22,7 +22,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > @@ -166,5 +166,6 @@ #YuLanImg { width: 100%; height: auto; + /* a */ } diff --git a/src/components/Engineering/Nowfault.vue b/src/components/Engineering/Nowfault.vue index 19d5a74..e2b4b89 100644 --- a/src/components/Engineering/Nowfault.vue +++ b/src/components/Engineering/Nowfault.vue @@ -21,7 +21,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/MessageManagement/MessageQuery.vue b/src/components/MessageManagement/MessageQuery.vue index ea96bfb..872660b 100644 --- a/src/components/MessageManagement/MessageQuery.vue +++ b/src/components/MessageManagement/MessageQuery.vue @@ -79,7 +79,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > { + if (valid) { + this.btnLoading = true; + submitApi = this.nozzle.sysPlatformAddOrUpdate; + submitParams = { + data: this.projectFormInfo.data + }; + this.handleAjax(submitApi, submitParams); + }else{ + return false; + } + }); + } + break; //项目删除按钮 case "delete": this.$confirm("此操作将永久删除该数据, 是否继续?", "提示", { @@ -762,30 +791,6 @@ }) }).catch(() =>{}) break; - //提交数据 - case "submit": - let submitType = this.dialogInfo.type; - let submitApi, submitParams; - console.log(333,this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions)); - let {lat, lon} = this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); - this.projectFormInfo.data.lat = lat; - this.projectFormInfo.data.lon = lon; - if(submitType === "update" || submitType === "create") { - this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); - this.projectFormInfo.ref.validate(valid => { - if (valid) { - this.btnLoading = true; - submitApi = this.nozzle.sysPlatformAddOrUpdate; - submitParams = { - data: this.projectFormInfo.data - }; - this.handleAjax(submitApi, submitParams); - }else{ - return false; - } - }); - } - break; //添加站点到项目 case "insert": if (this.UnRelateSiteTableInfo.selectList.length) { @@ -991,23 +996,15 @@ }, //遍历城市数组取得选中城市的经纬度,arr城市数组,id当前所选城市id getCurrentCityJwd(id, arr) { - let currentCity; - let flag = arr.some(item => { + arr.forEach(item => { if (item.id === id) { - currentCity = item; - console.log(1111,currentCity); - return true; + this.currentCity = {...item}; }else{ if (item.children && item.children.length) { this.getCurrentCityJwd(id, item.children); } } }); - if(flag) { - console.log(currentCity); - return currentCity; - } - } } }; diff --git a/src/components/DataAnalysis/StatisticalReport.vue b/src/components/DataAnalysis/StatisticalReport.vue index 3b7b097..6cea6d3 100644 --- a/src/components/DataAnalysis/StatisticalReport.vue +++ b/src/components/DataAnalysis/StatisticalReport.vue @@ -158,7 +158,7 @@ lock: true, text: "Loading", spinner: "el-icon-loading", - background: "rgba(0, 0, 0, 0.7)" + background: "rgba(255, 255, 255, 0.3)" }); this.getData1(); } diff --git a/src/components/Engineering/HistoricalFault.vue b/src/components/Engineering/HistoricalFault.vue index 432342d..f78a850 100644 --- a/src/components/Engineering/HistoricalFault.vue +++ b/src/components/Engineering/HistoricalFault.vue @@ -51,7 +51,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/Engineering/MyHomework_History.vue b/src/components/Engineering/MyHomework_History.vue index c177569..58b258f 100644 --- a/src/components/Engineering/MyHomework_History.vue +++ b/src/components/Engineering/MyHomework_History.vue @@ -33,7 +33,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > @@ -175,6 +175,7 @@ text-align: center; height: 60px; line-height: 60px; + color: var(--white); } /* 主体内容 */ #MH_HCertent { diff --git a/src/components/Engineering/MyHomework_Now.vue b/src/components/Engineering/MyHomework_Now.vue index 2905bba..d979e4e 100644 --- a/src/components/Engineering/MyHomework_Now.vue +++ b/src/components/Engineering/MyHomework_Now.vue @@ -22,7 +22,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > @@ -166,5 +166,6 @@ #YuLanImg { width: 100%; height: auto; + /* a */ } diff --git a/src/components/Engineering/Nowfault.vue b/src/components/Engineering/Nowfault.vue index 19d5a74..e2b4b89 100644 --- a/src/components/Engineering/Nowfault.vue +++ b/src/components/Engineering/Nowfault.vue @@ -21,7 +21,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/MessageManagement/MessageQuery.vue b/src/components/MessageManagement/MessageQuery.vue index ea96bfb..872660b 100644 --- a/src/components/MessageManagement/MessageQuery.vue +++ b/src/components/MessageManagement/MessageQuery.vue @@ -79,7 +79,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/config/index.js b/config/index.js index 83d2e65..45fc349 100644 --- a/config/index.js +++ b/config/index.js @@ -70,7 +70,7 @@ "/IotPc": { // 物联网平台端信息汇总 // 'target': 'http://192.168.16.115:8288', // 接口域名 - target: "http://192.168.16.100:8289", // 接口域名 + target: "http://132.232.115.20:8289", // 接口域名 changeOrigin: true, //是否跨域 pathRewrite: { "^/IotPc": "" //需要rewrite重写的, diff --git a/src/assets/css/index.css b/src/assets/css/index.css index 2a68327..a2a46b0 100644 --- a/src/assets/css/index.css +++ b/src/assets/css/index.css @@ -11,9 +11,6 @@ --black: rgb(0, 0, 0); /* 原色为黑色,切换后的颜色为白色,设置边框时使用 */ - --lightgray: #c1c5cc; - --lightblue: rgb(102, 177, 255); - --dialogtitle: rgb(0, 255, 255); /* 弹框高亮标题颜色 */ @@ -78,6 +75,14 @@ --selectlist: transparent; /* 下拉框默认背景色为透明色 变为#f4f8ff*/ + + --shouselect: rgb(60, 57, 57); + /* 首页下拉框默认背景色 变为#f4f8ff */ + + --elmentbgc: rgb(58, 58, 60); + + --diagiobgc: #000; + /* 弹框默认背景色 变为206, 223, 255 */ } .form-cascader .el-cascader-panel .el-radio { diff --git a/src/components/ConfigManager/SiteManagement.vue b/src/components/ConfigManager/SiteManagement.vue index 99f2424..f5013a7 100644 --- a/src/components/ConfigManager/SiteManagement.vue +++ b/src/components/ConfigManager/SiteManagement.vue @@ -154,7 +154,7 @@ v-loading="loading" element-loading-text="正在上传图片..." element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" :auto-upload="false" multiple action="#" diff --git a/src/components/ConfigManager/project.vue b/src/components/ConfigManager/project.vue index b4fb535..6e87663 100644 --- a/src/components/ConfigManager/project.vue +++ b/src/components/ConfigManager/project.vue @@ -122,6 +122,7 @@ :field-list="projectFormInfo.fieldList" :rules="projectFormInfo.rules" :list-type-info="listTypeInfo" + :limit-time="projectFormInfo.limitTime" :label-width="projectFormInfo.labelWidth" :need-clear-nodes="projectFormInfo.needClearNodes" :cascader-options="projectFormInfo.cascaderOptions" @@ -475,8 +476,11 @@ rules: {}, labelWidth: "110px", cascaderOptions: [], //区域级联数据源 - needClearNodes: false //是否清除级联上次数据高亮 - } + needClearNodes: false, //是否清除级联上次数据高亮 + limitTime: true, //是否开启选择时间区段限制 + }, + //保存当前选中城市信息以便获取经纬度 + currentCity: {}, }; }, watch: { @@ -632,6 +636,7 @@ this.dialogInfo.visible = true; this.projectFormInfo.needClearNodes = false; this.projectFormInfo.cascaderOptions = this.removeEmptyChild(this.allCity); + console.log(8888,this.removeEmptyChild(this.allCity)); for (let key in data) { if (key in this.projectFormInfo.data) { this.projectFormInfo.data[key] = data[key]; @@ -643,6 +648,30 @@ this.initRules(); }, 0); break; + //提交数据 + case "submit": + let submitType = this.dialogInfo.type; + let submitApi, submitParams; + this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); + const { lat, lon } = this.currentCity; + this.projectFormInfo.data.longitude = lon; + this.projectFormInfo.data.latitude = lat; + if(submitType === "update" || submitType === "create") { + this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); + this.projectFormInfo.ref.validate(valid => { + if (valid) { + this.btnLoading = true; + submitApi = this.nozzle.sysPlatformAddOrUpdate; + submitParams = { + data: this.projectFormInfo.data + }; + this.handleAjax(submitApi, submitParams); + }else{ + return false; + } + }); + } + break; //项目删除按钮 case "delete": this.$confirm("此操作将永久删除该数据, 是否继续?", "提示", { @@ -762,30 +791,6 @@ }) }).catch(() =>{}) break; - //提交数据 - case "submit": - let submitType = this.dialogInfo.type; - let submitApi, submitParams; - console.log(333,this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions)); - let {lat, lon} = this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); - this.projectFormInfo.data.lat = lat; - this.projectFormInfo.data.lon = lon; - if(submitType === "update" || submitType === "create") { - this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); - this.projectFormInfo.ref.validate(valid => { - if (valid) { - this.btnLoading = true; - submitApi = this.nozzle.sysPlatformAddOrUpdate; - submitParams = { - data: this.projectFormInfo.data - }; - this.handleAjax(submitApi, submitParams); - }else{ - return false; - } - }); - } - break; //添加站点到项目 case "insert": if (this.UnRelateSiteTableInfo.selectList.length) { @@ -991,23 +996,15 @@ }, //遍历城市数组取得选中城市的经纬度,arr城市数组,id当前所选城市id getCurrentCityJwd(id, arr) { - let currentCity; - let flag = arr.some(item => { + arr.forEach(item => { if (item.id === id) { - currentCity = item; - console.log(1111,currentCity); - return true; + this.currentCity = {...item}; }else{ if (item.children && item.children.length) { this.getCurrentCityJwd(id, item.children); } } }); - if(flag) { - console.log(currentCity); - return currentCity; - } - } } }; diff --git a/src/components/DataAnalysis/StatisticalReport.vue b/src/components/DataAnalysis/StatisticalReport.vue index 3b7b097..6cea6d3 100644 --- a/src/components/DataAnalysis/StatisticalReport.vue +++ b/src/components/DataAnalysis/StatisticalReport.vue @@ -158,7 +158,7 @@ lock: true, text: "Loading", spinner: "el-icon-loading", - background: "rgba(0, 0, 0, 0.7)" + background: "rgba(255, 255, 255, 0.3)" }); this.getData1(); } diff --git a/src/components/Engineering/HistoricalFault.vue b/src/components/Engineering/HistoricalFault.vue index 432342d..f78a850 100644 --- a/src/components/Engineering/HistoricalFault.vue +++ b/src/components/Engineering/HistoricalFault.vue @@ -51,7 +51,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/Engineering/MyHomework_History.vue b/src/components/Engineering/MyHomework_History.vue index c177569..58b258f 100644 --- a/src/components/Engineering/MyHomework_History.vue +++ b/src/components/Engineering/MyHomework_History.vue @@ -33,7 +33,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > @@ -175,6 +175,7 @@ text-align: center; height: 60px; line-height: 60px; + color: var(--white); } /* 主体内容 */ #MH_HCertent { diff --git a/src/components/Engineering/MyHomework_Now.vue b/src/components/Engineering/MyHomework_Now.vue index 2905bba..d979e4e 100644 --- a/src/components/Engineering/MyHomework_Now.vue +++ b/src/components/Engineering/MyHomework_Now.vue @@ -22,7 +22,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > @@ -166,5 +166,6 @@ #YuLanImg { width: 100%; height: auto; + /* a */ } diff --git a/src/components/Engineering/Nowfault.vue b/src/components/Engineering/Nowfault.vue index 19d5a74..e2b4b89 100644 --- a/src/components/Engineering/Nowfault.vue +++ b/src/components/Engineering/Nowfault.vue @@ -21,7 +21,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/MessageManagement/MessageQuery.vue b/src/components/MessageManagement/MessageQuery.vue index ea96bfb..872660b 100644 --- a/src/components/MessageManagement/MessageQuery.vue +++ b/src/components/MessageManagement/MessageQuery.vue @@ -79,7 +79,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/NFCloudPlatform/Attic.vue b/src/components/NFCloudPlatform/Attic.vue index c259fa3..a55aaaf 100644 --- a/src/components/NFCloudPlatform/Attic.vue +++ b/src/components/NFCloudPlatform/Attic.vue @@ -66,7 +66,7 @@ 提示:阀门开度尽量不要超过50
- 阀门开度值:{{waterValue}}%     + 阀门开度值:{{ waterValue }}%    
@@ -79,9 +79,9 @@
流量 - {{Liuliang}} + {{ Liuliang }} 水位 - {{shuiwei}} + {{ shuiwei }}
@@ -200,7 +200,9 @@ var Ary = this.formatterData(res.data); if (Ary[0] == "OK" && Ary[2] == 0) { // this.record(4); - this.$http.post(this.nozzle.engineeringWorkOpenPump).then(res => {});//开水泵 + this.$http + .post(this.nozzle.engineeringWorkOpenPump) + .then(res => {}); //开水泵 this.flag = true; this.readStatue(); this.$message({ @@ -256,7 +258,9 @@ var Ary = this.formatterData(res.data); if (Ary[0] == "OK" && Ary[2] == 0) { // this.record(5); - this.$http.post(this.nozzle.engineeringWorkClosePump).then(res => {});//关水泵 + this.$http + .post(this.nozzle.engineeringWorkClosePump) + .then(res => {}); //关水泵 this.flag = false; this.readStatue(); this.$message({ @@ -283,7 +287,9 @@ var Ary = this.formatterData(res.data); if (Ary[0] == "OK" && Ary[2] == 0) { // this.record(6); - this.$http.post(this.nozzle.engineeringWorkopenValve).then(res => {});//开阀门 + this.$http + .post(this.nozzle.engineeringWorkopenValve) + .then(res => {}); //开阀门 this.flag1 = true; this.readStatue(); this.$message({ @@ -305,7 +311,9 @@ var Ary = this.formatterData(res.data); if (Ary[0] == "OK" && Ary[2] == 0) { // this.record(7); - this.$http.post(this.nozzle.engineeringWorkcloseValve).then(res => {});//关阀门 + this.$http + .post(this.nozzle.engineeringWorkcloseValve) + .then(res => {}); //关阀门 this.flag1 = false; this.readStatue(); this.$message({ @@ -628,4 +636,4 @@ padding: 0 10px; color: #ffffff; } - \ No newline at end of file + diff --git a/config/index.js b/config/index.js index 83d2e65..45fc349 100644 --- a/config/index.js +++ b/config/index.js @@ -70,7 +70,7 @@ "/IotPc": { // 物联网平台端信息汇总 // 'target': 'http://192.168.16.115:8288', // 接口域名 - target: "http://192.168.16.100:8289", // 接口域名 + target: "http://132.232.115.20:8289", // 接口域名 changeOrigin: true, //是否跨域 pathRewrite: { "^/IotPc": "" //需要rewrite重写的, diff --git a/src/assets/css/index.css b/src/assets/css/index.css index 2a68327..a2a46b0 100644 --- a/src/assets/css/index.css +++ b/src/assets/css/index.css @@ -11,9 +11,6 @@ --black: rgb(0, 0, 0); /* 原色为黑色,切换后的颜色为白色,设置边框时使用 */ - --lightgray: #c1c5cc; - --lightblue: rgb(102, 177, 255); - --dialogtitle: rgb(0, 255, 255); /* 弹框高亮标题颜色 */ @@ -78,6 +75,14 @@ --selectlist: transparent; /* 下拉框默认背景色为透明色 变为#f4f8ff*/ + + --shouselect: rgb(60, 57, 57); + /* 首页下拉框默认背景色 变为#f4f8ff */ + + --elmentbgc: rgb(58, 58, 60); + + --diagiobgc: #000; + /* 弹框默认背景色 变为206, 223, 255 */ } .form-cascader .el-cascader-panel .el-radio { diff --git a/src/components/ConfigManager/SiteManagement.vue b/src/components/ConfigManager/SiteManagement.vue index 99f2424..f5013a7 100644 --- a/src/components/ConfigManager/SiteManagement.vue +++ b/src/components/ConfigManager/SiteManagement.vue @@ -154,7 +154,7 @@ v-loading="loading" element-loading-text="正在上传图片..." element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" :auto-upload="false" multiple action="#" diff --git a/src/components/ConfigManager/project.vue b/src/components/ConfigManager/project.vue index b4fb535..6e87663 100644 --- a/src/components/ConfigManager/project.vue +++ b/src/components/ConfigManager/project.vue @@ -122,6 +122,7 @@ :field-list="projectFormInfo.fieldList" :rules="projectFormInfo.rules" :list-type-info="listTypeInfo" + :limit-time="projectFormInfo.limitTime" :label-width="projectFormInfo.labelWidth" :need-clear-nodes="projectFormInfo.needClearNodes" :cascader-options="projectFormInfo.cascaderOptions" @@ -475,8 +476,11 @@ rules: {}, labelWidth: "110px", cascaderOptions: [], //区域级联数据源 - needClearNodes: false //是否清除级联上次数据高亮 - } + needClearNodes: false, //是否清除级联上次数据高亮 + limitTime: true, //是否开启选择时间区段限制 + }, + //保存当前选中城市信息以便获取经纬度 + currentCity: {}, }; }, watch: { @@ -632,6 +636,7 @@ this.dialogInfo.visible = true; this.projectFormInfo.needClearNodes = false; this.projectFormInfo.cascaderOptions = this.removeEmptyChild(this.allCity); + console.log(8888,this.removeEmptyChild(this.allCity)); for (let key in data) { if (key in this.projectFormInfo.data) { this.projectFormInfo.data[key] = data[key]; @@ -643,6 +648,30 @@ this.initRules(); }, 0); break; + //提交数据 + case "submit": + let submitType = this.dialogInfo.type; + let submitApi, submitParams; + this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); + const { lat, lon } = this.currentCity; + this.projectFormInfo.data.longitude = lon; + this.projectFormInfo.data.latitude = lat; + if(submitType === "update" || submitType === "create") { + this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); + this.projectFormInfo.ref.validate(valid => { + if (valid) { + this.btnLoading = true; + submitApi = this.nozzle.sysPlatformAddOrUpdate; + submitParams = { + data: this.projectFormInfo.data + }; + this.handleAjax(submitApi, submitParams); + }else{ + return false; + } + }); + } + break; //项目删除按钮 case "delete": this.$confirm("此操作将永久删除该数据, 是否继续?", "提示", { @@ -762,30 +791,6 @@ }) }).catch(() =>{}) break; - //提交数据 - case "submit": - let submitType = this.dialogInfo.type; - let submitApi, submitParams; - console.log(333,this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions)); - let {lat, lon} = this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); - this.projectFormInfo.data.lat = lat; - this.projectFormInfo.data.lon = lon; - if(submitType === "update" || submitType === "create") { - this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); - this.projectFormInfo.ref.validate(valid => { - if (valid) { - this.btnLoading = true; - submitApi = this.nozzle.sysPlatformAddOrUpdate; - submitParams = { - data: this.projectFormInfo.data - }; - this.handleAjax(submitApi, submitParams); - }else{ - return false; - } - }); - } - break; //添加站点到项目 case "insert": if (this.UnRelateSiteTableInfo.selectList.length) { @@ -991,23 +996,15 @@ }, //遍历城市数组取得选中城市的经纬度,arr城市数组,id当前所选城市id getCurrentCityJwd(id, arr) { - let currentCity; - let flag = arr.some(item => { + arr.forEach(item => { if (item.id === id) { - currentCity = item; - console.log(1111,currentCity); - return true; + this.currentCity = {...item}; }else{ if (item.children && item.children.length) { this.getCurrentCityJwd(id, item.children); } } }); - if(flag) { - console.log(currentCity); - return currentCity; - } - } } }; diff --git a/src/components/DataAnalysis/StatisticalReport.vue b/src/components/DataAnalysis/StatisticalReport.vue index 3b7b097..6cea6d3 100644 --- a/src/components/DataAnalysis/StatisticalReport.vue +++ b/src/components/DataAnalysis/StatisticalReport.vue @@ -158,7 +158,7 @@ lock: true, text: "Loading", spinner: "el-icon-loading", - background: "rgba(0, 0, 0, 0.7)" + background: "rgba(255, 255, 255, 0.3)" }); this.getData1(); } diff --git a/src/components/Engineering/HistoricalFault.vue b/src/components/Engineering/HistoricalFault.vue index 432342d..f78a850 100644 --- a/src/components/Engineering/HistoricalFault.vue +++ b/src/components/Engineering/HistoricalFault.vue @@ -51,7 +51,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/Engineering/MyHomework_History.vue b/src/components/Engineering/MyHomework_History.vue index c177569..58b258f 100644 --- a/src/components/Engineering/MyHomework_History.vue +++ b/src/components/Engineering/MyHomework_History.vue @@ -33,7 +33,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > @@ -175,6 +175,7 @@ text-align: center; height: 60px; line-height: 60px; + color: var(--white); } /* 主体内容 */ #MH_HCertent { diff --git a/src/components/Engineering/MyHomework_Now.vue b/src/components/Engineering/MyHomework_Now.vue index 2905bba..d979e4e 100644 --- a/src/components/Engineering/MyHomework_Now.vue +++ b/src/components/Engineering/MyHomework_Now.vue @@ -22,7 +22,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > @@ -166,5 +166,6 @@ #YuLanImg { width: 100%; height: auto; + /* a */ } diff --git a/src/components/Engineering/Nowfault.vue b/src/components/Engineering/Nowfault.vue index 19d5a74..e2b4b89 100644 --- a/src/components/Engineering/Nowfault.vue +++ b/src/components/Engineering/Nowfault.vue @@ -21,7 +21,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/MessageManagement/MessageQuery.vue b/src/components/MessageManagement/MessageQuery.vue index ea96bfb..872660b 100644 --- a/src/components/MessageManagement/MessageQuery.vue +++ b/src/components/MessageManagement/MessageQuery.vue @@ -79,7 +79,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/NFCloudPlatform/Attic.vue b/src/components/NFCloudPlatform/Attic.vue index c259fa3..a55aaaf 100644 --- a/src/components/NFCloudPlatform/Attic.vue +++ b/src/components/NFCloudPlatform/Attic.vue @@ -66,7 +66,7 @@ 提示:阀门开度尽量不要超过50
- 阀门开度值:{{waterValue}}%     + 阀门开度值:{{ waterValue }}%    
@@ -79,9 +79,9 @@
流量 - {{Liuliang}} + {{ Liuliang }} 水位 - {{shuiwei}} + {{ shuiwei }}
@@ -200,7 +200,9 @@ var Ary = this.formatterData(res.data); if (Ary[0] == "OK" && Ary[2] == 0) { // this.record(4); - this.$http.post(this.nozzle.engineeringWorkOpenPump).then(res => {});//开水泵 + this.$http + .post(this.nozzle.engineeringWorkOpenPump) + .then(res => {}); //开水泵 this.flag = true; this.readStatue(); this.$message({ @@ -256,7 +258,9 @@ var Ary = this.formatterData(res.data); if (Ary[0] == "OK" && Ary[2] == 0) { // this.record(5); - this.$http.post(this.nozzle.engineeringWorkClosePump).then(res => {});//关水泵 + this.$http + .post(this.nozzle.engineeringWorkClosePump) + .then(res => {}); //关水泵 this.flag = false; this.readStatue(); this.$message({ @@ -283,7 +287,9 @@ var Ary = this.formatterData(res.data); if (Ary[0] == "OK" && Ary[2] == 0) { // this.record(6); - this.$http.post(this.nozzle.engineeringWorkopenValve).then(res => {});//开阀门 + this.$http + .post(this.nozzle.engineeringWorkopenValve) + .then(res => {}); //开阀门 this.flag1 = true; this.readStatue(); this.$message({ @@ -305,7 +311,9 @@ var Ary = this.formatterData(res.data); if (Ary[0] == "OK" && Ary[2] == 0) { // this.record(7); - this.$http.post(this.nozzle.engineeringWorkcloseValve).then(res => {});//关阀门 + this.$http + .post(this.nozzle.engineeringWorkcloseValve) + .then(res => {}); //关阀门 this.flag1 = false; this.readStatue(); this.$message({ @@ -628,4 +636,4 @@ padding: 0 10px; color: #ffffff; } - \ No newline at end of file + diff --git a/src/components/NFCloudPlatform/VideoSurveillance.vue b/src/components/NFCloudPlatform/VideoSurveillance.vue index 7915994..a5eeb3d 100644 --- a/src/components/NFCloudPlatform/VideoSurveillance.vue +++ b/src/components/NFCloudPlatform/VideoSurveillance.vue @@ -4,7 +4,7 @@ v-loading="loading" element-loading-text="正在登陆中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/config/index.js b/config/index.js index 83d2e65..45fc349 100644 --- a/config/index.js +++ b/config/index.js @@ -70,7 +70,7 @@ "/IotPc": { // 物联网平台端信息汇总 // 'target': 'http://192.168.16.115:8288', // 接口域名 - target: "http://192.168.16.100:8289", // 接口域名 + target: "http://132.232.115.20:8289", // 接口域名 changeOrigin: true, //是否跨域 pathRewrite: { "^/IotPc": "" //需要rewrite重写的, diff --git a/src/assets/css/index.css b/src/assets/css/index.css index 2a68327..a2a46b0 100644 --- a/src/assets/css/index.css +++ b/src/assets/css/index.css @@ -11,9 +11,6 @@ --black: rgb(0, 0, 0); /* 原色为黑色,切换后的颜色为白色,设置边框时使用 */ - --lightgray: #c1c5cc; - --lightblue: rgb(102, 177, 255); - --dialogtitle: rgb(0, 255, 255); /* 弹框高亮标题颜色 */ @@ -78,6 +75,14 @@ --selectlist: transparent; /* 下拉框默认背景色为透明色 变为#f4f8ff*/ + + --shouselect: rgb(60, 57, 57); + /* 首页下拉框默认背景色 变为#f4f8ff */ + + --elmentbgc: rgb(58, 58, 60); + + --diagiobgc: #000; + /* 弹框默认背景色 变为206, 223, 255 */ } .form-cascader .el-cascader-panel .el-radio { diff --git a/src/components/ConfigManager/SiteManagement.vue b/src/components/ConfigManager/SiteManagement.vue index 99f2424..f5013a7 100644 --- a/src/components/ConfigManager/SiteManagement.vue +++ b/src/components/ConfigManager/SiteManagement.vue @@ -154,7 +154,7 @@ v-loading="loading" element-loading-text="正在上传图片..." element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" :auto-upload="false" multiple action="#" diff --git a/src/components/ConfigManager/project.vue b/src/components/ConfigManager/project.vue index b4fb535..6e87663 100644 --- a/src/components/ConfigManager/project.vue +++ b/src/components/ConfigManager/project.vue @@ -122,6 +122,7 @@ :field-list="projectFormInfo.fieldList" :rules="projectFormInfo.rules" :list-type-info="listTypeInfo" + :limit-time="projectFormInfo.limitTime" :label-width="projectFormInfo.labelWidth" :need-clear-nodes="projectFormInfo.needClearNodes" :cascader-options="projectFormInfo.cascaderOptions" @@ -475,8 +476,11 @@ rules: {}, labelWidth: "110px", cascaderOptions: [], //区域级联数据源 - needClearNodes: false //是否清除级联上次数据高亮 - } + needClearNodes: false, //是否清除级联上次数据高亮 + limitTime: true, //是否开启选择时间区段限制 + }, + //保存当前选中城市信息以便获取经纬度 + currentCity: {}, }; }, watch: { @@ -632,6 +636,7 @@ this.dialogInfo.visible = true; this.projectFormInfo.needClearNodes = false; this.projectFormInfo.cascaderOptions = this.removeEmptyChild(this.allCity); + console.log(8888,this.removeEmptyChild(this.allCity)); for (let key in data) { if (key in this.projectFormInfo.data) { this.projectFormInfo.data[key] = data[key]; @@ -643,6 +648,30 @@ this.initRules(); }, 0); break; + //提交数据 + case "submit": + let submitType = this.dialogInfo.type; + let submitApi, submitParams; + this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); + const { lat, lon } = this.currentCity; + this.projectFormInfo.data.longitude = lon; + this.projectFormInfo.data.latitude = lat; + if(submitType === "update" || submitType === "create") { + this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); + this.projectFormInfo.ref.validate(valid => { + if (valid) { + this.btnLoading = true; + submitApi = this.nozzle.sysPlatformAddOrUpdate; + submitParams = { + data: this.projectFormInfo.data + }; + this.handleAjax(submitApi, submitParams); + }else{ + return false; + } + }); + } + break; //项目删除按钮 case "delete": this.$confirm("此操作将永久删除该数据, 是否继续?", "提示", { @@ -762,30 +791,6 @@ }) }).catch(() =>{}) break; - //提交数据 - case "submit": - let submitType = this.dialogInfo.type; - let submitApi, submitParams; - console.log(333,this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions)); - let {lat, lon} = this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); - this.projectFormInfo.data.lat = lat; - this.projectFormInfo.data.lon = lon; - if(submitType === "update" || submitType === "create") { - this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); - this.projectFormInfo.ref.validate(valid => { - if (valid) { - this.btnLoading = true; - submitApi = this.nozzle.sysPlatformAddOrUpdate; - submitParams = { - data: this.projectFormInfo.data - }; - this.handleAjax(submitApi, submitParams); - }else{ - return false; - } - }); - } - break; //添加站点到项目 case "insert": if (this.UnRelateSiteTableInfo.selectList.length) { @@ -991,23 +996,15 @@ }, //遍历城市数组取得选中城市的经纬度,arr城市数组,id当前所选城市id getCurrentCityJwd(id, arr) { - let currentCity; - let flag = arr.some(item => { + arr.forEach(item => { if (item.id === id) { - currentCity = item; - console.log(1111,currentCity); - return true; + this.currentCity = {...item}; }else{ if (item.children && item.children.length) { this.getCurrentCityJwd(id, item.children); } } }); - if(flag) { - console.log(currentCity); - return currentCity; - } - } } }; diff --git a/src/components/DataAnalysis/StatisticalReport.vue b/src/components/DataAnalysis/StatisticalReport.vue index 3b7b097..6cea6d3 100644 --- a/src/components/DataAnalysis/StatisticalReport.vue +++ b/src/components/DataAnalysis/StatisticalReport.vue @@ -158,7 +158,7 @@ lock: true, text: "Loading", spinner: "el-icon-loading", - background: "rgba(0, 0, 0, 0.7)" + background: "rgba(255, 255, 255, 0.3)" }); this.getData1(); } diff --git a/src/components/Engineering/HistoricalFault.vue b/src/components/Engineering/HistoricalFault.vue index 432342d..f78a850 100644 --- a/src/components/Engineering/HistoricalFault.vue +++ b/src/components/Engineering/HistoricalFault.vue @@ -51,7 +51,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/Engineering/MyHomework_History.vue b/src/components/Engineering/MyHomework_History.vue index c177569..58b258f 100644 --- a/src/components/Engineering/MyHomework_History.vue +++ b/src/components/Engineering/MyHomework_History.vue @@ -33,7 +33,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > @@ -175,6 +175,7 @@ text-align: center; height: 60px; line-height: 60px; + color: var(--white); } /* 主体内容 */ #MH_HCertent { diff --git a/src/components/Engineering/MyHomework_Now.vue b/src/components/Engineering/MyHomework_Now.vue index 2905bba..d979e4e 100644 --- a/src/components/Engineering/MyHomework_Now.vue +++ b/src/components/Engineering/MyHomework_Now.vue @@ -22,7 +22,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > @@ -166,5 +166,6 @@ #YuLanImg { width: 100%; height: auto; + /* a */ } diff --git a/src/components/Engineering/Nowfault.vue b/src/components/Engineering/Nowfault.vue index 19d5a74..e2b4b89 100644 --- a/src/components/Engineering/Nowfault.vue +++ b/src/components/Engineering/Nowfault.vue @@ -21,7 +21,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/MessageManagement/MessageQuery.vue b/src/components/MessageManagement/MessageQuery.vue index ea96bfb..872660b 100644 --- a/src/components/MessageManagement/MessageQuery.vue +++ b/src/components/MessageManagement/MessageQuery.vue @@ -79,7 +79,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/NFCloudPlatform/Attic.vue b/src/components/NFCloudPlatform/Attic.vue index c259fa3..a55aaaf 100644 --- a/src/components/NFCloudPlatform/Attic.vue +++ b/src/components/NFCloudPlatform/Attic.vue @@ -66,7 +66,7 @@ 提示:阀门开度尽量不要超过50
- 阀门开度值:{{waterValue}}%     + 阀门开度值:{{ waterValue }}%    
@@ -79,9 +79,9 @@
流量 - {{Liuliang}} + {{ Liuliang }} 水位 - {{shuiwei}} + {{ shuiwei }}
@@ -200,7 +200,9 @@ var Ary = this.formatterData(res.data); if (Ary[0] == "OK" && Ary[2] == 0) { // this.record(4); - this.$http.post(this.nozzle.engineeringWorkOpenPump).then(res => {});//开水泵 + this.$http + .post(this.nozzle.engineeringWorkOpenPump) + .then(res => {}); //开水泵 this.flag = true; this.readStatue(); this.$message({ @@ -256,7 +258,9 @@ var Ary = this.formatterData(res.data); if (Ary[0] == "OK" && Ary[2] == 0) { // this.record(5); - this.$http.post(this.nozzle.engineeringWorkClosePump).then(res => {});//关水泵 + this.$http + .post(this.nozzle.engineeringWorkClosePump) + .then(res => {}); //关水泵 this.flag = false; this.readStatue(); this.$message({ @@ -283,7 +287,9 @@ var Ary = this.formatterData(res.data); if (Ary[0] == "OK" && Ary[2] == 0) { // this.record(6); - this.$http.post(this.nozzle.engineeringWorkopenValve).then(res => {});//开阀门 + this.$http + .post(this.nozzle.engineeringWorkopenValve) + .then(res => {}); //开阀门 this.flag1 = true; this.readStatue(); this.$message({ @@ -305,7 +311,9 @@ var Ary = this.formatterData(res.data); if (Ary[0] == "OK" && Ary[2] == 0) { // this.record(7); - this.$http.post(this.nozzle.engineeringWorkcloseValve).then(res => {});//关阀门 + this.$http + .post(this.nozzle.engineeringWorkcloseValve) + .then(res => {}); //关阀门 this.flag1 = false; this.readStatue(); this.$message({ @@ -628,4 +636,4 @@ padding: 0 10px; color: #ffffff; } - \ No newline at end of file + diff --git a/src/components/NFCloudPlatform/VideoSurveillance.vue b/src/components/NFCloudPlatform/VideoSurveillance.vue index 7915994..a5eeb3d 100644 --- a/src/components/NFCloudPlatform/VideoSurveillance.vue +++ b/src/components/NFCloudPlatform/VideoSurveillance.vue @@ -4,7 +4,7 @@ v-loading="loading" element-loading-text="正在登陆中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/common/PageForm/index.vue b/src/components/common/PageForm/index.vue index 20aab82..253d1b2 100644 --- a/src/components/common/PageForm/index.vue +++ b/src/components/common/PageForm/index.vue @@ -207,6 +207,20 @@ needClearNodes: { type: Boolean, default: false + }, + /** + * 限制选择的时间区段 + * false:不限制 + * ture:限制的时间区段,默认为半年 + */ + limitTime: { + type: Boolean, + default: false + }, + //限制选择的时间区段值,配合limitTime使用 + limitTimePeriod: { + type: Number, + default: 365 } }, data() { @@ -223,13 +237,23 @@ //结束时间不能大于开始时间 disabledDate: time => { if (this.data.endTime) { - return time.getTime() > new Date(this.data.endTime).getTime(); + let halfYear = this.limitTimePeriod / 2 * 24 * 3600 * 1000; + let endTime = new Date(this.data.endTime).getTime(); + let limitTime = endTime - halfYear; + let result = this.limitTime ? (limitTime > time.getTime() || time.getTime() > endTime) : (time.getTime() > endTime); + return result; } } }, pickerOptionsEnd: { disabledDate: time => { - return time.getTime() < new Date(this.data.startTime).getTime(); + if (this.data.startTime) { + let halfYear = this.limitTimePeriod / 2 * 24 * 3600 * 1000; + let startTime = new Date(this.data.startTime).getTime(); + let limitTime = startTime + halfYear; + let result = this.limitTime ? (limitTime < time.getTime() || time.getTime() < startTime) : (time.getTime() < startTime); + return result; + } } }, //当日具体时刻 @@ -338,11 +362,11 @@ }, //级联选中节点时触发事件 handleChange(val,node) { - console.log(val,node,this.cascaderOptions); this.data.area = val.length ? val[val.length - 1] : ""; }, //级联下拉框出现/隐藏触发事件 handleVisibleChange(visible) { + let that = this; if (visible) { this.timer = setInterval(() => { NodeList.prototype.forEach = Array.prototype.forEach; @@ -351,6 +375,9 @@ if (this.previousElementSibling) this.previousElementSibling.click(); }; + el.ondblclick = function() { + that.$refs.cascader[0].dropDownVisible = false; + } }); }, 1000); } else { diff --git a/config/index.js b/config/index.js index 83d2e65..45fc349 100644 --- a/config/index.js +++ b/config/index.js @@ -70,7 +70,7 @@ "/IotPc": { // 物联网平台端信息汇总 // 'target': 'http://192.168.16.115:8288', // 接口域名 - target: "http://192.168.16.100:8289", // 接口域名 + target: "http://132.232.115.20:8289", // 接口域名 changeOrigin: true, //是否跨域 pathRewrite: { "^/IotPc": "" //需要rewrite重写的, diff --git a/src/assets/css/index.css b/src/assets/css/index.css index 2a68327..a2a46b0 100644 --- a/src/assets/css/index.css +++ b/src/assets/css/index.css @@ -11,9 +11,6 @@ --black: rgb(0, 0, 0); /* 原色为黑色,切换后的颜色为白色,设置边框时使用 */ - --lightgray: #c1c5cc; - --lightblue: rgb(102, 177, 255); - --dialogtitle: rgb(0, 255, 255); /* 弹框高亮标题颜色 */ @@ -78,6 +75,14 @@ --selectlist: transparent; /* 下拉框默认背景色为透明色 变为#f4f8ff*/ + + --shouselect: rgb(60, 57, 57); + /* 首页下拉框默认背景色 变为#f4f8ff */ + + --elmentbgc: rgb(58, 58, 60); + + --diagiobgc: #000; + /* 弹框默认背景色 变为206, 223, 255 */ } .form-cascader .el-cascader-panel .el-radio { diff --git a/src/components/ConfigManager/SiteManagement.vue b/src/components/ConfigManager/SiteManagement.vue index 99f2424..f5013a7 100644 --- a/src/components/ConfigManager/SiteManagement.vue +++ b/src/components/ConfigManager/SiteManagement.vue @@ -154,7 +154,7 @@ v-loading="loading" element-loading-text="正在上传图片..." element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" :auto-upload="false" multiple action="#" diff --git a/src/components/ConfigManager/project.vue b/src/components/ConfigManager/project.vue index b4fb535..6e87663 100644 --- a/src/components/ConfigManager/project.vue +++ b/src/components/ConfigManager/project.vue @@ -122,6 +122,7 @@ :field-list="projectFormInfo.fieldList" :rules="projectFormInfo.rules" :list-type-info="listTypeInfo" + :limit-time="projectFormInfo.limitTime" :label-width="projectFormInfo.labelWidth" :need-clear-nodes="projectFormInfo.needClearNodes" :cascader-options="projectFormInfo.cascaderOptions" @@ -475,8 +476,11 @@ rules: {}, labelWidth: "110px", cascaderOptions: [], //区域级联数据源 - needClearNodes: false //是否清除级联上次数据高亮 - } + needClearNodes: false, //是否清除级联上次数据高亮 + limitTime: true, //是否开启选择时间区段限制 + }, + //保存当前选中城市信息以便获取经纬度 + currentCity: {}, }; }, watch: { @@ -632,6 +636,7 @@ this.dialogInfo.visible = true; this.projectFormInfo.needClearNodes = false; this.projectFormInfo.cascaderOptions = this.removeEmptyChild(this.allCity); + console.log(8888,this.removeEmptyChild(this.allCity)); for (let key in data) { if (key in this.projectFormInfo.data) { this.projectFormInfo.data[key] = data[key]; @@ -643,6 +648,30 @@ this.initRules(); }, 0); break; + //提交数据 + case "submit": + let submitType = this.dialogInfo.type; + let submitApi, submitParams; + this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); + const { lat, lon } = this.currentCity; + this.projectFormInfo.data.longitude = lon; + this.projectFormInfo.data.latitude = lat; + if(submitType === "update" || submitType === "create") { + this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); + this.projectFormInfo.ref.validate(valid => { + if (valid) { + this.btnLoading = true; + submitApi = this.nozzle.sysPlatformAddOrUpdate; + submitParams = { + data: this.projectFormInfo.data + }; + this.handleAjax(submitApi, submitParams); + }else{ + return false; + } + }); + } + break; //项目删除按钮 case "delete": this.$confirm("此操作将永久删除该数据, 是否继续?", "提示", { @@ -762,30 +791,6 @@ }) }).catch(() =>{}) break; - //提交数据 - case "submit": - let submitType = this.dialogInfo.type; - let submitApi, submitParams; - console.log(333,this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions)); - let {lat, lon} = this.getCurrentCityJwd(this.projectFormInfo.data.area,this.projectFormInfo.cascaderOptions); - this.projectFormInfo.data.lat = lat; - this.projectFormInfo.data.lon = lon; - if(submitType === "update" || submitType === "create") { - this.projectFormInfo.rules = this.$initRules(this.projectFormInfo.fieldList); - this.projectFormInfo.ref.validate(valid => { - if (valid) { - this.btnLoading = true; - submitApi = this.nozzle.sysPlatformAddOrUpdate; - submitParams = { - data: this.projectFormInfo.data - }; - this.handleAjax(submitApi, submitParams); - }else{ - return false; - } - }); - } - break; //添加站点到项目 case "insert": if (this.UnRelateSiteTableInfo.selectList.length) { @@ -991,23 +996,15 @@ }, //遍历城市数组取得选中城市的经纬度,arr城市数组,id当前所选城市id getCurrentCityJwd(id, arr) { - let currentCity; - let flag = arr.some(item => { + arr.forEach(item => { if (item.id === id) { - currentCity = item; - console.log(1111,currentCity); - return true; + this.currentCity = {...item}; }else{ if (item.children && item.children.length) { this.getCurrentCityJwd(id, item.children); } } }); - if(flag) { - console.log(currentCity); - return currentCity; - } - } } }; diff --git a/src/components/DataAnalysis/StatisticalReport.vue b/src/components/DataAnalysis/StatisticalReport.vue index 3b7b097..6cea6d3 100644 --- a/src/components/DataAnalysis/StatisticalReport.vue +++ b/src/components/DataAnalysis/StatisticalReport.vue @@ -158,7 +158,7 @@ lock: true, text: "Loading", spinner: "el-icon-loading", - background: "rgba(0, 0, 0, 0.7)" + background: "rgba(255, 255, 255, 0.3)" }); this.getData1(); } diff --git a/src/components/Engineering/HistoricalFault.vue b/src/components/Engineering/HistoricalFault.vue index 432342d..f78a850 100644 --- a/src/components/Engineering/HistoricalFault.vue +++ b/src/components/Engineering/HistoricalFault.vue @@ -51,7 +51,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/Engineering/MyHomework_History.vue b/src/components/Engineering/MyHomework_History.vue index c177569..58b258f 100644 --- a/src/components/Engineering/MyHomework_History.vue +++ b/src/components/Engineering/MyHomework_History.vue @@ -33,7 +33,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > @@ -175,6 +175,7 @@ text-align: center; height: 60px; line-height: 60px; + color: var(--white); } /* 主体内容 */ #MH_HCertent { diff --git a/src/components/Engineering/MyHomework_Now.vue b/src/components/Engineering/MyHomework_Now.vue index 2905bba..d979e4e 100644 --- a/src/components/Engineering/MyHomework_Now.vue +++ b/src/components/Engineering/MyHomework_Now.vue @@ -22,7 +22,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > @@ -166,5 +166,6 @@ #YuLanImg { width: 100%; height: auto; + /* a */ } diff --git a/src/components/Engineering/Nowfault.vue b/src/components/Engineering/Nowfault.vue index 19d5a74..e2b4b89 100644 --- a/src/components/Engineering/Nowfault.vue +++ b/src/components/Engineering/Nowfault.vue @@ -21,7 +21,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/MessageManagement/MessageQuery.vue b/src/components/MessageManagement/MessageQuery.vue index ea96bfb..872660b 100644 --- a/src/components/MessageManagement/MessageQuery.vue +++ b/src/components/MessageManagement/MessageQuery.vue @@ -79,7 +79,7 @@ v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/NFCloudPlatform/Attic.vue b/src/components/NFCloudPlatform/Attic.vue index c259fa3..a55aaaf 100644 --- a/src/components/NFCloudPlatform/Attic.vue +++ b/src/components/NFCloudPlatform/Attic.vue @@ -66,7 +66,7 @@ 提示:阀门开度尽量不要超过50
- 阀门开度值:{{waterValue}}%     + 阀门开度值:{{ waterValue }}%    
@@ -79,9 +79,9 @@
流量 - {{Liuliang}} + {{ Liuliang }} 水位 - {{shuiwei}} + {{ shuiwei }}
@@ -200,7 +200,9 @@ var Ary = this.formatterData(res.data); if (Ary[0] == "OK" && Ary[2] == 0) { // this.record(4); - this.$http.post(this.nozzle.engineeringWorkOpenPump).then(res => {});//开水泵 + this.$http + .post(this.nozzle.engineeringWorkOpenPump) + .then(res => {}); //开水泵 this.flag = true; this.readStatue(); this.$message({ @@ -256,7 +258,9 @@ var Ary = this.formatterData(res.data); if (Ary[0] == "OK" && Ary[2] == 0) { // this.record(5); - this.$http.post(this.nozzle.engineeringWorkClosePump).then(res => {});//关水泵 + this.$http + .post(this.nozzle.engineeringWorkClosePump) + .then(res => {}); //关水泵 this.flag = false; this.readStatue(); this.$message({ @@ -283,7 +287,9 @@ var Ary = this.formatterData(res.data); if (Ary[0] == "OK" && Ary[2] == 0) { // this.record(6); - this.$http.post(this.nozzle.engineeringWorkopenValve).then(res => {});//开阀门 + this.$http + .post(this.nozzle.engineeringWorkopenValve) + .then(res => {}); //开阀门 this.flag1 = true; this.readStatue(); this.$message({ @@ -305,7 +311,9 @@ var Ary = this.formatterData(res.data); if (Ary[0] == "OK" && Ary[2] == 0) { // this.record(7); - this.$http.post(this.nozzle.engineeringWorkcloseValve).then(res => {});//关阀门 + this.$http + .post(this.nozzle.engineeringWorkcloseValve) + .then(res => {}); //关阀门 this.flag1 = false; this.readStatue(); this.$message({ @@ -628,4 +636,4 @@ padding: 0 10px; color: #ffffff; } - \ No newline at end of file + diff --git a/src/components/NFCloudPlatform/VideoSurveillance.vue b/src/components/NFCloudPlatform/VideoSurveillance.vue index 7915994..a5eeb3d 100644 --- a/src/components/NFCloudPlatform/VideoSurveillance.vue +++ b/src/components/NFCloudPlatform/VideoSurveillance.vue @@ -4,7 +4,7 @@ v-loading="loading" element-loading-text="正在登陆中" element-loading-spinner="el-icon-loading" - element-loading-background="rgba(0, 0, 0, 0.8)" + element-loading-background="rgba(255, 255, 255, 0.3)" > diff --git a/src/components/common/PageForm/index.vue b/src/components/common/PageForm/index.vue index 20aab82..253d1b2 100644 --- a/src/components/common/PageForm/index.vue +++ b/src/components/common/PageForm/index.vue @@ -207,6 +207,20 @@ needClearNodes: { type: Boolean, default: false + }, + /** + * 限制选择的时间区段 + * false:不限制 + * ture:限制的时间区段,默认为半年 + */ + limitTime: { + type: Boolean, + default: false + }, + //限制选择的时间区段值,配合limitTime使用 + limitTimePeriod: { + type: Number, + default: 365 } }, data() { @@ -223,13 +237,23 @@ //结束时间不能大于开始时间 disabledDate: time => { if (this.data.endTime) { - return time.getTime() > new Date(this.data.endTime).getTime(); + let halfYear = this.limitTimePeriod / 2 * 24 * 3600 * 1000; + let endTime = new Date(this.data.endTime).getTime(); + let limitTime = endTime - halfYear; + let result = this.limitTime ? (limitTime > time.getTime() || time.getTime() > endTime) : (time.getTime() > endTime); + return result; } } }, pickerOptionsEnd: { disabledDate: time => { - return time.getTime() < new Date(this.data.startTime).getTime(); + if (this.data.startTime) { + let halfYear = this.limitTimePeriod / 2 * 24 * 3600 * 1000; + let startTime = new Date(this.data.startTime).getTime(); + let limitTime = startTime + halfYear; + let result = this.limitTime ? (limitTime < time.getTime() || time.getTime() < startTime) : (time.getTime() < startTime); + return result; + } } }, //当日具体时刻 @@ -338,11 +362,11 @@ }, //级联选中节点时触发事件 handleChange(val,node) { - console.log(val,node,this.cascaderOptions); this.data.area = val.length ? val[val.length - 1] : ""; }, //级联下拉框出现/隐藏触发事件 handleVisibleChange(visible) { + let that = this; if (visible) { this.timer = setInterval(() => { NodeList.prototype.forEach = Array.prototype.forEach; @@ -351,6 +375,9 @@ if (this.previousElementSibling) this.previousElementSibling.click(); }; + el.ondblclick = function() { + that.$refs.cascader[0].dropDownVisible = false; + } }); }, 1000); } else { diff --git a/src/components/common/PageTable/index.vue b/src/components/common/PageTable/index.vue index b992a54..1b82a2b 100644 --- a/src/components/common/PageTable/index.vue +++ b/src/components/common/PageTable/index.vue @@ -1,6 +1,13 @@ - + - {{ getDataName({dataList: listTypeInfo[item.list], value: 'value', label: 'key', data: scope.row[item.value]}) || '-' }} + {{ + getDataName({ + dataList: listTypeInfo[item.list], + value: "value", + label: "key", + data: scope.row[item.value] + }) || "-" + }}
@@ -77,9 +99,18 @@