From 77f4d007a704b0d4a8c7e85b615d5541255f4d0f Mon Sep 17 00:00:00 2001 From: wanggang <76527413@qq.com> Date: Fri, 19 Jul 2019 19:08:00 +0800 Subject: [PATCH] update Former-commit-id: f79e83e6eec8dc4d7ebe9f408581c1bf27d27660 --- .../FBeeService/Controllers/IrController.cs | 4 +- .../Infrastructure/DeviceService.cs | 1 + .../Assets/StreamingAssets/wwwroot/index.html | 57 ++++++++++++++++-- .../Assets/StreamingAssets/wwwroot/js/app.js | Bin 49188 -> 55730 bytes 4 files changed, 54 insertions(+), 8 deletions(-) diff --git a/projects/IoT/IoTServices/FBeeService/Controllers/IrController.cs b/projects/IoT/IoTServices/FBeeService/Controllers/IrController.cs index d68ac407..27e26b32 100644 --- a/projects/IoT/IoTServices/FBeeService/Controllers/IrController.cs +++ b/projects/IoT/IoTServices/FBeeService/Controllers/IrController.cs @@ -16,9 +16,9 @@ namespace FBeeService.Controllers this._deviceService = deviceService; } - [HttpGet, Route("[action]"), SwaggerOperation("发送指令")] + [HttpGet, Route("/[controller]/[action]"), SwaggerOperation("发送指令")] - public ApiResponse PressKey([SwaggerParameter("网关编号")]string gateway, [SwaggerParameter("设备编号")]string number, [SwaggerParameter("按键类型")]byte type, [SwaggerParameter("键值")]ushort code) + public ApiResponse Send([SwaggerParameter("网关编号")]string gateway, [SwaggerParameter("设备编号")]string number, [SwaggerParameter("按键类型")]byte type, [SwaggerParameter("键值")]ushort code) { return this.AsyncAction(() => { diff --git a/projects/IoT/IoTServices/FBeeService/Infrastructure/DeviceService.cs b/projects/IoT/IoTServices/FBeeService/Infrastructure/DeviceService.cs index fb4615ce..bf7b7552 100644 --- a/projects/IoT/IoTServices/FBeeService/Infrastructure/DeviceService.cs +++ b/projects/IoT/IoTServices/FBeeService/Infrastructure/DeviceService.cs @@ -1231,6 +1231,7 @@ namespace FBeeService } } deviceRepo.SaveChanges(); + this.SendDevice(device); } } } diff --git a/projects/IoTClient/Assets/StreamingAssets/wwwroot/index.html b/projects/IoTClient/Assets/StreamingAssets/wwwroot/index.html index 14dc32be..9e62527b 100644 --- a/projects/IoTClient/Assets/StreamingAssets/wwwroot/index.html +++ b/projects/IoTClient/Assets/StreamingAssets/wwwroot/index.html @@ -569,19 +569,64 @@
启用空调 禁用空调 - 启用电视 - 禁用电视 - 启用自定义 - 禁用自定义
-
+ + + +
+
+ +
+
+ + +
+
- +
+ +
+
+ + + + + +
+
+
+
+ +
+
+ +
+
+
+
+ +
+
+ + + +
+
+
+
+ +
+
+ + + + +
diff --git a/projects/IoTClient/Assets/StreamingAssets/wwwroot/js/app.js b/projects/IoTClient/Assets/StreamingAssets/wwwroot/js/app.js index affc59bd80f69fbd8b75f39bfab56656a3d717c9..5b50c11d9c714bef998d4cc1b382133d9b91718f 100644 GIT binary patch delta 3397 zcmb_fOK)3M5FXW*d!59oW5?9ND!EBoJ62jJ*GU@G5Y!4(2?|b9sJci4xXzjg*yjI!>}I{gEgB|E8W!Nk3MBifmuB!5hu(Rb zfSwdItl>S4_gU=_i|_@QC`bwcB|rM3&QqeI@ncbo?CX=cql z5u!xF=W2TfKX!!qwBtRVnrv~I$jnnw{_XrA=UVKG5>=fBl=T$+Od~S$^ae0x;qhL5 zkds+_1ouiU*)1?=#>}k6hW+A@(#N*~eXMT;c{3K}54RUM)#hgZ7iT-HdXXA6B@4CLv6~U_ zjdyMa_$!AdmFug{Uxh@g743?3SE;@#cDiau&61jW(akxh{jiy#SHbxadYOh4_jQV* z76)mcDMw{)L(!n@^zdS zxtg$e=U_Mg9t^VkCkJm`8sg-4?R@kb4{x6BmG`{;qvRR>`|VD4Z@xBn8>NAfP3tH{OxV+qMTd7&KiC% z(0TOgev%H6RI`S3?<`GYMSAf%_Cm#}CWI+UO&&@z3x>P{*|h3wi#(kufmv7JXM&dSoU59a#>qu3u%Pq% z8JF~q3O~vyre=<(^`-KBQ-Ank##iM>6@{O{m)bh&`g4GiNSA7-%jK!Dndru<}G zvn8v$5>d0po*@YJ^;C}0<5nV^MfCh2=5<=-HOt?}y7+_nei?k7#lg2Yf^7OdK1)_t z^w&{7pg8ZGKEgSp(=gjYy|K7xwOG)z7y)}QYQH2UI`e!bTDoxMpNCpyn%eMi&ZBYc Hm)HLXkd4pt delta 99 zcmdnAnR!VA^M+eVi(69pCKt?P+k7i&3Dab~xg48&il4AgF3{qed|->&rU`o-CmR?D yO}=pP%;dbAE|Y^U+HfZ^lroe6VLn6Nrve~6HkXit_b}R@0