3.27
This commit is contained in:
parent
d9766f43e8
commit
5b328629f8
@ -156,6 +156,7 @@
|
||||
"uniStatistics": {
|
||||
"enable": false
|
||||
},
|
||||
"sassImplementationName": "node-sass",
|
||||
"h5": {
|
||||
"title": "芯程物联",
|
||||
"router": {
|
||||
|
@ -488,7 +488,7 @@
|
||||
}
|
||||
|
||||
// 小程序中popup坑
|
||||
/deep/ .u-safe-bottom {
|
||||
::v-deep .u-safe-bottom {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
@ -144,9 +144,18 @@
|
||||
|
||||
<script>
|
||||
import projectConfig from '@/env.config.js';
|
||||
import { mapState, mapMutations } from 'vuex';
|
||||
import { logout, secureBind, wechatBind } from '@/apis/modules/common';
|
||||
import { deviceRelateUser } from '@/apis/modules/device';
|
||||
import {
|
||||
mapState,
|
||||
mapMutations
|
||||
} from 'vuex';
|
||||
import {
|
||||
logout,
|
||||
secureBind,
|
||||
wechatBind
|
||||
} from '@/apis/modules/common';
|
||||
import {
|
||||
deviceRelateUser
|
||||
} from '@/apis/modules/device';
|
||||
|
||||
export default {
|
||||
components: {},
|
||||
@ -705,14 +714,14 @@
|
||||
/* 设置文字颜色 */
|
||||
}
|
||||
|
||||
/deep/.uni-list-item__content-title[data-v-296a3d7e] {
|
||||
::v-deep.uni-list-item__content-title[data-v-296a3d7e] {
|
||||
font-size: 30rpx;
|
||||
color: #333;
|
||||
overflow: hidden;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
/deep/.uni-list-item__container {
|
||||
::v-deep .uni-list-item__container {
|
||||
padding: 30rpx;
|
||||
}
|
||||
|
||||
|
@ -78,9 +78,15 @@
|
||||
import moment from 'moment';
|
||||
import uniDataCheckbox from '@/pagesA/components/uni-data-checkbox/index.vue';
|
||||
import uniPagination from '@/pagesA/components/uni-pagination/index.vue';
|
||||
import { getSubGatewayList } from '@/apis/modules/gateway.js';
|
||||
import { listThingsModel } from '@/apis/modules/device.js';
|
||||
import { getHistoryList } from '@/apis/modules/deviceLog.js';
|
||||
import {
|
||||
getSubGatewayList
|
||||
} from '@/apis/modules/gateway.js';
|
||||
import {
|
||||
listThingsModel
|
||||
} from '@/apis/modules/device.js';
|
||||
import {
|
||||
getHistoryList
|
||||
} from '@/apis/modules/deviceLog.js';
|
||||
|
||||
export default {
|
||||
name: 'deviceHistory',
|
||||
@ -236,7 +242,10 @@
|
||||
},
|
||||
// 日期选择
|
||||
handleDateTimeClick() {
|
||||
const { beginTime, endTime } = this.queryParams;
|
||||
const {
|
||||
beginTime,
|
||||
endTime
|
||||
} = this.queryParams;
|
||||
if (this.dateTimeIndex === 1) {
|
||||
this.$refs.datetimePicker.innerValue = beginTime;
|
||||
} else {
|
||||
@ -246,7 +255,10 @@
|
||||
},
|
||||
// 时间选择下一步/确定
|
||||
handleConfirmDateTime(e) {
|
||||
const { beginTime, endTime } = this.queryParams;
|
||||
const {
|
||||
beginTime,
|
||||
endTime
|
||||
} = this.queryParams;
|
||||
if (this.dateTimeIndex === 1) {
|
||||
this.queryParams.beginTime = e.value;
|
||||
this.dateTimeIndex = this.dateTimeIndex + 1;
|
||||
@ -291,7 +303,9 @@
|
||||
},
|
||||
// 筛选确认
|
||||
handleConfirmFilter() {
|
||||
const { identifiers } = this.queryParams;
|
||||
const {
|
||||
identifiers
|
||||
} = this.queryParams;
|
||||
if (identifiers.length === 0) {
|
||||
uni.showToast({
|
||||
icon: 'none',
|
||||
@ -304,14 +318,19 @@
|
||||
},
|
||||
// 获取子设备列表数据
|
||||
getSlaveDatas() {
|
||||
const { deviceId } = this.deviceInfo;
|
||||
const {
|
||||
deviceId
|
||||
} = this.deviceInfo;
|
||||
const params = {
|
||||
gwDeviceId: deviceId,
|
||||
pageNum: 1,
|
||||
pageSize: 9999,
|
||||
};
|
||||
getSubGatewayList(params).then(res => {
|
||||
const { code, rows } = res;
|
||||
const {
|
||||
code,
|
||||
rows
|
||||
} = res;
|
||||
if (code === 200) {
|
||||
this.slaveList = rows.map(item => ({
|
||||
text: item.subDeviceName,
|
||||
@ -323,14 +342,19 @@
|
||||
},
|
||||
// 获取物模型
|
||||
getIdentifierList() {
|
||||
const { deviceId } = this.deviceInfo;
|
||||
const {
|
||||
deviceId
|
||||
} = this.deviceInfo;
|
||||
const params = {
|
||||
deviceId: deviceId,
|
||||
pageNum: 1,
|
||||
pageSize: 9999,
|
||||
};
|
||||
listThingsModel(params).then((res) => {
|
||||
const { code, rows } = res;
|
||||
const {
|
||||
code,
|
||||
rows
|
||||
} = res;
|
||||
if (code === 200) {
|
||||
this.identifierList = rows.map(item => ({
|
||||
text: item.modelName,
|
||||
@ -348,8 +372,16 @@
|
||||
},
|
||||
// 获取统计数据
|
||||
getHistory() {
|
||||
const { identifiers, beginTime, endTime, slaveId } = this.queryParams;
|
||||
const { deviceId, serialNumber } = this.deviceInfo;
|
||||
const {
|
||||
identifiers,
|
||||
beginTime,
|
||||
endTime,
|
||||
slaveId
|
||||
} = this.queryParams;
|
||||
const {
|
||||
deviceId,
|
||||
serialNumber
|
||||
} = this.deviceInfo;
|
||||
if (identifiers.length !== 0) {
|
||||
const idenList = identifiers.map((item) => {
|
||||
const iden = this.identifierList.find((chil) => chil.value === item);
|
||||
@ -434,7 +466,7 @@
|
||||
.time-shortcut {
|
||||
width: 190rpx;
|
||||
|
||||
/deep/ .uni-select {
|
||||
::v-deep .uni-select {
|
||||
height: 70rpx;
|
||||
}
|
||||
}
|
||||
|
@ -1410,7 +1410,7 @@
|
||||
padding: 0px 18px;
|
||||
border-radius: 5px;
|
||||
|
||||
/deep/ .u-line:first-child {
|
||||
::v-deep .u-line:first-child {
|
||||
border-bottom: transparent !important;
|
||||
}
|
||||
}
|
||||
|
@ -19,7 +19,9 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { updateDevice } from '@/apis/modules/device';
|
||||
import {
|
||||
updateDevice
|
||||
} from '@/apis/modules/device';
|
||||
|
||||
export default {
|
||||
data() {
|
||||
@ -51,7 +53,10 @@
|
||||
},
|
||||
onLoad(option) {
|
||||
this.data = JSON.parse(decodeURIComponent(option.item));
|
||||
const { deviceName, firmwareVersion } = this.data;
|
||||
const {
|
||||
deviceName,
|
||||
firmwareVersion
|
||||
} = this.data;
|
||||
this.model.name = deviceName;
|
||||
this.model.version = firmwareVersion;
|
||||
},
|
||||
@ -102,7 +107,7 @@
|
||||
.modbus-edit-wrap {
|
||||
padding: 10px;
|
||||
|
||||
/deep/ .u-form-item__body__left__content__required {
|
||||
::v-deep .u-form-item__body__left__content__required {
|
||||
left: 5px;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user