private void Load() { string Id = Request["Id"]; if (!string.IsNullOrEmpty(Id)) { string data = JsonHelper.GetJsonString(ExamineMeeting.Find(Id)); string sa = "{success: true ,data:" + data + "}"; Response.Write(sa); Response.End(); } }
private void Update() { string DistributeAmount = Request["DistributeAmount"]; Ent = JsonHelper.GetObject <ExamineMeeting>(Request["data"]); ExamineMeeting original_Ent = ExamineMeeting.Find(Ent.Id); EasyDictionary dic = JsonHelper.GetObject <EasyDictionary>(Request["data"]); original_Ent = DataHelper.MergeData <ExamineMeeting>(original_Ent, Ent, dic.Keys); original_Ent.DistributeAmount = Convert.ToDecimal(DistributeAmount); original_Ent.DoUpdate(); sql = "delete NCRL_SP..projectUser where projectid='" + original_Ent.Id + "'"; DataHelper.ExecSql(sql); string json = Request["json"]; IList <ProjectUser> sk = JsonHelper.GetObject <IList <ProjectUser> >(json); foreach (ProjectUser skEnt in sk) { skEnt.ProjectId = Ent.Id; skEnt.DoCreate(); } }