public JsonResult Add(string planTitle, string startTime, string endTime, string planDate, string remark, int planId = 0) { Plan plan = null; if (planId != 0) { plan = dbp.GetOnePlan(planId); } else { plan = new Plan(); } plan.PlanTitle = planTitle; plan.EmpId = 1; plan.StartTime = TimeAddHM(planDate, startTime); plan.EndTime = TimeAddHM(planDate, endTime); plan.Remark = remark; plan.CreateTime = DateTime.Now; dbp.Save(plan); return(Json("Index")); }
public void Save(Plan planGuard) { PlanData.Save(planGuard); }
public void Save(Plan plan) { PlanData.Save(plan); }