public JsonResult DocInfos(string str) { retValue ret = new retValue(); BLL.DocBLL _DocBLL = new DocBLL(); JObject o = null; string content = string.Empty; if (!string.IsNullOrEmpty(str)) { o = JObject.Parse(str); string test1 = o["test1"]._ToStrTrim(); string test2 = o["test2"]._ToStrTrim(); string Type = o["Type"]._ToStrTrim(); string Name = o["Name"]._ToStrTrim(); string ISSN = o["ISSN"]._ToStrTrim(); string BKDH = o["BKDH"]._ToStrTrim().ToUpper(); string PublishArea = o["PublishArea"]._ToStrTrim(); ret = _DocBLL.GetDoc("", Type, Name, ISSN, PublishArea, "", "", test1, test2, BKDH); } content = ret.toJson(); var js = JsonConvert.SerializeObject(ret); return(Json(js, JsonRequestBehavior.AllowGet)); }
public JsonResult Order_Deletes(string str) { BLL.OrderInfoBLL _BLL = new OrderInfoBLL(); retValue ret = new retValue(); string content = string.Empty; DataTable dt = str.ToTable(); string ids = ""; string costs = ""; foreach (DataRow item in dt.Rows) { if (!string.IsNullOrEmpty(item["ID"]._ToStrTrim())) { ids += item["ID"]._ToStrTrim() + ","; costs += item["CostID"]._ToStrTrim() + ","; } } ret = _BLL.DeleteByPK(ids.Remove(ids.Length - 1)); if (ret.result) { CostBLL costBLL = new CostBLL(); costBLL.DeleteByPK(costs); } content = ret.toJson(); var js = JsonConvert.SerializeObject(ret); return(Json(js, JsonRequestBehavior.AllowGet)); }
public JsonResult UserInfo_Deletes(string str) { retValue ret = new retValue(); BLL.UserBLL _UserBLL = new UserBLL(); string content = string.Empty; if (!string.IsNullOrEmpty(str)) { ret = _UserBLL.DeleteByPK(str); } content = ret.toJson(); var js = JsonConvert.SerializeObject(ret); return(Json(js, JsonRequestBehavior.AllowGet)); }
public JsonResult OrderPeopleInfo_AddEdits(string str) { BLL.SubscriberBLL _SubscriberBLL = new SubscriberBLL(); JObject o = null; string content = string.Empty; retValue ret = new retValue(); PMS.Models.UserModel userModel = Session["UserModel"] as PMS.Models.UserModel; int userid = userModel._ID; if (!string.IsNullOrEmpty(str)) { o = JObject.Parse(str); string ID = o["ID"]._ToStrTrim(); string MGUID = o["MGUID"]._ToStrTrim(); string OrderNo = o["OrderNo"]._ToStrTrim(); string UnitName = o["UnitName"]._ToStrTrim(); string Address = o["Address"]._ToStrTrim(); string Name = o["Name"]._ToStrTrim(); string Phone = o["Phone"]._ToStrTrim(); string Roads = o["Roads"]._ToStrTrim(); string State = o["State"]._ToStrTrim(); //新增 if (string.IsNullOrEmpty(ID)) { ret = _SubscriberBLL.Insert(OrderNo, UnitName, Name, Phone, Address, Roads, userid); } //更新 else { ret = _SubscriberBLL.UpdateByPK(ID._ToInt32(), OrderNo, UnitName, Name, Phone, Address, "", MGUID); } } content = ret.toJson(); var js = JsonConvert.SerializeObject(ret); return(Json(js, JsonRequestBehavior.AllowGet)); }
public JsonResult UserInfo_Update(string str) { retValue ret = new retValue(); BLL.UserBLL _UserBLL = new UserBLL(); string content = string.Empty; int count = 0; if (!string.IsNullOrEmpty(str)) { string[] ids = str.Split(','); foreach (string item in ids) { ret = _UserBLL.UpdateByPK(item._ToInt32(), "", "", "", "", "", "", "1", "", "", ""); if (ret.result) { count++; } } } if (count > 0) { ret.result = true; ret.data = "注销成功"; } else { ret.result = false; ret.reason = "注销失败"; } content = ret.toJson(); var js = JsonConvert.SerializeObject(ret); return(Json(js, JsonRequestBehavior.AllowGet)); }