Skip to content
This repository was archived by the owner on Jan 23, 2025. It is now read-only.

Commit f363c55

Browse files
committed
move group widget
1 parent 1c23959 commit f363c55

File tree

13 files changed

+86
-153
lines changed

13 files changed

+86
-153
lines changed

src/web/WEB-INF/includes/contest/editTab.jsp

Lines changed: 14 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -144,11 +144,16 @@
144144
<td class="sec_tab_type"><strong>: <span id="rPreRegisterUsers"></span></strong></td>
145145
</tr>
146146
<tr></tr>
147+
<tr>
148+
<td class="first_tab_type"><strong>Group(s):</strong></td>
149+
<td class="sec_tab_type"><strong>: <span id="rswGroups"></span></strong></td>
150+
</tr>
151+
<tr></tr>
147152
<tr>
148153
<td class="first_tab_type"><strong>Created By</strong></td>
149154
<td class="sec_tab_type"><strong>: <span id="rChallengeCreator"></span></strong></td>
150155
</tr>
151-
<tr></tr>
156+
<tr></tr>
152157
<%--<tr>--%>
153158
<%--<td class="first_tab_type"><strong>Challenge Fee</strong></td>--%>
154159
<%--<td class="sec_tab_type"><strong>: $<span id="rAdminFee"></span></strong></td>--%>
@@ -311,16 +316,20 @@
311316
<span class="name fixWidthName" title="Enter 1 or more members in a comma separated list. Member terms will be validated upon saving."><strong>Assign Member(s):</strong></span>
312317
<span class="value"><input type="text" name="preRegisterUsers" class="bigin" id="preRegisterUsers"/></span>
313318
</div>
314-
<br /><br />
319+
<div id="groupDisplay">
320+
<span class="name fixWidthName" title="Enter challenge groups"><strong>Group(s):</strong></span>
321+
<div id="groupDiv"><div id="groups"></div></div>
322+
</div>
323+
<br/><br/>
315324
<span class="name fixWidthName"><strong>Created By</strong></span>
316325
<span class ='small_info_spec' id="challegneCreatorLabel"></span>
317326
</div>
318327
</div>
319-
<p class="save">
328+
<p class="save">
320329
<a href="javascript:;" class="cancel_text">cancel</a>
321330
<a href="javascript:;"><img src="/images/save_change.png" alt="save" class="save_btn" /></a>
322-
</p>
323-
<div class="clear"></div>
331+
</p>
332+
<div class="clear"></div>
324333
</div><!-- End .detailsContent -->
325334
</div><!-- End .details -->
326335
<!-- End Contest Type Edit -->
@@ -739,18 +748,6 @@
739748

740749
<div class="bottom_spec">
741750
</div>
742-
<div class="groupDisplay">
743-
<p class="det_font">
744-
<span class="name"><strong>Challenge Groups</strong></span>
745-
746-
<br />
747-
<span class="small_info_spec" id="rswGroups">
748-
</span>
749-
</p>
750-
751-
<div class="bottom_spec">
752-
</div>
753-
</div>
754751
<p class="det_font">
755752
<span class="name"><strong>Final Deliverables</strong></span>
756753
<br />
@@ -817,10 +814,6 @@
817814

818815
</div>
819816
<!-- end .guidelines -->
820-
<h3>Challenge Group</h3>
821-
<div class="prizes group studio" id="groupStudioDiv">
822-
<div id="group_studio"></div>
823-
</div>
824817
</div> <!-- end .contestDetail -->
825818
<div class="deliverables">
826819
<h3><span class="icon">Final Deliverables:</span><a href="javascript:;" class="helpIcon"><span class="hide">Help</span></a></h3>

src/web/WEB-INF/includes/contest/editTabMarathon.jsp

