代码提交

This commit is contained in:
lixiaobang 2023-03-31 09:05:02 +08:00
parent 9fc2096f9f
commit 4138e4d774
1 changed files with 6 additions and 4 deletions

View File

@ -1811,8 +1811,9 @@ export default {
this.init();
// //
window.setInterval(() => {
if (this.unityChange == 0) {
getEnvironmentInfo( "2" ).then((res) => {
if (that.unityChange == 3 || that.unityChange == 0) {
// getEnvironmentInfo( "2" ).then((res) => {
getEnvironmentInfo( { siteId: "2" } ).then((res) => {
// this.eniorArr
console.log(res,'实时记录');
for (const key in res.data.data) {
@ -1888,7 +1889,8 @@ export default {
}
});
} else {
getEnvironmentInfo("96445C7C4AD6F0C5" ).then((res) => {
// getEnvironmentInfo("96445C7C4AD6F0C5" ).then((res) => {
getEnvironmentInfo({ siteId: "1" } ).then((res) => {
// this.eniorArr
for (const key in res.data.data) {
if (key == "doorState") {
@ -2125,7 +2127,7 @@ export default {
},
getTableData() {
// this.tableData = [];
if (this.unityChange == 0) {
if (this.unityChange == 0 ||this.unityChange == 3) {
getSwitchInfo({ siteId: "2" }).then((res) => {
this.tableData = res.data.data.items;
for (let i = 0; i < this.tableData.length; i++) {