回答編集履歴
2
修正
test
CHANGED
@@ -64,13 +64,13 @@
|
|
64
64
|
|
65
65
|
];
|
66
66
|
|
67
|
-
sort_flag = 0;
|
67
|
+
var sort_flag = 0;
|
68
68
|
|
69
69
|
sort_flag = sort_any("score_2", sort_flag);
|
70
70
|
|
71
71
|
function sort_any(field, flag) {
|
72
72
|
|
73
|
-
f = flag * 2 - 1;
|
73
|
+
var f = flag * 2 - 1;
|
74
74
|
|
75
75
|
arr.sort(function(a, b) {
|
76
76
|
|
1
修正
test
CHANGED
@@ -16,7 +16,7 @@
|
|
16
16
|
|
17
17
|
"score_2": 33,
|
18
18
|
|
19
|
-
"score_
|
19
|
+
"score_3": 46
|
20
20
|
|
21
21
|
},
|
22
22
|
|
@@ -30,7 +30,7 @@
|
|
30
30
|
|
31
31
|
"score_2": 31,
|
32
32
|
|
33
|
-
"score_
|
33
|
+
"score_3": 56
|
34
34
|
|
35
35
|
},
|
36
36
|
|