This repository was archived by the owner on Mar 4, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +10
-5
lines changed
js/app/challenge-details/js/controllers Expand file tree Collapse file tree 2 files changed +10
-5
lines changed Original file line number Diff line number Diff line change @@ -734,11 +734,11 @@ h1.center {
734
734
}
735
735
736
736
.challenge-detail .unregister {
737
- background : # e66 !important ;
737
+ background : # cef8c6 !important ;
738
738
}
739
739
740
740
.challenge-detail .unregister : hover {
741
- background : # d66 !important ;
741
+ background : # cef8c6 !important ;
742
742
}
743
743
744
744
.challenge-detail .btnAction : hover {
@@ -759,11 +759,11 @@ h1.center {
759
759
}
760
760
761
761
.challenge-detail .develop .unregister {
762
- background : # e66 !important ;
762
+ background : # cef8c6 !important ;
763
763
}
764
764
765
765
.challenge-detail .develop .unregister : hover {
766
- background : # d66 !important ;
766
+ background : # cef8c6 !important ;
767
767
}
768
768
769
769
.challenge-detail .btnAction .disabled {
Original file line number Diff line number Diff line change 331
331
if ( regList . indexOf ( handle ) == - 1 ) {
332
332
vm . isRegistered = false ;
333
333
}
334
+
335
+ var hasSubmitted = false ;
336
+ if ( submissionMap . indexOf ( handle ) >= 0 ) {
337
+ hasSubmitted = true ;
338
+ }
334
339
335
340
// If the challenge is active and in the registration phase we allow either
336
341
// registration, or unregistration.
337
342
if ( ( ( moment ( challenge . phases [ 0 ] . scheduledStartTime ) ) < moment ( ) && ( moment ( challenge . registrationEndDate ) ) > moment ( ) ) && challenge . currentStatus == 'Active' ) {
338
- if ( vm . isRegistered ) {
343
+ if ( vm . isRegistered && ! hasSubmitted ) {
339
344
vm . challenge . allowToUnregister = true ;
340
345
} else {
341
346
vm . challenge . registrationDisabled = false ;
You can’t perform that action at this time.
0 commit comments