mirror of
https://github.com/gnh1201/welsonjs.git
synced 2025-02-11 09:24:58 +00:00
fix
This commit is contained in:
parent
d786940ebd
commit
9a90778d34
15
app/index.js
15
app/index.js
|
@ -21,11 +21,13 @@ var assign = function() {
|
|||
SHELL.runVisibleWindow("cscript app.js shadow");
|
||||
};
|
||||
|
||||
/*
|
||||
var pingtest = function() {
|
||||
for (var i = 0; i < servers.length; i++) {
|
||||
servers[i].entry.find("span.ping").text(SYS.ping(servers[i].data.ipaddress) + " ms");
|
||||
servers[i].entry.find("span.status").text(SYS.ping(servers[i].data.ipaddress) + " ms");
|
||||
}
|
||||
};
|
||||
*/
|
||||
|
||||
var getLocalApplications = function() {
|
||||
// LDPlayer
|
||||
|
@ -194,6 +196,7 @@ var getMyServers = function(assignedServers) {
|
|||
var entry = template.clone();
|
||||
entry.find("a.title").text(res.data[i].ipaddress);
|
||||
entry.find("div.description").text(res.data[i].name);
|
||||
entry.find("span.status").text(res.data[i].status !== "published" ? "점검중" : "사용가능");
|
||||
entry.appendTo("#listview_servers");
|
||||
servers.push({
|
||||
"data": res.data[i],
|
||||
|
@ -210,13 +213,15 @@ var getMyServers = function(assignedServers) {
|
|||
.setBearerAuth(token)
|
||||
.setUseCache(false)
|
||||
.setParameters({
|
||||
//"filter[status][eq]": "published", // get only available items
|
||||
"filter[id][in]": assignedServers.join(','),
|
||||
"limit": "-1"
|
||||
})
|
||||
.get(apiUrl + "/netsolid/items/servers", onSuccess)
|
||||
;
|
||||
|
||||
pingtest();
|
||||
setInterval(pingtest, 5000);
|
||||
//pingtest();
|
||||
//setInterval(pingtest, 5000);
|
||||
//document.getElementById("btn_pingtest").onclick = pingtest;
|
||||
|
||||
getMyApplications();
|
||||
|
@ -238,6 +243,7 @@ var getAssignedServers = function() {
|
|||
.setBearerAuth(token)
|
||||
.setUseCache(false)
|
||||
.setParameters({
|
||||
//"filter[status][eq]": "published", // get only available items
|
||||
"filter[assigned_to][eq]": userId
|
||||
})
|
||||
.get(apiUrl + "/netsolid/items/assignedservers", onSuccess)
|
||||
|
@ -252,7 +258,7 @@ var getNotices = function() {
|
|||
var entry = template.clone();
|
||||
entry.find("a.title").text(res.data[i].title);
|
||||
entry.find("div.description").text(res.data[i].content);
|
||||
entry.find("span.ping").text(res.data[i].created_on.substring(0, 10));
|
||||
entry.find("span.status").text(res.data[i].created_on.substring(0, 10));
|
||||
entry.appendTo("#listview_notices");
|
||||
}
|
||||
|
||||
|
@ -262,6 +268,7 @@ var getNotices = function() {
|
|||
HTTP.create()
|
||||
.setContentType("application/x-www-form-urlencoded")
|
||||
.setParameters({
|
||||
"filter[status][eq]": "published", // get only available items
|
||||
"sort": "-created_on",
|
||||
"limit": 3
|
||||
})
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
<div class="col width-fit mobile-width-fit"><span class="icon icon-bell color-blue"></span></div>
|
||||
<div class="col width-fill mobile-width-fill">
|
||||
<span class="float-right">
|
||||
<span class="ping text">
|
||||
<span class="status text">
|
||||
N/A
|
||||
</span>
|
||||
<span class="icon icon-time"></span>
|
||||
|
@ -37,8 +37,8 @@
|
|||
<div class="col width-fit mobile-width-fit"><span class="icon icon-bookmark color-blue"></span></div>
|
||||
<div class="col width-fill mobile-width-fill">
|
||||
<span class="float-right">
|
||||
<span class="ping text">
|
||||
N/A
|
||||
<span class="status text">
|
||||
No measure
|
||||
</span>
|
||||
<span class="icon icon-bolt color-yellow"></span>
|
||||
</span>
|
||||
|
|
|
@ -2,7 +2,7 @@ html, body {
|
|||
padding: 0;
|
||||
margin: 0;
|
||||
width: 100%;
|
||||
height: 90%;
|
||||
overflow: hidden;
|
||||
font-size: 1em;
|
||||
font-family: "맑은 고딕", "Malgun Gothic", "Segoe UI", Calibri, Arial, Sans-Serif;
|
||||
}
|
||||
|
@ -14,8 +14,6 @@ input, textarea {
|
|||
|
||||
#app {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
#loading {
|
||||
|
|
Loading…
Reference in New Issue
Block a user