Class ClazzDaoHibernate

java.lang.Object
org.beangle.orm.hibernate.HibernateEntityDao
org.openurp.edu.clazz.dao.hibernate.internal.ClazzDaoHibernate
All Implemented Interfaces:
org.beangle.commons.dao.EntityDao, ClazzDao

public class ClazzDaoHibernate extends org.beangle.orm.hibernate.HibernateEntityDao implements ClazzDao
  • Constructor Details

    • ClazzDaoHibernate

      public ClazzDaoHibernate()
  • Method Details

    • getClazzesByCategory

      public org.beangle.commons.collection.page.Page<Clazz> getClazzesByCategory(Serializable id, ClazzFilterStrategy strategy, Semester semester, int pageNo, int pageSize)
      Description copied from interface: ClazzDao
      按照指定的类别获取当前学期的固定页面的教学任务
      Specified by:
      getClazzesByCategory in interface ClazzDao
      Parameters:
      id -
      pageNo -
      pageSize -
      Returns:
    • getClazzesByCategory

      public List<Clazz> getClazzesByCategory(Serializable id, ClazzFilterStrategy strategy, Collection<Semester> semesters)
      Description copied from interface: ClazzDao
      按照指定的类别获得当前学期的所有教学任务
      Specified by:
      getClazzesByCategory in interface ClazzDao
      Parameters:
      id -
      strategy -
      Returns:
    • getClazzesOfStd

      public List<Clazz> getClazzesOfStd(Serializable stdId, List<Semester> semesters)
    • updateClazzByCategory

      public int updateClazzByCategory(String attr, Object value, Long id, ClazzFilterStrategy strategy, Semester semester)
      Description copied from interface: ClazzDao
      依照过滤的类别,批量更新
      Specified by:
      updateClazzByCategory in interface ClazzDao
      Parameters:
      attr -
      value -
      semester -
    • updateClazzByCriteria

      public int updateClazzByCriteria(String attr, Object value, Clazz clazz, Integer[] stdTypeIds, Long[] departIds)
      Description copied from interface: ClazzDao
      通过更新条件查询的覆盖结果
      Specified by:
      updateClazzByCriteria in interface ClazzDao
      Parameters:
      attr -
      value -
      clazz -
      stdTypeIds -
      departIds -
    • countClazz

      public int countClazz(Serializable id, ClazzFilterStrategy strategy, Semester semester)
      Description copied from interface: ClazzDao
      按照学年度学期和给定的类别统计
      Specified by:
      countClazz in interface ClazzDao
      Parameters:
      strategy -
      Returns:
    • saveMergeResult

      public void saveMergeResult(Clazz[] clazzes, int index)
      Description copied from interface: ClazzDao
      tasks[target] is to be updated,and other's is to be deleted.
      Specified by:
      saveMergeResult in interface ClazzDao
      Parameters:
      clazzes -
      index -
    • remove

      public void remove(Clazz clazz)
      Description copied from interface: ClazzDao
      删除教学任务
      Specified by:
      remove in interface ClazzDao
      Parameters:
      clazz -
    • getOccupancies

      public List<Occupancy> getOccupancies(Clazz clazz)
    • saveGenResult

      public void saveGenResult(ExecutivePlan plan, Semester semester, List<Clazz> clazzes, boolean removeExists)
      Description copied from interface: ClazzDao
      1)保存一个培养计划的生成结果:tasks
      2)更新培养计划,记录已经生成的学期标记
      Specified by:
      saveGenResult in interface ClazzDao
      Parameters:
      plan - 来自于哪个培养计划
      semester - 生成到哪个学期?
      clazzes - 没有保存的任务
      removeExists - 是否删除已经生成过的教学任务
    • saveOrUpdate

      public void saveOrUpdate(Clazz clazz)
      Description copied from interface: ClazzDao
      保存新的教学任务或更新老的教学任务
      如果教学任务是新的,那么就生成课程序号
      如果教学任务是老的,那么就更新教学任务
      Specified by:
      saveOrUpdate in interface ClazzDao
      Parameters:
      clazz -
    • setClazzCRNGenerator

      public void setClazzCRNGenerator(ClazzCRNGenerator clazzSeqNoGenerator)