智能照明系统APP-本地串口
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
LightingSystemApp-serial/.svn/pristine/80/80cc706f1db82c5fabe20baeaf8...

63 lines
1.2 KiB

3 years ago
<template>
<view>
<u-navbar back-text="网关管理">
<view slot="right" style="margin-right: 16px">
<u-image src="@/static/img/operation.png" mode="widthFix" width="44" height="44" />
</view>
</u-navbar>
<button @tap="toAdd">添加网关</button>
</view>
</template>
<script>
import { getDevicePage } from "@/common/network/equipment/device";
export default {
data() {
return {
deviceList: [],
};
},
created() {},
mounted() {},
methods: {
getDevicePage() {
let data = {
orders: [
{
field: "deviceid",
type: "asc",
},
],
page: {
page: 1,
limit: 20,
},
};
getDevicePage(data)
.then((res) => {
if (res.code === 200) {
this.deviceList = res.data.page.list;
} else {
console.log(res);
}
})
.catch((err) => {
console.log(err);
});
},
toAdd() {
uni.navigateTo({
url: "/pages/device/add/add",
});
},
},
onLoad() {
this.getDevicePage();
},
};
</script>
<style scoped>
</style>