Beispiel #1
0
 public DN_Weekly_Schedule Update(DN_Weekly_Schedule weeklySchedule, WeeklyScheduleItem weeklyScheduleItem)
 {
     weeklySchedule.AgencyID    = weeklyScheduleItem.AgencyID;
     weeklySchedule.ScheduleID  = weeklyScheduleItem.ScheduleID;
     weeklySchedule.WeeklyID    = weeklyScheduleItem.WeeklyID;
     weeklySchedule.DateCreated = weeklyScheduleItem.DateCreated;
     return(weeklySchedule);
 }
Beispiel #2
0
 public ActionResult Add(string key, WeeklyScheduleItem weeklyScheduleItem)
 {
     if (key == Keyapi)
     {
         var obj = new DN_Weekly_Schedule();
         Update(obj, weeklyScheduleItem);
         _da.Save();
         _da.Add(obj);
         return(Json(1, JsonRequestBehavior.AllowGet));
     }
     return(Json(0, JsonRequestBehavior.AllowGet));
 }
Beispiel #3
0
        public DN_Weekly_Schedule UpdateMapping(int weeklyId, int scheduleId, int agencyId)
        {
            var weeklySchedule = new DN_Weekly_Schedule
            {
                WeeklyID    = weeklyId,
                ScheduleID  = scheduleId,
                AgencyID    = agencyId,
                DateCreated = ConvertDate.TotalSeconds(DateTime.Now)
            };

            return(weeklySchedule);
        }
Beispiel #4
0
 public void Delete(DN_Weekly_Schedule weeklySchedule)
 {
     FDIDB.DN_Weekly_Schedule.Remove(weeklySchedule);
 }
Beispiel #5
0
 public void Add(DN_Weekly_Schedule weeklySchedule)
 {
     FDIDB.DN_Weekly_Schedule.Add(weeklySchedule);
 }