public PurchaseSetting Create(PurchaseSettingCreateApiModel created, int departmentId, int userId) { var setting = new PurchaseSetting { HospitalDepartmentId = departmentId, CreateUserId = userId, CreateTime = DateTime.Now, Name = created.Name, Remark = created.Remark, }; _context.PurchaseSetting.Add(setting); _context.SaveChanges(); return(setting); }
public JsonResult Post(PurchaseSettingCreateApiModel created) { var data = _purchaseSettingService.Create(created, HospitalDepartment.Id, Profile.Id); return(Json(data)); }
public PurchaseSetting Create(PurchaseSettingCreateApiModel created, int departmentId, int userId) { return(_purchaseSettingRespository.Create(created, departmentId, userId)); }