public JsonResult ChangeSignChangeSignadmin(string IDSet) { //int f //=0; var catmodle = OPBiz.GetEntity(TF_PersonnelFile_Transmitting_OutSet.SelectAll().Where(TF_PersonnelFile_Transmitting_OutSet.Id.Equal(IDSet))); catmodle.States = 1; catmodle.WhereExpression = TF_PersonnelFile_Transmitting_OutSet.Id.Equal(IDSet); var f = OPBiz.Update(catmodle); HttpReSultMode ReSultMode = new HttpReSultMode(); if (f > 0) { ReSultMode.Code = 11; ReSultMode.Data = f.ToString(); ReSultMode.Msg = "提交成功!"; SysOperateLogBiz.AddSysOperateLog(UserData.Id.ToString(), UserData.UserName, e3net.Mode.OperatEnumName.提交, "档案转出--提交", true, WebClientIP, "档案转出"); return(Json(ReSultMode, JsonRequestBehavior.AllowGet)); } else { ReSultMode.Code = -13; ReSultMode.Data = "0"; ReSultMode.Msg = "提交失败!"; SysOperateLogBiz.AddSysOperateLog(UserData.Id.ToString(), UserData.UserName, e3net.Mode.OperatEnumName.提交, "档案转出--提交", false, WebClientIP, "档案转出"); return(Json(ReSultMode, JsonRequestBehavior.AllowGet)); } }
public JsonResult EditInfo(RMS_User RMS_UserModle) { bool IsAdd = false; if (!(RMS_UserModle.Id != null && !RMS_UserModle.Id.ToString().Equals("00000000-0000-0000-0000-000000000000"))) //id为空,是添加 { IsAdd = true; } if (IsAdd) { RMS_UserModle.Id = Guid.NewGuid(); RMS_UserModle.CreateTime = DateTime.Now; RMS_UserModle.ModifyTime = DateTime.Now; //rol.RoleDescription = RMS_UserModle.RoleDescription; //rol.RoleOrder = RMS_UserModle.RoleOrder; OPBiz.Add(RMS_UserModle); return(Json("ok", JsonRequestBehavior.AllowGet)); } else { RMS_UserModle.WhereExpression = RMS_UserSet.Id.Equal(RMS_UserModle.Id); // spmodel.GroupId = GroupId; if (OPBiz.Update(RMS_UserModle) > 0) { return(Json("ok", JsonRequestBehavior.AllowGet)); } else { return(Json("Nok", JsonRequestBehavior.AllowGet)); } } }
public JsonResult EditInfo(TF_LifeComments EidModle) { HttpReSultMode ReSultMode = new HttpReSultMode(); bool IsAdd = false; EidModle.UpdateTime = DateTime.Now; if (!(EidModle.Id != null && !EidModle.Id.ToString().Equals("00000000-0000-0000-0000-000000000000")))//id为空,是添加 { IsAdd = true; } if (IsAdd) { EidModle.Id = Guid.NewGuid(); EidModle.CreateMan = UserData.UserName; EidModle.CreateTime = DateTime.Now; EidModle.isValid = true; EidModle.isDeleted = false; EidModle.States = -1; try { OPBiz.Add(EidModle); ReSultMode.Code = 11; ReSultMode.Data = EidModle.Id.ToString(); ReSultMode.Msg = "保存成功,请尽快提交审核!"; SysOperateLogBiz.AddSysOperateLog(UserData.Id.ToString(), UserData.UserName, e3net.Mode.OperatEnumName.新增, "生平管理--新增", true, WebClientIP, "生平管理"); } catch (Exception e) { ReSultMode.Code = -11; ReSultMode.Data = e.ToString(); ReSultMode.Msg = "添加失败"; SysOperateLogBiz.AddSysOperateLog(UserData.Id.ToString(), UserData.UserName, e3net.Mode.OperatEnumName.新增, "生平管理--新增", false, WebClientIP, "生平管理"); } } else { EidModle.WhereExpression = TF_LifeCommentsSet.Id.Equal(EidModle.Id); // EidModle.ChangedMap.Remove("id");//移除主键值 if (OPBiz.Update(EidModle) > 0) { ReSultMode.Code = 11; ReSultMode.Data = ""; ReSultMode.Msg = "保存成功,请尽快提交审核!"; SysOperateLogBiz.AddSysOperateLog(UserData.Id.ToString(), UserData.UserName, e3net.Mode.OperatEnumName.修改, "生平管理--修改", true, WebClientIP, "生平管理"); } else { ReSultMode.Code = -13; ReSultMode.Data = ""; ReSultMode.Msg = "修改失败"; SysOperateLogBiz.AddSysOperateLog(UserData.Id.ToString(), UserData.UserName, e3net.Mode.OperatEnumName.修改, "生平管理--修改", false, WebClientIP, "生平管理"); } } return(Json(ReSultMode, JsonRequestBehavior.AllowGet)); }
public JsonResult EditInfo(TF_EntryAndExitRegistration EidModle) { HttpReSultMode ReSultMode = new HttpReSultMode(); bool IsAdd = false; EidModle.UpdateTime = DateTime.Now; if (!(EidModle.Id != null && !EidModle.Id.ToString().Equals("00000000-0000-0000-0000-000000000000")))//id为空,是添加 { IsAdd = true; } //if (IsAdd) //{ // EidModle.Id = Guid.NewGuid(); // EidModle.CreateMan = UserData.UserName; // EidModle.CreateTime = DateTime.Now; // EidModle.isValid = true; // EidModle.isDeleted = false; // EidModle.ApprovalStates = -1; // try // { // OPBiz.Add(EidModle); // ReSultMode.Code = 11; // ReSultMode.Data = EidModle.Id.ToString(); // ReSultMode.Msg = "添加成功"; // } // catch (Exception e) // { // ReSultMode.Code = -11; // ReSultMode.Data = e.ToString(); // ReSultMode.Msg = "添加失败"; // } //} //else //{ EidModle.WhereExpression = TF_EntryAndExitRegistrationSet.Id.Equal(EidModle.Id); // EidModle.ChangedMap.Remove("id");//移除主键值 if (OPBiz.Update(EidModle) > 0) { SysOperateLogBiz.AddSysOperateLog(UserData.Id.ToString(), UserData.UserName, e3net.Mode.OperatEnumName.修改, "证件审核--修改", true, WebClientIP, "证件审核"); ReSultMode.Code = 11; ReSultMode.Data = ""; ReSultMode.Msg = "修改成功"; } else { ReSultMode.Code = -13; ReSultMode.Data = ""; ReSultMode.Msg = "修改失败"; } //} return Json(ReSultMode, JsonRequestBehavior.AllowGet); }
public JsonResult EditInfo(RMS_User EidModle) { HttpReSultMode ReSultMode = new HttpReSultMode(); bool IsAdd = false; if (!(EidModle.Id != null && !EidModle.Id.ToString().Equals("00000000-0000-0000-0000-000000000000")))//id为空,是添加 { IsAdd = true; } if (IsAdd) { var mql2 = RMS_UserSet.LoginName.Equal(EidModle.LoginName); long i = OPBiz.GetCount <RMS_UserSet>(mql2); if (i > 0) { ReSultMode.Code = -13; ReSultMode.Data = ""; ReSultMode.Msg = "用户名已存在"; } else { EidModle.UserType = 0; EidModle.Id = Guid.NewGuid(); EidModle.CreateTime = DateTime.Now; EidModle.ModifyTime = DateTime.Now; //rol.RoleDescription = EidModle.RoleDescription; //rol.RoleOrder = EidModle.RoleOrder; OPBiz.Add(EidModle); ReSultMode.Code = 11; ReSultMode.Data = EidModle.Id.ToString(); ReSultMode.Msg = "添加成功"; SysOperateLogBiz.AddSysOperateLog(UserData.Id.ToString(), UserData.UserName, e3net.Mode.OperatEnumName.新增, "用户管理--新增", true, WebClientIP, "用户管理"); } } else { EidModle.WhereExpression = RMS_UserSet.Id.Equal(EidModle.Id); // spmodel.GroupId = GroupId; if (OPBiz.Update(EidModle) > 0) { ReSultMode.Code = 11; ReSultMode.Data = ""; ReSultMode.Msg = "修改成功"; SysOperateLogBiz.AddSysOperateLog(UserData.Id.ToString(), UserData.UserName, e3net.Mode.OperatEnumName.修改, "用户管理--修改", true, WebClientIP, "用户管理"); } else { ReSultMode.Code = -13; ReSultMode.Data = ""; ReSultMode.Msg = "修改失败"; SysOperateLogBiz.AddSysOperateLog(UserData.Id.ToString(), UserData.UserName, e3net.Mode.OperatEnumName.修改, "用户管理--修改", false, WebClientIP, "用户管理"); } } return(Json(ReSultMode, JsonRequestBehavior.AllowGet)); }
public JsonResult ScatteredEditInfo(TF_PersonnelFile_Transmitting_Out EidModle) { HttpReSultMode ReSultMode = new HttpReSultMode(); bool IsAdd = false; if (!(EidModle.Id != null && !EidModle.Id.ToString().Equals("00000000-0000-0000-0000-000000000000")))//id为空,是添加 { IsAdd = true; } if (IsAdd) { EidModle.Id = Guid.NewGuid(); EidModle.CreateMan = UserData.UserName; EidModle.CreateManId = UserData.Id; EidModle.CreateTime = DateTime.Now; EidModle.isDeleted = false; EidModle.States = 0; EidModle.SubmitState = "零散"; try { List <TF_PersonnelFile_Transmitting_Out_Item> listItem = JsonHelper.JSONToList <TF_PersonnelFile_Transmitting_Out_Item>(EidModle.FistName); int OriginalCount = 0; int DuplicateCount = 0; int MaterialCount = 0; string allname = ""; if (listItem != null && listItem.Count > 0) { EidModle.FistName = listItem[0].RealName; allname += listItem[0].RealName + "、"; for (int i = 0; i < listItem.Count; i++) { OriginalCount += listItem[i].OriginalCount; DuplicateCount += listItem[i].DuplicateCount; MaterialCount += listItem[i].MaterialCount;//统计数 listItem[i].Id = Guid.NewGuid();; listItem[i].OwnerId = EidModle.Id; OPItemBiz.Add(listItem[i]);//添加项 } EidModle.OriginalCount = OriginalCount; EidModle.DuplicateCount = DuplicateCount; EidModle.MaterialCount = MaterialCount; EidModle.NumberS = listItem.Count; } allname = allname.TrimEnd('、'); EidModle.FileName = allname; OPBiz.Add(EidModle); ReSultMode.Code = 11; ReSultMode.Data = EidModle.Id.ToString(); ReSultMode.Msg = "添加成功"; SysOperateLogBiz.AddSysOperateLog(UserData.Id.ToString(), UserData.UserName, e3net.Mode.OperatEnumName.新增, "档案转出--零散材料新增", true, WebClientIP, "档案转出"); } catch (Exception e) { ReSultMode.Code = -11; ReSultMode.Data = e.ToString(); ReSultMode.Msg = "添加失败"; SysOperateLogBiz.AddSysOperateLog(UserData.Id.ToString(), UserData.UserName, e3net.Mode.OperatEnumName.新增, "档案转出--零散材料新增", false, WebClientIP, "档案转出"); } } else { EidModle.WhereExpression = TF_PersonnelFile_Transmitting_OutSet.Id.Equal(EidModle.Id); List <TF_PersonnelFile_Transmitting_Out_Item> listItem = JsonHelper.JSONToList <TF_PersonnelFile_Transmitting_Out_Item>(EidModle.FistName); EidModle.FistName = listItem[0].RealName; EidModle.TransmittingMan = UserData.UserName; EidModle.TransmittingTime = DateTime.Now; // EidModle.ChangedMap.Remove("id");//移除主键值 if (OPBiz.Update(EidModle) > 0) { int OriginalCount = 0; int DuplicateCount = 0; int MaterialCount = 0; if (listItem != null && listItem.Count > 0) { EidModle.FistName = listItem[0].RealName; for (int i = 0; i < listItem.Count; i++) { // OriginalCount += listItem[i].OriginalCount; // DuplicateCount += listItem[i].DuplicateCount; // MaterialCount += listItem[i].MaterialCount;//统计数 // listItem[i].Id = listItem[i].Id; ; // listItem[i].OwnerId = EidModle.Id; listItem[i].WhereExpression = TF_PersonnelFile_Transmitting_Out_ItemSet.Id.Equal(listItem[i].Id); OPItemBiz.Update(listItem[i]);//添加项 } } ReSultMode.Code = 11; ReSultMode.Data = ""; ReSultMode.Msg = "修改成功"; SysOperateLogBiz.AddSysOperateLog(UserData.Id.ToString(), UserData.UserName, e3net.Mode.OperatEnumName.修改, "档案转出--零散材料修改", true, WebClientIP, "档案转出"); } else { ReSultMode.Code = -13; ReSultMode.Data = ""; ReSultMode.Msg = "修改失败"; SysOperateLogBiz.AddSysOperateLog(UserData.Id.ToString(), UserData.UserName, e3net.Mode.OperatEnumName.修改, "档案转出--零散材料修改", false, WebClientIP, "档案转出"); } } return(Json(ReSultMode, JsonRequestBehavior.AllowGet)); }
public JsonResult EditInfo(TS_ShopUser TS_ShopUserModle) { HttpReSultMode ReSultMode = new HttpReSultMode(); bool IsAdd = false; if (TS_ShopUserModle.Details != null) { TS_ShopUserModle.Details = TS_ShopUserModle.Details.Replace("<", "<").Replace(">", ">"); } else { TS_ShopUserModle.Details = ""; } TS_ShopUserModle.UpdateTime = DateTime.Now; if (TS_ShopUserModle.Longitude != null && TS_ShopUserModle.Latitude != null)//geohash编码 { double Latitude = double.Parse(TS_ShopUserModle.Latitude.ToString()); double Longitude = double.Parse(TS_ShopUserModle.Longitude.ToString()); TS_ShopUserModle.geohash = Geohash.Encode(Latitude, Longitude); } if (!(TS_ShopUserModle.Id != null && !TS_ShopUserModle.Id.ToString().Equals("00000000-0000-0000-0000-000000000000")))//id为空,是添加 { IsAdd = true; } if (IsAdd) { TS_ShopUserModle.Id = Guid.NewGuid(); TS_ShopUserModle.AddTime = DateTime.Now; TS_ShopUserModle.LocationUpdateTime = DateTime.Now; TS_ShopUserModle.isDeleted = false; TS_ShopUserModle.isValid = 1; try { OPBiz.Add(TS_ShopUserModle); ReSultMode.Code = 11; ReSultMode.Data = TS_ShopUserModle.Id.ToString(); ReSultMode.Msg = "添加成功"; } catch (Exception e) { ReSultMode.Code = -11; ReSultMode.Data = e.ToString(); ReSultMode.Msg = "添加失败"; } } else { TS_ShopUserModle.WhereExpression = TS_ShopUserSet.Id.Equal(TS_ShopUserModle.Id); //TS_ShopUserModle.ChangedMap.Remove("doctorid");//移除主键值 if (OPBiz.Update(TS_ShopUserModle) > 0) { ReSultMode.Code = 11; ReSultMode.Data = ""; ReSultMode.Msg = "修改成功"; } else { ReSultMode.Code = -13; ReSultMode.Data = ""; ReSultMode.Msg = "修改失败"; } } return(Json(ReSultMode, JsonRequestBehavior.AllowGet)); }