wx-program
pangdundun 2024-03-11 14:51:37 +08:00
parent 66be5f35f7
commit cf6867aac4
41 changed files with 139 additions and 74 deletions

View File

@ -229,14 +229,30 @@
// ,1#
getStatus(equipmentNumber, targetValue) {
if (targetValue == 1) {
// if (targetValue == 1) {
// return ''
// } else if (targetValue == 0 && equipmentNumber == 0) {
// return '1#'
// } else if (targetValue == 0 && equipmentNumber == 15) {
// return '2#'
// } else if (targetValue == 0 && equipmentNumber != 0 && equipmentNumber != 15) {
// return equipmentNumber + '#'
// }
if(targetValue == 1){
if(equipmentNumber ==0){
return '目标'
} else if (targetValue == 0 && equipmentNumber == 0) {
}else{
return '目标'+ equipmentNumber +'#'
}
}else {
if(equipmentNumber ==0){
return '1#平均'
} else if (targetValue == 0 && equipmentNumber == 15) {
}else if(equipmentNumber == 15){
return '2#平均'
} else if (targetValue == 0 && equipmentNumber != 0 && equipmentNumber != 15) {
return equipmentNumber + '#'
}else {
return equipmentNumber +'#'
}
}
}
}

View File

@ -538,7 +538,7 @@
});
uni.stopPullDownRefresh();
i.childList = res.data;
i.childList_mubiao = res.data.filter(el => (this.getStatus(el.equipmentNumber, el.targetValue)) == '目标');
i.childList_mubiao = res.data.filter(el => (this.getStatus(el.equipmentNumber, el.targetValue)) == '目标' || (this.getStatus(el.equipmentNumber, el.targetValue)) == ('目标' + el.equipmentNumber +'#'));
i.childList_1 = res.data.filter(el => (this.getStatus(el.equipmentNumber, el.targetValue)) == '1#平均');
i.childList_2 = res.data.filter(el => (this.getStatus(el.equipmentNumber, el.targetValue)) == '2#平均');
@ -611,15 +611,32 @@
// ,1#
getStatus(equipmentNumber, targetValue) {
if (targetValue == 1) {
// if (targetValue == 1) {
// return ''
// } else if (targetValue == 0 && equipmentNumber == 0) {
// return '1#'
// } else if (targetValue == 0 && equipmentNumber == 15) {
// return '2#'
// } else if (targetValue == 0 && equipmentNumber != 0 && equipmentNumber != 15) {
// return equipmentNumber + '#'
// }
if(targetValue == 1){
if(equipmentNumber ==0){
return '目标'
} else if (targetValue == 0 && equipmentNumber == 0) {
return '1#平均'
} else if (targetValue == 0 && equipmentNumber == 15) {
return '2#平均'
} else if (targetValue == 0 && equipmentNumber != 0 && equipmentNumber != 15) {
return equipmentNumber + '#'
}else{
return '目标'+ equipmentNumber +'#'
}
}else {
if(equipmentNumber ==0){
return '1#平均'
}else if(equipmentNumber == 15){
return '2#平均'
}else {
return equipmentNumber +'#'
}
}
},
//

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1557,7 +1557,7 @@ function initData(vueOptions, context) {
try {
data = data.call(context); // 支持 Vue.prototype 上挂的数据
} catch (e) {
if (Object({"NODE_ENV":"development","VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"greenhouse-wisdom-applet","VUE_APP_PLATFORM":"mp-weixin","BASE_URL":"/"}).VUE_APP_DEBUG) {
if (Object({"VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"greenhouse-wisdom-applet","VUE_APP_PLATFORM":"mp-weixin","NODE_ENV":"development","BASE_URL":"/"}).VUE_APP_DEBUG) {
console.warn('根据 Vue 的 data 函数初始化小程序 data 失败,请尽量确保 data 函数中不访问 vm 对象,否则可能影响首次数据渲染速度。', data);
}
}
@ -8934,7 +8934,7 @@ function type(obj) {
function flushCallbacks$1(vm) {
if (vm.__next_tick_callbacks && vm.__next_tick_callbacks.length) {
if (Object({"NODE_ENV":"development","VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"greenhouse-wisdom-applet","VUE_APP_PLATFORM":"mp-weixin","BASE_URL":"/"}).VUE_APP_DEBUG) {
if (Object({"VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"greenhouse-wisdom-applet","VUE_APP_PLATFORM":"mp-weixin","NODE_ENV":"development","BASE_URL":"/"}).VUE_APP_DEBUG) {
var mpInstance = vm.$scope;
console.log('[' + (+new Date) + '][' + (mpInstance.is || mpInstance.route) + '][' + vm._uid +
']:flushCallbacks[' + vm.__next_tick_callbacks.length + ']');
@ -8955,14 +8955,14 @@ function nextTick$1(vm, cb) {
//1.nextTick 之前 已 setData 且 setData 还未回调完成
//2.nextTick 之前存在 render watcher
if (!vm.__next_tick_pending && !hasRenderWatcher(vm)) {
if(Object({"NODE_ENV":"development","VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"greenhouse-wisdom-applet","VUE_APP_PLATFORM":"mp-weixin","BASE_URL":"/"}).VUE_APP_DEBUG){
if(Object({"VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"greenhouse-wisdom-applet","VUE_APP_PLATFORM":"mp-weixin","NODE_ENV":"development","BASE_URL":"/"}).VUE_APP_DEBUG){
var mpInstance = vm.$scope;
console.log('[' + (+new Date) + '][' + (mpInstance.is || mpInstance.route) + '][' + vm._uid +
']:nextVueTick');
}
return nextTick(cb, vm)
}else{
if(Object({"NODE_ENV":"development","VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"greenhouse-wisdom-applet","VUE_APP_PLATFORM":"mp-weixin","BASE_URL":"/"}).VUE_APP_DEBUG){
if(Object({"VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"greenhouse-wisdom-applet","VUE_APP_PLATFORM":"mp-weixin","NODE_ENV":"development","BASE_URL":"/"}).VUE_APP_DEBUG){
var mpInstance$1 = vm.$scope;
console.log('[' + (+new Date) + '][' + (mpInstance$1.is || mpInstance$1.route) + '][' + vm._uid +
']:nextMPTick');
@ -9058,7 +9058,7 @@ var patch = function(oldVnode, vnode) {
});
var diffData = this.$shouldDiffData === false ? data : diff(data, mpData);
if (Object.keys(diffData).length) {
if (Object({"NODE_ENV":"development","VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"greenhouse-wisdom-applet","VUE_APP_PLATFORM":"mp-weixin","BASE_URL":"/"}).VUE_APP_DEBUG) {
if (Object({"VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"greenhouse-wisdom-applet","VUE_APP_PLATFORM":"mp-weixin","NODE_ENV":"development","BASE_URL":"/"}).VUE_APP_DEBUG) {
console.log('[' + (+new Date) + '][' + (mpInstance.is || mpInstance.route) + '][' + this._uid +
']差量更新',
JSON.stringify(diffData));
@ -12674,7 +12674,7 @@ function _extends() {
var formatRegExp = /%[sdj%]/g;
var warning = function warning() {}; // don't print warning message when in production env or node runtime
if (typeof process !== 'undefined' && Object({"NODE_ENV":"development","VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"greenhouse-wisdom-applet","VUE_APP_PLATFORM":"mp-weixin","BASE_URL":"/"}) && "development" !== 'production' && typeof window !== 'undefined' && typeof document !== 'undefined') {
if (typeof process !== 'undefined' && Object({"VUE_APP_DARK_MODE":"false","VUE_APP_NAME":"greenhouse-wisdom-applet","VUE_APP_PLATFORM":"mp-weixin","NODE_ENV":"development","BASE_URL":"/"}) && "development" !== 'production' && typeof window !== 'undefined' && typeof document !== 'undefined') {
warning = function warning(type, errors) {
if (typeof console !== 'undefined' && console.warn) {
if (errors.every(function (e) {

View File

@ -395,17 +395,33 @@ var _default = {
},
// 判断是否是平均或者目标,或者是1#
getStatus: function getStatus(equipmentNumber, targetValue) {
// if (targetValue == 1) {
// return '目标'
// } else if (targetValue == 0 && equipmentNumber == 0) {
// return '1#平均'
// } else if (targetValue == 0 && equipmentNumber == 15) {
// return '2#平均'
// } else if (targetValue == 0 && equipmentNumber != 0 && equipmentNumber != 15) {
// return equipmentNumber + '#'
// }
if (targetValue == 1) {
if (equipmentNumber == 0) {
return '目标';
} else if (targetValue == 0 && equipmentNumber == 0) {
} else {
return '目标' + equipmentNumber + '#';
}
} else {
if (equipmentNumber == 0) {
return '1#平均';
} else if (targetValue == 0 && equipmentNumber == 15) {
} else if (equipmentNumber == 15) {
return '2#平均';
} else if (targetValue == 0 && equipmentNumber != 0 && equipmentNumber != 15) {
} else {
return equipmentNumber + '#';
}
}
}
}
};
exports.default = _default;

View File

@ -1054,7 +1054,7 @@ var _default = {
uni.stopPullDownRefresh();
i.childList = res.data;
i.childList_mubiao = res.data.filter(function (el) {
return _this.getStatus(el.equipmentNumber, el.targetValue) == '目标';
return _this.getStatus(el.equipmentNumber, el.targetValue) == '目标' || _this.getStatus(el.equipmentNumber, el.targetValue) == '目标' + el.equipmentNumber + '#';
});
i.childList_1 = res.data.filter(function (el) {
return _this.getStatus(el.equipmentNumber, el.targetValue) == '1#平均';
@ -1153,15 +1153,31 @@ var _default = {
},
// 判断是否是平均或者目标,或者是1#
getStatus: function getStatus(equipmentNumber, targetValue) {
// if (targetValue == 1) {
// return '目标'
// } else if (targetValue == 0 && equipmentNumber == 0) {
// return '1#平均'
// } else if (targetValue == 0 && equipmentNumber == 15) {
// return '2#平均'
// } else if (targetValue == 0 && equipmentNumber != 0 && equipmentNumber != 15) {
// return equipmentNumber + '#'
// }
if (targetValue == 1) {
if (equipmentNumber == 0) {
return '目标';
} else if (targetValue == 0 && equipmentNumber == 0) {
} else {
return '目标' + equipmentNumber + '#';
}
} else {
if (equipmentNumber == 0) {
return '1#平均';
} else if (targetValue == 0 && equipmentNumber == 15) {
} else if (equipmentNumber == 15) {
return '2#平均';
} else if (targetValue == 0 && equipmentNumber != 0 && equipmentNumber != 15) {
} else {
return equipmentNumber + '#';
}
}
},
// 气象站
getcontrol_geteqetdata: function getcontrol_geteqetdata(userId) {