File tree Expand file tree Collapse file tree 7 files changed +30
-17
lines changed Expand file tree Collapse file tree 7 files changed +30
-17
lines changed Original file line number Diff line number Diff line change @@ -37,6 +37,7 @@ export default Model.extend({
3737 currentAttempt : DS . belongsTo ( 'contest-attempt' ) ,
3838 college_contest : DS . belongsTo ( 'college_contest' ) ,
3939 contest_type : DS . attr ( ) ,
40+ showProblemScore : DS . attr ( ) ,
4041 hasEnded : Ember . computed ( 'end_time' , function ( ) {
4142 return moment ( this . end_time ) . isBefore ( moment ( ) )
4243 } ) ,
Original file line number Diff line number Diff line change 2929 <h4 class =" yellow d-inline-block" >{{ content.topSubmission.resultParams.message }} </h4 >
3030 {{ else }}
3131 {{ /if }}
32- <div class =" row mx-0 justify-content-start" >
33- <div class =" col-6 px-0" >
34- <progress value =" {{ content.topSubmission.score }} " max =" 100" class =" mt-3 d-inline-block" ></progress >
35- </div >
36- <div class =" col-6 px-0" >
37- <h5 class =" d-inline-block mt-2 pl-3" >{{ content.topSubmission.score }} /100 Points</h5 >
32+ {{ #if contest.showProblemScore }}
33+ <div class =" row mx-0 justify-content-start" >
34+ <div class =" col-6 px-0" >
35+ <progress value =" {{ content.topSubmission.score }} " max =" 100" class =" mt-3 d-inline-block" ></progress >
36+ </div >
37+ <div class =" col-6 px-0" >
38+ <h5 class =" d-inline-block mt-2 pl-3" >{{ content.topSubmission.score }} /100 Points</h5 >
39+ </div >
3840 </div >
39- </ div >
41+ {{ /if }}
4042 </div >
4143 {{ else }}
4244 <div class =" col-xl-3 col-lg-4 col-md-5 col-12" >
4547 <h4 class =" yellow d-inline-block" >Not Attempted</h4 >
4648 {{ else }}
4749 {{ /if }}
50+ {{ #if contest.showProblemScore }}
4851 <div class =" row mx-0 justify-content-start" >
4952 <div class =" col-6 px-0" >
5053 <progress value =" 0" max =" 100" class =" mt-3 d-inline-block" ></progress >
5356 <h5 class =" d-inline-block mt-2 pl-3" >0/100 Points</h5 >
5457 </div >
5558 </div >
59+ {{ /if }}
5660 </div >
5761 {{ /if }}
5862 </div >
Original file line number Diff line number Diff line change 2424 <span
2525 class =" orange font-mds extra-bold" >{{ or content.topSubmission.resultParams.message ' Not Attempted' }} </span >
2626 </div >
27- <div class =" col-6" >
28- <div class =" row no-gutters justify-content-end" >
29- <div class =" col-xl-6 col-5" >
30- <progress value =" {{ or content.topSubmission.score 0 }} " max =" 100" class =" d-inline-block v-align-m" ></progress >
31- </div >
32- <div >
33- <h5 class =" d-inline-block pl-3" >{{ or content.topSubmission.score 0 }} /100 Pts</h5 >
27+ {{ #if contest.showProblemScore }}
28+ <div class =" col-6" >
29+ <div class =" row no-gutters justify-content-end" >
30+ <div class =" col-xl-6 col-5" >
31+ <progress value =" {{ or content.topSubmission.score 0 }} " max =" 100" class =" d-inline-block v-align-m" ></progress >
32+ </div >
33+ <div >
34+ <h5 class =" d-inline-block pl-3" >{{ or content.topSubmission.score 0 }} /100 Pts</h5 >
35+ </div >
3436 </div >
3537 </div >
36- </ div >
38+ {{ /if }}
3739 </div >
3840 <div class =" row no-gutters" >
3941 <div class =" tab-nav-underline w-100 justify-content-start bg-white position-sticky" >
Original file line number Diff line number Diff line change @@ -20,5 +20,6 @@ export default class Content extends Route {
2020
2121 setupController ( controller , model ) {
2222 controller . set ( 'content' , model . content )
23+ controller . set ( 'contest' , model . contest )
2324 }
2425}
Original file line number Diff line number Diff line change 77 </div >
88<div class =" row my-4" >
99 <div class =" col-12" >
10- <ContentHeader @content ={{ content }} />
10+ <ContentHeader
11+ @content ={{ content }}
12+ @contest ={{ contest }} />
1113 </div >
1214</div >
1315
Original file line number Diff line number Diff line change @@ -34,5 +34,6 @@ export default class ContentRoute extends Route {
3434
3535 setupController ( controller , model ) {
3636 controller . set ( 'content' , model . content )
37+ controller . set ( 'contest' , model . contest )
3738 }
3839}
Original file line number Diff line number Diff line change 11<div class =" row my-4" >
22 <div class =" col-12" >
3- <ContentHeader @content ={{ content }} />
3+ <ContentHeader
4+ @content ={{ content }}
5+ @contest ={{ contest }} />
46 </div >
57</div >
68{{ outlet }}
You can’t perform that action at this time.
0 commit comments