mirror of
https://github.com/gnh1201/welsonjs.git
synced 2025-05-14 05:31:03 +00:00
fix
This commit is contained in:
parent
b9dd615ec8
commit
253cc80cd3
16
app/index.js
16
app/index.js
|
@ -41,9 +41,19 @@ var showLocalApplications = function() {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
// Chrome (or General applications)
|
// Chrome (demo)
|
||||||
|
localApplications.push({
|
||||||
// todo
|
name: "Program",
|
||||||
|
uniqueId: "chrome-10001.exe"
|
||||||
|
});
|
||||||
|
localApplications.push({
|
||||||
|
name: "Program",
|
||||||
|
uniqueId: "chrome-10002.exe"
|
||||||
|
});
|
||||||
|
localApplications.push({
|
||||||
|
name: "Program",
|
||||||
|
uniqueId: "chrome-10003.exe"
|
||||||
|
});
|
||||||
|
|
||||||
var template = $("#listview_applications .template");
|
var template = $("#listview_applications .template");
|
||||||
for (var i = 0; i < servers.length; i++) {
|
for (var i = 0; i < servers.length; i++) {
|
||||||
|
|
|
@ -33,12 +33,6 @@
|
||||||
<div class="col">
|
<div class="col">
|
||||||
<div class="col width-fit mobile-width-fit"><span class="icon icon-bookmark color-blue"></span></div>
|
<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">
|
<div class="col width-fill mobile-width-fill">
|
||||||
<span class="float-right">
|
|
||||||
<span class="ping text">
|
|
||||||
N/A
|
|
||||||
</span>
|
|
||||||
<span class="icon icon-bolt color-yellow"></span>
|
|
||||||
</span>
|
|
||||||
<div class="col width-fill mobile-width-fill">
|
<div class="col width-fill mobile-width-fill">
|
||||||
<a class="title fatty" href="#">Repo 1</a>
|
<a class="title fatty" href="#">Repo 1</a>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -50,6 +50,21 @@ exports.getCountByProcessName = function(processName) {
|
||||||
return num;
|
return num;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
exports.getAvailableProcesses = function() {
|
||||||
|
var PIDs = [];
|
||||||
|
var cmd = "tasklist | findstr .exe";
|
||||||
|
var result = SHELL.exec(cmd);
|
||||||
|
var lines = result.split(/\r?\n/);
|
||||||
|
for(var i = 0; i < lines.length; i++) {
|
||||||
|
var row = lines[i].split(/\s+/);
|
||||||
|
PIDs.push({
|
||||||
|
PID: row[1],
|
||||||
|
name: row[0]
|
||||||
|
});
|
||||||
|
}
|
||||||
|
return PIDs;
|
||||||
|
};
|
||||||
|
|
||||||
exports.getCountOfSessions = function() {
|
exports.getCountOfSessions = function() {
|
||||||
return exports.getCountByProcessName("ss-local.exe");
|
return exports.getCountByProcessName("ss-local.exe");
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue
Block a user