提交:场景控制 选择设备 更换接口 /iot/device/projectDev

This commit is contained in:
23688nl 2022-09-28 16:14:42 +08:00
parent f6602d37cd
commit 1af91ba9e5
3 changed files with 14 additions and 4 deletions

View File

@ -232,3 +232,12 @@ export function projectSceneLoggingList(query) {
params: query
});
}
// 查询 查询 项目中设备列表
export function projectSelectDeviceList(query) {
return request({
url: "/iot/device/projectDev",
method: "get",
params: query
});
}

View File

@ -154,7 +154,8 @@
// import { listDevice } from "@/api/iot/device";
import SelectTableWrap from "@/components/SelectTable/index";
import { getDeviceFunList, getDeviceCmdList } from "@/api/iot/device";
import { getDeviceList } from "@/api/app";
import { projectSelectDeviceList } from "@/api/iot/project_new";
export default {
name: "EDeviceParam",
@ -403,7 +404,7 @@ export default {
this.deviceChildList(data);
},
deviceChildList(data) {
getDeviceList(Object.assign(data.page, data.param)).then((res) => {
projectSelectDeviceList(Object.assign(data.page, data.param)).then((res) => {
this.tableSelectOption.tableList = res.rows;
this.tableList = res.rows;
this.tableSelectOption.queryOpt.page.total = Number(res.total);

View File

@ -49,7 +49,7 @@
</template>
<script>
import SelectTableWrap from "@/components/SelectTable/index";
import { getDeviceList } from "@/api/app";
import { projectSelectDeviceList } from "@/api/iot/project_new";
export default {
name: "ESelectDevice",
@ -200,7 +200,7 @@ export default {
},
//
getSiteChildList(data, type) {
getDeviceList(Object.assign(data.param, this.param, data.page)).then(
projectSelectDeviceList(Object.assign(data.param, this.param, data.page)).then(
(response) => {
if (response.rows.length > 0) {
this.tableSelectOption.tableList = response.rows;