Lines changed: 19 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -105,14 +105,17 @@
105105
<td class="first_tab_type"><strong>Challenge Fee</strong></td>
106106
<td class="sec_tab_type"><strong>: $<span id="rAdminFee"></span></strong></td>
107107
</tr>
108+
<tr></tr>
108109
<tr class="preRegisterUsersDiv hide">
109110
<td class="first_tab_type"><strong>Assign Member(s):</strong></td>
110111
<td class="sec_tab_type"><strong>: <span id="rPreRegisterUsers"></span></strong></td>
111112
</tr>
113+
<tr></tr>
112114
<tr>
113-
<td class="first_tab_type"><strong>Created By</strong></td>
114-
<td class="sec_tab_type"><strong>: <span id="rChallengeCreator"></span></strong></td>
115+
<td class="first_tab_type"><strong>Group(s):</strong></td>
116+
<td class="sec_tab_type"><strong>: <span id="rswGroups"></span></strong></td>
115117
</tr>
118+
<tr></tr>
116119
<tr>
117120
<td class="first_tab_type"><strong>Created By</strong></td>
118121
<td class="sec_tab_type"><strong>: <span id="rChallengeCreator"></span></strong></td>
@@ -244,23 +247,27 @@
244247
<span class="name fixWidthName"><strong>Task</strong></span>
245248
<input type="checkbox" name="privateProject" id="privateProject"/>
246249
</div>
247-
<br />
248250
<div id="preRegisterUsersEditDiv">
251+
<br />
249252
<span class="name fixWidthName"><strong>Assign Member(s):</strong></span>
250253
<span class="value"><input type="text" name="preRegisterUsers" class="bigin" id="preRegisterUsers"/></span>
251254
</div>
252-
<br /><br />
253-
255+
<br />
256+
<div id="groupDisplay">
257+
<span class="name fixWidthName" title="Enter challenge groups"><strong>Group(s):</strong></span>
258+
<div id="groupDiv"><div id="groups"></div></div>
259+
</div>
260+
<br/><br/>
254261
<span class="name fixWidthName"><strong>Created By</strong></span>
255262
<span class ='small_info_spec' id="challegneCreatorLabel"></span>
256-
257-
263+
<br/>
264+
<p class="save">
265+
<a href="javascript:;" class="cancel_text">cancel</a>
266+
<a href="javascript:;"><img src="/images/save_change.png" alt="save" class="save_btn" /></a>
267+
</p>
268+
<div class="clear"></div>
258269
</div>
259-
<p class="save">
260-
<a href="javascript:;" class="cancel_text">cancel</a>
261-
<a href="javascript:;"><img src="/images/save_change.png" alt="save" class="save_btn" /></a>
262-
</p>
263-
<div class="clear"></div>
270+
<div class="clear"></div>
264271
</div><!-- End .detailsContent -->
265272
</div><!-- End .details -->
266273
<!-- End Contest Type Edit -->
@@ -508,18 +515,6 @@
508515
</span>
509516
</div>
510517
</p>
511-
<div class="groupDisplay">
512-
<p class="det_font">
513-
<span class="name"><strong>Challenge Groups</strong></span>
514-
515-
<br />
516-
<span class="small_info_spec" id="rswGroups">
517-
</span>
518-
</p>
519-
520-
<div class="bottom_spec">
521-
</div>
522-
</div>
523518
</div><!-- End .detailsContent -->
524519
</div><!-- End .details -->
525520
<!-- END Spec Display -->
@@ -567,10 +562,6 @@
567562

568563
</div>
569564
<!-- end .guidelines -->
570-
<h3>Challenge Group</h3>
571-
<div class="prizes group algorithm" id="groupAlgorithmDiv">
572-
<div id="group_algorithm"></div>
573-
</div>
574565
</div> <!-- end .contestDetail -->
575566

576567
</div> <!-- End .launchContestOut -->

src/web/WEB-INF/includes/contest/editTabSoftware.jsp

