public ActionResult DetailsGetDataPager(int pageIndex, int pageSize, int id) { ShopInfoBll objShopInfoBll = new ShopInfoBll(); return(Content(JsonConvert.SerializeObject(objShopInfoBll.GetWeixinMPShop(pageIndex, pageSize, id, LoginUser.UserBasic.EnterpriseID)))); }
/// <summary> /// 代理商门店导入 /// </summary> /// <returns></returns> public ActionResult Introduction() { Dictionary <string, string> dic = new Dictionary <string, string>(); dic.Add("渠道ID", "Id"); dic.Add("渠道类型(必填)", "Type"); dic.Add("渠道或者门店名称(必填)", "Name"); dic.Add("所属代理商(必填)", "AgentID"); dic.Add("所属省(必填)", "ProvinceID"); dic.Add("所属市(必填)", "CityID"); dic.Add("所属区/县(必填)", "CountryID"); dic.Add("联系人(必填)", "Contact"); dic.Add("注册手机号码(必填)", "Tel"); System.Data.DataTable dt = null; System.Data.DataTable newDt = new ShopInfoBll().InsertShopInfoFromExcel(LoginUser.UserBasic.EnterpriseID, dt); long timer = DateTime.Now.Ticks; if (dt.Rows.Count > 0) { Session["loadFile"] = newDt; return(Content(new { status = false }.GetJson())); } return(Content(new { status = true }.GetJson())); }
public ActionResult EditShopQRNum(int id) { ShopInfoBll objShopInfoBll = new ShopInfoBll(); var model = objShopInfoBll.GetByID(id, LoginUser.UserBasic.EnterpriseID); return(View(model)); }
public JsonResult UpdateAfter(ShopInfo model) { ShopInfoBll shopBll = new ShopInfoBll(); model.EnterpriseID = AgentLoginUser.UserBasic.EnterpriseID; return(Json(shopBll.Update(model))); }
public string SavePath(HttpPostedFileBase file) { Dictionary <string, string> dic = new Dictionary <string, string>(); dic.Add("渠道ID", "Id"); dic.Add("渠道类型(必填)", "Type"); dic.Add("渠道或者门店名称(必填)", "Name"); dic.Add("所属代理商(必填)", "AgentID"); dic.Add("所属省(必填)", "ProvinceID"); dic.Add("所属市(必填)", "CityID"); dic.Add("所属区/县(必填)", "CountryID"); dic.Add("联系人(必填)", "Contact"); dic.Add("注册手机号码(必填)", "Tel"); DataTable dt = file.GetDataTable(dic); DataTable newDt = new ShopInfoBll().InsertShopInfoFromExcel(LoginUser.UserBasic.EnterpriseID, dt); long timer = DateTime.Now.Ticks; if (newDt.Rows.Count > 0) { Session["loadFile"] = newDt; return(new { status = false }.GetJson()); } return(new { status = true }.GetJson()); }
/// <summary> /// 批量移动到渠道分组 /// 负责人:谢海荣 /// </summary> /// <param name="ChannelId">渠道分组ID</param> /// <param name="shopIdList">实体店ID集合</param> /// <returns></returns> public JsonResult MobileShop(int ChannelId, string shopIdList) { ShopInfoBll shopBll = new ShopInfoBll(); string[] shopIdLists = shopIdList.Split(','); return(Json(shopBll.Pause(ChannelId, shopIdLists))); }
public ActionResult WeixinMPProvinceDetail(int WeixinMPID = 0, int ProvoiceID = 0) { //Bll要在这里实例化 不要在action外面 避免生成很多废代码 ShopInfoBll objShopInfoBll = new ShopInfoBll(); var data = objShopInfoBll.GetShopCityCountOfProvince(WeixinMPID, ProvoiceID, LoginUser.UserBasic.EnterpriseID); return View(data); }
public ActionResult WeixinMPProvinceDetail(int WeixinMPID = 0, int ProvoiceID = 0) { //Bll要在这里实例化 不要在action外面 避免生成很多废代码 ShopInfoBll objShopInfoBll = new ShopInfoBll(); var data = objShopInfoBll.GetShopCityCountOfProvince(WeixinMPID, ProvoiceID, LoginUser.UserBasic.EnterpriseID); return(View(data)); }
/// <summary> /// 关闭代理商门店 /// 负责人:谢海荣 /// </summary> /// <param name="shopId">直营店ID</param> /// <returns></returns> public JsonResult Delete(int shopId) { ShopInfoBll shopBll = new ShopInfoBll(); int status1 = 3; int status2 = 6; return(Json(shopBll.Pause(status1, status2, shopId))); }
/// <summary> /// 批量关闭直营店 /// 负责人:谢海荣 /// </summary> /// <param name="shopIdList">直营店ID集合</param> /// <returns></returns> public JsonResult PauseDelete(string shopIdList) { ShopInfoBll shopBll = new ShopInfoBll(); string[] shopIdLists = shopIdList.Split(','); int statusGuid = 3; int status = 6; return(Json(shopBll.PauseDele(statusGuid, status, shopIdLists))); }
public ActionResult EditShopQRNumBatch(int id, string shopID) { ShopInfoBll objShopInfoBll = new ShopInfoBll(); var model = objShopInfoBll.GetNotWeixinMPListByIDStr(shopID, LoginUser.UserBasic.EnterpriseID); WeixinMPBll objWeixinMPBll = new WeixinMPBll(); //总可分配数 ViewBag.Total = objWeixinMPBll.GetQRNumCan(id, LoginUser.UserBasic.EnterpriseID); //当前微信公众号ID ViewBag.WeixinMPID = id; return(View(model)); }
/// <summary> /// 代理商门店详情页 /// 负责人:谢海荣 /// </summary> /// <param name="model">model</param> /// <returns></returns> public ActionResult Details(int ShopId) { ShopInfoBll bll = new ShopInfoBll(); if (Convert.ToInt32(bll.GetModeltCount(ShopId, "e0001")) == 0) { return(Content("<script>alert('不存在此门店');history.go(-1)</script>")); } else { return(View(bll.GetModel(ShopId, LoginUser.UserBasic.EnterpriseID))); } }
/// <summary> /// 代理商门店详情页 /// 负责人:谢海荣 /// </summary> /// <param name="model">model</param> /// <returns></returns> public ActionResult Details(int ShopId) { ShopInfoBll bll = new ShopInfoBll(); int GetCount = Convert.ToInt32(bll.GetModeltCount(ShopId, AgentLoginUser.UserBasic.EnterpriseID, AgentLoginUser.RoleID)); if (GetCount == 0) { return(Content("<script>alert('不存在此门店信息!');history.go(-1)</script>")); } else { ShopInfoView model = new ShopInfoView(); model = bll.GetModel(ShopId, AgentLoginUser.UserBasic.EnterpriseID, AgentLoginUser.RoleID); return(View(model)); } }
/// <summary> /// 审核门店 /// </summary> /// <param name="Remarks">审核备注</param> /// <param name="ShopId">门店ID</param> /// <returns></returns> public JsonResult ToExamine(string Remarks, int ShopId, int pd) { ShopInfoBll shopBll = new ShopInfoBll(); int status; if (pd == 1) { status = 2; } else { status = 4; } return(Json(shopBll.ToExamine(status, Remarks, ShopId))); }
/// <summary> /// 暂停,恢复 /// 负责人:谢海荣 /// </summary> /// <param name="shopIdList"></param> /// <param name="Pd"></param> /// <returns></returns> public JsonResult Edit(int shopId, int Pd) { ShopInfoBll shopBll = new ShopInfoBll(); int status1, status2; if (Pd == 1) { status1 = 2; status2 = 5; } else { status1 = 0; status2 = 0; } return Json(shopBll.Pause(status1, status2, shopId)); }
/// <summary> /// 暂停,恢复 /// 负责人:谢海荣 /// </summary> /// <param name="shopIdList"></param> /// <param name="Pd"></param> /// <returns></returns> public JsonResult Edit(int shopId, int Pd) { ShopInfoBll shopBll = new ShopInfoBll(); int status1, status2; if (Pd == 1) { status1 = 2; status2 = 5; } else { status1 = 0; status2 = 0; } return(Json(shopBll.Pause(status1, status2, shopId))); }
public JsonResult Agent_CreateAfter(ShopInfo model) { ShopInfoBll bll = new ShopInfoBll(); model.Relation = 2; model.ContactPhone = ""; model.Address = ""; model.Range = ""; model.shopIMG = ""; model.WeixinMPID = 0; model.Remarks = ""; model.ContactTEL = ""; model.Status = 1; model.ProvinceID = model.ProvinceID; model.CityID = model.CityID; model.CountyID = model.CountyID; model.EnterpriseID = LoginUser.UserBasic.EnterpriseID; return(Json(bll.Create(model))); }
public string SavePath(HttpPostedFileBase file) { Dictionary<string, string> dic = new Dictionary<string, string>(); dic.Add("渠道ID", "Id"); dic.Add("渠道类型(必填)", "Type"); dic.Add("渠道或者门店名称(必填)", "Name"); dic.Add("所属代理商(必填)", "AgentID"); dic.Add("所属省(必填)", "ProvinceID"); dic.Add("所属市(必填)", "CityID"); dic.Add("所属区/县(必填)", "CountryID"); dic.Add("联系人(必填)", "Contact"); dic.Add("注册手机号码(必填)", "Tel"); DataTable dt = file.GetDataTable(dic); DataTable newDt = new ShopInfoBll().InsertShopInfoFromExcel(LoginUser.UserBasic.EnterpriseID, dt); long timer = DateTime.Now.Ticks; if (newDt.Rows.Count > 0) { Session["loadFile"] = newDt; return new { status = false }.GetJson(); } return new { status = true }.GetJson(); }
public JsonResult CreateAfter(ShopInfo model) { Utility.ReturnData <string> returnData = new Utility.ReturnData <string>(); ShopInfoBll shopBll = new ShopInfoBll(); UserPC _model = CacheHelp.Get("user") as UserPC; model.Relation = 1; model.ContactPhone = ""; model.Address = ""; model.Range = ""; model.shopIMG = ""; model.WeixinMPID = 0; model.Remarks = ""; model.AgentID = 0; model.ContactTEL = ""; model.Status = 2; model.ProvinceID = model.ProvinceID; model.CityID = model.CityID; model.CountyID = model.CountyID; model.EnterpriseID = LoginUser.UserBasic.EnterpriseID; returnData = shopBll.Create(model); return(Json(returnData)); }
public ActionResult GetNotWeixinMP(int pageIndex, int pageSize) { ShopInfoBll objShopInfoBll = new ShopInfoBll(); return(Content(JsonConvert.SerializeObject(objShopInfoBll.GetNotWeixinMPEnterpriseShop(pageIndex, pageSize, LoginUser.UserBasic.EnterpriseID)))); }
/// <summary> /// 代理商门店详情页 /// 负责人:谢海荣 /// </summary> /// <param name="model">model</param> /// <returns></returns> public ActionResult Details(int ShopId) { ShopInfoBll bll = new ShopInfoBll(); int GetCount = Convert.ToInt32(bll.GetModeltCount(ShopId, AgentLoginUser.UserBasic.EnterpriseID, AgentLoginUser.RoleID)); if (GetCount == 0) { return Content("<script>alert('不存在此门店信息!');history.go(-1)</script>"); } else { ShopInfoView model = new ShopInfoView(); model = bll.GetModel(ShopId, AgentLoginUser.UserBasic.EnterpriseID, AgentLoginUser.RoleID); return View(model); } }
public JsonResult CreateAfter(ShopInfo model) { Utility.ReturnData<string> returnData = new Utility.ReturnData<string>(); ShopInfoBll shopBll = new ShopInfoBll(); //UserPC _model = CacheHelp.Get("user") as UserPC; model.Relation = 2; model.ContactPhone = ""; model.Address = ""; model.Range = ""; model.shopIMG = ""; model.WeixinMPID = 0; model.Remarks = ""; model.AgentID = AgentLoginUser.RoleID; model.ContactTEL = ""; model.Status = 1; model.ChannelGroupID = 0; model.ProvinceID = model.ProvinceID; model.CityID = model.CityID; model.CountyID = model.CountyID; model.EnterpriseID = AgentLoginUser.UserBasic.EnterpriseID; returnData = shopBll.Create(model); return Json(returnData); }
/// <summary> /// 批量关闭直营店 /// 负责人:谢海荣 /// </summary> /// <param name="shopIdList">直营店ID集合</param> /// <returns></returns> public JsonResult PauseDelete(string shopIdList) { ShopInfoBll shopBll = new ShopInfoBll(); string[] shopIdLists = shopIdList.Split(','); int statusGuid = 3; int status = 6; return Json(shopBll.PauseDele(statusGuid, status, shopIdLists)); }
/// <summary> /// 代理商门店详情页 /// 负责人:谢海荣 /// </summary> /// <param name="model">model</param> /// <returns></returns> public ActionResult Details(int ShopId) { ShopInfoBll bll = new ShopInfoBll(); if (Convert.ToInt32(bll.GetModeltCount(ShopId, "e0001")) == 0) { return Content("<script>alert('不存在此门店');history.go(-1)</script>"); } else { return View(bll.GetModel(ShopId, LoginUser.UserBasic.EnterpriseID)); } }
public ActionResult GetNotWeixinMP(int pageIndex, int pageSize) { ShopInfoBll objShopInfoBll = new ShopInfoBll(); return Content(JsonConvert.SerializeObject(objShopInfoBll.GetNotWeixinMPEnterpriseShop(pageIndex, pageSize, LoginUser.UserBasic.EnterpriseID))); }
public ActionResult EditAgentShopAfter(ShopInfo model) { ShopInfoBll shopBll = new ShopInfoBll(); model.EnterpriseID = LoginUser.UserBasic.EnterpriseID; return Json(shopBll.Update(model)); }
public ActionResult DetailsGetTotal(int id) { ShopInfoBll objShopInfoBll = new ShopInfoBll(); return(Content(objShopInfoBll.GetWeixinMPShopTotal(id, LoginUser.UserBasic.EnterpriseID).ToString())); }
/// <summary> /// 用于输入框实体店名称关键字搜索 /// 竺杨平添加 /// </summary> /// <param name="q">关键字</param> /// <param name="limit">取前第几行</param> /// <param name="status">实体店状态</param> /// <returns></returns> public ActionResult GetShopName(string q, int limit = 20, int status = 0) { ShopInfoBll objShopInfoBll = new ShopInfoBll(); return(Content(JsonConvert.SerializeObject(objShopInfoBll.GetShopName(q, limit, status)))); }
/// <summary> /// 用于输入框实体店名称关键字搜索 /// 竺杨平添加 /// </summary> /// <param name="q">关键字</param> /// <param name="limit">取前第几行</param> /// <param name="status">实体店状态</param> /// <returns></returns> public ActionResult GetShopName(string q, int limit = 20, int status = 0) { ShopInfoBll objShopInfoBll = new ShopInfoBll(); return Content(JsonConvert.SerializeObject(objShopInfoBll.GetShopName(q, limit, status))); }
/// <summary> /// 批量移动到渠道分组 /// 负责人:谢海荣 /// </summary> /// <param name="ChannelId">渠道分组ID</param> /// <param name="shopIdList">实体店ID集合</param> /// <returns></returns> public JsonResult MobileShop(int ChannelId, string shopIdList) { ShopInfoBll shopBll = new ShopInfoBll(); string[] shopIdLists = shopIdList.Split(','); return Json(shopBll.Pause(ChannelId, shopIdLists)); }
/// <summary> /// 代理商门店导入 /// </summary> /// <returns></returns> public ActionResult Introduction() { Dictionary<string, string> dic = new Dictionary<string, string>(); dic.Add("渠道ID", "Id"); dic.Add("渠道类型(必填)", "Type"); dic.Add("渠道或者门店名称(必填)", "Name"); dic.Add("所属代理商(必填)", "AgentID"); dic.Add("所属省(必填)", "ProvinceID"); dic.Add("所属市(必填)", "CityID"); dic.Add("所属区/县(必填)", "CountryID"); dic.Add("联系人(必填)", "Contact"); dic.Add("注册手机号码(必填)", "Tel"); System.Data.DataTable dt = null; System.Data.DataTable newDt = new ShopInfoBll().InsertShopInfoFromExcel(LoginUser.UserBasic.EnterpriseID, dt); long timer = DateTime.Now.Ticks; if (dt.Rows.Count > 0) { Session["loadFile"] = newDt; return Content(new { status = false }.GetJson()); } return Content(new { status = true }.GetJson()); }
/// <summary> /// 门店编辑页面 /// 负责人:谢海荣 /// </summary> /// <param name="model">直营店实例</param> /// <returns></returns> public ActionResult Update(int ID) { ShopInfoBll bll = new ShopInfoBll(); return View(bll.GetModel(ID, AgentLoginUser.UserBasic.EnterpriseID, AgentLoginUser.RoleID)); }
public ActionResult DetailsGetDataPager(int pageIndex, int pageSize, int id) { ShopInfoBll objShopInfoBll = new ShopInfoBll(); return Content(JsonConvert.SerializeObject(objShopInfoBll.GetWeixinMPShop(pageIndex, pageSize, id, LoginUser.UserBasic.EnterpriseID))); }
public JsonResult UpdateAfter(ShopInfo model) { ShopInfoBll shopBll = new ShopInfoBll(); model.EnterpriseID = AgentLoginUser.UserBasic.EnterpriseID; return Json(shopBll.Update(model)); }
public ActionResult EditShopQRNumBatch(int id, string shopID) { ShopInfoBll objShopInfoBll = new ShopInfoBll(); var model = objShopInfoBll.GetNotWeixinMPListByIDStr(shopID, LoginUser.UserBasic.EnterpriseID); WeixinMPBll objWeixinMPBll = new WeixinMPBll(); //总可分配数 ViewBag.Total = objWeixinMPBll.GetQRNumCan(id, LoginUser.UserBasic.EnterpriseID); //当前微信公众号ID ViewBag.WeixinMPID = id; return View(model); }
public ActionResult GetNotWeixinMPTotal() { ShopInfoBll objShopInfoBll = new ShopInfoBll(); return Content(objShopInfoBll.GetNotWeixinMPEnterpriseShopTotal(LoginUser.UserBasic.EnterpriseID).ToString()); }
public ActionResult GetNotWeixinMPTotal() { ShopInfoBll objShopInfoBll = new ShopInfoBll(); return(Content(objShopInfoBll.GetNotWeixinMPEnterpriseShopTotal(LoginUser.UserBasic.EnterpriseID).ToString())); }
public ActionResult DetailsGetTotal(int id) { ShopInfoBll objShopInfoBll = new ShopInfoBll(); return Content(objShopInfoBll.GetWeixinMPShopTotal(id, LoginUser.UserBasic.EnterpriseID).ToString()); }
public JsonResult Agent_CreateAfter(ShopInfo model) { ShopInfoBll bll = new ShopInfoBll(); model.Relation = 2; model.ContactPhone = ""; model.Address = ""; model.Range = ""; model.shopIMG = ""; model.WeixinMPID = 0; model.Remarks = ""; model.ContactTEL = ""; model.Status = 1; model.ProvinceID = model.ProvinceID; model.CityID = model.CityID; model.CountyID = model.CountyID; model.EnterpriseID = LoginUser.UserBasic.EnterpriseID; return Json(bll.Create(model)); }
public ActionResult EditShopQRNum(int id) { ShopInfoBll objShopInfoBll = new ShopInfoBll(); var model = objShopInfoBll.GetByID(id, LoginUser.UserBasic.EnterpriseID); return View(model); }
/// <summary> /// 门店编辑页面 /// 负责人:谢海荣 /// </summary> /// <param name="model">直营店实例</param> /// <returns></returns> public ActionResult Update(int ID) { ShopInfoBll bll = new ShopInfoBll(); return(View(bll.GetModel(ID, AgentLoginUser.UserBasic.EnterpriseID, AgentLoginUser.RoleID))); }
/// <summary> /// 审核门店 /// </summary> /// <param name="Remarks">审核备注</param> /// <param name="ShopId">门店ID</param> /// <returns></returns> public JsonResult ToExamine(string Remarks, int ShopId,int pd) { ShopInfoBll shopBll = new ShopInfoBll(); int status; if (pd == 1) { status = 2; } else { status = 4; } return Json(shopBll.ToExamine(status, Remarks, ShopId)); }
/// <summary> /// 关闭代理商门店 /// 负责人:谢海荣 /// </summary> /// <param name="shopId">直营店ID</param> /// <returns></returns> public JsonResult Delete(int shopId) { ShopInfoBll shopBll = new ShopInfoBll(); int status1 = 3; int status2 = 6; return Json(shopBll.Pause(status1, status2, shopId)); }