sbd-npm 1.5.3 → 1.5.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/constant.js +1 -1
- package/package.json +1 -1
- package/status.js +9 -3
- package/util.js +17 -0
package/constant.js
CHANGED
|
@@ -160,11 +160,11 @@ const MenuList = [
|
|
|
160
160
|
'icon': 'retweet',
|
|
161
161
|
'menu': [
|
|
162
162
|
{'key': 'portfolio_recommend', 'name': '关注', 'url': '/0x2da99e58e28de94b670c4200657ac7e26dd8dceb'},
|
|
163
|
+
{'key': 'portfolio_gao', 'name': '高大侠', 'url': '/0x44fe5ef98b6802a9e7a893a1dcc231031ef8683d'},
|
|
163
164
|
{'key': 'portfolio_chen', 'name': '陈营长极品投资', 'url': '/0x3f8cbeeeb38138a626e935017a4cc25f47ce3dbe'},
|
|
164
165
|
{'key': 'portfolio_stratagem', 'name': '上兵伐谋zgz', 'url': '/0x622a4a04d7a04e3b28c85a36500371ba28edea83'},
|
|
165
166
|
{'key': 'portfolio_zeng', 'name': '老曾阿牛', 'url': '/0x2cf53b473b916e1d8b9998de00bb782171bb2630'},
|
|
166
167
|
{'key': 'portfolio_dao', 'name': '专注成长的股事笔记', 'url': '/0xf9d3664538c43bf7f886674abe7af9710aab82ec'},
|
|
167
|
-
{'key': 'portfolio_vegetable', 'name': 'Veget', 'url': '/0x671dd9dcfca7dbc220c8164c92a74d2c561c6464'},
|
|
168
168
|
{'key': 'portfolio_tianjin', 'name': '天津股侠', 'url': '/0xb8428e42237a7485a787e2ab1b5ae0f057258f18'},
|
|
169
169
|
{'key': 'portfolio_junk', 'name': 'HK破烂王', 'url': '/0xfa43c30e5399feb566fb9a8181c175b0af0dff7f'},
|
|
170
170
|
{'key': 'portfolio_star50', 'name': '科创50', 'url': '/0x378b2601d83c467f81f1d4e323c8bfbc72f6cc0d'},
|
package/package.json
CHANGED
package/status.js
CHANGED
|
@@ -880,9 +880,15 @@ $(function () {
|
|
|
880
880
|
handle_process_kill: function(element_id, action_type) {
|
|
881
881
|
$("#" + element_id + " .process_kill").each(function() {
|
|
882
882
|
$(this).click(function() {
|
|
883
|
-
let
|
|
884
|
-
let
|
|
885
|
-
let
|
|
883
|
+
let tr_obj = $(this).parent().parent();
|
|
884
|
+
let pid = tr_obj.children('td').eq(0).text();
|
|
885
|
+
let cmdline_index = tr_obj.parent().parent().find('thead td').filter(function () {
|
|
886
|
+
return $(this).text().includes('启动命令');
|
|
887
|
+
}).index();
|
|
888
|
+
if (cmdline_index < 0) {
|
|
889
|
+
cmdline_index = action_type === 2 ? 3 : 6;
|
|
890
|
+
}
|
|
891
|
+
let cmdline_obj = tr_obj.children('td').eq(cmdline_index);
|
|
886
892
|
let cmdline = cmdline_obj.attr('title') ? cmdline_obj.attr('title') : cmdline_obj.text();
|
|
887
893
|
let action = Status.parse_machine_action(cmdline);
|
|
888
894
|
let pid_action = "[" + pid + "(" + action + ")]";
|
package/util.js
CHANGED
|
@@ -323,6 +323,23 @@ const Util = {
|
|
|
323
323
|
},
|
|
324
324
|
error: function (jqXHR, textStatus, errorThrown) {
|
|
325
325
|
Util.hide_tips();
|
|
326
|
+
if (errorThrown) {
|
|
327
|
+
if (jqXHR.status) {
|
|
328
|
+
errorThrown += '(HTTP ' + jqXHR.status + ')';
|
|
329
|
+
}
|
|
330
|
+
} else {
|
|
331
|
+
if ((textStatus === 'error' && jqXHR.status === 0) || !navigator.onLine) {
|
|
332
|
+
errorThrown = "网络异常";
|
|
333
|
+
} else if (textStatus === 'timeout') {
|
|
334
|
+
errorThrown = "请求超时";
|
|
335
|
+
} else if (textStatus === 'abort') {
|
|
336
|
+
errorThrown = "请求被中止";
|
|
337
|
+
} else if (jqXHR.status) {
|
|
338
|
+
errorThrown = '请求失败(HTTP ' + jqXHR.status + ')';
|
|
339
|
+
} else {
|
|
340
|
+
errorThrown = "未知错误";
|
|
341
|
+
}
|
|
342
|
+
}
|
|
326
343
|
let msg = "[" + textStatus + "] " + errorThrown;
|
|
327
344
|
Util.show_tips(msg, 0, "alert-danger");
|
|
328
345
|
}
|