sbd-npm 1.1.88 → 1.1.89
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/package.json +1 -1
- package/util.js +12 -2
- package/.npmignore +0 -1
package/package.json
CHANGED
package/util.js
CHANGED
@@ -1940,9 +1940,9 @@ const Util = {
|
|
1940
1940
|
} else {
|
1941
1941
|
Util.refresh_index_price(element_id, index_list.join("-"), is_us, 0);
|
1942
1942
|
}
|
1943
|
-
|
1943
|
+
let total_num = valid_code_list.length;
|
1944
|
+
if (total_num > 0 && total_num < 100) { // 涨跌统计
|
1944
1945
|
if ($("#" + element_id + "_tips").length) {
|
1945
|
-
let total_num = valid_code_list.length;
|
1946
1946
|
let average_change_percent = Math.round((total_change_percent / total_num) * 10000) / 100;
|
1947
1947
|
let average_year_change_percent = Math.round((total_year_change_percent / total_num) * 10000) / 100;
|
1948
1948
|
let week_tips_id = element_id + "week_tips";
|
@@ -2448,6 +2448,16 @@ const Util = {
|
|
2448
2448
|
return Util.to_float(digit / 100000000, fraction);
|
2449
2449
|
},
|
2450
2450
|
|
2451
|
+
/**
|
2452
|
+
* 转为以万为单位的数值
|
2453
|
+
* @param digit
|
2454
|
+
* @param fraction
|
2455
|
+
* @returns {*|number}
|
2456
|
+
*/
|
2457
|
+
to_ten_thousand: function (digit, fraction = 2) {
|
2458
|
+
return Util.to_float(digit / 10000, fraction);
|
2459
|
+
},
|
2460
|
+
|
2451
2461
|
/**
|
2452
2462
|
* 转为相应单位的数值
|
2453
2463
|
* @param digit
|
package/.npmignore
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
sbd-npm.md
|