Skip to content

Commit

Permalink
SAK-26141 Access settings for syllabus items are not available except…
Browse files Browse the repository at this point in the history
… in Bulk Edit view

git-svn-id: https://source.sakaiproject.org/svn/syllabus/trunk@312360 66ffb92e-73f9-0310-93c1-f5514f145a0a
  • Loading branch information
Bryan Holladay committed Aug 22, 2014
1 parent 9848e2c commit 7decbd3
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,8 @@ clickToAddTitle=Click to add title
clickToAddStartDate=Click to add start date
clickToAddEndDate=Click to add end date
clickToAddBody=Click to add body text
clickToHideWorld=Click to make this syllabus item viewable to only this site
clickToAddWorld=Click to make this syllabus item publicly viewable to the whole world
dragToReorder=Drag to reorder
clickToPublish=Click to publish
clickToUnpublish=Click to unpublish
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -449,6 +449,13 @@ public void updateEntity(EntityReference ref, Object entity, Map<String, Object>
data.setLinkCalendar(false);
}
syllabusManager.saveSyllabus(data);
}else if("view".equals(params.get("toggle"))){
if(status){
data.setView("yes");
}else{
data.setView("no");
}
syllabusManager.saveSyllabus(data);
}
}else if(params.containsKey("delete")){
//Delete item
Expand Down
4 changes: 4 additions & 0 deletions syllabus/syllabus-app/src/webapp/syllabus/main.jsp
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,8 @@
setupToggleImages("publish", "publish", "publishOn", "publishOff", msgs);
//Calendar Toggle
setupToggleImages("linkCalendar", "linkCal", "linkCalOn", "linkCalOff", msgs);
//Public/Private to the world toggle
setupToggleImages("view", "linkWorld", "linkWorldOn", "linkWorldOff", msgs);
}else{
//remove CSS classes (otherwise you get those hover over "pencil edit" images
$(".editItem").removeClass("editItem");
Expand Down Expand Up @@ -235,6 +237,8 @@
<h:graphicImage url="/images/lightbulb_off.gif" styleClass="actionIcon publish publishOff" title="#{msgs.clickToPublish}" style="#{eachEntry.status == eachEntry.draftStatus ? '' : 'display:none'}"/>
<h:graphicImage url="/images/calendar_view_month.png" rendered="#{SyllabusTool.calendarExistsForSite}" title="#{msgs.clickToRemoveCal}" styleClass="actionIcon linkCal linkCalOn" style="#{eachEntry.entry.linkCalendar ? '' : 'display:none'}"/>
<h:graphicImage url="/images/calendar_view_month_no.png" rendered="#{SyllabusTool.calendarExistsForSite}" title="#{msgs.clickToAddCal}" styleClass="actionIcon linkCal linkCalOff" style="#{eachEntry.entry.linkCalendar ? 'display:none' : ''}"/>
<h:graphicImage url="/images/world.png" title="#{msgs.clickToHideWorld}" styleClass="actionIcon linkWorld linkWorldOn" style="#{eachEntry.entry.view == 'yes' ? '' : 'display:none'}"/>
<h:graphicImage url="/images/world_off.png" title="#{msgs.clickToAddWorld}" styleClass="actionIcon linkWorld linkWorldOff" style="#{eachEntry.entry.view == 'no' ? '' : 'display:none'}"/>
<f:verbatim>
<img src="/library/image/silk/cross.png" class="actionImage delete" onclick="showConfirmDeleteHelper(this, event);" title="</f:verbatim><h:outputText value="#{msgs.clickToDelete}"/><f:verbatim>">
</f:verbatim>
Expand Down

0 comments on commit 7decbd3

Please sign in to comment.