智慧教室
+ +{{node.name}}({{node.count}})
- +{{node.name}}({{node.count}})
+diff --git a/projects/Infrastructure/wwwroot/favicon.ico b/projects/Infrastructure/wwwroot/favicon.ico index a3a79998..9ffa7168 100644 Binary files a/projects/Infrastructure/wwwroot/favicon.ico and b/projects/Infrastructure/wwwroot/favicon.ico differ diff --git a/projects/Infrastructure/wwwroot/images/logo.png b/projects/Infrastructure/wwwroot/images/logo.png index 8cc09cda..75ae5e47 100644 Binary files a/projects/Infrastructure/wwwroot/images/logo.png and b/projects/Infrastructure/wwwroot/images/logo.png differ diff --git a/projects/IoTCenter/wwwroot/images/logo.png b/projects/IoTCenter/wwwroot/images/logo.png index c85258f9..75ae5e47 100644 Binary files a/projects/IoTCenter/wwwroot/images/logo.png and b/projects/IoTCenter/wwwroot/images/logo.png differ diff --git a/projects/JobServer/wwwroot/favicon.ico b/projects/JobServer/wwwroot/favicon.ico index a3a79998..9ffa7168 100644 Binary files a/projects/JobServer/wwwroot/favicon.ico and b/projects/JobServer/wwwroot/favicon.ico differ diff --git a/projects/StudyCenter/wwwroot/favicon.ico b/projects/StudyCenter/wwwroot/favicon.ico index a3a79998..9ffa7168 100644 Binary files a/projects/StudyCenter/wwwroot/favicon.ico and b/projects/StudyCenter/wwwroot/favicon.ico differ diff --git a/projects/StudyCenter/wwwroot/images/logo.png b/projects/StudyCenter/wwwroot/images/logo.png index 8cc09cda..75ae5e47 100644 Binary files a/projects/StudyCenter/wwwroot/images/logo.png and b/projects/StudyCenter/wwwroot/images/logo.png differ diff --git a/projects/WebSPA/wwwroot/css/app.css b/projects/WebSPA/wwwroot/css/app.css index 01c47c99..1dc8c7cb 100644 --- a/projects/WebSPA/wwwroot/css/app.css +++ b/projects/WebSPA/wwwroot/css/app.css @@ -894,7 +894,7 @@ ul { .weui-header{ top: 0; color: #ffffff; - background-color: #07c160; + background-color: #35A9FE; position: fixed; right: 0; left: 0; diff --git a/projects/WebSPA/wwwroot/favicon.ico b/projects/WebSPA/wwwroot/favicon.ico index a3a79998..9ffa7168 100644 Binary files a/projects/WebSPA/wwwroot/favicon.ico and b/projects/WebSPA/wwwroot/favicon.ico differ diff --git a/projects/WebSPA/wwwroot/images/electricity.svg b/projects/WebSPA/wwwroot/images/electricity.svg new file mode 100644 index 00000000..365489c6 --- /dev/null +++ b/projects/WebSPA/wwwroot/images/electricity.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/projects/WebSPA/wwwroot/images/humidity.svg b/projects/WebSPA/wwwroot/images/humidity.svg new file mode 100644 index 00000000..863a9084 --- /dev/null +++ b/projects/WebSPA/wwwroot/images/humidity.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/projects/WebSPA/wwwroot/images/logo.png b/projects/WebSPA/wwwroot/images/logo.png index c85258f9..75ae5e47 100644 Binary files a/projects/WebSPA/wwwroot/images/logo.png and b/projects/WebSPA/wwwroot/images/logo.png differ diff --git a/projects/WebSPA/wwwroot/images/off.svg b/projects/WebSPA/wwwroot/images/off.svg new file mode 100644 index 00000000..6f56815b --- /dev/null +++ b/projects/WebSPA/wwwroot/images/off.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/projects/WebSPA/wwwroot/images/on.svg b/projects/WebSPA/wwwroot/images/on.svg new file mode 100644 index 00000000..f2a7a8c3 --- /dev/null +++ b/projects/WebSPA/wwwroot/images/on.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/projects/WebSPA/wwwroot/images/temperature.svg b/projects/WebSPA/wwwroot/images/temperature.svg new file mode 100644 index 00000000..4889f472 --- /dev/null +++ b/projects/WebSPA/wwwroot/images/temperature.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/projects/WebSPA/wwwroot/js/app.js b/projects/WebSPA/wwwroot/js/app.js index 7433a1ac..da753827 100644 --- a/projects/WebSPA/wwwroot/js/app.js +++ b/projects/WebSPA/wwwroot/js/app.js @@ -1,5 +1,6 @@ var userAgent = navigator.userAgent; var isApp = userAgent.indexOf('isapp') !== -1; +var localStoreMsg = false; // 是否本地存储消息 /* API 网关 */ var apigateway = config.apigateway; console.log('config:'); @@ -171,6 +172,10 @@ var onReturnBack = function (){ } } +window.addEventListener("popstate", function(e) { + $('.weui-header a.weui-header-left')[0].click(); +}, false); + // indexedDB兼容 var indexedDB = window.indexedDB || window.webkitindexedDB || window.msIndexedDB || mozIndexedDB || null; @@ -214,7 +219,10 @@ function saveMessage(msg){ // 校验数据格式(当前只存储带key的消息,后续会有调整) if( jsonMsg.key ){ console.log('IS MSG'); - objectStore.add({data: jsonMsg}); + // 本地存储 + if(localStoreMsg){ + objectStore.add({data: jsonMsg}); + } // objectStore.delete(store.state.messages[0]._id); store.commit('setMessages', [{data: jsonMsg}]); } diff --git a/projects/WebSPA/wwwroot/js/util.js b/projects/WebSPA/wwwroot/js/util.js index 677f481a..2d913927 100644 --- a/projects/WebSPA/wwwroot/js/util.js +++ b/projects/WebSPA/wwwroot/js/util.js @@ -76,6 +76,20 @@ function execScene(id) { }); } +function nodePower(number, command) { + var loading = weui.loading('提交中...'); + axios.post('/IoTCenter/api/v1/node/power'+command, '"' + number + '"', { headers: { 'Content-Type': 'application/json;charset=UTF-8' } }) + .then(function (response) { + console.log(response); + }) + .catch(function (error) { + console.log(error); + }) + .finally(function () { + loading.hide(); + }); +} + /** * 格式化时间 * @param {*} value diff --git a/projects/WebSPA/wwwroot/pages/home.html b/projects/WebSPA/wwwroot/pages/home.html index a9ce7a14..79b8a568 100644 --- a/projects/WebSPA/wwwroot/pages/home.html +++ b/projects/WebSPA/wwwroot/pages/home.html @@ -20,7 +20,7 @@