Skip to content

Commit

Permalink
feat: update 4.9.0
Browse files Browse the repository at this point in the history
  • Loading branch information
zhangxiaoyin committed Sep 3, 2024
1 parent b062d2e commit 4f59fe7
Show file tree
Hide file tree
Showing 6 changed files with 69 additions and 7 deletions.
3 changes: 2 additions & 1 deletion CHANGELOG.EN.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
## [4.8.7](https://github.com/dgiot/iotStudio/compare/v4.8.6...v4.8.7) (2024-07-15)
## [4.8.9](https://github.com/dgiot/iotStudio/compare/v4.8.6...v4.8.9) (2024-08-01)


### Features

* import modbusxtcp ([6f1bc81](https://github.com/dgiot/iotStudio/commit/6f1bc81511d09ee2be0d62c3baa8f370b48e7589))
* import wmx ([83c0b64](https://github.com/dgiot/iotStudio/commit/83c0b64afa28d6332765a3efc962c0e5ca238a74))
* template ([3484162](https://github.com/dgiot/iotStudio/commit/3484162577145de32e3f5735bb3fadd72327f9c7))
* update 4.8.9 ([b062d2e](https://github.com/dgiot/iotStudio/commit/b062d2e88c229c5cf5d7986e7068e9a20a9e982d))



Expand Down
3 changes: 2 additions & 1 deletion CHANGELOG.ZH.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
## [4.8.7](https://github.com/dgiot/iotStudio/compare/v4.8.6...v4.8.7) (2024-07-15)
## [4.8.9](https://github.com/dgiot/iotStudio/compare/v4.8.6...v4.8.9) (2024-08-01)


### Features

* import modbusxtcp ([6f1bc81](https://github.com/dgiot/iotStudio/commit/6f1bc81511d09ee2be0d62c3baa8f370b48e7589))
* import wmx ([83c0b64](https://github.com/dgiot/iotStudio/commit/83c0b64afa28d6332765a3efc962c0e5ca238a74))
* template ([3484162](https://github.com/dgiot/iotStudio/commit/3484162577145de32e3f5735bb3fadd72327f9c7))
* update 4.8.9 ([b062d2e](https://github.com/dgiot/iotStudio/commit/b062d2e88c229c5cf5d7986e7068e9a20a9e982d))



Expand Down
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
## [4.8.7](https://github.com/dgiot/iotStudio/compare/v4.8.6...v4.8.7) (2024-07-15)
## [4.8.9](https://github.com/dgiot/iotStudio/compare/v4.8.6...v4.8.9) (2024-08-01)


### Features

* import modbusxtcp ([6f1bc81](https://github.com/dgiot/iotStudio/commit/6f1bc81511d09ee2be0d62c3baa8f370b48e7589))
* import wmx ([83c0b64](https://github.com/dgiot/iotStudio/commit/83c0b64afa28d6332765a3efc962c0e5ca238a74))
* template ([3484162](https://github.com/dgiot/iotStudio/commit/3484162577145de32e3f5735bb3fadd72327f9c7))
* update 4.8.9 ([b062d2e](https://github.com/dgiot/iotStudio/commit/b062d2e88c229c5cf5d7986e7068e9a20a9e982d))



Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@dgiot/dgiot-dashboard",
"version": "4.8.9",
"version": "4.9.0",
"author": "dgiot",
"license": "MPL-2.0",
"private": false,
Expand Down
27 changes: 26 additions & 1 deletion src/views/DeviceCloud/manage/editdevices.vue
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,24 @@
type="datetime"
/>
</el-form-item>
<el-form-item label="物模型指标">
<el-select
multiple
filterable
collapse-tags
v-model="params.keys"
placeholder="请选择"
size="mini"
style="width: 300px"
>
<el-option
v-for="(item, index) in wmxkeys"
:key="index"
:label="item.label"
:value="item.value"
/>
</el-select>
</el-form-item>
<el-form-item :label="$translateTitle('developer.type')">

<el-select
Expand Down Expand Up @@ -639,6 +657,10 @@
<script src="./js/editdevices.js"></script>
<style lang="scss" scoped>
::v-deep {
.el-select__tags {
white-space: nowrap;
overflow: hidden;
}
.el-tabs__header {
margin: 0;
}
Expand All @@ -662,7 +684,10 @@
transition: 0.3s;
}
}
.el-select__tags {
white-space: nowrap;
overflow: hidden;
}
.chartsinfo {
margin-top: 15px;
Expand Down
38 changes: 36 additions & 2 deletions src/views/DeviceCloud/manage/js/editdevices.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ import { getCardDevice, getDabDevice, getDevice } from '@/api/Device/index.js'
import Instruct from '@/views/DeviceCloud/category/instruct_manage'
import { queryView } from '@/api/View'
import runningState from '@/views/DeviceCloud/manage/component/Device/runningState'
import { getProduct } from '../../../../api/Product'

const columns = [
{
title: '图片',
Expand Down Expand Up @@ -238,7 +240,7 @@ export default {
number: 1,
interval: 'h',
datetimerange: '',
keys: '*',
keys: [],
limit: 100,
endTime: new Date().getTime(),
startTime: new Date().getTime() - 3600 * 1000 * 24 * 7,
Expand Down Expand Up @@ -392,6 +394,7 @@ export default {
dirlength: 20,
selectproduct: '',
watchNum: 0,
wmxkeys: [],
chartType: [
{ type: 'line', name: '折线图' },
{ type: 'histogram', name: '柱状图' },
Expand Down Expand Up @@ -431,6 +434,7 @@ export default {
mounted() {
// this.deviceInfo.product.objectId = this.$route.query.productid
this.getDeviceInfo(this.$route.query.deviceid)
this.getwmxkey()
this.setTreeFlag(false)
this.params.style = this.chartType[0].type
console.log(' this.params.style', this.params.style)
Expand All @@ -453,6 +457,28 @@ export default {
this.Unbscribe()
},
methods: {
async getwmxkey() {
const productdetail = await getProduct(this.$route.query.productid)
let wmxList = productdetail.thing?.properties || []
let options = []
if (wmxList.length > 0) {
wmxList.forEach((item) => {
if (item.isshow == true) {
let o = {
label: item.name,
value: item.identifier,
}
options.push(o)
}
})
this.params.keys = [wmxList[0].identifier]
}
options.unshift({
label: '全选',
value: '*',
})
this.wmxkeys = options
},
/**
* @Author: dext7r
* @Date: 2021-12-24 12:13:39
Expand Down Expand Up @@ -740,11 +766,19 @@ export default {
startTime,
endTime,
} = this.params
let newkeys = 'not'
if (keys.length > 0) {
newkeys = keys.join(',')
}
if (newkeys.indexOf('*') != -1) {
newkeys = '*'
}
this.params.keys = ['*']
let params = {
starttime: moment(startTime).valueOf(),
endtime: moment(endTime).valueOf(),
interval: number + interval,
keys: keys,
keys: newkeys,
limit: limit,
function: _function,
style: style,
Expand Down

0 comments on commit 4f59fe7

Please sign in to comment.