sbd-npm 1.3.96 → 1.3.99
Sign up to get free protection for your applications and to get access to all the features.
- package/package.json +1 -1
- package/summary_daily.js +1 -1
- package/util.js +24 -9
package/package.json
CHANGED
package/summary_daily.js
CHANGED
@@ -76,10 +76,10 @@ $(function () {
|
|
76
76
|
Util.post(location.pathname, {date: $("#trade_date").val(), action: "market_overview", is_init: Util.is_init}, function (j) {
|
77
77
|
DailySummary.pack_market_overview(j["market_overview"]);
|
78
78
|
DailySummary.fetch_statistics_daily();
|
79
|
-
DailySummary.fetch_hsgt_ten(0);
|
80
79
|
if (j["date"] && !Util.is_mobile()) {
|
81
80
|
DailySummary.init_date_component(j["date"]);
|
82
81
|
}
|
82
|
+
DailySummary.fetch_hsgt_ten(0);
|
83
83
|
});
|
84
84
|
},
|
85
85
|
|
package/util.js
CHANGED
@@ -622,7 +622,7 @@ const Util = {
|
|
622
622
|
*/
|
623
623
|
rand_stock: function (rand_btn_id, stock_type) {
|
624
624
|
$("#" + rand_btn_id).click(function () {
|
625
|
-
$(
|
625
|
+
$(this).attr("disabled", true);
|
626
626
|
Util.post("/action", {action: "rand_stock", stock_type: stock_type}, function (j) {
|
627
627
|
$("#" + rand_btn_id).attr("disabled", false);
|
628
628
|
if (j["code"]) {
|
@@ -1439,15 +1439,29 @@ const Util = {
|
|
1439
1439
|
* @param component_id
|
1440
1440
|
*/
|
1441
1441
|
init_public_fund_component: function (component_id) {
|
1442
|
-
let modal_content_html = '<table class="table table-bordered table-hover table-striped text-center"><
|
1442
|
+
let modal_content_html = '<table class="table table-bordered table-hover table-striped text-center"><tbody id="' + component_id + '_body_body"><tr><td colspan="2">Loading...</td></tr></tbody></table>';
|
1443
1443
|
Util.init_modal_skeleton(component_id, modal_content_html);
|
1444
1444
|
let component_obj = $('#' + component_id);
|
1445
1445
|
component_obj.on('shown.bs.modal', function (e) {
|
1446
1446
|
let fund_code = $(e.relatedTarget).attr("data-val");
|
1447
|
-
|
1447
|
+
if (fund_code) {
|
1448
|
+
Util.fetch_public_fund_detail(fund_code, component_id);
|
1449
|
+
} else {
|
1450
|
+
if (localStorage["modal_public_fund_code"]) {
|
1451
|
+
Util.fetch_public_fund_detail(localStorage["modal_public_fund_code"], component_id);
|
1452
|
+
} else {
|
1453
|
+
let request_arguments = Util.request_arguments();
|
1454
|
+
if (request_arguments["fund_code"]) {
|
1455
|
+
Util.fetch_public_fund_detail(request_arguments["fund_code"], component_id);
|
1456
|
+
}
|
1457
|
+
}
|
1458
|
+
}
|
1448
1459
|
});
|
1449
1460
|
component_obj.on('hidden.bs.modal', function () {
|
1450
|
-
$("#" + component_id + "_body_body").html("<tr><td colspan='
|
1461
|
+
$("#" + component_id + "_body_body").html("<tr><td colspan='14'>Loading...</td></tr>");
|
1462
|
+
if (localStorage["modal_public_fund_code"]) {
|
1463
|
+
localStorage.removeItem("modal_public_fund_code");
|
1464
|
+
}
|
1451
1465
|
Util.hide_tips();
|
1452
1466
|
});
|
1453
1467
|
},
|
@@ -1461,7 +1475,7 @@ const Util = {
|
|
1461
1475
|
if (!fund_code) {
|
1462
1476
|
return;
|
1463
1477
|
}
|
1464
|
-
$("#" + component_id + "_body_body").html("<tr><td colspan='
|
1478
|
+
$("#" + component_id + "_body_body").html("<tr><td colspan='14'>Loading...</td></tr>");
|
1465
1479
|
$("#" + component_id + "_title").html(fund_code);
|
1466
1480
|
Util.post(Util.get_url("fund_public"), {action: "public_fund_detail", fund_code: fund_code}, function (j) {
|
1467
1481
|
let _html = [];
|
@@ -1484,10 +1498,11 @@ const Util = {
|
|
1484
1498
|
_html.push("<tr><td colspan='3'>单位净值</td><td colspan='4'>", net, "</td><td colspan='3'>资产规模</td><td colspan='4'>", assets, "</td></tr>");
|
1485
1499
|
_html.push("<tr><td colspan='3'>成立日期</td><td colspan='4'>", public_date, "</td><td colspan='3'>发行日期</td><td colspan='4'>", issue_date, "</td></tr>");
|
1486
1500
|
_html.push("<tr><td colspan='3'>基金管理公司</td><td colspan='4'>", Util.pack_fund_administrator(j), "</td><td colspan='3'>基金经理</td><td colspan='4'>", Util.pack_fund_manager(j), "</td></tr>");
|
1487
|
-
_html.push("<tr><td colspan='
|
1488
|
-
_html.push("<tr><td colspan='
|
1489
|
-
_html.push("<tr><td colspan='
|
1490
|
-
_html.push("<tr><td colspan='
|
1501
|
+
_html.push("<tr><td colspan='3'>基金托管人</td><td colspan='4'>", (j["custodian"] ? j["custodian"] : "--"), "</td><td colspan='3'>经办律师事务所</td><td colspan='4'>", (j["lawyer"] ? j["lawyer"] : "--"), "</td></tr>");
|
1502
|
+
_html.push("<tr><td colspan='3'>会计师事务所</td><td colspan='4'>", (j["accounting"] ? j["accounting"] : "--"), "</td><td colspan='3'>注册地址</td><td colspan='4'>", Util.map_url(j["location"], j["location"]), "</td></tr>");
|
1503
|
+
_html.push("<tr><td colspan='3'>近一周</td><td colspan='4'>", Util.parse_ratio(j["one_week_change"]), "</td><td colspan='3'>近一月</td><td colspan='4'>", Util.parse_ratio(j["one_month_change"]), "</td></tr>");
|
1504
|
+
_html.push("<tr><td colspan='3'>近一年</td><td colspan='4'>", Util.parse_ratio(j["one_year_change"]), "</td><td colspan='3'>年初至今</td><td colspan='4'>", Util.pack_html_link('https://fundf10.eastmoney.com/jdzf_' + j["fund_code"] + '.html', Util.parse_ratio(j["ytd_change"])), "</td></tr>");
|
1505
|
+
_html.push("<tr><td colspan='5'>成立以来</td><td colspan='9'>", Util.parse_ratio(j["establish_change"]), "</td></tr>");
|
1491
1506
|
_html.push("<tr class='info'><th colspan='14' text-align='center'>", Util.pack_html_link("http://fund.eastmoney.com/f10/ccmx_" + j["fund_code"] + ".html", "持股明细"), " <span id='fund_stock_date_zone'></span></th></tr>");
|
1492
1507
|
_html.push("<tr id='" + component_id + "_head'><th>序号</th><th>股票代码</th><th>股票名</th><th>PE</th><th>总市值</th><th>行业</th><th>地区</th><th>价格</th><th>年初至今</th><th>近5日</th><th>股东数</th><th>持有量</th><th class='info'>占比</th><th>持仓市值</th></tr>");
|
1493
1508
|
_html.push("<tr class='" + component_id + "_tr'><td colspan='14'>暂无数据</td></tr>");
|