[Building Sakai] course site session dropdown

Ron Peterson rpeterso at mtholyoke.edu
Fri Sep 10 12:42:52 PDT 2010


2010-09-10_12:13:53-0400 Zhen Qian <zqian at umich.edu>:
> 
> Do you have your own implementation of CourseManagementService?

Nope.  I double checked that my codebase matches what you show below
exactly, and it does.

This is the data in my table.  The only term that shows up when I create
a new site is Spring 2010, even though the is_current field for that
term is 0, and the date range does not include today's date.

"ACADEMIC_SESSION_ID","VERSION","LAST_MODIFIED_BY","LAST_MODIFIED_DATE","CREATED_BY","CREATED_DATE","ENTERPRISE_ID","TITLE","DESCRIPTION","START_DATE","END_DATE","IS_CURRENT"
"20061000","1","","","ELLA25","31-JUL-08","2006/FA","Fall_2006","Fall_2006","07-SEP-06","13-DEC-06","0"
"20071001","1","","","ELLA25","31-JUL-08","2007/JA","JTerm_2007","JTerm_2007","03-JAN-07","23-JAN-07","0"
"20071002","1","","","ELLA25","31-JUL-08","2007/SP","Spring_2007","Spring_2007","29-JAN-07","18-MAY-07","0"
"20071003","1","","","ELLA25","31-JUL-08","2007/SU","Summer_2007","Summer_2007","01-JUN-07","31-AUG-07","0"
"20071004","1","","","ELLA25","31-JUL-08","2007/FA","Fall_2007","Fall_2007","06-SEP-07","19-DEC-07","0"
"20081005","1","","","ELLA25","31-JUL-08","2008/JA","JTerm_2008","JTerm_2008","03-JAN-08","23-JAN-08","0"
"20081006","1","","","ELLA25","31-JUL-08","2008/SP","Spring_2008","Spring_2008","30-JAN-08","13-MAY-08","0"
"20081007","1","","","ELLA25","31-JUL-08","2008/SU","Summer_2008","Summer_2008","01-JUN-08","31-AUG-08","0"
"20081008","1","","","ELLA25","31-JUL-08","2008/FA","Fall_2008","Fall_2008","04-SEP-08","19-DEC-08","0"
"20091009","1","","","ELLA25","31-JUL-08","2009/JA","JTerm_2009","JTerm_2009","05-JAN-09","23-JAN-09","0"
"20091010","1","","","ELLA25","31-JUL-08","2009/SP","Spring_2009","Spring_2009","29-JAN-09","13-MAY-09","0"
"20091011","1","","","ELLA25","31-JUL-08","2009/SU","Summer_2009","Summer_2009","01-JUN-09","31-AUG-09","0"
"20091012","1","","","ELLA25","31-JUL-08","2009/FA","Fall_2009","Fall_2009","10-SEP-09","22-DEC-09","0"
"20101013","1","","","ELLA25","31-JUL-08","2010/JA","JTerm_2010","JTerm_2010","04-JAN-10","22-JAN-10","0"
"20101014","1","","","ELLA25","31-JUL-08","2010/SP","Spring_2010","Spring_2010","27-JAN-10","12-MAY-10","0"
"20101015","1","","","ELLA25","31-JUL-08","2010/SU","Summer_2010","Summer_2010","01-JUN-10","31-AUG-10","0"
"20101016","1","","","ELLA25","31-JUL-08","2010/FA","Fall_2010","Fall_2010","09-SEP-10","22-DEC-10","1"
"20111017","1","","","ELLA25","31-JUL-08","2011/JA","JTerm_2011","JTerm_2011","03-JAN-11","20-JAN-11","1"
"20111018","1","","","ELLA25","31-JUL-08","2011/SP","Spring_2011","Spring_2011","26-JAN-11","12-MAY-11","1"
"20111019","1","","","ELLA25","31-JUL-08","2011/SU","Summer_2011","Summer_2011","01-JUN-11","31-AUG-11","1"
"20111020","1","","","ELLA25","31-JUL-08","2011/FA","Fall_2011","Fall_2011","08-SEP-11","21-DEC-11","1"
"20121021","1","","","ELLA25","31-JUL-08","2012/JA","JTerm_2012","JTerm_2012","05-JAN-12","24-JAN-12","1"
"20121022","1","","","ELLA25","31-JUL-08","2012/SP","Spring_2012","Spring_2012","31-JAN-12","16-MAY-12","1"

Thanks for any insight.

-Ron-

> Otherwise, if you are running 2.6.2 and using the default hibernate-impl of
> CourseManagementService [1], it should pick up the is_current table
> setting:
> 
> >From [1]:
> 	public List<AcademicSession> getCurrentAcademicSessions() {
> 		return
> getHibernateTemplate().findByNamedQuery("findCurrentAcademicSessions");
> 	}
> 
> >From [2]:
>     <query name="findCurrentAcademicSessions">
>         <![CDATA[
>         from AcademicSessionCmImpl as term where
>         	term.current=true
>         	order by term.startDate
>         ]]>
>     </query>
> 
> Thanks,
> - Zhen
> 
> [1]
> https://source.sakaiproject.org/svn/course-management/tags/sakai-2.6.2/cm-impl/hibernate-impl/impl/src/java/org/sakaiproject/coursemanagement/impl/CourseManagementServiceHibernateImpl.java
> 
> [2]
> https://source.sakaiproject.org/svn/course-management/tags/sakai-2.6.2/cm-impl/hibernate-impl/hibernate/src/hibernate/org/sakaiproject/coursemanagement/impl/AcademicSessionCmImpl.hbm.xml
> 
> On Fri, 10 Sep 2010 15:51:53 +0000, "Maurer, Christopher Wayne"
> <chmaurer at iupui.edu> wrote:
> > Make sure that the session's start and end dates include the current date
> > as I don't think they'll show otherwise.
> > 
> > Chris
> > 
> > On Sep 10, 2010, at 11:49 AM, Ron Peterson wrote:
> > 
> >> Hi,
> >> 
> >> Running Sakai 2.6.2.  I have a problem with the dropdown to select an
> >> academic term when creating a new course site - it only shows a single
> >> term, and not the term I want.
> >> 
> >> There appears to be a relevant discussion here:
> >> 
> >> http://jira.sakaiproject.org/browse/SAK-15531
> >> 
> >> ...which concludes with the advice to check out the following URL:
> >> 
> >> http://confluence.sakaiproject.org/confluence/x/WIAFAw
> >> 
> >> However, that URL is unavailable.
> >> 
> >> I've modified the IS_CURRENT column in my CM_ACADEMIC_SESSION_T table
> >> to be true for the terms I'd like to see, but no luck.
> >> 
> >> ??
> >> 
> >> -Ron-
> >> _______________________________________________
> >> sakai-dev mailing list
> >> sakai-dev at collab.sakaiproject.org
> >> http://collab.sakaiproject.org/mailman/listinfo/sakai-dev
> >> 
> >> TO UNSUBSCRIBE: send email to
> >> sakai-dev-unsubscribe at collab.sakaiproject.org with a subject of
> >> "unsubscribe"
> > 
> > _______________________________________________
> > sakai-dev mailing list
> > sakai-dev at collab.sakaiproject.org
> > http://collab.sakaiproject.org/mailman/listinfo/sakai-dev
> > 
> > TO UNSUBSCRIBE: send email to
> sakai-dev-unsubscribe at collab.sakaiproject.org
> > with a subject of "unsubscribe"


More information about the sakai-dev mailing list