Skip to content

Commit 98065e3

Browse files
Frontend: Show challenge start date in submit tab & disable submission when start date is in future(Cloud-CV#2032)
1 parent 1e6845e commit 98065e3

File tree

1 file changed

+9
-4
lines changed

1 file changed

+9
-4
lines changed

frontend/src/views/web/challenge/submission.html

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,16 +38,21 @@
3838
<ul>
3939
<b>Select Phase:</b>
4040
<li ng-repeat="item in challenge.phases.results">
41-
<input ng-if="challenge.currentDate < item.end_date" type="radio" name="selectPhase" class="with-gap selectPhase" id="{{item.id}}" value="{{item.id}}" ng-model="challenge.phaseId" ng-click="challenge.showRemainingSubmissions(item.id)">
42-
<input ng-if="challenge.currentDate >= item.end_date" type="radio" name="selectPhase" class="with-gap selectPhase" id="{{item.id}}" value="{{item.id}}" ng-model="challenge.phaseId" ng-click="challenge.showRemainingSubmissions(item.id)" disabled="true">
41+
<input ng-disabled="challenge.currentDate < item.start_date || challenge.currentDate >= item.end_date" type="radio" name="selectPhase" class="with-gap selectPhase" id="{{item.id}}" value="{{item.id}}" ng-model="challenge.phaseId" ng-click="challenge.showRemainingSubmissions(item.id)">
4342
<label for="{{item.id}}"></label>
4443
<div class="show-member-title pointer" ng-if="!item.showPrivate"><strong class="text-med-black">Phase: </strong>{{item.name}}
4544
<br>
46-
<strong class="text-med-black">End Date: </strong>{{item.end_date | date:'medium'}}</div>
45+
<strong class="text-med-black">Start Date: </strong>{{item.start_date | date:'medium'}}
46+
<br>
47+
<strong class="text-med-black">End Date: </strong>{{item.end_date | date:'medium'}}
48+
</div>
4749
<div class="show-member-title pointer" ng-if="item.showPrivate"><strong class="text-highlight">Phase: </strong> <span class="text-highlight">
4850
{{item.name}}</span>
4951
<br>
50-
<strong class="text-highlight">End Date: </strong><span class="text-highlight">{{item.end_date | date:'medium'}}</span></div>
52+
<strong class="text-highlight">Start Date: </strong><span class="text-highlight">{{item.start_date | date:'medium'}}</span>
53+
<br>
54+
<strong class="text-highlight">End Date: </strong><span class="text-highlight">{{item.end_date | date:'medium'}}</span>
55+
</div>
5156
<div class="clearfix"></div>
5257
</li>
5358
<div class="row">

0 commit comments

Comments
 (0)