File tree Expand file tree Collapse file tree 3 files changed +8
-3
lines changed
reducers/challenge-listing Expand file tree Collapse file tree 3 files changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -812,7 +812,7 @@ function create(initialState) {
812
812
sorts : {
813
813
ongoing : 'updated' ,
814
814
openForRegistration : 'updated' ,
815
- my : 'updated ' ,
815
+ my : 'startDate ' ,
816
816
// past: 'updated',
817
817
reviewOpportunities : 'review-opportunities-start-date' ,
818
818
} ,
Original file line number Diff line number Diff line change @@ -35,7 +35,7 @@ export const BUCKET_DATA = {
35
35
// hideCount: false,
36
36
name : 'My Challenges' ,
37
37
sorts : [
38
- SORTS . MOST_RECENT ,
38
+ SORTS . MOST_RECENT_START_DATE ,
39
39
// SORTS.TIME_TO_SUBMIT,
40
40
// SORTS.NUM_REGISTRANTS,
41
41
// SORTS.NUM_SUBMISSIONS,
Original file line number Diff line number Diff line change @@ -8,6 +8,7 @@ import { sumBy } from 'lodash';
8
8
export const SORTS = {
9
9
// CURRENT_PHASE: 'current-phase',
10
10
MOST_RECENT : 'updated' ,
11
+ MOST_RECENT_START_DATE : 'startDate' ,
11
12
// NUM_REGISTRANTS: 'num-registrants',
12
13
// NUM_SUBMISSIONS: 'num-submissions',
13
14
// PRIZE_HIGH_TO_LOW: 'prize-high-to-low',
@@ -29,6 +30,10 @@ export default {
29
30
name : 'Most recent' ,
30
31
order : 'desc' ,
31
32
} ,
33
+ [ SORTS . MOST_RECENT_START_DATE ] : {
34
+ name : 'Most recent' ,
35
+ order : 'desc' ,
36
+ } ,
32
37
// [SORTS.NUM_REGISTRANTS]: {
33
38
// func: (a, b) => b.numOfRegistrants - a.numOfRegistrants,
34
39
// name: '# of registrants',
@@ -89,7 +94,7 @@ export default {
89
94
} ,
90
95
[ SORTS . REVIEW_OPPORTUNITIES_START_DATE ] : {
91
96
// This will implicitly use moment#valueOf
92
- func : ( a , b ) => moment ( a . startDate ) - moment ( b . startDate ) ,
97
+ func : ( a , b ) => moment ( b . startDate ) - moment ( a . startDate ) , // descending
93
98
name : 'Review start date' ,
94
99
} ,
95
100
} ;
You can’t perform that action at this time.
0 commit comments