Lines changed: 10 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,11 @@
164164
<td class="sec_tab_type"><strong>: <span id="rPreRegisterUsers"></span></strong></td>
165165
</tr>
166166
<tr></tr>
167+
<tr>
168+
<td class="first_tab_type"><strong>Group(s):</strong></td>
169+
<td class="sec_tab_type"><strong>: <span id="rswGroups"></span></strong></td>
170+
</tr>
171+
<tr></tr>
167172
<tr>
168173
<td class="first_tab_type"><strong>Created By</strong></td>
169174
<td class="sec_tab_type"><strong>: <span id="rChallengeCreator"></span></strong></td>
@@ -327,17 +332,19 @@
327332
</div>
328333
<div class="clearFix"></div>
329334
</div>
330-
<br />
331335
<div id="privateProjectEditDiv" class="hide">
332336
<span class="name fixWidthName" title="Run this as an assigned task. Registration will not be open to anyone else, but it will still be publically listed."><strong>Task</strong></span>
333337
<input type="checkbox" name="privateProject" id="privateProject"/>
334338
</div>
335-
<br />
336339
<div id="preRegisterUsersEditDiv" class="hide">
337340
<span class="name fixWidthName" title="Enter 1 or more members in a comma separated list. Member terms will be validated upon saving."><strong>Assign Member(s):</strong></span>
338341
<span class="value"><input type="text" name="preRegisterUsers" class="bigin" id="preRegisterUsers"/></span>
339342
</div>
340-
<br/><br />
343+
<div id="groupDisplay">
344+
<span class="name fixWidthName" title="Enter challenge groups"><strong>Group(s):</strong></span>
345+
<div id="groupDiv"><div id="groups"></div></div>
346+
</div>
347+
<br/><br/>
341348
<div>
342349

343350
<span class="name fixWidthName"><strong>Created By</strong></span>
@@ -346,8 +353,6 @@
346353

347354
</div>
348355

349-
350-
351356
</p>
352357
<p class="save">
353358
<a href="javascript:;" class="cancel_text">cancel</a>
@@ -781,19 +786,6 @@
781786
</div> <!-- End of .technology -->
782787
</s:if>
783788

784-
<div class="groupDisplay">
785-
<p class="det_font">
786-
<span class="name"><strong>Challenge Groups</strong></span>
787-
788-
<br />
789-
<span class="small_info_spec" id="rswGroups">
790-
</span>
791-
</p>
792-
793-
<div class="bottom_spec">
794-
</div>
795-
</div>
796-
797789
<div class="component">
798790
<p class="det_font">
799791
<span class="name"><strong>Catalog Name</strong></span>
@@ -958,11 +950,6 @@
958950
</div> <!-- end of prizesInner_tech -->
959951
</div>
960952
</s:if>
961-
<h3>Challenge Group</h3>
962-
<div class="prizes group software" id="groupSoftwareDiv">
963-
<div id="group_software"></div>
964-
</div>
965-
966953
</div> <!-- end .contestDetail -->
967954
</div> <!-- End .launchContestOut -->
968955

src/web/WEB-INF/includes/launch/contestSelection.jsp

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,12 @@
201201
<label>Assign Member(s):</label>
202202
<input name="preRegisterUsers" type="text" class="text"/>
203203
</div>
204-
204+
<div class="row">
205+
<label>Group(s):</label>
206+
<div id="groupDiv">
207+
<div id="groups"></div>
208+
</div>
209+
</div>
205210
</div>
206211
<!-- end .addNewContest -->
207212
</form>

src/web/WEB-INF/includes/launch/overview.jsp

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -65,11 +65,6 @@
6565
</div>
6666
</div>
6767
<!-- end round 2 information -->
68-
<h3>Challenge Group</h3>
69-
<div class="prizes group studio" id="groupStudioDiv">
70-
<div id="group_studio"></div>
71-
</div>
72-
7368
<!-- upload -->
7469
<div id="uploadSection">
7570

