6/20提交

This commit is contained in:
home孙 2025-06-20 17:28:16 +08:00
parent 9763b320eb
commit 84930b1639
61 changed files with 1088 additions and 652 deletions

View File

@ -262,7 +262,7 @@ geteqetdata(data) {
},
// 数据采集器的实时数据
getdataRtdata(data) {
return sendGetRequest(`/getdata/rtdata?deviceId=` + data, ``)
return sendGetRequest(`/getdata/rtdata`, data)
},
//测试施肥机读取设备状态信息 //读取数据 根据文档编号读取 所有数据展示都出自这个接口
postReg(data) {
@ -281,11 +281,11 @@ getdataRtdata(data) {
},
//获取实时数据
postRtdata(data) {
return sendPostRequest(`/getFs/rtdata?equipmentId=` + data, ``);
return sendPostParamsRequest(`/getFs/rtdata`, data);
},
//获取实时数据
postFsdata(data) {
return sendPostRequest(`/chart/fsdata?equipmentId=` + data, ``);
return sendPostParamsRequest(`/chart/fsdata`, data);
},
//获取监控地址
getGethls(data) {
@ -299,12 +299,12 @@ getdataRtdata(data) {
//控制器接口
//控制器实时数据
getControlRtdata(data) {
return sendPostRequest(`/getcontrol/rtdata?equipmentId=` + data, ``);
getControlRtdata(params) {
return sendPostParamsRequest(`/getcontrol/rtdata` ,params);
},
//控制器实时数据折线图
getControlFsdata(data) {
return sendPostRequest(`/getcontrol/fsdata?equipmentId=` + data, ``);
getControlFsdata(params) {
return sendPostParamsRequest(`/getcontrol/fsdata`,params);
},
//控制器数据上传数据获取
getControldataUpload(data) {
@ -336,7 +336,7 @@ getdataRtdata(data) {
},
//控制器 气象站实时数据折线图
getControlChartdata(data) {
return sendPostRequest(`/equip/chartdata?equipmentId=` + data, ``)
return sendPostParamsRequest(`/equip/chartdata`,data)
},
//首页历史数据/数据分析弹窗
selFsAvgdata(data) {
@ -384,9 +384,7 @@ getdataRtdata(data) {
return sendGetRequest(`/readControl/getState?deviceId=${deviceId}`, data);
},
getcontrol_rtDatastation(equipmentId, data) {
return sendGetRequest(`/getcontrol/rtDatastation?equipmentId=${equipmentId}`, data)
},
//控制器根据设备查看权限
getcontrol_cpermission(equipmentId, data) {
return sendPostRequest(`/getcontrol/cpermission?deviceId=${equipmentId}`, data)
@ -745,7 +743,7 @@ getIccid(data){
},
//当天折线图
chart_fidata(data) {
return sendPostRequest(`/chart/fidata?equipmentId=${data}`,``)
return sendPostParamsRequest(`/chart/fidata`,data)
},
//智能灌溉1
readFi_irrigate(url,data) {

View File

@ -192,7 +192,7 @@ textarea {
.collapse .no-list {
width: 100%;
height: 76px;
line-height: 76px;
line-height: 25px;
padding-left: 25px;
border-bottom: 1px solid rgba(168, 182, 200, 0.2);
cursor: pointer;
@ -1329,7 +1329,7 @@ textarea {
}
.btn.btn-w66 {
width: 66px;
min-width: 66px;
min-width: unset;
}
@ -2424,7 +2424,6 @@ textarea {
.realTime .page-content .realTime-bottom .left-view > div .video-control .video-btn > div > div {
white-space: nowrap;
width: 40px;
}
.realTime .page-content .realTime-bottom .right {
@ -4025,6 +4024,7 @@ textarea {
font-size: 20px;
font-weight: bold;
padding: 15px 0;
color: #fff;
}
.model-sel {

View File

@ -203,7 +203,7 @@ textarea {
.no-list {
width: 100%;
height: 76px;
line-height: 76px;
line-height: 25px;
padding-left: 25px;
border-bottom: 1px solid rgba(168, 182, 200, 0.2);
cursor: pointer;
@ -1401,7 +1401,7 @@ textarea {
}
&.btn-w66 {
width: 66px;
min-width: 66px;
min-width: unset;
}
@ -2557,7 +2557,6 @@ textarea {
>div {
white-space: nowrap;
width: 40px;
}
}
}
@ -4283,6 +4282,7 @@ textarea {
font-size: 20px;
font-weight: bold;
padding: 15px 0;
color: #fff;
}
.model-sel {

View File

@ -1,11 +1,11 @@
<template>
<div class="set-params collapse scroll">
<div class="set-top">
<img src="../assets/image/set-icon.png" alt="">设定值参数
<img src="../assets/image/set-icon.png" alt="">{{$t('setParams.title')}}
</div>
<div class="set-tips">
<div @click="toHome($store.state.equipmentIndex)">
{{ $store.state.equipmentList[$store.state.equipmentIndex - 1].deviceTypeName }}状态显示</div>
{{ $t('setParams.statusDisplay', {deviceName: $store.state.equipmentList[$store.state.equipmentIndex - 1].deviceTypeName}) }}</div>
</div>
<el-collapse v-model="$store.state.activeNames">
<template v-for="item, index in routerList">
@ -22,7 +22,7 @@
item1.name }} <div class="status" :class="item1.status == 0 ? 'outline' : 'online'"
v-if="item1.status >= 0">{{ item1.status
== 0
? '离线' : '在线' }}</div>
? $t('index.offline') : $t('index.online') }}</div>
</li>
</ul>
</el-collapse-item>
@ -37,46 +37,47 @@
export default {
data() {
return {
routerList: [
{ name: '施肥机配方设置', list: [], router: 'formula' },
{
name: '灌溉组配置', router: 'irrigateSet', list: [
{ name: '1#灌溉组配置', status: -1, router: 'irrigateSet', index: 1 },
{ name: '2#灌溉组配置', status: -1, router: 'irrigateSet', index: 2 },
{ name: '3#灌溉组配置', status: -1, router: 'irrigateSet', index: 3 },
{ name: '4#灌溉组配置', status: -1, router: 'irrigateSet', index: 4 },
{ name: '5#灌溉组配置', status: -1, router: 'irrigateSet', index: 5 },
{ name: '6#灌溉组配置', status: -1, router: 'irrigateSet', index: 6 },
{ name: '7#灌溉组配置', status: -1, router: 'irrigateSet', index: 7 },
{ name: '8#灌溉组配置', status: -1, router: 'irrigateSet', index: 8 },
{ name: '9#灌溉组配置', status: -1, router: 'irrigateSet', index: 9 },
{ name: '10#灌溉组配置', status: -1, router: 'irrigateSet', index: 10 },
{ name: '11#灌溉组配置', status: -1, router: 'irrigateSet', index: 11 },
{ name: '12#灌溉组配置', status: -1, router: 'irrigateSet', index: 12 },
{ name: '13#灌溉组配置', status: -1, router: 'irrigateSet', index: 13 },
{ name: '14#灌溉组配置', status: -1, router: 'irrigateSet', index: 14 },
{ name: '15#灌溉组配置', status: -1, router: 'irrigateSet', index: 15 },
{ name: '16#灌溉组配置', status: -1, router: 'irrigateSet', index: 16 }]
},
{ name: '厂家内部PID配置', list: [], router: 'PIDSet', isRouter: true, },
{ name: '系统参数配置', list: [], router: 'systemSet', isRouter: true, },
{ name: '传感器通道配置', list: [], router: 'sensorSet', isRouter: true, },
{ name: '数据上传', list: [], router: 'upload', isRouter: true, },],
routerNow: 'formula',
routerIndex: 1,
routerList:[],
}
},
watch: {
"$route"(newName, oldName) {
this.gerRouter();
},
},
'$i18n.locale'() {
this.initRouterList()
}
},
mounted() {
this.gerRouter();
this.dataInit()
},
created(){
this.initRouterList()
},
methods: {
initRouterList(){
this.routerList=[
{ name: this.$t('setParams.formulaSettings'), list: [], router: 'formula' },
{
name:this.$t('setParams.irrigationGroupConfig'), router: 'irrigateSet', list: this.$t('setParams.irrigationGroups').map((name, index) => ({
name,
status: -1,
router: 'irrigateSet',
index: index + 1
}))
},
{ name: this.$t('setParams.internalPIDConfig'), list: [], router: 'PIDSet', isRouter: true, },
{ name:this.$t('setParams.systemParamsConfig'), list: [], router: 'systemSet', isRouter: true, },
{ name: this.$t('setParams.sensorChannelConfig'), list: [], router: 'sensorSet', isRouter: true, },
{ name: this.$t('setParams.dataUpload'), list: [], router: 'upload', isRouter: true, },]
setTimeout(() => {
this.getList()
}, 0);
},
///
getByid() {
var store = this.$store.state

View File

@ -1,7 +1,7 @@
<template>
<div class="set-params collapse scroll">
<div class="set-top">
<img src="../assets/image/set-icon.png" alt="" />设定值参数
<img src="../assets/image/set-icon.png" alt="" />{{$t('setParams.title')}}
</div>
<div class="set-tips">
<!-- <div @click="toHome($store.state.equipmentIndex)">
@ -41,7 +41,7 @@
:class="item1.status == 0 ? 'outline' : 'online'"
v-if="item1.status >= 0"
>
{{ item1.status == 0 ? "离线" : "在线" }}
{{ item1.status == 0 ? $t('index.offline') : $t('index.online') }} }}
</div>
</li>
</ul>
@ -81,6 +81,9 @@ export default {
this.dataInit();
}
},
'$i18n.locale'() {
this.dataInit();
}
},
mounted() {
this.gerRouter();
@ -117,7 +120,7 @@ export default {
const that = this;
this.loading = this.$loading({
lock: true,
text: "加载中",
text:this.$t('message.loading'),
spinner: "el-icon-loading",
background: "rgba(0, 0, 0, 0.7)",
});
@ -133,21 +136,21 @@ export default {
if (el.id == 1) {
var list = [
{
name: "目标温度",
name: this.$t('setParams.targetTemp'),
list: [],
router: "targetTemperature",
isRouter: true,
index: 1,
},
{
name: "目标湿度",
name:this.$t('setParams.targetHumidity'),
list: [],
router: "targetHumidity",
isRouter: true,
index: 2,
},
{
name: "目标CO2",
name:this.$t('setParams.targetCO2'),
list: [],
router: "targetCo2",
isRouter: true,
@ -179,37 +182,37 @@ export default {
} else if (el.id == 19) {
var list = [
{
name: "通风窗1",
name:this.$t('setParams.sunroofControl')+'1',
status: -1,
router: "sunroofControl",
index: 1,
},
{
name: "通风窗2",
name: this.$t('setParams.sunroofControl')+"2",
status: -1,
router: "sunroofControl",
index: 2,
},
{
name: "通风窗3",
name: this.$t('setParams.sunroofControl')+"3",
status: -1,
router: "sunroofControl",
index: 3,
},
{
name: "通风窗4",
name: this.$t('setParams.sunroofControl')+"4",
status: -1,
router: "sunroofControl",
index: 4,
},
{
name: "通风窗5",
name: this.$t('setParams.sunroofControl')+"5",
status: -1,
router: "sunroofControl",
index: 5,
},
{
name: "通风窗6",
name: this.$t('setParams.sunroofControl')+"6",
status: -1,
router: "sunroofControl",
index: 6,
@ -231,13 +234,13 @@ export default {
} else if (el.id == 25) {
var list = [
{
name: "外遮阳1",
name: this.$t('setParams.outShade')+"1",
status: -1,
router: "outsizeSunshade",
index: 1,
},
{
name: "外遮阳2",
name:this.$t('setParams.outShade')+"2",
status: -1,
router: "outsizeSunshade",
index: 2,
@ -259,13 +262,13 @@ export default {
} else if (el.id == 24) {
var list = [
{
name: "内遮阳1",
name: this.$t('setParams.inShade')+"1",
status: -1,
router: "insizeSunshade",
index: 1,
},
{
name: "内遮阳2",
name: this.$t('setParams.inShade')+"2",
status: -1,
router: "insizeSunshade",
index: 2,
@ -287,13 +290,13 @@ export default {
} else if (el.id == 27) {
var list = [
{
name: "内保温1",
name: this.$t('setParams.inInsulation')+"1" ,
status: -1,
router: "internalInsulation",
index: 1,
},
{
name: "内保温2",
name: this.$t('setParams.inInsulation')+"2" ,
status: -1,
router: "internalInsulation",
index: 2,
@ -315,25 +318,25 @@ export default {
} else if (el.id == 29) {
var list = [
{
name: "立面保温1",
name: this.$t('setParams.facadeInsulation')+"1",
status: -1,
router: "facadeInsulation",
index: 1,
},
{
name: "立面保温2",
name: this.$t('setParams.facadeInsulation')+"2",
status: -1,
router: "facadeInsulation",
index: 2,
},
{
name: "立面保温3",
name: this.$t('setParams.facadeInsulation')+"3",
status: -1,
router: "facadeInsulation",
index: 3,
},
{
name: "立面保温4",
name: this.$t('setParams.facadeInsulation')+"4",
status: -1,
router: "facadeInsulation",
index: 4,
@ -354,9 +357,9 @@ export default {
});
} else if (el.id == 26) {
var list = [
{ name: "风机", status: -1, router: "wetFan", index: 1 },
{ name: "湿帘泵", status: -1, router: "wetFan", index: 2 },
{ name: "湿帘外翻窗", status: -1, router: "wetFan", index: 3 },
{ name:this.$t('setParams.wetFan'), status: -1, router: "wetFan", index: 1 },
{ name:this.$t('setParams.wetPump') , status: -1, router: "wetFan", index: 2 },
{ name:this.$t('setParams.wetWindow'), status: -1, router: "wetFan", index: 3 },
];
let newList;
if (el.child.length) {
@ -374,13 +377,13 @@ export default {
} else if (el.id == 21) {
var list = [
{
name: "环流风扇1",
name: this.$t('setParams.circulationFan')+"1",
status: -1,
router: "circulationCan",
index: 1,
},
{
name: "环流风扇2",
name: this.$t('setParams.circulationFan')+"2",
status: -1,
router: "circulationCan",
index: 2,
@ -430,13 +433,13 @@ export default {
} else if (el.id == 23) {
var list = [
{
name: "高压微雾1",
name: this.$t('setParams.highPressureMist')+"1",
status: -1,
router: "coercionMist",
index: 1,
},
{
name: "高压微雾2",
name: this.$t('setParams.highPressureMist')+"2",
status: -1,
router: "coercionMist",
index: 2,
@ -474,7 +477,7 @@ export default {
this.routerList.push({
id: el.id,
sort: el.sort,
name: "电磁阀",
name:this.$t('setParams.solenoidValve'),
list: [],
router: "electromagneticControl",
});
@ -596,7 +599,7 @@ export default {
{
id: el.id,
sort: el.sort,
name: "加热水泵",
name:this.$t('setParams.waterPump'),
list: [],
router: "waterPump",
isRouter: true,
@ -604,7 +607,7 @@ export default {
{
id: el.id,
sort: el.sort,
name: "地热风机",
name:this.$t('setParams.geothermalFan') ,
list: [],
router: "geothermalFan",
isRouter: true,
@ -612,7 +615,7 @@ export default {
{
id: el.id,
sort: el.sort,
name: "上风口",
name:this.$t('setParams.uptake') ,
list: [],
router: "uptake",
isRouter: true,
@ -620,7 +623,7 @@ export default {
{
id: el.id,
sort: el.sort,
name: "下风口",
name:this.$t('setParams.downtake'),
list: [],
router: "downtake",
isRouter: true,
@ -628,7 +631,7 @@ export default {
{
id: el.id,
sort: el.sort,
name: "卷被",
name:this.$t('setParams.rollByRoll') ,
list: [],
router: "rollByRoll",
isRouter: true,
@ -636,7 +639,7 @@ export default {
{
id: el.id,
sort: el.sort,
name: "除雪",
name:this.$t('setParams.snowRemoval') ,
list: [],
router: "snowRemoval",
isRouter: true,
@ -722,33 +725,33 @@ export default {
{
id: el.id,
sort: el.sort,
name: "日光温室特殊参数(山地型温室)",
name: this.$t('setParams.mountainGreenhouse'),
router: "skylight",
list: [
{ name: "顶卷膜1", status: -1, router: "skylight", index: 1 },
{ name: "顶卷膜2", status: -1, router: "skylight", index: 2 },
{ name: "顶卷膜3", status: -1, router: "skylight", index: 3 },
{ name: "顶卷膜4", status: -1, router: "skylight", index: 4 },
{ name: this.$t('setParams.skylight')+"1", status: -1, router: "skylight", index: 1 },
{ name: this.$t('setParams.skylight')+"2", status: -1, router: "skylight", index: 2 },
{ name: this.$t('setParams.skylight')+"3", status: -1, router: "skylight", index: 3 },
{ name: this.$t('setParams.skylight')+"4", status: -1, router: "skylight", index: 4 },
],
},
{
id: el.id,
sort: el.sort,
name: "风机(山地型温室)",
name:this.$t('setParams.mountainFan'),
router: "fan",
list: [
{ name: "风机1", status: -1, router: "fan", index: 1 },
{ name: "风机2", status: -1, router: "fan", index: 2 },
{ name: "风机3", status: -1, router: "fan", index: 3 },
{ name: "风机4", status: -1, router: "fan", index: 4 },
{ name: "风机5", status: -1, router: "fan", index: 5 },
{ name:this.$t('setParams.fan')+"1", status: -1, router: "fan", index: 1 },
{ name:this.$t('setParams.fan')+"2", status: -1, router: "fan", index: 2 },
{ name:this.$t('setParams.fan')+"3", status: -1, router: "fan", index: 3 },
{ name:this.$t('setParams.fan')+"4", status: -1, router: "fan", index: 4 },
{ name:this.$t('setParams.fan')+"5", status: -1, router: "fan", index: 5 },
],
}
);
} else if (el.id == 30) {
var list = [
{ name: "CO2补气", status: -1, router: "CO2", index: 1 },
{ name: "CO2补气", status: -1, router: "CO2", index: 2 },
{ name:this.$t('setParams.CO2') , status: -1, router: "CO2", index: 1 },
{ name: this.$t('setParams.CO2'), status: -1, router: "CO2", index: 2 },
];
let newList;
if (el.child.length) {
@ -767,9 +770,9 @@ export default {
}
});
// this.routerList.sort((a, b) => a.sort - b.sort);
this.$forceUpdate()
this.routerList.push({
name: "系统参数配置",
name:this.$t('setParams.systemParamsConfig'),
list: [],
router: "systemSet-con",
isRouter: true,

View File

@ -1,7 +1,7 @@
<template>
<div class="set-params collapse scroll">
<div class="set-top">
<img src="../assets/image/set-icon.png" alt="">设定值参数
<img src="../assets/image/set-icon.png" alt="">{{$t('setParams.title')}}
</div>
<!-- -->
<div class="set-tips" @click="toHome($store.state.equipmentIndex)">
@ -24,7 +24,7 @@
v-if="item1.status >= 0">{{
item1.status
== 0
? '离线' : '在线' }}</div>
? $t('index.offline') : $t('index.online') }}</div>
</li>
</ul>
</el-collapse-item>
@ -39,48 +39,46 @@
export default {
data() {
return {
routerList: [
// { name: '', list: [], router: 'formula' },
{ name: `${this.$store.state.equipmentList[this.$store.state.equipmentIndex - 1].deviceTypeName}状态显示`, list: [], router: 'status-soil', isRouter: true, },
{
name: '灌溉组配置', router: 'irrigateSet-soil', list: [
{ name: '1#灌溉组配置', status: -1, router: 'irrigateSet-soil', index: 1 },
{ name: '2#灌溉组配置', status: -1, router: 'irrigateSet-soil', index: 2 },
{ name: '3#灌溉组配置', status: -1, router: 'irrigateSet-soil', index: 3 },
{ name: '4#灌溉组配置', status: -1, router: 'irrigateSet-soil', index: 4 },
{ name: '5#灌溉组配置', status: -1, router: 'irrigateSet-soil', index: 5 },
{ name: '6#灌溉组配置', status: -1, router: 'irrigateSet-soil', index: 6 },
{ name: '7#灌溉组配置', status: -1, router: 'irrigateSet-soil', index: 7 },
{ name: '8#灌溉组配置', status: -1, router: 'irrigateSet-soil', index: 8 },
{ name: '9#灌溉组配置', status: -1, router: 'irrigateSet-soil', index: 9 },
{ name: '10#灌溉组配置', status: -1, router: 'irrigateSet-soil', index: 10 },
{ name: '11#灌溉组配置', status: -1, router: 'irrigateSet-soil', index: 11 },
{ name: '12#灌溉组配置', status: -1, router: 'irrigateSet-soil', index: 12 },
{ name: '13#灌溉组配置', status: -1, router: 'irrigateSet-soil', index: 13 },
{ name: '14#灌溉组配置', status: -1, router: 'irrigateSet-soil', index: 14 },
{ name: '15#灌溉组配置', status: -1, router: 'irrigateSet-soil', index: 15 },
{ name: '16#灌溉组配置', status: -1, router: 'irrigateSet-soil', index: 16 }]
},
{ name: '固有参数', list: [], router: 'intrinsicParameter-soil', isRouter: true, },
{ name: '系统参数配置', list: [], router: 'systemSet-soil', isRouter: true, },
{ name: '传感器通道配置', list: [], router: 'sensorSet-soil', isRouter: true, },
{ name: '数据上传', list: [], router: 'upload-soil', isRouter: true, },],
routerList: [ ],
routerNow: 'irrigateSet-soil',
routerIndex: 1,
namesArray:[]
}
},
watch: {
"$route"(newName, oldName) {
this.gerRouter();
},
},
'$i18n.locale'() {
this.initRouterList()
}
},
created(){
this.initRouterList()
},
mounted() {
this.gerRouter();
this.dataInit()
},
methods: {
initRouterList(){
this.routerList=[ { name: this.$t('setParams.statusDisplay', {deviceName: this.$store.state.equipmentList[this.$store.state.equipmentIndex - 1].deviceTypeName}), list: [], router: 'status-soil', isRouter: true, },
{
name:this.$t('setParams.irrigationGroupConfig'), router: 'irrigateSet-soil', list: this.$t('setParams.irrigationGroups').map((name, index) => ({
name,
status: -1,
router: 'irrigateSet-soil',
index: index + 1
}))
},
{ name:this.$t('setParams.intrinsicParams') , list: [], router: 'intrinsicParameter-soil', isRouter: true, },
{ name:this.$t('setParams.systemParamsConfig') , list: [], router: 'systemSet-soil', isRouter: true, },
{ name:this.$t('setParams.sensorChannelConfig'), list: [], router: 'sensorSet-soil', isRouter: true, },
{ name:this.$t('setParams.dataUpload') , list: [], router: 'upload-soil', isRouter: true, },]
setTimeout(() => {
this.getList()
}, 0);
},
///
getByid() {
var store = this.$store.state
@ -111,44 +109,23 @@ export default {
this.api.getFi_getName(data).then(res => {
if (res.data.code == 200) {
// name1name16
const namesArray = [];
this.namesArray = [];
for (let i = 1; i <= 16; i++) {
namesArray.push(res.data.data[`name${i}`]);
this.namesArray.push(res.data.data[`name${i}`]);
}
// routerList[1].listname
this.routerList[1].list.forEach((item, index) => {
if (index < namesArray.length) {
item.name = namesArray[index];
}
});
this.getList()
}
})
},
getList() {
var store = this.$store.state
// store.nameList.forEach((el, index) => {
// if (index < 8) {
// if (store.equipmentName['fertilization' + store.nameList[index]]) {
// // store.equipmentName['fertilization'+store.nameList[index]]
// this.routerList[0].list.push({
// name: '' + (index + 1),
// status: -1,
// index: index + 1,
// router: 'formula'
// })
// }
// }
// // if (store.equipmentName['solenoid' + store.nameList[index]]) {
// // // store.equipmentName['fertilization'+store.nameList[index]]
// // this.routerList[1].list.push({
// // name: store.equipmentName['solenoid' + store.nameList[index]],
// // status: -1,
// // index: index + 1,
// // router: 'irrigateSet'
// // })
// // }
// })
this.routerList[1].list.forEach((item, index) => {
if (index < this.namesArray.length) {
item.name = this.namesArray[index];
}
});
},
//
toHome(index) {

View File

@ -4,7 +4,6 @@ import VueI18n from "vue-i18n";
import zh from "element-ui/lib/locale/lang/zh-CN"; // element-ui的中文包
import en from "element-ui/lib/locale/lang/en"; // element-ui的英语包
import { getLanguage, DEFAULT_LANGUAGE } from "../utils/language";
Vue.use(VueI18n); // 全局挂载
// 引入i18n
const i18n = new VueI18n({

View File

@ -10,8 +10,23 @@ module.exports = {
passwordPlaceholder: "Please enter password",
loginSuccess: "Login Success",
},
comparisonOperators: [
{ name: 'Greater than (>)', value: 1 },
{ name: 'Less than (<)', value: 2 },
{ name: 'Greater than or equal (>=)', value: 3 },
{ name: 'Less than or equal (<=)', value: 4 }
],
message:{
delete:'Delete successfully.',
add:'Added successfully',
change:'Modified successfully',
loading: 'Loading',
},
index: {
// header
noData:'NO DATA',
confirm: 'Confirm',
cancel: 'Cancel',
realTimeData: "Realtime",
setParams: "Params",
galleryData: "Gallery",
@ -32,6 +47,7 @@ module.exports = {
pestMonitor: "Pest Monitoring",
// management
mgmt:'Management',
userMgmt: "User Management",
adminMgmt: "Admin Management",
deviceStatusConfig: "Device Status Settings",
@ -54,16 +70,193 @@ module.exports = {
// system
welcome: "Welcome, ",
noPermission: "No access permission!",
developing: "Page under development",
noPageForDevice: "Not available for {device}",
logoutSuccess: "Logout successful",
logoutSuccess: 'Logout successful',
requestError: 'Request error',
noPageForDevice: 'No this page for {device}',
noPermission: 'You currently have no permission to view!',
pageDeveloping: 'This page is under development',
weatherStation: 'Weather station',
dataCollector: 'Data collector',
pestDevice: 'Pest monitoring device',
cardExpiryWarning: `<div>The IoT card <span class="color-red">{iccid}</span> for device <span class="color-red">{deviceName}</span> is about to expire. Remaining time: <span class="color-red">{daysDifference} days</span>. Please contact the administrator.</div>`,
notification: 'Notification',
// devices
greenhouse: "Greenhouse",
fertigationMachine: "Fertigation Machine",
weatherStation: "Weather Station",
dataCollector: "Data Collector",
},
setParams: {
title: 'Parameter Settings',
statusDisplay: '{deviceName} Status Display',
formulaSettings: 'Fertilizer Formula Settings',
irrigationGroupConfig: 'Irrigation Group Configuration',
intrinsicParams: 'Intrinsic Parameters',
internalPIDConfig: 'Internal PID Configuration',
systemParamsConfig: 'System Parameters Configuration',
sensorChannelConfig: 'Sensor Channel Configuration',
dataUpload: 'Data Upload',
irrigationGroups: [
'Irrigation Group 1#', 'Irrigation Group 2#', 'Irrigation Group 3#', 'Irrigation Group 4#',
'Irrigation Group 5#', 'Irrigation Group 6#', 'Irrigation Group 7#', 'Irrigation Group 8#',
'Irrigation Group 9#', 'Irrigation Group 10#', 'Irrigation Group 11#', 'Irrigation Group 12#',
'Irrigation Group 13#', 'Irrigation Group 14#', 'Irrigation Group 15#', 'Irrigation Group 16#'
],
targetTemp: 'Target Temperature',
targetHumidity: 'Target Humidity',
targetCO2: 'Target CO2',
alarmSettings: 'Alarm Settings',
sunroofControl: 'Skylight',
outShade: 'External Shade',
inShade: 'Internal Shade',
inInsulation: 'Internal Insulation',
facadeInsulation: 'Facade Insulation',
wetCurtain: 'Wet Curtain System',
circulationFan: 'Circulation Fan',
airConditioning: 'Air Conditioning',
led: 'LED Control',
heatFan: 'Heater Fan',
highPressureMist: 'High Pressure Mist',
solenoidValve: 'Solenoid Valve',
sensorConfig: 'Sensor Configuration',
synthesis: 'Synthesis Settings',
upload: 'Data Upload',
forceOutput: 'Force Output',
intrinsicParams: 'Intrinsic Parameters',
parameterSet: 'Parameter Settings',
waterPump: 'Water Pump',
geothermalFan: 'Geothermal Fan',
uptake: 'Upper Vent',
downtake: 'Lower Vent',
rollByRoll: 'Rolling Curtain',
snowRemoval: 'Snow Removal',
mountainGreenhouse: 'Mountain Greenhouse Special Parameters',
mountainFan: 'Fan (Mountain Greenhouse)',
CO2: 'CO2 Supplement',
skylight: 'Rolling Film',
fan: 'Fan',
wetFan: 'Fan',
wetPump: 'Wet Curtain Pump',
wetWindow: 'Wet Curtain Window',
circulationFan: 'Circulation Fan',
highPressureMist: 'High Pressure Mist',
solenoidValve: 'Solenoid Valve',
CO2: 'CO2 Supplement'
},
realTime: {
target: 'Target',
average: 'Avg',
title: 'Real-time Data',
weatherStation: 'Ecological Weather Station',
deviceOffline: 'Device Offline',
smsAlarm: 'SMS Alarm',
viewAllData: 'View All Real-time Data',
deviceStatus: 'Device Operation Status',
fault:'fault',
iccid:'iccid',
sunrise: 'Sunrise',
sunset: 'Sunset',
batteryVoltage: 'Wireless Battery Voltage',
delete: 'Delete',
autoControl: 'Auto Control',
mobileControl: 'Mobile Control',
deviceInvalid: 'Device Invalid',
CalculationResults: 'Calculation results',
addDevice: 'Add Device',
clickToAdd: 'Click to Add',
heatingMode: 'Heating Mode',
heatingMode1: 'Heating Mode',
coolingMode: 'Cooling Mode',
autoMode: 'Auto Mode',
dehumidifyMode: 'Dehumidify Mode',
airSupplyMode: 'Air Supply Mode',
heatingCoolingMode: 'Heating/Cooling Mode',
light: 'Fill Light',
open: 'OPEN',
close: 'CLOSE',
return: 'RETURN',
status: {
still: 'Still',
opening: 'Opening',
closing: 'Closing',
unfolding: 'Unfolding',
folding: 'Folding',
openWindow: 'Open Window',
closeWindow: 'Close Window'
},
dialog:{
title: 'Please select devices to display',
choose:'Please select.',
confirm: 'Confirm'
},
alarm: {
title: 'Controller SMS Alarm Rules',
newRule: 'New Alarm Rule',
deviceCode: 'Device Code',
phone1: 'Phone 1',
phone2: 'Phone 2',
condition: 'Condition',
setValue: 'Set Value',
add: 'Add',
existingRules: 'Existing Rules',
alarmName: 'Alarm Name',
condition: 'Condition',
value: 'Value',
operation: 'Operation',
delete: 'Delete'
},
wirelessSensor: {
title: 'Wireless Sensor Debug Info',
batteryVoltage: 'Battery Voltage',
signalQuality: 'Signal Quality',
},
directions: {
north: 'North',
northeast: 'Northeast',
east: 'East',
southeast: 'Southeast',
south: 'South',
southwest: 'Southwest',
west: 'West',
northwest: 'Northwest'
},
},
imageGallery: {
title: 'Image Gallery',
title1: "Historical Data",
title2: "Data Analysis",
quickQuery: 'Quick Query',
today: 'Today',
yesterday: 'Yesterday',
custom: 'Custom',
timeRange: 'Time Range',
startTime: 'Start Time',
endTime: 'End Time',
to: 'to',
query: 'Search',
downloadImages: 'Download Images',
totalImages: 'Total {total} images',
imageList: 'Image List',
download: "Download",
dataStatistics: "Data Statistics",
time: "Time",
name: "Name",
difference: "Difference",
max: "Max",
min: "Min",
avg: "Average",
return: "Return"
},
videoMonitoring: {
title: "Video Monitoring",
topLeft: "Top Left",
topRight: "Top Right",
bottomLeft: "Bottom Left",
bottomRight: "Bottom Right",
zoomIn: "Zoom In",
zoomOut: "Zoom Out",
focusNear: "Focus Near",
focusFar: "Focus Far"
}
};

View File

@ -10,7 +10,22 @@ module.exports = {
passwordPlaceholder: "请输入密码",
loginSuccess: "登录成功",
},
comparisonOperators: [
{ name: '大于(>)', value: 1 },
{ name: '小于(<)', value: 2 },
{ name: '大于等于(>=)', value: 3 },
{ name: '小于等于(<=)', value: 4 }
],
message:{
delete:'删除成功',
add:'添加成功',
change:'修改成功',
loading:'加载中',
},
index: {
noData:'无数据',
confirm: '确定',
cancel: '取消',
// header
realTimeData: "实时数据",
setParams: "设定值参数",
@ -32,6 +47,7 @@ module.exports = {
pestMonitor: "虫情",
// management
mgmt:'管理',
userMgmt: "用户管理",
adminMgmt: "管理员管理",
deviceStatusConfig: "控制器设备状态值设置",
@ -52,16 +68,194 @@ module.exports = {
online: "在线",
offline: "离线",
// system
// message
welcome: "欢迎,",
noPermission: "您当前没有权限查看!",
developing: "当前页面正在努力开发中",
noPageForDevice: "{device}无该页面",
logoutSuccess: "退出登录成功",
// devices
greenhouse: "温室",
fertigationMachine: "施肥机",
weatherStation: "气象站",
dataCollector: "数据采集器"
}
logoutSuccess: '退出登录成功',
requestError: '请求出错',
noPageForDevice: '{device}无该页面',
noPermission: '您当前没有权限查看!',
pageDeveloping: '当前页面正在努力开发中',
weatherStation: '气象站',
dataCollector: '数据采集器',
pestDevice: '虫情设备',
cardExpiryWarning: `<div><span class="color-red">{deviceName}</span>卡号为{iccid},物联网卡即将到期,剩余时间<span class="color-red">{daysDifference}天</span>,请联系管理员。</div>`,
notification: '提示',
},
setParams: {
title: '设定值参数',
statusDisplay: '{deviceName}状态显示',
formulaSettings: '施肥机配方设置',
irrigationGroupConfig: '灌溉组配置',
intrinsicParams: '固有参数',
internalPIDConfig: '厂家内部PID配置',
systemParamsConfig: '系统参数配置',
sensorChannelConfig: '传感器通道配置',
dataUpload: '数据上传',
irrigationGroups: [
'1#灌溉组配置', '2#灌溉组配置', '3#灌溉组配置', '4#灌溉组配置',
'5#灌溉组配置', '6#灌溉组配置', '7#灌溉组配置', '8#灌溉组配置',
'9#灌溉组配置', '10#灌溉组配置', '11#灌溉组配置', '12#灌溉组配置',
'13#灌溉组配置', '14#灌溉组配置', '15#灌溉组配置', '16#灌溉组配置'
],
targetTemp: '目标温度',
targetHumidity: '目标湿度',
targetCO2: '目标CO2',
alarmSettings: '报警设置',
sunroofControl: '通风窗',
outShade: '外遮阳',
inShade: '内遮阳',
inInsulation: '内保温',
facadeInsulation: '立面保温',
wetCurtain: '湿帘系统',
circulationFan: '环流风扇',
airConditioning: '空调控制',
led: 'LED控制',
heatFan: '暖风机',
highPressureMist: '高压微雾',
solenoidValve: '电磁阀',
sensorConfig: '传感器配置',
synthesis: '综合设置',
upload: '数据上传',
forceOutput: '强制输出',
intrinsicParams: '固有参数',
parameterSet: '参数设置',
waterPump: '加热水泵',
geothermalFan: '地热风机',
uptake: '上风口',
downtake: '下风口',
rollByRoll: '卷被',
snowRemoval: '除雪',
mountainGreenhouse: '日光温室特殊参数(山地型温室)',
mountainFan: '风机(山地型温室)',
CO2: 'CO2补气',
skylight: '顶卷膜',
fan: '风机',
wetFan: '风机',
wetPump: '湿帘泵',
wetWindow: '湿帘外翻窗',
circulationFan: '环流风扇',
highPressureMist: '高压微雾',
solenoidValve: '电磁阀',
CO2: 'CO2补气'
},
realTime: {
target: '目标',
average: '平均',
title: '实时数据',
weatherStation: '生态气象站',
deviceOffline: '设备离线',
smsAlarm: '短信报警',
viewAllData: '查看全部实时数据',
deviceStatus: '设备运行状态',
fault:'故障',
iccid:'卡号',
sunrise: '日出',
sunset: '日落',
batteryVoltage: '无线电池电压',
delete: '删除',
autoControl: '自动控制',
mobileControl: '手机控制',
deviceInvalid: '当前设备无效',
CalculationResults: '计算结果',
addDevice: '添加设备',
clickToAdd: '点击添加设备',
heatingMode: '加热模式',
heatingMode1: '制热模式',
coolingMode: '制冷模式',
autoMode: '自动模式',
dehumidifyMode: '除湿模式',
airSupplyMode: '送风模式',
heatingCoolingMode: '冷暖模式',
light: '补光灯',
open: '开启',
close: '关闭',
return: '返 回',
status: {
still: '静止状态',
opening: '正向打开中',
closing: '反向关闭中',
unfolding: '正向展开中',
folding: '反向收拢中',
openWindow: '正向开窗',
closeWindow: '反向关窗'
},
dialog:{
title: '请选择要显示的设备',
choose: '请选择',
confirm: '确 认'
},
alarm: {
title: '控制器短信报警规则',
newRule: '新建报警规则',
deviceCode: '设备code码',
phone1: '用户1手机号',
phone2: '用户2手机号',
condition: '判断条件',
setValue: '请输入设定值',
add: '添加',
existingRules: '原有报警规则',
alarmName: '报警名称',
condition: '判断条件',
value: '数值',
operation: '操作',
delete: '删除'
},
wirelessSensor: {
title: '无线传感器调试信息',
batteryVoltage: '无线传感器电池电压',
signalQuality: '无线传感器信号质量',
},
directions: {
north: '北',
northeast: '东北',
east: '东',
southeast: '东南',
south: '南',
southwest: '西南',
west: '西',
northwest: '西北'
},
},
imageGallery: {
title: '图库数据',
title1: "历史数据",
title2: "数据分析",
quickQuery: '快速查询',
today: '今日',
yesterday: '昨日',
custom: '自定义',
timeRange: '时间段',
startTime: '开始时间',
endTime: '结束时间',
to: '至',
query: '查询',
downloadImages: '下载图片',
totalImages: '共有{total}张图片',
imageList: '图片列表',
download: "下载",
dataStatistics: "数据统计",
time: "时间",
name: "名称",
difference: "差值",
max: "最大值",
min: "最小值",
avg: "平均值",
return: "返回",
},
videoMonitoring: {
title: "视频监控",
topLeft: "左上",
topRight: "右上",
bottomLeft: "左下",
bottomRight: "右下",
zoomIn: "放大+",
zoomOut: "缩小-",
focusNear: "近焦距",
focusFar: "远焦距"
},
};

View File

@ -19,6 +19,7 @@ import 'video.js/dist/video-js.css'; // 引入video.js的样式
import 'video.js';
import 'videojs-contrib-hls'; // 引入支持HLS的插件
import i18n from "./i18n/index"; // 国际化模块
// element-ui的国际化
Vue.use(ElementUI, {
i18n: (key, value) => i18n.t(key, value),

View File

@ -1,4 +1,5 @@
import ElementUI from 'element-ui';
// 语言选项缓存的key
const CACHE_KEY = "local";

View File

@ -103,30 +103,9 @@ export default {
currentLanguage: getLanguage(),//
time: null,//
headerActive: 0,
leftList: [],
activeNames: [3],
leftList: [
{ name: '首页', img: require('../assets/image/index-icon.png'), list: [], router: 'realTime', isRouter: true, },
{ name: '温室', routerList: ['realTime', 'dataAnalysis', 'historyData','air-conditioning', 'exitSettings', 'videoMonitoring','imageData', 'skylight', 'control', 'systemSet-con', 'fan', 'upload-con', 'sensorSet-con', 'synthesis-con', 'alarmSettings', 'waterPump', 'geothermalFan', 'uptake', 'downtake', 'rollByRoll', 'snowRemoval', "targetTemperature", "targetHumidity", "targetCo2", "sunroofControl", "outsizeSunshade", "insizeSunshade", "wetFan", "LED", 'electromagneticControl', "coercionMist", "circulationCan", "internalInsulation", "forceOutput", "intrinsicParameter", "parameterSet"], img: require('../assets/image/left-img0.png'), list: [] },
// { name: '', img: require('../assets/image/left-img1.png'), list: [] },
{ name: '施肥机', routerList: ['status-soil','formula', 'dataAnalysis', 'historyData', 'irrigateSet', 'videoMonitoring','imageData', 'PIDSet', 'systemSet', 'upload', 'sensorSet', 'realTime', 'history', 'dataAnalysis'], img: require('../assets/image/left-img2.png'), list: [] },
{ name: '智能灌溉', routerList: ['realTime', 'dataAnalysis', 'historyData','irrigateSet-soil', 'videoMonitoring','imageData','PIDSet-soil', 'systemSet-soil', 'upload-soil', 'sensorSet-soil', 'realTime', 'history', 'dataAnalysis'], img: require('../assets/image/irrigateSet-icon1-act.png'), list: [] },
{ name: '数据采集器', routerList: ['realTime', 'historyData', 'exitSettings', 'skylight', 'control', 'systemSet-con','imageData', 'fan', 'upload-con', 'sensorSet-con', 'synthesis-con', 'alarmSettings', 'waterPump', 'geothermalFan', 'uptake', 'downtake', 'rollByRoll', 'snowRemoval', "targetTemperature", "targetHumidity", "targetCo2", "sunroofControl", "outsizeSunshade", "insizeSunshade", "wetFan", "LED", 'electromagneticControl', "coercionMist", "circulationCan", "internalInsulation", "forceOutput", "intrinsicParameter", "parameterSet"], img: require('../assets/image/left-img3.png'), list: [] },
{ name: '生态气象站', routerList: ['realTime', 'historyData', 'exitSettings', 'skylight', 'control', 'systemSet-con','imageData', 'fan', 'upload-con', 'sensorSet-con', 'synthesis-con', 'alarmSettings', 'waterPump', 'geothermalFan', 'uptake', 'downtake', 'rollByRoll', 'snowRemoval', "targetTemperature", "targetHumidity", "targetCo2", "sunroofControl", "outsizeSunshade", "insizeSunshade", "wetFan", "LED", 'electromagneticControl', "coercionMist", "circulationCan", "internalInsulation", "forceOutput", "intrinsicParameter", "parameterSet"], img: require('../assets/image/left-img3.png'), list: [] },
{ name: '虫情', routerList: ['insectPestDetail'], img: require('../assets/image/index-icon1.png'), list: [] },
],
leftList1: [
{ name: '管理', img: require('../assets/image/index-icon.png'), list: [], router: 'manage', isRouter: true, },
{ name: '用户管理', routerList: [''], img: require('../assets/image/left-img0.png'), list: [
{deviceTypeName:'控制器设备状态值设置',router:'deviceStatusSet',index:0},
{deviceTypeName:'控制器设备设定值设置',router:'deviceSet',index:1},
{deviceTypeName:'设备信息管理',router:'deviceInfoManage',index:2},
{deviceTypeName:'设备绑定气象站数据',router:'weatherData',index:3},
{deviceTypeName:'大数据设备信息',router:'dataDevice',index:4},
{deviceTypeName:'手机控制模块信息',router:'mobileControl',index:5},
] },
],
manageList:['deviceStatusSet',
'deviceSet',
'deviceInfoManage',
@ -158,7 +137,7 @@ export default {
},
computed:{
headerList(){
return [
var topMenu=[
{ name: this.$t('index.realTimeData'), router: 'realTime', routerList: ['realTime'], img: require('../assets/image/header-img1.png') },
// { name: '', router: 'status', index: 1, routerList: ['formula', 'irrigateSet', 'PIDSet', 'systemSet', 'upload', 'sensorSet'], img: require('../assets/image/header-img0.png') },
{ name:this.$t('index.setParams') , router: 'status', index: 1, routerList: ['formula', 'status', 'exitSettings', 'skylight', 'systemSet-con', 'fan', 'upload-con', 'sensorSet-con', 'alarmSettings', 'synthesis-con', 'waterPump', 'geothermalFan', 'uptake', 'downtake', 'rollByRoll', 'snowRemoval', "targetTemperature", "targetHumidity", "targetCo2", "sunroofControl", "outsizeSunshade", "insizeSunshade", "wetFan", "LED", 'electromagneticControl', "coercionMist", "circulationCan", "internalInsulation", "forceOutput", "intrinsicParameter", "parameterSet",], img: require('../assets/image/header-img0.png') },
@ -175,7 +154,54 @@ export default {
{ name:this.$t('index.bigData') , router: 'largeScreen', routerList: ['largeScreen'], img: require('../assets/image/header-img8.png') }
]
}
const foundObject = this.limitUserId.find(item => item.id == 3);
const foundName =topMenu.findIndex(item => item.name == this.$t('index.qrTrace'));
if (foundObject) {
if (foundName == -1) {
topMenu.push({ name: this.$t('index.qrTrace'), router: 'setsuyuan', index: 1, routerList: ['setsuyuan'], img: require('../assets/image/header-img4.png') })
}
} else {
if (foundName != -1) {
topMenu.splice(foundName, 1)
}
}
return topMenu
},
leftList1(){
//
var baseMenu= [
{ name: this.$t('index.mgmt'), img: require('../assets/image/index-icon.png'), list: [], router: 'manage', isRouter: true, },
{ name: this.$t('index.userMgmt'), routerList: [''], img: require('../assets/image/left-img0.png'), list: [
{deviceTypeName:this.$t('index.deviceStatusConfig'),router:'deviceStatusSet',index:0},
{deviceTypeName:this.$t('index.deviceSetConfig'),router:'deviceSet',index:1},
{deviceTypeName:this.$t('index.deviceInfoMgmt'),router:'deviceInfoManage',index:2},
{deviceTypeName:this.$t('index.weatherBinding'),router:'weatherData',index:3},
{deviceTypeName:this.$t('index.bigDataDevice'),router:'dataDevice',index:4},
{deviceTypeName:this.$t('index.mobileControl'),router:'mobileControl',index:5},
] },]
//
var adminMenu=[
{ name: this.$t('index.adminMgmt'), routerList: [''], img: require('../assets/image/left-img0.png'), list: [
{deviceTypeName:this.$t('index.userControl'),router:'userInfoControl',index:6},
{deviceTypeName:this.$t('index.deviceControl'),router:'deviceManage',index:7},
{deviceTypeName:this.$t('index.websiteBanner'),router:'officialWebsiteBanner',index:8},
{deviceTypeName:this.$t('index.websiteProducts'),router:'officialWebsiteProduct',index:11},
{deviceTypeName:this.$t('index.websiteCases'),router:'officialWebsiteCase',index:9},
{deviceTypeName:this.$t('index.companyProfile'),router:'officialWebsiteDetail',index:12},
{deviceTypeName:this.$t('index.websiteNews'),router:'officialWebsiteNews',index:10},
// {deviceTypeName:'',router:'videoManage',index:8},
] },
]
if (this.roleId === 1) {
return [...baseMenu, ...adminMenu];
}else{
return baseMenu
}
}
},
watch: {
"$route"(newName, oldName) {
@ -185,6 +211,9 @@ export default {
this.getByid()
}
},
'$i18n.locale'() {
this.initLeftList()
}
},
mounted() {
const that = this
@ -219,11 +248,33 @@ export default {
this.get_user_getjurisdiction()
//
this.getRole()
},
created(){
this.initLeftList()
},
beforeDestroy() {
this.IDTimer && clearInterval(this.IDTimer)
},
methods: {
initLeftList() {
this.leftList = [
{ name: this.$t('index.home'), img: require('../assets/image/index-icon.png'), list: [], router: 'realTime', isRouter: true, },
{ name: this.$t('index.greenhouse'), routerList: ['realTime', 'dataAnalysis', 'historyData','air-conditioning', 'exitSettings', 'videoMonitoring','imageData', 'skylight', 'control', 'systemSet-con', 'fan', 'upload-con', 'sensorSet-con', 'synthesis-con', 'alarmSettings', 'waterPump', 'geothermalFan', 'uptake', 'downtake', 'rollByRoll', 'snowRemoval', "targetTemperature", "targetHumidity", "targetCo2", "sunroofControl", "outsizeSunshade", "insizeSunshade", "wetFan", "LED", 'electromagneticControl', "coercionMist", "circulationCan", "internalInsulation", "forceOutput", "intrinsicParameter", "parameterSet"], img: require('../assets/image/left-img0.png'), list: [] },
// { name: '', img: require('../assets/image/left-img1.png'), list: [] },
{ name: this.$t('index.fertigation'), routerList: ['status-soil','formula', 'dataAnalysis', 'historyData', 'irrigateSet', 'videoMonitoring','imageData', 'PIDSet', 'systemSet', 'upload', 'sensorSet', 'realTime', 'history', 'dataAnalysis'], img: require('../assets/image/left-img2.png'), list: [] },
{ name:this.$t('index.smartIrrigation') , routerList: ['realTime', 'dataAnalysis', 'historyData','irrigateSet-soil', 'videoMonitoring','imageData','PIDSet-soil', 'systemSet-soil', 'upload-soil', 'sensorSet-soil', 'realTime', 'history', 'dataAnalysis'], img: require('../assets/image/irrigateSet-icon1-act.png'), list: [] },
{ name:this.$t('index.dataCollector') , routerList: ['realTime', 'historyData', 'exitSettings', 'skylight', 'control', 'systemSet-con','imageData', 'fan', 'upload-con', 'sensorSet-con', 'synthesis-con', 'alarmSettings', 'waterPump', 'geothermalFan', 'uptake', 'downtake', 'rollByRoll', 'snowRemoval', "targetTemperature", "targetHumidity", "targetCo2", "sunroofControl", "outsizeSunshade", "insizeSunshade", "wetFan", "LED", 'electromagneticControl', "coercionMist", "circulationCan", "internalInsulation", "forceOutput", "intrinsicParameter", "parameterSet"], img: require('../assets/image/left-img3.png'), list: [] },
{ name:this.$t('index.weatherStation') , routerList: ['realTime', 'historyData', 'exitSettings', 'skylight', 'control', 'systemSet-con','imageData', 'fan', 'upload-con', 'sensorSet-con', 'synthesis-con', 'alarmSettings', 'waterPump', 'geothermalFan', 'uptake', 'downtake', 'rollByRoll', 'snowRemoval', "targetTemperature", "targetHumidity", "targetCo2", "sunroofControl", "outsizeSunshade", "insizeSunshade", "wetFan", "LED", 'electromagneticControl', "coercionMist", "circulationCan", "internalInsulation", "forceOutput", "intrinsicParameter", "parameterSet"], img: require('../assets/image/left-img3.png'), list: [] },
{ name:this.$t('index.pestMonitor') , routerList: ['insectPestDetail'], img: require('../assets/image/index-icon1.png'), list: [] },
]
setTimeout(() => {
this.leftListInit1()
this.leftListInit2()
}, 0);
},
getRole(){
// var user= JSON.parse(localStorage.getItem('userInfo'))
// this.api.selUserbyid(user.userid).then(res=>{
@ -241,10 +292,10 @@ export default {
if (res.data.code == 200) {
this.limitUserId = res.data.data;
const foundObject = this.limitUserId.find(item => item.id == 3);
const foundName = this.headerList.findIndex(item => item.name == '二维码追溯');
const foundName = this.headerList.findIndex(item => item.name == this.$t('index.qrTrace'));
if (foundObject) {
if (foundName == -1) {
this.headerList.push({ name: '二维码追溯', router: 'setsuyuan', index: 1, routerList: ['setsuyuan'], img: require('../assets/image/header-img4.png') })
this.headerList.push({ name: this.$t('index.qrTrace'), router: 'setsuyuan', index: 1, routerList: ['setsuyuan'], img: require('../assets/image/header-img4.png') })
}
} else {
if (foundName != -1) {
@ -349,12 +400,17 @@ var iccidList=[]
if(res.data.code==200&&res.data.data){
iccidList.push(res.data.data)
this.$store.state.iccidList=iccidList
if(res1.data.data&&res.data.data.expired){
setTimeout(() => {
setTimeout(() => {
this.$notify({
title: '提示',
title: this.$t('index.notification'),
dangerouslyUseHTMLString: true,
message: `<div><span class="color-red">${res.data.data.deviceName}</span>卡号为${res.data.data.iccid},物联网卡即将到期,剩余时间<span class="color-red">${res.data.data.daysDifference}天</span>,请联系管理员。</div>`,
message: this.$t('index.cardExpiryWarning', {
deviceName: res.data.data.deviceName,
iccid: res.data.data.iccid,
daysDifference: res.data.data.daysDifference
}),
duration:60000,//10s
});
}, 10);
@ -392,6 +448,81 @@ var iccidList=[]
// true
return true;
},
leftListInit1(){
this.leftList[1].list = []
this.leftList[2].list = []
this.leftList[3].list = []
this.leftList[4].list = []
this.leftList[5].list = []
this.$store.state.equipmentList.forEach((el, index) => {
//deviceId
if (this.deviceId && this.deviceId == el.deviceId) {
this.$store.state.equipmentIndex = index + 1
}
if (el.deviceName == 1) {
this.leftList.forEach((el1, index1) => {
if (el1.name ==this.$t('index.fertigation') ) {
this.leftList[index1].list.push(el)
}
})
} else if (el.deviceName == 10) {
this.leftList.forEach((el1, index1) => {
if (el1.name ==this.$t('index.greenhouse') ) {
this.leftList[index1].list.push(el)
}
})
} else if (el.deviceName == 20) {
this.leftList.forEach((el1, index1) => {
if (el1.name == this.$t('index.smartIrrigation')) {
this.leftList[index1].list.push(el)
}
})
}else if (el.deviceName == 40) {
this.leftList.forEach((el1, index1) => {
if (el1.name == this.$t('index.dataCollector')) {
this.leftList[index1].list.push(el)
}
})
}
// else if (el.deviceName == 30) {
// this.leftList.forEach((el1, index1) => {
// if (el1.name == '') {
// this.leftList[index1].list.push(el)
// }
// })
// }
})
},
leftListInit2(){
this.$store.state.equipmentList.forEach((el, index) => {
if (el.deviceName == '30') {
this.leftList.forEach((el1, index1) => {
if (el1.name ==this.$t('index.weatherStation') ) {
this.leftList[index1].list.push(el)
}
})
}
})
this.leftList.forEach((el1, index1) => {
if (el1.name ==this.$t('index.greenhouse') ) {
this.leftList[index1].list.sort(this.compare('equipmentStatu'))
}
if (el1.name ==this.$t('index.fertigation') ) {
this.leftList[index1].list.sort(this.compare('equipmentStatu'))
}
if (el1.name == this.$t('index.smartIrrigation')) {
this.leftList[index1].list.sort(this.compare('equipmentStatu'))
}
if (el1.name ==this.$t('index.weatherStation') ) {
this.leftList[index1].list.sort(this.compare('equipmentStatu'))
}
if (el1.name == this.$t('index.dataCollector')) {
this.leftList[index1].list.sort(this.compare('equipmentStatu'))
}
})
},
//
getEqbyid(selTrue) {
@ -417,50 +548,7 @@ var iccidList=[]
localStorage.setItem('equipmentSelList', JSON.stringify(data))
// this.$store.state.equipmentSelList=res.data.data
}
this.leftList[1].list = []
this.leftList[2].list = []
this.leftList[3].list = []
this.leftList[4].list = []
this.leftList[5].list = []
this.$store.state.equipmentList.forEach((el, index) => {
//deviceId
if (this.deviceId && this.deviceId == el.deviceId) {
this.$store.state.equipmentIndex = index + 1
}
if (el.deviceName == 1) {
this.leftList.forEach((el1, index1) => {
if (el1.name == '施肥机') {
this.leftList[index1].list.push(el)
}
})
} else if (el.deviceName == 10) {
this.leftList.forEach((el1, index1) => {
if (el1.name == '温室') {
this.leftList[index1].list.push(el)
}
})
} else if (el.deviceName == 20) {
this.leftList.forEach((el1, index1) => {
if (el1.name == '智能灌溉') {
this.leftList[index1].list.push(el)
}
})
}else if (el.deviceName == 40) {
this.leftList.forEach((el1, index1) => {
if (el1.name == '数据采集器') {
this.leftList[index1].list.push(el)
}
})
}
// else if (el.deviceName == 30) {
// this.leftList.forEach((el1, index1) => {
// if (el1.name == '') {
// this.leftList[index1].list.push(el)
// }
// })
// }
})
this.leftListInit1()
this.api.geteqetdata(userInfo.userid).then((res) => {
if (res.data.code == 200) {
var list = this.$store.state.equipmentList
@ -474,34 +562,8 @@ var iccidList=[]
deviceName: '30'
};
}))
this.$store.state.equipmentList.forEach((el, index) => {
if (el.deviceName == '30') {
this.leftList.forEach((el1, index1) => {
if (el1.name == '生态气象站') {
this.leftList[index1].list.push(el)
}
})
}
})
this.leftList.forEach((el1, index1) => {
if (el1.name == '温室') {
this.leftList[index1].list.sort(this.compare('equipmentStatu'))
}
if (el1.name == '施肥机') {
this.leftList[index1].list.sort(this.compare('equipmentStatu'))
}
if (el1.name == '智能灌溉') {
this.leftList[index1].list.sort(this.compare('equipmentStatu'))
}
if (el1.name == '生态气象站') {
this.leftList[index1].list.sort(this.compare('equipmentStatu'))
}
if (el1.name == '数据采集器') {
this.leftList[index1].list.sort(this.compare('equipmentStatu'))
}
})
this.leftListInit2()
this.gerRouter()
this.getByid()
var data = {
@ -518,41 +580,7 @@ var iccidList=[]
this.roleId=res.data.data.roleId
if(this.roleId==1){
this.leftList1= [
{ name: '管理', img: require('../assets/image/index-icon.png'), list: [], router: 'manage', isRouter: true, },
{ name: '用户管理', routerList: [''], img: require('../assets/image/left-img0.png'), list: [
{deviceTypeName:'控制器设备状态值设置',router:'deviceStatusSet',index:0},
{deviceTypeName:'控制器设备设定值设置',router:'deviceSet',index:1},
{deviceTypeName:'设备信息管理',router:'deviceInfoManage',index:2},
{deviceTypeName:'设备绑定气象站数据',router:'weatherData',index:3},
{deviceTypeName:'大数据设备信息',router:'dataDevice',index:4},
{deviceTypeName:'手机控制模块信息',router:'mobileControl',index:5},
] },
{ name: '管理员管理', routerList: [''], img: require('../assets/image/left-img0.png'), list: [
{deviceTypeName:'用户信息管理',router:'userInfoControl',index:6},
{deviceTypeName:'设备管理',router:'deviceManage',index:7},
{deviceTypeName:'官网顶部轮播图管理',router:'officialWebsiteBanner',index:8},
{deviceTypeName:'官网产品管理',router:'officialWebsiteProduct',index:11},
{deviceTypeName:'官网案例管理',router:'officialWebsiteCase',index:9},
{deviceTypeName:'官网公司简介',router:'officialWebsiteDetail',index:12},
{deviceTypeName:'官网新闻管理',router:'officialWebsiteNews',index:10},
// {deviceTypeName:'',router:'videoManage',index:8},
] },
]
}else{
this.leftList1= [
{ name: '管理', img: require('../assets/image/index-icon.png'), list: [], router: 'manage', isRouter: true, },
{ name: '用户管理', routerList: [''], img: require('../assets/image/left-img0.png'), list: [
{deviceTypeName:'控制器设备状态值设置',router:'deviceStatusSet',index:0},
{deviceTypeName:'控制器设备设定值设置',router:'deviceSet',index:1},
{deviceTypeName:'设备信息管理',router:'deviceInfoManage',index:2},
{deviceTypeName:'设备绑定气象站数据',router:'weatherData',index:3},
{deviceTypeName:'大数据设备信息',router:'dataDevice',index:4},
{deviceTypeName:'手机控制模块信息',router:'mobileControl',index:5},
] },
]
}
this.mainData=res.data.data.project
}
})
@ -575,7 +603,7 @@ var iccidList=[]
if (res.data.code == 200) {
this.$message({
message: '退出登录成功',
message:this.$t('index.logoutSuccess'),
type: "success",
});
localStorage.removeItem('token')
@ -583,7 +611,7 @@ var iccidList=[]
localStorage.removeItem('equipmentSelList')
this.$router.push({ name: 'login' })
} else {
this.$message.error("请求出错");
this.$message.error(this.$t('index.requestError'));
}
})
},
@ -594,7 +622,7 @@ var iccidList=[]
if (item.router) {
//
if(this.routerNow == 'insectPestDetail'||this.routerNow == 'insectPestImageList'){
this.$message('虫情设备无该页面');
this.$message(this.$t('index.noPageForDevice', {device: this.$t('index.pestDevice')}));
return
}
if (item.http) {
@ -611,11 +639,11 @@ var iccidList=[]
} else if (item.router == 'status') {
if (this.deviceName == '30') {
this.$message('气象站无该页面');
this.$message(this.$t('index.noPageForDevice', {device: this.$t('index.weatherStation')}));
return
}
if (this.deviceName == '40') {
this.$message('数据采集器无该页面');
this.$message(this.$t('index.noPageForDevice', {device: this.$t('index.dataCollector')}));
return
}
if (this.deviceName == '10') {
@ -631,8 +659,8 @@ var iccidList=[]
this.$router.push({ path: `/realTime` })
} else if (item.router == 'videoMonitoring') {
if (this.deviceName == '30') {
this.$message('气象站无该页面');
if (this.deviceName == '30') {
this.$message(this.$t('index.noPageForDevice', {device: this.$t('index.weatherStation')}));
return
}
this.$router.push({ path: `/videoMonitoring` })
@ -648,7 +676,7 @@ var iccidList=[]
//
const foundObject = this.limitUserId.find(item => item.id == 2 || item.id == 1 || item.id == 5|| item.id == 7|| item.id == 8|| item.id == 9|| item.id == 10|| item.id == 11 || item.id == 12|| item.id == 13);
if (!foundObject) {
this.$message('您当前没有权限查看!')
this.$message(this.$t('index.noPermission'));
return
} else {
this.$router.push({ name: item.router })
@ -659,7 +687,7 @@ var iccidList=[]
this.$router.push({ name: item.router })
}
} else {
this.$message('当前页面正在努力开发中');
this.$message(this.$t('index.pageDeveloping'));
}
},
toRouter1(item) {
@ -720,9 +748,9 @@ var iccidList=[]
}
}
else if (item.deviceName == 30) {
this.$message('气象站无该页面');
this.$message(this.$t('index.noPageForDevice', {device: this.$t('index.weatherStation')}));
} else if (item.deviceName == 40) {
this.$message('数据采集器无该页面');
this.$message(this.$t('index.noPageForDevice', {device: this.$t('index.dataCollector')}));
}
}
} else if ( this.$route.query.index == item.index) {
@ -731,7 +759,7 @@ var iccidList=[]
this.$router.push({ name: item.router })
}
} else {
this.$message('当前页面正在努力开发中');
this.$message(this.$t('index.pageDeveloping'));
}
},
toRouter2(item){

View File

@ -121,7 +121,7 @@ window.open(routeData.href, '_blank');
getImage() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -140,7 +140,7 @@ export default {
confirmModel() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -545,7 +545,7 @@ export default {
openRoleModel(deviceId) {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -569,7 +569,7 @@ openRoleModel(deviceId) {
changeAddModel() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -589,7 +589,7 @@ openRoleModel(deviceId) {
openModelName(item,index){
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -607,7 +607,7 @@ openRoleModel(deviceId) {
openModelName1(item,index){
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -625,7 +625,7 @@ openModelName1(item,index){
changeAddModel3(){
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -644,7 +644,7 @@ changeAddModel3(){
changeAddModel1() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -664,7 +664,7 @@ changeAddModel3(){
changeAddModel2(){
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -94,7 +94,7 @@ export default {
confirmModel() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -130,7 +130,7 @@ export default {
confirmBtn() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -313,7 +313,7 @@ export default {
}
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -120,7 +120,7 @@ export default {
confirmBtn() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -691,7 +691,7 @@ export default {
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -141,7 +141,7 @@ export default {
mounted() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -491,7 +491,7 @@ export default {
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -309,7 +309,7 @@ export default {
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -232,7 +232,7 @@ export default {
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -4,30 +4,30 @@
<div class="page-content">
<div class="table-title">
<img src="../../assets/image/analysis.png" alt="" />
数据分析
{{ $t('imageGallery.title2') }}
</div>
<div class="flex-view">
<div class="input-btn">
<span>快速查询</span>
<span>{{ $t('imageGallery.quickQuery') }}</span>
<div class="btn btn-w66" @click="active = 0" :class="active == 0 ? 'blue' : 'off'">
今日
{{ $t('imageGallery.today') }}
</div>
<div class="btn btn-w66" @click="active = 1" :class="active == 1 ? 'blue' : 'off'">
昨日
{{ $t('imageGallery.yesterday') }}
</div>
<div class="btn btn-w66" @click="active = 2" :class="active == 2 ? 'blue' : 'off'">
自定义
{{ $t('imageGallery.custom') }}
</div>
</div>
<div class="input-sel-time">
<span>时间段</span>
<el-date-picker v-model="dateRange" type="datetimerange" range-separator="至" start-placeholder="开始时间"
end-placeholder="结束时间">
</el-date-picker>
<span>{{ $t('imageGallery.timeRange') }}</span>
<el-date-picker v-model="dateRange" type="datetimerange" :range-separator="$t('imageGallery.to')"
:start-placeholder="$t('imageGallery.startTime')" :end-placeholder="$t('imageGallery.endTime')">
</el-date-picker>
</div>
<div class="input-btn ">
<div class="btn blue" @click="search">
查询
{{ $t('imageGallery.query') }}
</div>
</div>
</div>
@ -41,6 +41,7 @@
<script>
import { realTimeLine1 } from '@/assets/js/charts'
import { changeLanguage, getLanguage } from '@/utils/language'
export default {
data() {
return {
@ -62,6 +63,9 @@ export default {
this.dataInit()
},
'$i18n.locale'() {
this.dataInit()
}
},
mounted() {
this.indexs = this.$route.query.index ? this.$route.query.index : 1;
@ -92,7 +96,7 @@ export default {
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -132,7 +136,8 @@ export default {
endTime: this.getTime(this.dateRange[1]),
page: 1,
pageSize: 999,
isEquipment: store.equipmentList[index - 1].deviceName == 30 ? 1 : 0
isEquipment: store.equipmentList[index - 1].deviceName == 30 ? 1 : 0,
enName:getLanguage()
}
var data1 = store.equipmentList[index - 1].deviceId
this.api.selFsTime(data).then(res => {

View File

@ -297,7 +297,7 @@ export default {
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -160,7 +160,7 @@ export default {
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -222,7 +222,7 @@ export default {
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -161,7 +161,7 @@ export default {
this.indexs = this.$route.query.id ? this.$route.query.id : 1;
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -76,7 +76,7 @@
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -233,7 +233,7 @@ export default {
this.titleName = store.equipmentName['fertilization' + store.nameList[this.indexs - 1]]
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -249,7 +249,7 @@ export default {
this.titleName = store.equipmentName['fertilization' + store.nameList[this.indexs - 1]]
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -473,7 +473,7 @@ export default {
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -3,36 +3,36 @@
<div class="page-content">
<div class="table-title">
<img src="../../assets/image/real-time.png" alt="" />
历史数据
{{ $t('imageGallery.title1') }}
</div>
<div class="flex-view">
<div class="input-btn">
<span>快速查询</span>
<span>{{ $t('imageGallery.quickQuery') }}</span>
<div class="btn btn-w66" @click="active = 0" :class="active == 0 ? 'blue' : 'off'">
今日
{{ $t('imageGallery.today') }}
</div>
<div class="btn btn-w66" @click="active = 1" :class="active == 1 ? 'blue' : 'off'">
昨日
{{ $t('imageGallery.yesterday') }}
</div>
<div class="btn btn-w66" @click="active = 2" :class="active == 2 ? 'blue' : 'off'">
自定义
{{ $t('imageGallery.custom') }}
</div>
</div>
<div class="input-sel-time">
<span>时间段</span>
<el-date-picker v-model="dateRange" type="datetimerange" range-separator=""
start-placeholder="开始时间" end-placeholder="结束时间">
<span>{{ $t('imageGallery.timeRange') }}</span>
<el-date-picker v-model="dateRange" type="datetimerange" :range-separator="$t('imageGallery.to')"
:start-placeholder="$t('imageGallery.startTime')" :end-placeholder="$t('imageGallery.endTime')">
</el-date-picker>
</div>
<div class="input-btn ">
<div class="btn blue" @click="search">
查询
{{ $t('imageGallery.query') }}
</div>
<div class="btn blue" @click="download">
下载
{{ $t('imageGallery.downloadImages') }}
</div>
<div class="btn blue" @click="openModel">
数据统计
{{ $t('imageGallery.dataStatistics') }}
</div>
<!-- <div class="btn blue">
/夜平均时间范围设置
@ -42,7 +42,7 @@
<div class="table-view">
<el-table :data="tableData" :row-class-name="tableRowClassName" max-height="520" style="width: 100%">
<el-table-column min-width='180' prop="time" label="时间"></el-table-column>
<el-table-column min-width='180' prop="time" :label="$t('imageGallery.time')"></el-table-column>
<el-table-column min-width='150' :label="item" v-for="item, index in tableList" :key="index">
<template slot-scope="scope">
<div>{{ scope.row[item] }}</div>
@ -56,46 +56,46 @@
</el-pagination>
</div>
</div>
<el-dialog title="数据统计" class="vrcode-model" :append-to-body="true" :visible.sync="addModel" width="80%">
<el-button class="model-return-btn" type="primary" @click="addModel = false"> </el-button>
<div class="model-title">数据统计</div>
<el-dialog :title="$t('imageGallery.dataStatistics')" class="vrcode-model" :append-to-body="true" :visible.sync="addModel" width="80%">
<el-button class="model-return-btn" type="primary" @click="addModel = false">{{$t('realTime.return')}}</el-button>
<div class="model-title"> {{ $t('imageGallery.dataStatistics') }}</div>
<div class="flex-view">
<div class="input-btn">
<span>快速查询</span>
<span>{{ $t('imageGallery.query') }}</span>
<div class="btn btn-w66" @click="active1 = 0" :class="active1 == 0 ? 'blue' : 'off'">
今日
{{ $t('imageGallery.today') }}
</div>
<div class="btn btn-w66" @click="active1 = 1" :class="active1 == 1 ? 'blue' : 'off'">
昨日
{{ $t('imageGallery.yesterday') }}
</div>
<div class="btn btn-w66" @click="active1 = 2" :class="active1 == 2 ? 'blue' : 'off'">
自定义
{{ $t('imageGallery.custom') }}
</div>
</div>
<div class="input-sel-time">
<span>时间段</span>
<el-date-picker v-model="dateRange1" type="datetimerange" range-separator=""
start-placeholder="开始时间" end-placeholder="结束时间">
<span>{{ $t('imageGallery.timeRange') }}</span>
<el-date-picker v-model="dateRange1" type="datetimerange" :range-separator="$t('imageGallery.to')"
:start-placeholder="$t('imageGallery.startTime')" :end-placeholder="$t('imageGallery.endTime')">
</el-date-picker>
</div>
<div class="input-btn ">
<div class="btn blue" @click="search1">
查询
{{ $t('imageGallery.query') }}
</div>
<div class="btn blue" @click="download1">
下载
{{ $t('imageGallery.download') }}
</div>
</div>
</div>
<div class="table-view" style="padding-bottom: 20px;">
<el-table :data="tableData1" :row-class-name="tableRowClassName" max-height="520" style="width: 100%">
<el-table-column min-width='180' prop="time" label="时间"></el-table-column>
<el-table-column min-width='150' prop="envirnmentName" label="名称"></el-table-column>
<el-table-column min-width='150' prop="dif" label="差值"></el-table-column>
<el-table-column min-width='150' prop="max" label="最大值"></el-table-column>
<el-table-column min-width='150' prop="min" label="最小值"></el-table-column>
<el-table-column min-width='150' prop="avg" label="平均值"></el-table-column>
<el-table-column min-width='180' prop="time" :label="$t('imageGallery.time')"></el-table-column>
<el-table-column min-width='150' prop="envirnmentName" :label="$t('imageGallery.name')"></el-table-column>
<el-table-column min-width='150' prop="dif" :label="$t('imageGallery.difference')"></el-table-column>
<el-table-column min-width='150' prop="max" :label="$t('imageGallery.max')"></el-table-column>
<el-table-column min-width='150' prop="min" :label="$t('imageGallery.min')"></el-table-column>
<el-table-column min-width='150' prop="avg" :label="$t('imageGallery.avg')"></el-table-column>
</el-table>
<el-pagination @size-change="handleSizeChange1" @current-change="handleCurrentChange1"
@ -110,6 +110,7 @@
<script>
// 1 1
import { Loading } from 'element-ui';
import { changeLanguage, getLanguage } from '@/utils/language'
export default {
data() {
return {
@ -149,6 +150,9 @@ export default {
this.dataInit()
},
'$i18n.locale'() {
this.dataInit()
}
},
mounted() {
@ -179,7 +183,7 @@ export default {
dataInit1() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -197,7 +201,7 @@ export default {
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -215,7 +219,7 @@ export default {
download1() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -254,7 +258,7 @@ export default {
download() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -322,7 +326,8 @@ export default {
endTime: this.getTime(this.dateRange[1]),
page: this.currentPage,
pageSize: this.pageSize,
isEquipment: store.equipmentList[index - 1].deviceName == 30 ? 1 : 0
isEquipment: store.equipmentList[index - 1].deviceName == 30 ? 1 : 0,
enName:getLanguage()
}
this.api.selFsTime(data).then(res => {
this.loading.close()

View File

@ -3,33 +3,33 @@
<div class="page-content">
<div class="table-title">
<img src="../../assets/image/real-time.png" alt="" />
{{ deviceName }}图库数据
{{ deviceName }}{{ $t('imageGallery.title') }}
</div>
<div class="flex-view">
<div class="input-btn">
<span>快速查询</span>
<span>{{ $t('imageGallery.quickQuery') }}</span>
<div class="btn btn-w66" @click="active = 0" :class="active == 0 ? 'blue' : 'off'">
今日
{{ $t('imageGallery.today') }}
</div>
<div class="btn btn-w66" @click="active = 1" :class="active == 1 ? 'blue' : 'off'">
昨日
{{ $t('imageGallery.yesterday') }}
</div>
<div class="btn btn-w66" @click="active = 2" :class="active == 2 ? 'blue' : 'off'">
自定义
{{ $t('imageGallery.custom') }}
</div>
</div>
<div class="input-sel-time">
<span>时间段</span>
<el-date-picker v-model="dateRange" type="datetimerange" range-separator=""
start-placeholder="开始时间" end-placeholder="结束时间">
<span>{{ $t('imageGallery.timeRange') }}</span>
<el-date-picker v-model="dateRange" type="datetimerange" :range-separator="$t('imageGallery.to')"
:start-placeholder="$t('imageGallery.startTime')" :end-placeholder="$t('imageGallery.endTime')">
</el-date-picker>
</div>
<div class="input-btn ">
<div class="btn blue" @click="search">
查询
{{ $t('imageGallery.query') }}
</div>
<div class="btn blue" @click="download">
下载图片
{{ $t('imageGallery.downloadImages') }}
</div>
<!-- <div class="btn blue">
数据统计
@ -112,7 +112,7 @@ export default {
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text:this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -140,7 +140,7 @@ export default {
async download() {
// this.loading = this.$loading({
// lock: true,
// text: '',
// text: this.$t('message.loading'),
// spinner: 'el-icon-loading',
// background: 'rgba(0, 0, 0, 0.7)'
// });

View File

@ -309,7 +309,7 @@ export default {
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -253,7 +253,7 @@ export default {
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -211,7 +211,7 @@ modelConfirm(){
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -820,7 +820,7 @@ this.dataInit();
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -544,7 +544,7 @@ export default {
const that = this;
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -557,7 +557,7 @@ export default {
this.indexs = this.$route.query.id ? this.$route.query.id : 1;
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -571,7 +571,7 @@ export default {
this.indexs = this.$route.query.id ? this.$route.query.id : 1;
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -189,7 +189,7 @@
</div>
<!-- 甘井设施农业 -->
<div class="drag_box9" ref="drag_box9" v-show="limitUserId == 9">
<img class="drag_img" src="../../assets/img/map5.png" alt="" />
<img class="drag_img" src="https://lihemix.oss-cn-hangzhou.aliyuncs.com/%E7%94%98%E4%BA%95%E6%9D%91%E5%A4%A7%E6%95%B0%E6%8D%AE/%E5%80%BE%E6%96%9C%E5%9B%BE.png" alt="" />
<img class="axis_shimen" src="../../assets/img/axis1.png" alt="" @click="handlerAxis_5" />
<img class="axis_shimen1" src="../../assets/img/axis1.png" alt="" @click="handlerAxis_5" />
<img class="axis_shimen2" src="../../assets/img/axis1.png" alt="" @click="handlerAxis_5" />
@ -538,6 +538,7 @@ import vueSeamless from "vue-seamless-scroll";
import axios from "axios";
import { changeLanguage, getLanguage } from '@/utils/language'
import { pestLine } from "@/assets/js/charts";
export default {
name: "largeScreen",
@ -717,6 +718,11 @@ export default {
}
clearInterval(this.timer_) && this.timer_;
},
watch:{
'$i18n.locale'() {
this.dataInit()
}
},
methods: {
// id9
timeInit() {
@ -744,7 +750,8 @@ export default {
endTime: this.getdataTime(this.dateRange[1]),
page: this.currentPage,
pageSize: this.pageSize,
isEquipment:0
isEquipment:0,
enName:getLanguage()
}
this.api.selFsTime(data).then(res => {
if (res.data.code == 200) {
@ -858,8 +865,11 @@ export default {
var data1 ='2024070113400048'
var nowDevice = store.equipmentList.find(item => item.deviceId == data1);
this.imgUrl =nowDevice? nowDevice.hls:null
this.api.getControlFsdata(data1).then(res => {
var params={
equipmentId:data1,
enName:getLanguage()
}
this.api.getControlFsdata(params).then(res => {
if (res.data.code == 200) {
var chartsData = res.data.data
realTimeLine2('realTime-line', chartsData, data1,0)
@ -891,8 +901,11 @@ export default {
var data1 ='2024111816300001'
var nowDevice = store.equipmentList.find(item => item.deviceId == data1);
this.imgUrl =nowDevice? nowDevice.hls:null
this.api.getControlFsdata(data1).then(res => {
var params={
equipmentId:data1,
enName:getLanguage()
}
this.api.getControlFsdata(params).then(res => {
if (res.data.code == 200) {
var chartsData = res.data.data
realTimeLine2('realTime-line', chartsData, data1)
@ -1170,7 +1183,11 @@ export default {
//
getWeatherData(equipmentId) {
this.api.getcontrol_rtDatastation(equipmentId).then((res) => {
var params={
equipmentId:equipmentId,
enName:getLanguage()
}
this.api.getControlRtDatastation(params).then((res) => {
// console.log('', res);
if (res.data.code == 200) {
this.weatherDataList = res.data.data;

View File

@ -430,7 +430,7 @@
<div class="map">
<div class="map1">
<div class="drag_box9" ref="drag_box9">
<img class="drag_img" src="../../assets/img/map5.png" alt="" />
<img class="drag_img" src="https://lihemix.oss-cn-hangzhou.aliyuncs.com/%E7%94%98%E4%BA%95%E6%9D%91%E5%A4%A7%E6%95%B0%E6%8D%AE/%E5%80%BE%E6%96%9C%E5%9B%BE.png" alt="" />
<!-- <div class="popBox" v-for="(item, index) in popContentList" :key="index">
<template>
<div class="pole_item" :style="getTopOrLeft9(9)">

View File

@ -280,7 +280,7 @@ export default {
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

File diff suppressed because it is too large Load Diff

View File

@ -527,7 +527,7 @@ return num
};
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -188,7 +188,7 @@ export default {
mounted() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -115,7 +115,7 @@ export default {
mounted() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -194,7 +194,7 @@ export default {
'$route.query.change'(newVal, oldVal) {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -207,7 +207,7 @@ export default {
this.indexs = this.$route.query.id ? this.$route.query.id : 1;
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -116,7 +116,7 @@ export default {
mounted() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -350,7 +350,7 @@ export default {
var store = this.$store.state
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -83,7 +83,7 @@ export default {
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -139,7 +139,7 @@ this.dataInit();
downLoadData() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -173,7 +173,7 @@ this.dataInit();
changeTxt(e) {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -223,7 +223,7 @@ this.dataInit();
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -101,7 +101,7 @@ export default {
mounted() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -117,7 +117,7 @@ export default {
downLoadData() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -149,7 +149,7 @@ export default {
changeTxt(e) {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -126,7 +126,7 @@ export default {
mounted() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -142,7 +142,7 @@ export default {
downLoadData() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
@ -176,7 +176,7 @@ export default {
changeTxt(e) {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -112,7 +112,7 @@
const that = this;
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -210,7 +210,7 @@
const that = this;
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -301,7 +301,7 @@ export default {
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -284,7 +284,7 @@ export default {
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -263,7 +263,7 @@ export default {
mounted() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -95,7 +95,7 @@ export default {
mounted() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});

View File

@ -3,7 +3,7 @@
<div class="page-content new-data">
<div class="table-title">
<img src="../../assets/image/real-time.png" alt="" />
{{ deviceTypeName }}视频监控<span class="outline" v-if="deviceState == 0">(设备离线)</span>
{{ deviceTypeName }}{{ $t('videoMonitoring.title') }}<span class="outline" v-if="deviceState == 0">({{ $t('realTime.deviceOffline') }})</span>
</div>
<div class="flex-list realTime-bottom videoMonitoring-monitor">
<div class="left-view" v-if="deviceName != 30">
@ -30,29 +30,37 @@
</div>
</div>
<div class="video-btn">
<div @mousedown="downStart(4)"><img src="../../assets/img/video-icon0.png" alt="">
<div>左上 </div>
<div @mousedown="downStart(4)">
<img src="../../assets/img/video-icon0.png" alt="">
<div>{{ $t('videoMonitoring.topLeft') }}</div>
</div>
<div @mousedown="downStart(6)"><img src="../../assets/img/video-icon1.png" alt="">
<div>右上 </div>
<div @mousedown="downStart(6)">
<img src="../../assets/img/video-icon1.png" alt="">
<div>{{ $t('videoMonitoring.topRight') }}</div>
</div>
<div @mousedown="downStart(5)"><img src="../../assets/img/video-icon2.png" alt="">
<div>左下 </div>
<div @mousedown="downStart(5)">
<img src="../../assets/img/video-icon2.png" alt="">
<div>{{ $t('videoMonitoring.bottomLeft') }}</div>
</div>
<div @mousedown="downStart(7)"><img src="../../assets/img/video-icon3.png" alt="">
<div>右下 </div>
<div @mousedown="downStart(7)">
<img src="../../assets/img/video-icon3.png" alt="">
<div>{{ $t('videoMonitoring.bottomRight') }}</div>
</div>
<div @mousedown="downStart(8)"><img src="../../assets/img/video-icon4.png" alt="">
<div>放大+</div>
<div @mousedown="downStart(8)">
<img src="../../assets/img/video-icon4.png" alt="">
<div>{{ $t('videoMonitoring.zoomIn') }}</div>
</div>
<div @mousedown="downStart(9)"><img src="../../assets/img/video-icon5.png" alt="">
<div>缩小-</div>
<div @mousedown="downStart(9)">
<img src="../../assets/img/video-icon5.png" alt="">
<div>{{ $t('videoMonitoring.zoomOut') }}</div>
</div>
<div @mousedown="downStart(10)"><img src="../../assets/img/video-icon6.png" alt="">
<div>近焦距</div>
<div @mousedown="downStart(10)">
<img src="../../assets/img/video-icon6.png" alt="">
<div>{{ $t('videoMonitoring.focusNear') }}</div>
</div>
<div @mousedown="downStart(11)"><img src="../../assets/img/video-icon7.png" alt="">
<div>远焦距</div>
<div @mousedown="downStart(11)">
<img src="../../assets/img/video-icon7.png" alt="">
<div>{{ $t('videoMonitoring.focusFar') }}</div>
</div>
</div>
</div>

View File

@ -663,7 +663,7 @@ export default {
dataInit() {
this.loading = this.$loading({
lock: true,
text: '加载中',
text: this.$t('message.loading'),
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});