public override void saveChildren(IModelObject mo)
        {
            Employee ret = (Employee)mo;

            //*Child Association:jobhistory
            if (ret.JobHistoryLoaded)       //scc
            {
                OracleMappers.JobHistoryDBMapper jobhistoryMapper = new OracleMappers.JobHistoryDBMapper(this.dbConn);
                jobhistoryMapper.saveList(ret.PrJobHistory);
                jobhistoryMapper.deleteList(ret.PrJobHistoryGetDeleted());
            }
            //*Child Association:courses
            if (ret.CoursesLoaded)       //scc
            {
                OracleMappers.EmployeeTrainingHistoryDBMapper coursesMapper = new OracleMappers.EmployeeTrainingHistoryDBMapper(this.dbConn);
                coursesMapper.saveList(ret.PrCourses);
                coursesMapper.deleteList(ret.PrCoursesGetDeleted());
            }
            //*Child Association:traininghistory
            if (ret.TrainingHistoryLoaded)       //scc
            {
                OracleMappers.EmployeeTrainingHistoryDBMapper traininghistoryMapper = new OracleMappers.EmployeeTrainingHistoryDBMapper(this.dbConn);
                traininghistoryMapper.saveList(ret.PrTrainingHistory);
                traininghistoryMapper.deleteList(ret.PrTrainingHistoryGetDeleted());
            }
        }
Esempio n. 2
0
 public override void saveChildren(IModelObject mo)
 {
     Employee ret = (Employee)mo;
     //*Child Association:jobhistory
     if (ret.JobHistoryLoaded) { //scc
     OracleMappers.JobHistoryDBMapper jobhistoryMapper = new OracleMappers.JobHistoryDBMapper(this.dbConn);
     jobhistoryMapper.saveList(ret.PrJobHistory);
     jobhistoryMapper.deleteList(ret.PrJobHistoryGetDeleted());
     }
     //*Child Association:courses
     if (ret.CoursesLoaded) { //scc
     OracleMappers.EmployeeTrainingHistoryDBMapper coursesMapper = new OracleMappers.EmployeeTrainingHistoryDBMapper(this.dbConn);
     coursesMapper.saveList(ret.PrCourses);
     coursesMapper.deleteList(ret.PrCoursesGetDeleted());
     }
     //*Child Association:traininghistory
     if (ret.TrainingHistoryLoaded) { //scc
     OracleMappers.EmployeeTrainingHistoryDBMapper traininghistoryMapper = new OracleMappers.EmployeeTrainingHistoryDBMapper(this.dbConn);
     traininghistoryMapper.saveList(ret.PrTrainingHistory);
     traininghistoryMapper.deleteList(ret.PrTrainingHistoryGetDeleted());
     }
 }