فهرست منبع

设备管理九宫格默认在线请求

ming 1 هفته پیش
والد
کامیت
b75adba33c
1فایلهای تغییر یافته به همراه6 افزوده شده و 4 حذف شده
  1. 6 4
      src/pages/business/fireIot/deviceManage/components/deviceDetailsList.vue

+ 6 - 4
src/pages/business/fireIot/deviceManage/components/deviceDetailsList.vue

@@ -84,7 +84,7 @@ const data = reactive({
     { label: "在线", value: "1" },
     { label: "离线", value: "2" },
   ],
-  radioValue: "",
+  radioValue: "1",
   dropdownShow: false,
 });
 
@@ -103,8 +103,8 @@ function init() {
  */
 
 function dmpDeviceInfoApi() {
-  dmpDeviceInfo({ productId: productId.value, deviceName: deviceName.value, current: current.value, size: pageSize.value }).then((requset) => {
-    if (requset.status === "SUCCESS") {
+  dmpDeviceInfo({ current: current.value, size: pageSize.value ,deviceStatus:radioValue.value }).then((requset) => {
+    if (requset.status == "SUCCESS") {
       dataList.value = requset.data.records;
       total.value = requset.data.total;
 
@@ -129,8 +129,10 @@ function handleToDevice(array) {
  * @单选change事件
  */
 function radioChange(e) {
+  // console.log(e,'e')
   radioValue.value = e;
-  selectListApi();
+  dmpDeviceInfoApi();
+  dropdownShow.value=false
 }
 
 /**