protected override void SetValue(string id) { Sys_BankInfoBLL sbiBLL = new Sys_BankInfoBLL(); txtBank.DataSource = sbiBLL.GetList(" 1 = 1 and IsDeleted = 0 order by Code"); txtBank.DataTextField = "Name"; txtBank.DataValueField = "Name"; txtBank.DataBind(); BindDdlPwdQuestion(ddlQuestion); foreach (Model.Roles item in BLL.Roles.RolsList.Values.ToList().Where(emp => emp.VState).ToList()) { ddlMemberType.Items.Add(new ListItem(item.RName, item.RType));//角色 } ////会员级别 //ddlSHMoney.DataSource = BLL.Configuration.Model.SHMoneyTable; //ddlSHMoney.DataTextField = "MAgencyName"; //ddlSHMoney.DataValueField = "MAgencyType"; //ddlSHMoney.DataBind(); string mid = HttpUtility.UrlDecode(Request["id"].Trim()); model = BllModel.GetModel(mid); MemberModel = model; }
protected override void SetPowerZone() { RioMJB.Checked = true; foreach (Model.BankModel item in BLL.Member.ManageMember.GetMyBankInfo()) { ddlToBank.Items.Add(item.Bank); } Model.Member model = TModel; txtBankName.Value = model.BankCardName; txtFromBank.Value = model.Bank; txtHKDate.Value = DateTime.Now.ToString("yyyy-MM-dd HH:mm"); Model.Member manage = BllModel.GetModel(BLL.Member.ManageMember.TModel.MID); adminBank = manage.Bank; try { //adminBank = new CommonBLL.Sys_BankInfoBLL().GetModel(manage.Bank).Name; adminBranch = manage.Branch; adminBankNumber = manage.BankNumber; adminBankCardName = manage.BankCardName; alipay = manage.Alipay; weixin = manage.WeChat; } catch { } }
protected override string btnAdd_Click() { string offer = Request.Form["txtoffer"].Trim(); string get = Request.Form["txtget"].Trim(); if (string.IsNullOrEmpty(offer)) { return("买入许愿果会员帐号不能为空"); } else { if (BllModel.GetModel(offer) == null) { return("买入许愿果会员帐号不存在"); } } if (string.IsNullOrEmpty(get)) { return("卖出许愿果会员帐号不能为空"); } else { if (BllModel.GetModel(get) == null) { return("卖出许愿果会员帐号不存在"); } } return(BLL.MHelpMatch.MatchingHelp3(offer, get)); }
protected override void SetValue(string id) { url = "Member/SHListSJ.aspx"; sjmodel = BllModel.GetModel(id); hdmid.Value = sjmodel.MID; if (TModel.Role.IsAdmin && !sjmodel.MState) { //填写接点人 isNew = false; } foreach (Model.SHMoney item in BLL.Configuration.Model.SHMoneyList.Values.Where(emp => emp.MAgencyType != "001")) { MAgencyTypeColor += "<td style='width:60px;color:#00CCFF;'>" + item.MAgencyName + "<br />[" + item.Money + "]</td>"; if (item.Money <= sjmodel.MAgencyType.Money || !BLL.ChangeMoney.EnoughChange(TModel.MID, item.Money - sjmodel.MAgencyType.Money, "MJB")) { continue; } else { MyMAgencyTypeRdo += "<input name='AgencyTypeList' id='" + item.MAgencyType + "' value='" + item.MAgencyType + "' type='radio' />" + item.MAgencyName + "[" + (item.Money - sjmodel.MAgencyType.Money) + "] "; } } if (string.IsNullOrEmpty(MyMAgencyTypeRdo)) { MyMAgencyTypeRdo += "暂不可升级"; } }
protected override void SetPowerZone() { bankauto.Value = string.IsNullOrEmpty(TModel.BankNumber) ? "0" : "1"; getsuiji.Value = GetRanLJ(); mantissa = GetMantissa(); Session["mantissa"] = mantissa; //code = GetHKCode(); //Session["code"] = code; //txtTel.Value = TModel.Tel; //RioMJB.Checked = true; //foreach (Model.BankModel item in BLL.Member.ManageMember.GetMyBankInfo()) //{ // ddlToBank.Items.Add(item.Bank); //} //Model.Member model = TModel; //txtBankName.Value = model.BankCardName; //txtFromBank.Value = model.Bank; //txtHKDate.Value = DateTime.Now.ToString("yyyy-MM-dd HH:mm"); Model.Member manage = BllModel.GetModel(BLL.Member.ManageMember.TModel.MID); try { adminBank = manage.Bank; adminBranch = manage.Branch; adminBankNumber = manage.BankNumber; adminBankCardName = manage.BankCardName; alipayname = manage.QRCode; alipay = manage.Alipay; weixin = manage.WeChat; } catch { } }
public override void ProcessRequest(HttpContext context) { base.ProcessRequest(context); List <string> typeList = new List <string>() { "SH" }; List <string> mType = new List <string> { "MJB" }; string mKey = ""; string strWhere = " '1'='1' "; if (!string.IsNullOrEmpty(context.Request["mKey"])) { mKey = context.Request["mKey"]; } if (!string.IsNullOrEmpty(context.Request["startDate"])) { strWhere += " and changedate>'" + context.Request["startDate"] + " 00:00:00' "; } if (!string.IsNullOrEmpty(context.Request["endDate"])) { strWhere += " and changedate<'" + context.Request["endDate"] + " 23:59:59' "; } Model.Member memberModel = (TModel == null ? BllModel.TModel : TModel); if (!memberModel.Role.Super) { mKey = memberModel.MID; } int count; List <Model.ChangeMoney> ListChangeMoney = BllModel.GetChangeMoneyEntityList(mKey, BLL.Member.ManageMember.TModel.MID, "", "true", typeList, mType, pageIndex, pageSize, strWhere, out count); StringBuilder sb = new StringBuilder(); for (int i = 0; i < ListChangeMoney.Count; i++) { Model.Member member = BllModel.GetModel(ListChangeMoney[i].SHMID); sb.Append(ListChangeMoney[i].CID + "~"); sb.Append((i + 1) + (pageIndex - 1) * pageSize + "~"); sb.Append(member.MID + "~"); sb.Append(member.MName + "~"); sb.Append(member.Tel + "~"); sb.Append(member.MAgencyType.MAgencyName + "~"); sb.Append(ListChangeMoney[i].Money.ToFixedDecimal() + "~"); sb.Append(ListChangeMoney[i].CRemarks + "~"); sb.Append((ListChangeMoney[i].CState ? "已生效" : "未生效") + "~"); sb.Append(ListChangeMoney[i].ChangeDate.ToString("yyyy-MM-dd HH:mm")); sb.Append("≌"); } var info = new { PageData = Traditionalized(sb), TotalCount = count }; context.Response.Write(JavaScriptConvert.SerializeObject(info)); }
/// <summary> /// 货币转移 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> protected override string btnAdd_Click() { if (!string.IsNullOrEmpty(Request.Form["txtMID"])) { if (BllModel.GetModel(Request.Form["txtMID"]) == null) { return("会员不存在"); } } return(BLL.Task.Add(TaskModel)); }
protected override void SetValue(string id) { string mid = HttpUtility.UrlDecode(Request["id"].Trim()); model = BllModel.GetModel(mid); if (model != null) { txtMID.Value = model.MID; txtMName.Value = model.MName; txtTel.Value = model.Tel; } }
protected override string btnAdd_Click() { if (!TModel.Role.IsAdmin) { return("您没有权限"); } Model.Member model = BllModel.GetModel(Request.Form["txtMID"]); if (model == null) { return("会员帐号不存在"); } string moneyType = "MHB"; switch (Request.Form["kfType"]) { case "MJB": moneyType = "MJB"; break; case "MHB": moneyType = "MHB"; break; default: return("参数异常"); } if (!string.IsNullOrEmpty(Request.Form["txtMHB"])) { int money = int.Parse(Request.Form["txtMHB"]); if (money > 0) { Hashtable MyHs = new Hashtable(); BLL.ChangeMoney.HBChangeTran(money, model.MID, BLL.Member.ManageMember.TModel.MID, "KF", null, moneyType, Request.Form["txtRemark"], MyHs); if (BLL.CommonBase.RunHashtable(MyHs)) { return("扣费成功"); } else { return("扣费失败"); } } else { return("扣费金额必须大于0"); } } else { return("参数异常"); } }
/// <summary> /// 货币转移 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> protected override string btnAdd_Click() { //验证身份证号 //if (Request.Form["txtNumID"].Trim() != TModel.NumID) //{ // return "身份证号校验失败!"; //} //if (Check_SQ_Answer()) { string MType = "MGP"; //if (Request.Form["RioHK"] == "1") //{ // MType = "MJB"; //} //else //{ // MType = "MGP"; //} Model.Member fmodel = null; Model.Member tmodel = null; if (!TModel.Role.IsAdmin) { fmodel = TModel; } else { fmodel = BllModel.GetModel(Request.Form["txtFromMID"]); } tmodel = BllModel.GetModel(Request.Form["txtMID"]); if (fmodel == null || tmodel == null) { return("转入或转出会员不存在!"); } if (tmodel.IsClock) { return("对方账户已冻结,无法转账!"); } if (!string.IsNullOrEmpty(Request.Form["txtMHB"])) { int money = int.Parse(Request.Form["txtMHB"]); return(BLL.ChangeMoney.ZZMoneyChange(money, fmodel.MID, Request.Form["txtMID"], "ZZ", MType)); } else { return("转账金额不能为空"); } } //else // return "密保问题错误"; }
protected override void SetValue(string id) { Model.Member model = BllModel.GetModel(id); if (model != null) { if (TModel.MID == model.FMID || TModel.FMID == model.MID || TModel.Role.IsAdmin) { BllModel.TModel = model; FormsAuthentication.SetAuthCookie(model.MID, true); } } Response.Redirect("Default.aspx"); }
public override void ProcessRequest(HttpContext context) { base.ProcessRequest(context); string strWhere = " MID<>''"; string sh = " and IsValid=0 "; if (!string.IsNullOrEmpty(context.Request["tState"])) { if (context.Request["tState"] == "true") { sh = " and IsValid=1 "; } } if (!string.IsNullOrEmpty(context.Request["mKey"])) { strWhere += string.Format(" and MID='{0}' ", (context.Request["mKey"])); } if (!string.IsNullOrEmpty(context.Request["startDate"])) { strWhere += " and CreateTime>'" + context.Request["startDate"] + " 00:00:00' "; } if (!string.IsNullOrEmpty(context.Request["endDate"])) { strWhere += " and CreateTime<'" + context.Request["endDate"] + " 23:59:59' "; } int count; List <Model.Agents> ListMember = BLL.Agents.GetBCenterEntityList(strWhere + sh, pageIndex, pageSize, out count); StringBuilder sb = new StringBuilder(); for (int i = 0; i < ListMember.Count; i++) { Model.Member model = BllModel.GetModel(ListMember[i].MID); sb.Append(ListMember[i].ID + "~"); sb.Append((i + 1) + (pageIndex - 1) * pageSize + "~"); sb.Append(ListMember[i].MID + "~"); sb.Append(model.MName + "~"); sb.Append(model.Tel + "~"); sb.Append(ListMember[i].CreateTime.ToString("yyyy-MM-dd HH:mm") + "~"); sb.Append(BLL.Roles.RolsList[ListMember[i].Type].RName + "~"); sb.Append(ListMember[i].Province + ListMember[i].City + ListMember[i].Zone + "~"); sb.Append(ListMember[i].IsValidStr); sb.Append("≌"); } var info = new { PageData = Traditionalized(sb), TotalCount = count }; context.Response.Write(JavaScriptConvert.SerializeObject(info)); }
public override void ProcessRequest(HttpContext context) { base.ProcessRequest(context); string mKey = ""; string strWhere = " '1'='1' "; if (!string.IsNullOrEmpty(context.Request["mKey"])) { mKey = context.Request["mKey"]; } if (!string.IsNullOrEmpty(context.Request["startDate"])) { strWhere += " and changedate>'" + context.Request["startDate"] + " 00:00:00' "; } if (!string.IsNullOrEmpty(context.Request["endDate"])) { strWhere += " and changedate<'" + context.Request["endDate"] + " 23:59:59' "; } Model.Member memberModel = (TModel == null ? BllModel.TModel : TModel); if (!memberModel.Role.Super) { mKey = memberModel.MID; } strWhere += string.Format(" and (FromMID='{0}' or ToMID='{0}') ", mKey); List <Model.ChangeMoney> ListChangeMoney = BllModel.GetChangeMoneyEntityList(strWhere + " order by ChangeDate desc"); StringBuilder sb = new StringBuilder(); for (int i = (pageIndex - 1) * pageSize; i < ListChangeMoney.Count && i < pageIndex * pageSize; i++) { Model.Member member = BllModel.GetModel(mKey); sb.Append(ListChangeMoney[i].CID + "~"); sb.Append(i + 1 + "~"); sb.Append(member.MID + "~"); sb.Append(member.MName + "~"); sb.Append((ListChangeMoney[i].FromMID == member.MID ? "<b style='color:red;'>支出</b>" : "<b style='blue'>收入</b>") + "~"); sb.Append(ListChangeMoney[i].Money.ToFixedDecimal() + "~"); sb.Append((ListChangeMoney[i].CState ? "已生效" : "未生效") + "~"); sb.Append(ListChangeMoney[i].ChangeTypeStr + "~"); sb.Append(ListChangeMoney[i].ChangeDate.ToString("yyyy-MM-dd HH:mm")); sb.Append("≌"); } var info = new { PageData = Traditionalized(sb), TotalCount = ListChangeMoney.Count }; context.Response.Write(JavaScriptConvert.SerializeObject(info)); }
protected string GetBankInfo(object mid) { string result = string.Empty; if (!string.IsNullOrEmpty(mid.ToString())) { Model.Member mem = BllModel.GetModel(mid.ToString()); if (mem != null) { result = "开户银行:" + mem.Bank + " 开户名:" + mem.BankCardName + "<br/>开户支行:" + mem.Branch + "<br/>银行账号:" + mem.BankNumber + "<br/>手机号码:" + mem.Tel; } } return(result); }
protected override string btnModify_Click() { //if (Check_SQ_Answer()) //{ sjmodel = TModel; if (!string.IsNullOrEmpty(Request.Form["hdmid"])) { sjmodel = BllModel.GetModel(Request.Form["hdmid"]); } if (BLL.Configuration.Model.SHMoneyList.ContainsKey(Request.Form["AgencyTypeList"])) { Model.SHMoney shmoney = BLL.Configuration.Model.SHMoneyList[Request.Form["AgencyTypeList"]]; if (BLL.ChangeMoney.EnoughChange(TModel.MID, shmoney.Money - sjmodel.MAgencyType.Money, "MJB")) { try { if (BLL.Member.upmidlist.Contains(sjmodel.MID)) { return("升级处理中,请等待!"); } else { BLL.Member.upmidlist.Add(sjmodel.MID); } Hashtable MyHs = new Hashtable(); return(BllModel.UpMAgencyType(shmoney, Request.Form["hdmid"], TModel, shmoney.Money - sjmodel.MConfig.SHMoney, MyHs)); } finally { if (BLL.Member.upmidlist.Contains(sjmodel.MID)) { BLL.Member.upmidlist.Remove(sjmodel.MID); } } } else { return("您的账号余额不足"); } } else { return("未知会员级别"); } //} //else // return "密保问题错误*"; }
/// <summary> /// 货币转移 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> protected override string btnAdd_Click() { if (!string.IsNullOrEmpty(Request.Form["txtMID"])) { if (!string.IsNullOrEmpty(Request.Form["hdMID"])) { Model.Member TMember = BllModel.GetModel(Request.Form["hdMID"]); BLL.Task.ManageSend(TMember, "尊敬的" + TMember.MID + "会员,您有一封新邮件,请注意查收!"); } if (BllModel.GetModel(Request.Form["txtMID"]) == null) { return("会员不存在"); } } return(BLL.Task.Add(TaskModel)); }
public override void ProcessRequest(HttpContext context) { base.ProcessRequest(context); string mkey = ""; string strWhere = " '1'='1' "; if (!string.IsNullOrEmpty(context.Request["tState"])) { strWhere += " and HKType=" + context.Request["tState"]; } Model.Member memberModel = (TModel == null ? BllModel.TModel : TModel); if (!memberModel.Role.IsAdmin) { mkey = memberModel.MID; } if (!string.IsNullOrEmpty(mkey)) { strWhere += " and MID='" + mkey + "' "; } int count; List <Model.HKModel> List = BLL.HKModel.GetList(strWhere, pageIndex, pageSize, out count); StringBuilder sb = new StringBuilder(); for (int i = 0; i < List.Count; i++) { Model.Member member = BllModel.GetModel(List[i].MID); sb.Append(List[i].HKCode + "~"); sb.Append((i + 1) + (pageIndex - 1) * pageSize + "~"); //sb.Append(List[i].HKCode + "~"); //sb.Append(List[i].MID + "~"); sb.Append(List[i].FromBank + "~"); sb.Append(List[i].RealMoney + "~"); sb.Append(List[i].BankName + "~"); sb.Append(List[i].Remark + "~"); sb.Append(List[i].HKDate.ToString("yyyy-MM-dd HH:mm") + "~"); sb.Append((List[i].HKState ? "已审核" : "未审核") + "~"); sb.Append(List[i].ConfirmTime != null ? Convert.ToDateTime(List[i].ConfirmTime).ToString("yyyy-MM-dd HH:mm") : ""); sb.Append("≌"); } var info = new { PageData = Traditionalized(sb), TotalCount = count }; context.Response.Write(JavaScriptConvert.SerializeObject(info)); }
/// <summary> /// 货币转移 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> protected override string btnAdd_Click() { string MType = "MHB"; MType = Request.Form["RioHK"]; if (MType == "MJB") { MType = "MJB"; } else { return("转账币种错误"); } Model.Member fmodel = null; Model.Member tmodel = null; if (!TModel.Role.Super) { fmodel = TModel; } else { fmodel = BllModel.GetModel(Request.Form["txtFromMID"]); } tmodel = BllModel.GetModel(Request.Form["txtMID"]); if (fmodel == null || tmodel == null) { return("转入或转出会员不存在!"); } if (fmodel.IsClock) { return("转出会员账户冻结,不能转账"); } if (tmodel.IsClock) { return("转入会员账户冻结,不能转账"); } if (!string.IsNullOrEmpty(Request.Form["txtMHB"])) { int money = int.Parse(Request.Form["txtMHB"]); return(BLL.ChangeMoney.ZZMoneyChange(money, fmodel.MID, Request.Form["txtMID"], "ZZ", MType)); } else { return("转账金额不能为空"); } }
protected override void SetValue(string id) { BindDdlPwdQuestion(ddl_PwdQuestion); foreach (Model.Roles item in BLL.Roles.RolsList.Values.ToList().Where(emp => emp.VState).ToList()) { ddlMemberType.Items.Add(new ListItem(item.RName, item.RType));//角色 } //会员级别 ddlSHMoney.DataSource = BLL.Configuration.Model.SHMoneyTable; ddlSHMoney.DataTextField = "MAgencyName"; ddlSHMoney.DataValueField = "MAgencyType"; ddlSHMoney.DataBind(); string mid = HttpUtility.UrlDecode(Request["id"].Trim()); model = BllModel.GetModel(mid); MemberModel = model; }
protected string getMName(object mid, object Remark, object ChangeCount) { string result = string.Empty; if (!string.IsNullOrEmpty(mid.ToString())) { Model.Member mem = BllModel.GetModel(mid.ToString()); if (mem != null) { result = mem.MName; if (ChangeCount.ToString() != "0") { result += "<b style='color:red;'>(" + Remark + ")</b>"; } } } return(result); }
protected override string btnModify_Click() { sjmodel = TModel; if (!string.IsNullOrEmpty(Request.Form["hdmid"])) { sjmodel = BllModel.GetModel(Request.Form["hdmid"]); } if (BLL.Configuration.Model.SHMoneyList.ContainsKey(Request.Form["AgencyTypeList"])) { Model.SHMoney shmoney = BLL.Configuration.Model.SHMoneyList[Request.Form["AgencyTypeList"]]; if (BLL.ChangeMoney.EnoughChange(TModel.MID, shmoney.Money - sjmodel.MAgencyType.Money, "MJB")) { try { if (BLL.Member.upmidlist.Contains(sjmodel.MID)) { return("升级处理中,请等待!"); } else { BLL.Member.upmidlist.Add(sjmodel.MID); } return(BllModel.UpMAgencyType(shmoney, Request.Form["hdmid"], "MJB", TModel, shmoney.Money - sjmodel.MConfig.SHMoney)); } finally { if (BLL.Member.upmidlist.Contains(sjmodel.MID)) { BLL.Member.upmidlist.Remove(sjmodel.MID); } } } else { return("您的报单币账户余额不足"); } } else { return("未知会员级别"); } }
//分发 protected override string btnModify_Click() { int count = int.Parse(Request.Form["txtCount"]); string txtMID = Request.Form["txtMID"]; //校验是否存在该会员 Model.Member mem = BllModel.GetModel(txtMID); if (mem == null) { return("不存在该会员"); } else { lock (obj) { Hashtable hs = new Hashtable(); List <Model.ActiveCode> codeList = BLL.ActiveCode.GetTopList("UseState=0 and MID='" + TModel.MID + "'", count); if (codeList.Count >= count) { foreach (Model.ActiveCode ac in codeList) { ac.SwitchType = "手动转移"; ac.MID = txtMID; BLL.ActiveCode.Update(ac, hs); BLL.ChangeMoney.InsertTran(new Model.ChangeMoney { FromMID = TModel.MID, ToMID = txtMID, CompleteTime = DateTime.Now, ChangeType = "Active", MoneyType = "Active", CRemarks = ac.Code, ChangeDate = DateTime.Now, CState = true }, hs); } if (BLL.CommonBase.RunHashtable(hs)) { return("1"); } } return("0"); } } //return BLL.MemberApply.DeleteApply(CheckHasApplyed(TModel.MID, 1, int.Parse(Request.Form["hidtype"])).Id.ToString()); }
protected override void SetValue(string id) { match = BLL.MHelpMatch.GetModel(id); hidId.Value = id; if (match != null) { getMemberModel = BllModel.GetModel(match.GetMID); getTJMemberModel = BllModel.GetModel(getMemberModel.MTJ); spLeaveTime.InnerHtml = MatchTimeLeave(match, MMMMatchTimeType.PayLimitTime, "打款倒计时", ""); ////剩余付款时间 //DateTime matchTime = match.MatchTime; //DateTime matchTimeAdd = matchTime.AddMinutes(BLL.MMMConfig.Model.PayLimitTimes); //if (match.ChangeCount == 1) //{ // matchTimeAdd = matchTime.AddMinutes(BLL.MMMConfig.Model.PayLimitTimesPre); //} //TimeSpan d3 = matchTimeAdd.Subtract(DateTime.Now); //long totalMM = Convert.ToInt64(Math.Round(d3.TotalMilliseconds, 0).ToString()); //spLeaveTime.InnerHtml = (totalMM / 3600000).ToString() + "小时" + ((totalMM / 60000) % 60).ToString() + "分钟" + ((totalMM / 1000) % 60).ToString() + "秒"; } }
protected override void SetValue(string id) { match = BLL.MHelpMatch.GetModel(id); hidId.Value = id; if (match != null) { getMemberModel = BllModel.GetModel(match.OfferMID); getTJMemberModel = BllModel.GetModel(getMemberModel.MTJ); spLeaveTime.InnerHtml = MatchTimeLeave(match, MMMMatchTimeType.ConfirmLimitTime, "收款确认倒计时", ""); //DateTime PayTime = Convert.ToDateTime(match.PayTime); //DateTime matchTimeAdd = PayTime.AddMinutes(BLL.MMMConfig.Model.ConfirmLimitTimes);//以分钟计算 //TimeSpan d3 = matchTimeAdd.Subtract(DateTime.Now); //long totalMM = Convert.ToInt64(Math.Round(d3.TotalMilliseconds, 0).ToString()); ////totalMM = totalMM * 60000; //spLeaveTime.InnerHtml = (totalMM / 3600000).ToString() + "小时" + ((totalMM / 60000) % 60).ToString() + "分钟" + ((totalMM / 1000) % 60).ToString() + "秒"; if (match.MatchState == 2) { btnOK.Visible = true; } txtjujuemessage.Value = match.PicUrl1; } }
public override void ProcessRequest(HttpContext context) { base.ProcessRequest(context); List <string> cTypeList = new List <string>(); List <string> mTypeList = new List <string> { "MHB", "MJB", "MGP", "MCW", "CTB", "CTD" }; string mKey = "", shmKey = "", cState = ""; string strWhere = " '1'='1' "; if (!string.IsNullOrEmpty(context.Request["typeList"])) { string types = context.Request["typeList"].Remove(context.Request["typeList"].Length - 1); cTypeList = new List <string>(types.Split('|')); cTypeList.Add("TJKF"); } if (!string.IsNullOrEmpty(context.Request["mKey"])) { mKey = context.Request["mKey"]; } if (!string.IsNullOrEmpty(context.Request["tState"])) { cState = context.Request["tState"]; } if (!string.IsNullOrEmpty(context.Request["txtKey"])) { shmKey = context.Request["txtKey"]; } if (!string.IsNullOrEmpty(cState)) { strWhere += " and ChangeType ='" + cState + "' "; } if (!string.IsNullOrEmpty(context.Request["startDate"])) { strWhere += " and changedate>'" + context.Request["startDate"] + " 00:00:00' "; } if (!string.IsNullOrEmpty(context.Request["endDate"])) { strWhere += " and changedate<'" + context.Request["endDate"] + " 23:59:59' "; } if (!string.IsNullOrEmpty(context.Request["moneyType"])) { mTypeList = new List <string> { context.Request["moneyType"] }; } if (!string.IsNullOrEmpty(context.Request["countdate"])) { strWhere += " and changedate>'" + context.Request["countdate"] + " 00:00:00' and changedate<'" + context.Request["countdate"] + " 23:59:59'"; } Model.Member memberModel = (TModel == null ? BllModel.TModel : TModel); if (!memberModel.Role.IsAdmin) { mKey = memberModel.MID; //cState = "true"; } int count; string toMID = mKey; string fromMID = BLL.Member.ManageMember.TModel.MID; if (cState == "TJKF") { toMID = BLL.Member.ManageMember.TModel.MID; fromMID = mKey; } List <Model.ChangeMoney> ListChangeMoney = BllModel.GetChangeMoneyEntityList(fromMID, toMID, shmKey, cState, cTypeList, mTypeList, pageIndex, pageSize, strWhere, out count); StringBuilder sb = new StringBuilder(); for (int i = 0; i < ListChangeMoney.Count; i++) { //if (shmid != ListChangeMoney[i].SHMID) //{ // shmid = ListChangeMoney[i].SHMID; // if (i != 0) // { // sb.Append("~~~~~~~~~≌"); // } //} sb.Append(ListChangeMoney[i].CID + "~"); sb.Append((i + 1) + (pageIndex - 1) * pageSize + "~"); if (ListChangeMoney[i].ChangeType == "TJKF") { if (TModel.Role.IsAdmin) { Model.Member member = BllModel.GetModel(ListChangeMoney[i].FromMID); sb.Append(member.MID + "~"); sb.Append(member.MAgencyType.MAgencyName + "~"); } sb.Append("-" + Math.Round(ListChangeMoney[i].Money, 2) + "~"); } else { if (TModel.Role.IsAdmin) { Model.Member member = BllModel.GetModel(ListChangeMoney[i].ToMID); sb.Append(member.MID + "~"); sb.Append(member.MAgencyType.MAgencyName + "~"); } sb.Append(Math.Round(ListChangeMoney[i].Money, 6) + "~"); } //sb.Append(Math.Round(ListChangeMoney[i].TakeOffMoney, 2) + "~"); //sb.Append(ListChangeMoney[i].TakeOffMoney+ "~"); //sb.Append(ListChangeMoney[i].MCWMoney + "~"); //sb.Append(ListChangeMoney[i].ReBuyMoney+ "~"); //sb.Append(ListChangeMoney[i].ReBuyMoney + "~"); sb.Append(ListChangeMoney[i].ChangeTypeStr + "~"); string JJsource = (!string.IsNullOrEmpty(ListChangeMoney[i].CRemarks)) ? ListChangeMoney[i].CRemarks + "~" : ListChangeMoney[i].SHMID + "~"; sb.Append(JJsource); sb.Append((ListChangeMoney[i].CState ? "已生效" : "未生效") + "~"); sb.Append(ListChangeMoney[i].ChangeDate.ToString("yyyy-MM-dd HH:mm")); if (!ListChangeMoney[i].CState) { //sb.Append(RemainLeaveTime(ListChangeMoney[i].ChangeDate, BLL.Configuration.Model.DFHOutCount)); string button = "<input onclick=\"TQJJ(" + ListChangeMoney[i].CID + ")\" class=\"btn btn-success\" value=\"提取奖金\" type=\"button\">"; //if (ListChangeMoney[i].ToMID != TModel.MID) //{ // button = "<span style=\"color:red;\">等待提取</span>"; //} sb.Append(DateDiffStr(DateDiffType.MI, ListChangeMoney[i].ChangeDate, BLL.MMMConfig.Model.GLRewardFreezeTimes, "倒计时:", button)); } sb.Append("≌"); } var info = new { PageData = Traditionalized(sb), TotalCount = count }; context.Response.Write(JavaScriptConvert.SerializeObject(info)); }
protected override string btnModify_Click() { //if (Check_SQ_Answer()) //{ sjmodel = TModel; if (!string.IsNullOrEmpty(Request.Form["hdmid"])) { sjmodel = BllModel.GetModel(Request.Form["hdmid"]); } //if (!sjmodel.MState) //{ // if (string.IsNullOrWhiteSpace(Request.Form["txtMBD"])) // { // return "接点人不能为空"; // } //} if (BLL.Configuration.Model.SHMoneyList.ContainsKey(Request.Form["AgencyTypeList"])) { Model.SHMoney shmoney = BLL.Configuration.Model.SHMoneyList[Request.Form["AgencyTypeList"]]; if (BLL.ChangeMoney.EnoughChange(TModel.MID, shmoney.Money - sjmodel.MAgencyType.Money, "MJB")) { try { if (BLL.Member.upmidlist.Contains(sjmodel.MID)) { return("升级处理中,请等待!"); } else { BLL.Member.upmidlist.Add(sjmodel.MID); } var result = BllModel.UpMAgencyType(shmoney, Request.Form["hdmid"], "MJB", TModel, shmoney.Money - sjmodel.MConfig.SHMoney, Request.Form["txtMBD"]); if (TModel.Role.IsAdmin) { BLL.OperationRecordBLL.Add(TModel.MID, ChangeType.O_SJHY, "升级会员"); } return(result); } finally { if (BLL.Member.upmidlist.Contains(sjmodel.MID)) { BLL.Member.upmidlist.Remove(sjmodel.MID); } } } else { return("您的" + BLL.Reward.List["MJB"].RewardName + "账户余额不足"); } } else { return("未知会员级别"); } //} //else // return "密保问题错误*"; }
public override void ProcessRequest(HttpContext context) { base.ProcessRequest(context); string mkey = ""; string strWhere = " '1'='1' "; if (!string.IsNullOrEmpty(context.Request["startDate"])) { strWhere += " and BankCreateDate>'" + context.Request["startDate"] + " 00:00:00' "; } if (!string.IsNullOrEmpty(context.Request["endDate"])) { strWhere += " and BankCreateDate<'" + context.Request["endDate"] + " 23:59:59' "; } if (!string.IsNullOrEmpty(context.Request["mKey"])) { mkey = context.Request["mKey"]; } Model.Member memberModel = (TModel == null ? BllModel.TModel : TModel); if (!memberModel.Role.Super) { mkey = memberModel.MID; } if (!string.IsNullOrEmpty(mkey)) { strWhere += " and MID='" + mkey + "' "; } int count; List <Model.BankModel> List = BLL.BankModel.GetList(strWhere, pageIndex, pageSize, out count); StringBuilder sb = new StringBuilder(); for (int i = 0; i < List.Count; i++) { Model.Member member = BllModel.GetModel(List[i].MID); sb.Append(List[i].BankCode + "~"); sb.Append((i + 1) + (pageIndex - 1) * pageSize + "~"); if (TModel.Role.Super) { sb.Append(member.MID + "~"); sb.Append(member.MName + "~"); } sb.Append("<span>" + List[i].BankInfo.Name + "</span>~"); sb.Append(List[i].Branch + "~"); sb.Append(List[i].BankNumber + "~"); sb.Append(List[i].BankCardName + "~"); sb.Append(List[i].BankCreateDate.ToString("yyyy-MM-dd HH:mm")); //sb.Append((List[i].IsPrimary ? "是" : "否")); sb.Append("≌"); } //string zhNames = "", enNames = ""; //var list = CommonBLL.Sys_LanguageBLL.GetList("IsDeleted=0 and Status=1 order by LEN(ZHName) desc"); //foreach (Sys_Language obj in list) //{ // zhNames += obj.ZHName + "*"; // enNames += obj.ENName + "*"; //} //string[] zhs = zhNames.Split('*'); //string[] ens = enNames.Split('*'); //string cc = sb.ToString(); //for (var i = 0; i < zhs.Length; i++) //{ // if (cc.IndexOf(zhs[i]) != -1) // { // if (!string.IsNullOrEmpty(zhs[i]) && !string.IsNullOrEmpty(ens[i])) // cc = cc.Replace(zhs[i], ens[i]); // } //} var info = new { PageData = Traditionalized(sb), TotalCount = count }; //var info = new { PageData = sb.ToString(), TotalCount = count }; context.Response.Write(JavaScriptConvert.SerializeObject(info)); }
public override void ProcessRequest(HttpContext context) { base.ProcessRequest(context); List <string> cTypeList = new List <string>(); List <string> mTypeList = new List <string> { "MHB", "MJB", "MGP" }; string strWhere = " and '1'='1' "; string TypeLength = "100"; string mKey = ""; if (!string.IsNullOrEmpty(context.Request["typeList"])) { string types = context.Request["typeList"].Remove(context.Request["typeList"].Length - 1); cTypeList = new List <string>(types.Split('|')); } if (!string.IsNullOrEmpty(context.Request["txtKey"])) { mKey = context.Request["txtKey"]; } if (!string.IsNullOrEmpty(context.Request["startDate"])) { strWhere += " and changedate>'" + context.Request["startDate"] + " 00:00:00' "; } if (!string.IsNullOrEmpty(context.Request["endDate"])) { strWhere += " and changedate<'" + context.Request["endDate"] + " 23:59:59' "; } if (!string.IsNullOrEmpty(context.Request["moneyType"])) { mTypeList = new List <string> { context.Request["moneyType"] }; } if (!string.IsNullOrEmpty(context.Request["tState"])) { TypeLength = context.Request["tState"]; } Model.Member memberModel = (TModel == null ? BllModel.TModel : TModel); if (!memberModel.Role.Super) { mKey = memberModel.MID; } if (!string.IsNullOrEmpty(mKey)) { strWhere += " and tomid='" + mKey + "' "; } StringBuilder sqlstr = new StringBuilder("select tomid,"); foreach (string CType in cTypeList) { sqlstr.AppendFormat("sum(case when changetype='{0}' then money else 0 end) as '{0}',", CType); } sqlstr.Append("sum(TakeOffMoney) as 'Take',"); sqlstr.Append("sum(ReBuyMoney) as 'ReBuy',"); sqlstr.Append("sum(MCWMoney) as 'MCW',"); sqlstr.Append("sum(money) as 'HeJi',"); sqlstr.Append("sum(money-TakeOffMoney-ReBuyMoney-MCWMoney) as 'JJ'"); sqlstr.AppendFormat(",CONVERT(varchar(" + TypeLength + "), changedate, 23) as 'Date' from changemoney a where "); sqlstr.AppendFormat(" changetype in ('{0}') ", String.Join("','", cTypeList.ToArray())); sqlstr.Append(strWhere); sqlstr.Append("group by CONVERT(varchar(" + TypeLength + "), changedate, 23),tomid order by CONVERT(varchar(" + TypeLength + "), changedate, 23) desc"); DataTable table = BLL.CommonBase.GetTable(sqlstr.ToString()); StringBuilder sb = new StringBuilder(); decimal[] heji = new decimal[cTypeList.Count + 4]; for (int i = (pageIndex - 1) * pageSize; i < table.Rows.Count && i < pageSize * (pageIndex); i++) { int j = 0; Model.Member member = BllModel.GetModel(table.Rows[i]["ToMID"].ToString()); sb.Append(i + 1 + "~"); sb.Append(i + 1 + "~"); if (TModel.Role.Super) { sb.Append("<a href=\"javascript:void(0);\" onclick=\"callhtml('ChangeMoney/JJJLList.aspx?id=" + member.MID + "');\">" + member.MID + "</a>~"); //sb.Append(member.MName + "~"); sb.Append(member.MAgencyType.MAgencyName + "~"); } sb.Append(table.Rows[i]["DFH"] + "~"); sb.Append(table.Rows[i]["Date"] + "~"); sb.Append(table.Rows[i]["TJ"] + "~"); //推荐奖 sb.Append(table.Rows[i]["PY"] + "~"); //培育奖 sb.Append(table.Rows[i]["BT"] + "~"); //报单奖 sb.Append(table.Rows[i]["DP"] + "~"); //平衡将 //sb.Append(0+ "~");//网络费 sb.Append(table.Rows[i]["Take"] + "~"); //进入现金比金额 sb.Append(table.Rows[i]["ReBuy"]); //进入循环币金额 //for (; j < cTypeList.Count; j++) //{ // sb.Append(table.Rows[i][cTypeList[j]] + "~"); // heji[j] += Convert.ToDecimal(table.Rows[i][cTypeList[j]]); //} //sb.Append(table.Rows[i]["MCW"] + "~"); //heji[j++] += Convert.ToDecimal(table.Rows[i]["HeJi"]); //sb.Append(table.Rows[i]["ReBuy"] + "~"); //heji[j++] += Convert.ToDecimal("-" + table.Rows[i]["ReBuy"]); //sb.Append(table.Rows[i]["Take"] + "~"); //heji[j++] += Convert.ToDecimal("-" + table.Rows[i]["Take"]); //sb.Append(table.Rows[i]["JJ"]); //heji[j++] += Convert.ToDecimal(table.Rows[i]["JJ"]); sb.Append("≌"); } //if (TModel.Role.Super) // sb.Append("~~~合计~"); //else // sb.Append("~合计~"); //foreach (decimal item in heji) //{ // sb.Append(item + "~"); //} //sb.Append("≌"); var info = new { PageData = Traditionalized(sb), TotalCount = table.Rows.Count }; context.Response.Write(JavaScriptConvert.SerializeObject(info)); }
public override void ProcessRequest(HttpContext context) { base.ProcessRequest(context); List <string> cTypeList = new List <string>(); List <string> mTypeList = new List <string> { "MHB" }; string mKey = "", shmKey = "", cState = ""; string strWhere = " '1'='1' "; string types = "TG"; cTypeList = new List <string>(types.Split('|')); if (!string.IsNullOrEmpty(context.Request["mKey"])) { mKey = context.Request["mKey"]; } //if (!string.IsNullOrEmpty(context.Request["tState"])) //{ // cState = context.Request["tState"]; //} if (!string.IsNullOrEmpty(context.Request["txtKey"])) { shmKey = context.Request["txtKey"]; } if (!string.IsNullOrEmpty(context.Request["startDate"])) { strWhere += " and changedate>'" + context.Request["startDate"] + " 00:00:00' "; } if (!string.IsNullOrEmpty(context.Request["endDate"])) { strWhere += " and changedate<'" + context.Request["endDate"] + " 23:59:59' "; } if (!string.IsNullOrEmpty(context.Request["moneyType"])) { mTypeList = new List <string> { context.Request["moneyType"] }; } Model.Member memberModel = (TModel == null ? BllModel.TModel : TModel); if (!memberModel.Role.IsAdmin) { mKey = memberModel.MID; cState = "true"; } int count; List <Model.ChangeMoney> ListChangeMoney = BllModel.GetChangeMoneyEntityList(BLL.Member.ManageMember.TModel.MID, mKey, shmKey, cState, cTypeList, mTypeList, pageIndex, pageSize, strWhere, out count); StringBuilder sb = new StringBuilder(); for (int i = 0; i < ListChangeMoney.Count; i++) { Model.Member member = BllModel.GetModel(ListChangeMoney[i].ToMID); sb.Append(ListChangeMoney[i].CID + "~"); sb.Append((i + 1) + (pageIndex - 1) * pageSize + "~"); sb.Append(member.MID + "~"); sb.Append(ListChangeMoney[i].ChangeDate.ToString("yyyy-MM-dd HH:mm") + "~"); sb.Append(ListChangeMoney[i].Money + "~"); sb.Append((ListChangeMoney[i].CState ? "已生效" : "未生效") + "~"); sb.Append(ListChangeMoney[i].CRemarks); sb.Append("≌"); } var info = new { PageData = Traditionalized(sb), TotalCount = count }; context.Response.Write(JavaScriptConvert.SerializeObject(info)); }
public override void ProcessRequest(HttpContext context) { base.ProcessRequest(context); List <string> cTypeList = new List <string>(); List <string> mTypeList = new List <string> { "MHB", "MJB", "MGP", "MCW" }; string mKey = "", shmKey = "", cState = ""; string strWhere = " '1'='1' "; //if (!string.IsNullOrEmpty(context.Request["typeList"])) //{ // string types = context.Request["typeList"].Remove(context.Request["typeList"].Length - 1); //} cTypeList = new List <string> { "JJSY" }; if (!string.IsNullOrEmpty(context.Request["mKey"])) { mKey = context.Request["mKey"]; } if (!string.IsNullOrEmpty(context.Request["tState"])) { cState = context.Request["tState"]; } if (!string.IsNullOrEmpty(context.Request["txtKey"])) { shmKey = context.Request["txtKey"]; } if (!string.IsNullOrEmpty(context.Request["startDate"])) { strWhere += " and changedate>'" + context.Request["startDate"] + " 00:00:00' "; } if (!string.IsNullOrEmpty(context.Request["endDate"])) { strWhere += " and changedate<'" + context.Request["endDate"] + " 23:59:59' "; } if (!string.IsNullOrEmpty(context.Request["moneyType"])) { mTypeList = new List <string> { context.Request["moneyType"] }; } Model.Member memberModel = (TModel == null ? BllModel.TModel : TModel); if (!memberModel.Role.IsAdmin) { mKey = memberModel.MID; cState = "true"; } int count; List <Model.ChangeMoney> ListChangeMoney = BllModel.GetChangeMoneyEntityList(BLL.Member.ManageMember.TModel.MID, mKey, shmKey, cState, cTypeList, mTypeList, pageIndex, pageSize, strWhere, out count); StringBuilder sb = new StringBuilder(); for (int i = 0; i < ListChangeMoney.Count; i++) { Model.Member member = BllModel.GetModel(ListChangeMoney[i].ToMID); //if (shmid != ListChangeMoney[i].SHMID) //{ // shmid = ListChangeMoney[i].SHMID; // if (i != 0) // { // sb.Append("~~~~~~~~~≌"); // } //} sb.Append(ListChangeMoney[i].CID + "~"); sb.Append((i + 1) + (pageIndex - 1) * pageSize + "~"); if (TModel.Role.IsAdmin) { sb.Append(member.MID + "~"); sb.Append(member.MAgencyType.MAgencyName + "~"); } if (ListChangeMoney[i].ChangeType == "ZZB") { sb.Append(ListChangeMoney[i].Money + "(手续费" + ListChangeMoney[i].TakeOffMoney.ToString() + ")" + "~"); } else { sb.Append(ListChangeMoney[i].Money + "~"); } //sb.Append(ListChangeMoney[i].TakeOffMoney+ "~"); //sb.Append(ListChangeMoney[i].MCWMoney + "~"); //sb.Append(ListChangeMoney[i].ReBuyMoney+ "~"); //sb.Append(ListChangeMoney[i].ReBuyMoney + "~"); sb.Append(ListChangeMoney[i].ChangeTypeStr + "~"); string JJsource = (ListChangeMoney[i].ChangeType == "DFH" || ListChangeMoney[i].ChangeType == "PY" || ListChangeMoney[i].ChangeType == "TJ" || ListChangeMoney[i].ChangeType == "DP") ? ListChangeMoney[i].CRemarks + "~" : ListChangeMoney[i].SHMID + "~"; sb.Append(JJsource); sb.Append((ListChangeMoney[i].CState ? "已生效" : "未生效") + "~"); sb.Append(ListChangeMoney[i].ChangeDate.ToString("yyyy-MM-dd HH:mm")); sb.Append("≌"); } var info = new { PageData = Traditionalized(sb), TotalCount = count }; context.Response.Write(JavaScriptConvert.SerializeObject(info)); }