src/web/WEB-INF/includes/launch/overviewAlgorithm.jsp

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -44,10 +44,6 @@
4444
</div>
4545
</div>
4646
<!-- end Match Rules -->
47-
<h3>Challenge Group</h3>
48-
<div class="prizes group algorithm" id="groupAlgorithmDiv">
49-
<div id="group_algorithm"></div>
50-
</div>
5147
<!-- upload -->
5248
<div id="alUploadSection">
5349
<h3>File Upload (20MB maximum):</h3>

src/web/WEB-INF/includes/launch/overviewSoftware.jsp

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -109,10 +109,6 @@
109109
</select>
110110
</div>
111111
</div>
112-
<h3>Challenge Group</h3>
113-
<div class="prizes group software" id="groupSoftwareDiv">
114-
<div id="group_software"></div>
115-
</div>
116112

117113
<div id="swThurgoodDiv" style="display: none">
118114
<h3>Use Thurgood to check challenge submissions?</h3><br/>

src/web/WEB-INF/includes/launch/review.jsp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@
5858
<td><span id="rEndDate"></span><a href="javascript:showPage('contestSelectionPage');" class="tipLink"><img src="/images/edit-icon.png" alt="Edit"/></a></td>
5959
</tr>
6060
<tr class="rGroups">
61-
<th>Challenge Groups :</th>
61+
<th>Group(s) :</th>
6262
<td><a href="javascript:backReview();" class="tipLink"><img src="/images/edit-icon.png" alt="Edit"/></a></td>
6363
</tr>
6464
</table>

src/web/css/direct/launchcontest.css

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3189,8 +3189,20 @@ div#winnerDiv {
31893189
padding: 2px 5px 2px 5px;
31903190
margin-right: 5px;
31913191
}
3192-
div.group{
3193-
width: 675px;
3192+
#groupDiv{
31943193
border: 1px solid #CCC;
3194+
border-radius: 5px;
3195+
margin-left: 132px;
3196+
width: auto;
3197+
margin-right: 50px;
3198+
}
3199+
.ms-ctn-focus{
3200+
background-color: #ffffff;
3201+
}
3202+
#groupDisplay #groupDiv{
3203+
margin-left: 150px;
3204+
}
3205+
div#groupDisplay {
31953206
margin-top: 20px;
3196-
}
3207+
}
3208+

src/web/scripts/launch/contestDetailSoftware.js

Lines changed: 10 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2596,16 +2596,7 @@ function populateSpecSection(initFlag) {
25962596
$("#swThurgoodDiv input").removeAttr("checked");
25972597
}
25982598

2599-
var gid = "#group_" + getContestType()[0].toLowerCase();
2600-
var groupMap = {};
2601-
$.each(securityGroups, function(i, val){
2602-
groupMap[''+val.id]=val;
2603-
});
2604-
var selectedGroup = []
2605-
$.each(mainWidget.softwareCompetition.groups, function(i, val){
2606-
selectedGroup.push(groupMap[val]);
2607-
});
2608-
jQuery_1_11_1(gid).magicSuggest().setSelection(selectedGroup);
2599+
jQuery_1_11_1("#groups").magicSuggest().setValue(mainWidget.softwareCompetition.groups);
26092600

26102601
// for studio
26112602
if (mainWidget.competitionType == "STUDIO") {
@@ -2661,11 +2652,16 @@ function populateSpecSection(initFlag) {
26612652
});
26622653
$('#rswTechnologies').html(html);
26632654
}
2664-
var sGroup="";
2665-
$.each(selectedGroup,function(i,group) {
2666-
sGroup += group.name +"<br/>";
2655+
var groupMap = {};
2656+
$.each(securityGroups, function(i, val){
2657+
groupMap[''+val.id]=val.name;
26672658
});
2668-
$('#rswGroups').html(sGroup);
2659+
var selectedGroupName = [];
2660+
$.each(mainWidget.softwareCompetition.groups, function(i, val){
2661+
selectedGroupName.push(groupMap[val]);
2662+
});
2663+
2664+
$('#rswGroups').html(selectedGroupName.join(", "));
26692665

26702666
if(isPlatformContest()) {
26712667
var html = "";

0 commit comments

Comments
 (0)