wxd
/
MShopWeApp
Toggle navigation
Sign in
Sign in
Project
Files
Commits
Network
Graphs
Milestones
Issues
0
Merge Requests
0
Labels
Wiki
Download as
Email Patches
Plain Diff
Browse Code »
Commit
5dc6eaf0ad22daf6142409ba907ffdb2b63d485d
Authored by
yvan.ni
2021-12-18 11:10:38 +0800
1 parent
9267aaf9
结算的时候,商品的价格要按照价格排序
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
0 deletions
pages/cart/cart2/ladder_calculate.js
pages/cart/cart2/ladder_calculate.js
View file @
5dc6eaf
...
...
@@ -49,6 +49,11 @@ module.exports = {
49
49
del_g.push(item);
50
50
}
51
51
52
+ function sortData(a, b) {
53
+ return a.price - b.price
54
+ }
55
+ no_in_arr.sort(sortData);
56
+
52
57
//开始阶梯计算价格
53
58
var lev = 0;
54
59
for (let j in ladder_list) {
...
...