public ActionResult Create(string name, StringList keywords) { byte[] icon; string filename; GetFileFromRequest(out icon, out filename); var res = MasterLocator.ChalkableDepartmentService.Add(name, keywords, icon); return(Json(ChalkableDepartmentViewData.Create(res), contentType)); }
protected ClassInfoViewData(ClassDetails cClass, Room room, ChalkableDepartment department) : base(cClass) { if (room != null) { Room = RoomViewData.Create(room); } if (department != null) { Department = ChalkableDepartmentViewData.Create(department); } }
public ActionResult Update(Guid chalkableDepartmentId, string name, StringList keywords) { byte[] icon; string filename; GetFileFromRequest(out icon, out filename); if (icon == null) { icon = MasterLocator.DepartmentIconService.GetPicture(chalkableDepartmentId.ToString(), null, null); } var res = MasterLocator.ChalkableDepartmentService.Edit(chalkableDepartmentId, name, keywords, icon); return(Json(ChalkableDepartmentViewData.Create(res), contentType)); }
public ActionResult Info(Guid chalkableDepartmentId) { var res = MasterLocator.ChalkableDepartmentService.GetChalkableDepartmentById(chalkableDepartmentId); return(Json(ChalkableDepartmentViewData.Create(res))); }
public ActionResult List() { var res = MasterLocator.ChalkableDepartmentService.GetChalkableDepartments(); return(Json(ChalkableDepartmentViewData.Create(res))); }