예제 #1
0
        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"));
        }
예제 #2
0
 public void Save(Plan planGuard)
 {
     PlanData.Save(planGuard);
 }
예제 #3
0
 public void Save(Plan plan)
 {
     PlanData.Save(plan);
 }