From 33f45c5ca7befc63e20fa62061b03e1ece8cace1 Mon Sep 17 00:00:00 2001 From: "liujw155@outlook.com" Date: Thu, 29 Aug 2024 18:11:03 +0800 Subject: [PATCH 1/4] add tid1641 style && logic --- src/pages.json | 12 ++ .../device/pages/lighting_timie/list.vue | 86 ++++++++ .../device/pages/lighting_timie/setting.vue | 217 +++++++++++++++++++++ 3 files changed, 315 insertions(+) create mode 100644 src/subpackage/device/pages/lighting_timie/list.vue create mode 100644 src/subpackage/device/pages/lighting_timie/setting.vue diff --git a/src/pages.json b/src/pages.json index 5dcf150..2eb219c 100644 --- a/src/pages.json +++ b/src/pages.json @@ -438,6 +438,18 @@ "style": { "navigationBarTitleText": "" } + }, + { + "path": "pages/lighting_timie/list", + "style": { + "navigationBarTitleText": "照明管理" + } + }, + { + "path": "pages/lighting_timie/setting", + "style": { + "navigationBarTitleText": "照明管理" + } } ] }, diff --git a/src/subpackage/device/pages/lighting_timie/list.vue b/src/subpackage/device/pages/lighting_timie/list.vue new file mode 100644 index 0000000..8522d70 --- /dev/null +++ b/src/subpackage/device/pages/lighting_timie/list.vue @@ -0,0 +1,86 @@ + + + + + \ No newline at end of file diff --git a/src/subpackage/device/pages/lighting_timie/setting.vue b/src/subpackage/device/pages/lighting_timie/setting.vue new file mode 100644 index 0000000..cb16a96 --- /dev/null +++ b/src/subpackage/device/pages/lighting_timie/setting.vue @@ -0,0 +1,217 @@ + + + + + \ No newline at end of file From d2b06226977058023f3f1e70038f84864854d4c3 Mon Sep 17 00:00:00 2001 From: "liujw155@outlook.com" Date: Fri, 30 Aug 2024 18:24:12 +0800 Subject: [PATCH 2/4] finish tid1641 --- src/pages.json | 4 +- src/subpackage/device/js/device_api.js | 6 + src/subpackage/device/pages/index/index.vue | 34 ++- src/subpackage/device/pages/lighting_time/list.vue | 180 ++++++++++++++ .../device/pages/lighting_time/setting.vue | 271 +++++++++++++++++++++ .../device/pages/lighting_timie/list.vue | 86 ------- .../device/pages/lighting_timie/setting.vue | 217 ----------------- .../device/pages/switch_manage/switch_manage.vue | 8 +- src/subpackage/device/static/images/delete.png | Bin 0 -> 365 bytes src/utils/util.js | 4 +- 10 files changed, 492 insertions(+), 318 deletions(-) create mode 100644 src/subpackage/device/pages/lighting_time/list.vue create mode 100644 src/subpackage/device/pages/lighting_time/setting.vue delete mode 100644 src/subpackage/device/pages/lighting_timie/list.vue delete mode 100644 src/subpackage/device/pages/lighting_timie/setting.vue create mode 100644 src/subpackage/device/static/images/delete.png diff --git a/src/pages.json b/src/pages.json index 2eb219c..df82c08 100644 --- a/src/pages.json +++ b/src/pages.json @@ -440,13 +440,13 @@ } }, { - "path": "pages/lighting_timie/list", + "path": "pages/lighting_time/list", "style": { "navigationBarTitleText": "照明管理" } }, { - "path": "pages/lighting_timie/setting", + "path": "pages/lighting_time/setting", "style": { "navigationBarTitleText": "照明管理" } diff --git a/src/subpackage/device/js/device_api.js b/src/subpackage/device/js/device_api.js index b6ef2e5..7d129e4 100644 --- a/src/subpackage/device/js/device_api.js +++ b/src/subpackage/device/js/device_api.js @@ -69,6 +69,12 @@ export const DEVICE_API = { brandList:`${ORIGIN}/stadium/brand/all`, // 获取品牌列表 brandInfo:`${ORIGIN}/stadium/brand/get`, // 获取品牌信息 + // 20240830 tid1641 小程序-商家助手小程序照明定时任务优化 + cacScheduledTaskGet:`${ORIGIN}/admin/cacScheduledTask/data`, // 获取YZK照明定时列表接口 + cacScheduledTaskSave:`${ORIGIN}/admin/cacScheduledTask/save`, // 设置YZK照明定时 + cacScheduledTaskDelete:`${ORIGIN}/admin/cacScheduledTask/delete`, // 删除YZK照明定时 + + } export default DEVICE_API; \ No newline at end of file diff --git a/src/subpackage/device/pages/index/index.vue b/src/subpackage/device/pages/index/index.vue index a9432b8..3f0547b 100644 --- a/src/subpackage/device/pages/index/index.vue +++ b/src/subpackage/device/pages/index/index.vue @@ -10,7 +10,8 @@ 欧轩智能中控 - + + 设备id:{{ curStoreInfo.device_name || "-" }} @@ -32,7 +33,7 @@ { - util.hideLoad(); - this.deviceInfo = res || {}; - uni.setStorageSync("deviceInfo",res) + let _data = res?.data || {} + util.hideLoad(); + if(_data.code === 0){ + this.deviceInfo = _data?.data || {}; + uni.setStorageSync("deviceInfo",res) + }else{ + return Promise.reject(_data); + } + }) + .catch(err=>{ + util.hideLoad(); + util.showModal({ + title: '提示', + content: err?.message || '中控在线状态查询失败!' + }) }) - .catch(util.hideLoad) }, goBack(){ uni.navigateBack({ delta:1 }); diff --git a/src/subpackage/device/pages/lighting_time/list.vue b/src/subpackage/device/pages/lighting_time/list.vue new file mode 100644 index 0000000..991df61 --- /dev/null +++ b/src/subpackage/device/pages/lighting_time/list.vue @@ -0,0 +1,180 @@ + + + + + \ No newline at end of file diff --git a/src/subpackage/device/pages/lighting_time/setting.vue b/src/subpackage/device/pages/lighting_time/setting.vue new file mode 100644 index 0000000..de2990a --- /dev/null +++ b/src/subpackage/device/pages/lighting_time/setting.vue @@ -0,0 +1,271 @@ + + + + + \ No newline at end of file diff --git a/src/subpackage/device/pages/lighting_timie/list.vue b/src/subpackage/device/pages/lighting_timie/list.vue deleted file mode 100644 index 8522d70..0000000 --- a/src/subpackage/device/pages/lighting_timie/list.vue +++ /dev/null @@ -1,86 +0,0 @@ - - - - - \ No newline at end of file diff --git a/src/subpackage/device/pages/lighting_timie/setting.vue b/src/subpackage/device/pages/lighting_timie/setting.vue deleted file mode 100644 index cb16a96..0000000 --- a/src/subpackage/device/pages/lighting_timie/setting.vue +++ /dev/null @@ -1,217 +0,0 @@ - - - - - \ No newline at end of file diff --git a/src/subpackage/device/pages/switch_manage/switch_manage.vue b/src/subpackage/device/pages/switch_manage/switch_manage.vue index d00c0af..8b1ddac 100644 --- a/src/subpackage/device/pages/switch_manage/switch_manage.vue +++ b/src/subpackage/device/pages/switch_manage/switch_manage.vue @@ -210,7 +210,13 @@ export default { if(this.pageInfo.hardware_type=='IotSim')return util.routeTo(`/subpackage/device/pages/index/lot_manage?mac=${switchInfo.hardware_standard}`, 'nT'); } - if(status == 3) return (()=>{ + + // 云中空,照明,开定时得区分开来 + if(status === 3 && switchInfo?.hardware_type === "Light" && switchInfo?.hardware_connect_method === "YZK" ){ + let { hardware_name, id } = switchInfo; + let _qryStr = `hardware_id=${id || ''}&hardware_name=${util.jsonStr(hardware_name || '')}` + return util.routeTo(`/subpackage/device/pages/lighting_time/list?${_qryStr}`, 'nT'); + } else if (status == 3) return (()=>{ switchInfo.switchData = _data;//将中控组合数据传递到下层 let timing_setting = `/subpackage/device/pages/timing/timing_setting?switchInfo=${encodeURIComponent(JSON.stringify(switchInfo))}` util.routeTo(`${timing_setting}`, 'nT'); diff --git a/src/subpackage/device/static/images/delete.png b/src/subpackage/device/static/images/delete.png new file mode 100644 index 0000000000000000000000000000000000000000..b358e0b3085bf5667ea9d73b211f5028c29cb599 GIT binary patch literal 365 zcmeAS@N?(olHy`uVBq!ia0vp^Dj>|k3?#4J%UA`ZTmyVUT!HktbLY;UJqsiu3?Lg0 z;DX3fK=zq4XMp7S^XE^WJ`GfSaGi$+&>*prAirRSrIAw~ddYo!z4b8v_qLjHTT%A2 zsp|WuKGXxMIOyr(7-Dhy?WEH}M+5|1-z!`?@%!O_`_fsbeB6XKoyt4sH2t>w!UM@K zuFVLWE_<mP`S*C{vnABZ%Fw8ivBKy63mx|=NjhUN*YOGjSe5iadVeoYIb6Mw<&;$S Date: Mon, 2 Sep 2024 14:21:31 +0800 Subject: [PATCH 3/4] vtest 1.1.60 --- src/subpackage/device/js/device_api.js | 1 - 1 file changed, 1 deletion(-) diff --git a/src/subpackage/device/js/device_api.js b/src/subpackage/device/js/device_api.js index 7d129e4..db1f4f5 100644 --- a/src/subpackage/device/js/device_api.js +++ b/src/subpackage/device/js/device_api.js @@ -73,7 +73,6 @@ export const DEVICE_API = { cacScheduledTaskGet:`${ORIGIN}/admin/cacScheduledTask/data`, // 获取YZK照明定时列表接口 cacScheduledTaskSave:`${ORIGIN}/admin/cacScheduledTask/save`, // 设置YZK照明定时 cacScheduledTaskDelete:`${ORIGIN}/admin/cacScheduledTask/delete`, // 删除YZK照明定时 - } From a5885c5afc27aec7933903e6e5537093c270d535 Mon Sep 17 00:00:00 2001 From: "liujw155@outlook.com" Date: Mon, 2 Sep 2024 14:36:25 +0800 Subject: [PATCH 4/4] v 1.1.60 formal & tid1641 --- src/js/api.js | 4 ++-- src/manifest.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/js/api.js b/src/js/api.js index 550179d..88f6939 100644 --- a/src/js/api.js +++ b/src/js/api.js @@ -1,5 +1,5 @@ -export const ORIGIN = `https://testmanager.ouxuanzhineng.cn`; // 测试 -// export const ORIGIN = `https://minimanage.ouxuanzhineng.cn`; // 正式 +// export const ORIGIN = `https://testmanager.ouxuanzhineng.cn`; // 测试 +export const ORIGIN = `https://minimanage.ouxuanzhineng.cn`; // 正式 // export const ORIGIN = `http://192.168.1.135:9090`; // 20210927 测试 diff --git a/src/manifest.json b/src/manifest.json index d409cc9..3fe960c 100644 --- a/src/manifest.json +++ b/src/manifest.json @@ -73,7 +73,7 @@ // } // }, /* 正式 wxf1294b279ad1b845 */ - "appid" : "wx7106e84614cf0060", + "appid" : "wxf1294b279ad1b845", "setting" : { "urlCheck" : false, "minified" : true