예제 #1
0
        public async Task <JsonResult> SavePlan(Plan model)
        {
            using (PlanRepository planRepo = new PlanRepository())
            {
                if (string.IsNullOrEmpty(model.PlanID))
                {
                    model.PlanID = CommonHelper.GetRandomString("PL");
                }
                var res = await planRepo.AddOrUpdatePlanAsync(model);

                return(Json(new { isOk = res }));
            }
        }