private void BindData() { // anpPage.CurrentPageIndex, anpPage.PageSize PagerSet pagerSet = FacadeManage.aideRecordFacade.GetListLock("WHQJAccountsDB.dbo.AccountsInfo (NOLOCK) A INNER JOIN WHQJRecordDB.dbo.AgentCountRecord (NOLOCK) R ON A.UserID = R.UserID ", SearchItems, " ORDER BY R.CountTime DESC ", anpPage.CurrentPageIndex, anpPage.PageSize, "A.UserID,A.GameID,A.NickName,R.CountTime,R.Tax,R.SubNumber,R.ParentID,R.BeggarNumber,R.CurrReward"); string startDate = CtrlHelper.GetText(txtStartDate); string endDate = CtrlHelper.GetText(txtEndDate); string gameid = CtrlHelper.GetText(GameId); int uid = FacadeManage.aideAccountsFacade.GetAccountInfoByGameId(Convert.ToInt32(gameid)).UserID; DataSet ds = FacadeManage.aideRecordFacade.CountReward($"WHERE UserID={uid} AND CountTime BETWEEN '{startDate}' AND '{endDate}'"); if (ds.Tables.Count > 0) { DataRow row = ds.Tables[0].Rows[0]; long ImmediateMoney = 0; long otherMoney = 0; string person = "0"; if (row["Person"] != DBNull.Value) { person = row["Person"].ToString(); } if (row["ImmediateMoney"] != DBNull.Value) { ImmediateMoney = (long)(Convert.ToInt64(row["ImmediateMoney"]) * 0.3); } if (row["OtherMoney"] != DBNull.Value) { otherMoney = (long)(Convert.ToInt64(row["OtherMoney"]) * 0.3); } lbTotal.Text = person; Label1.Text = FacadeManage.ConversionMoneyToShow(ImmediateMoney).ToString(); Label1.Text = FacadeManage.ConversionMoneyToShow(otherMoney).ToString(); } anpPage.RecordCount = pagerSet.RecordCount; rptDataList.DataSource = pagerSet.PageSet.Tables[0]; rptDataList.DataBind(); }
/// <summary> /// 数据保存 /// </summary> protected void btnSave_Click(object sender, EventArgs e) { //判断权限 if (!AuthUserOperationPermission(Permission.Edit)) { return; } if (IntParam > 0) { ConfigInfo config = FacadeManage.aideNativeWebFacade.GetConfigInfo(IntParam); if (config != null) { config.ConfigString = CtrlHelper.GetText(txtConfigString); config.Field1 = txtField1.Text; config.Field2 = CtrlHelper.GetText(txtField2); config.Field3 = CtrlHelper.GetText(txtField3); config.Field4 = CtrlHelper.GetText(txtField4); config.Field5 = CtrlHelper.GetText(txtField5); config.Field6 = CtrlHelper.GetText(txtField6); config.Field7 = CtrlHelper.GetText(txtField7); config.Field8 = txtField8.Text; config.Field9 = CtrlHelper.GetText(txtField9); config.Field10 = CtrlHelper.GetText(txtField10); config.Field11 = CtrlHelper.GetText(txtField11); config.Field12 = CtrlHelper.GetText(txtField12); config.Field13 = CtrlHelper.GetText(txtField13); int result = FacadeManage.aideNativeWebFacade.UpdateConfigInfo(config); if (result > 0) { ShowInfo("配置修改成功"); } else { ShowInfo("配置修改失败"); } } } }
protected void btnUpdate_Click(object sender, EventArgs e) { AccountsProtect protect = new AccountsProtect(); protect.UserID = Utility.StrToInt(ViewState["UserID"], 0); protect.LogonPass = TextEncrypt.EncryptPassword(CtrlHelper.GetTextAndFilter(txtNewPass)); protect.Response1 = CtrlHelper.GetTextAndFilter(txtResponse1); protect.Response2 = CtrlHelper.GetTextAndFilter(txtResponse2); protect.Response3 = CtrlHelper.GetTextAndFilter(txtResponse3); protect.LastLogonIP = GameRequest.GetUserIP(); Message umsg = FacadeManage.aideAccountsFacade.ResetLogonPasswd(protect); if (umsg.Success) { int userid = Utility.StrToInt(ViewState["UserID"], 0); if (Fetch.GetUserCookie() != null) { if (userid == Fetch.GetUserCookie().UserID) { Fetch.DeleteUserCookie(); ShowAndRedirect("重置登录密码成功,请您重新登录!", "/Login.aspx"); } else { RenderAlertInfo3(false, "重置登录密码成功,可用这个帐号重新登录!"); } } ShowAndRedirect("重置登录密码成功,请登录!", "/Login.aspx"); } else { Show(umsg.Content); txtResponse1.Text = ""; txtResponse2.Text = ""; txtResponse3.Text = ""; } }
/// <summary> /// 页面加载 /// </summary> protected void Page_Load(object sender, EventArgs e) { base.moduleID = 100; //判断权限 AuthUserOperationPermission(Permission.GrantGameID); if (IsPostBack) { return; } if (IntParam <= 0) { return; } AccountsInfo model = FacadeManage.aideAccountsFacade.GetAccountInfoByUserId(IntParam); if (model == null) { return; } CtrlHelper.SetText(ltNickName, model.NickName); CtrlHelper.SetText(ltGameID, model.GameID.ToString()); DataBindGameId(); }
/// <summary> /// 数据绑定 /// </summary> private void SystemMessageDataBind() { if (IntParam > 0) { SystemMessage systemMessage = FacadeManage.aidePlatformFacade.GetSystemMessageInfo(IntParam); if (systemMessage != null) { CtrlHelper.SetText(txtMessageString, systemMessage.MessageString.Trim()); ddlMessageType.SelectedValue = systemMessage.MessageType.ToString().Trim(); CtrlHelper.SetText(txtStartTime, systemMessage.StartTime.ToString("yyyy-MM-dd HH:mm:ss").Trim()); CtrlHelper.SetText(txtConcludeTime, systemMessage.ConcludeTime.ToString("yyyy-MM-dd HH:mm:ss").Trim()); CtrlHelper.SetText(txtTimeRate, systemMessage.TimeRate.ToString().Trim()); CtrlHelper.SetText(txtCollectNote, systemMessage.CollectNote.Trim()); Servers = systemMessage.ServerRange; } } else { CtrlHelper.SetText(txtStartTime, DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss")); CtrlHelper.SetText(txtConcludeTime, DateTime.Now.AddDays(10).ToString("yyyy-MM-dd HH:mm:ss")); CtrlHelper.SetText(txtTimeRate, "60"); } }
private void GameUserDataBind() { //验证数据 if (id <= 0) { return; } //获取用户信息 Base_Users user = aidePlatformManagerFacade.GetUserByUserID(id); if (user == null) { MessageBox("用户信息不存在"); return; } CtrlHelper.SetText(lblAccounts, user.Username); CtrlHelper.SetText(lblRoleID, GetRoleName(user.RoleID)); CtrlHelper.SetText(hdfOldLogonPass, user.Password); CtrlHelper.SetText(lblLoginTimes, user.LoginTimes.ToString()); CtrlHelper.SetText(lblLastLogonIP, IPQuery.GetAddressWithIP(user.LastLoginIP)); CtrlHelper.SetText(lblLastLogonDate, user.LastLogintime.ToString()); }
/// <summary> /// 页面加载 /// </summary> protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { if (IntParam > 0) { AccountsAgentInfo info = FacadeManage.aideAccountsFacade.GetAccountsAgentInfo(IntParam); if (info != null) { AccountsInfo accounts = FacadeManage.aideAccountsFacade.GetAccountInfoByUserId(info.UserID); CtrlHelper.SetText(txtAgentNote, info.AgentNote); CtrlHelper.SetText(txtCompellation, info.Compellation); CtrlHelper.SetText(txtContactAddress, info.ContactAddress); CtrlHelper.SetText(txtContactPhone, info.ContactPhone); CtrlHelper.SetText(txtDomain, info.AgentDomain); CtrlHelper.SetText(txtQQAccount, info.QQAccount); CtrlHelper.SetText(txtWCNickName, accounts.NickName); ddlLevel.SelectedValue = info.AgentLevel.ToString(); } } } }
/// <summary> /// 页面加载 /// </summary> protected void Page_Load(object sender, EventArgs e) { if (IsPostBack) { return; } IMGroupProperty groupInfo = FacadeManage.aideGroupFacade.GetGroupInfo(LongParam); if (groupInfo == null) { return; } CtrlHelper.SetText(lblGroupName, $"{groupInfo.GroupName}({groupInfo.GroupID})"); CtrlHelper.SetText(lblCreatetInfo, $"{groupInfo.CreaterNickName}({groupInfo.CreaterGameID})"); IList <IMGroupMember> list = FacadeManage.aideGroupFacade.GetGroupMemberList(LongParam); int ownerIndex = 0; for (int i = 0; i < list.Count; i++) { if (Convert.ToInt32(list[i].MemberID) == groupInfo.CreaterID) { ownerIndex = i; continue; } AccountsInfo ai = FacadeManage.aideAccountsFacade .GetAccountInfoByUserId(list[i].MemberID); list[i].NickName = ai.NickName; list[i].GameID = ai.GameID; } list.RemoveAt(ownerIndex); ddlMemberUserId.DataSource = list; ddlMemberUserId.DataTextField = "ShowName"; ddlMemberUserId.DataValueField = "MemberID"; ddlMemberUserId.DataBind(); ddlMemberUserId.Items.Insert(0, new ListItem("请选择新会长", "0")); }
/// <summary> /// 数据保存 /// </summary> protected void btnSave_Click(object sender, EventArgs e) { CurrencyExchConfig config = new CurrencyExchConfig(); if (IntParam > 0) { AuthUserOperationPermission(Permission.Edit); config = FacadeManage.aideTreasureFacade.GetCurrencyExch(IntParam); } else { AuthUserOperationPermission(Permission.Add); } config.ConfigName = CtrlHelper.GetText(txtProductName); config.Diamond = CtrlHelper.GetInt(txtCurrency, 0); config.ExchGold = Convert.ToInt64(txtGold.Text); config.ImageType = Convert.ToByte(txtImageType.Text); config.SortID = CtrlHelper.GetInt(txtSortID, 0); //验证是否存在相同钻石配置 if (IntParam <= 0 && FacadeManage.aideTreasureFacade.IsExistCurrencyExch(config.Diamond)) { ShowError("抱歉,相同额度的钻石已存在"); return; } int result = IntParam > 0 ? FacadeManage.aideTreasureFacade.UpdateCurrencyExch(config) : FacadeManage.aideTreasureFacade.InsertCurrencyExch(config); if (result > 0) { ShowInfo("配置信息操作成功", "GoldExchConfigList.aspx", 1200); } else { ShowError("配置信息操作失败"); } }
private void BindData( ) { if (StrCmd == "add") { litInfo.Text = "新增"; txtPageID.Enabled = true; } else { litInfo.Text = "更新"; txtPageID.Enabled = false; } if (IntParam <= 0) { return; } //获取信息 GamePageItem gamePageItem = FacadeManage.aidePlatformFacade.GetGamePageItemInfo(IntParam); if (gamePageItem == null) { ShowError("页面信息不存在"); Redirect("GamePageItemList.aspx"); return; } CtrlHelper.SetText(txtPageID, gamePageItem.PageID.ToString( ).Trim( )); CtrlHelper.SetText(txtPageName, gamePageItem.DisplayName.Trim( )); ddlGameKind.SelectedValue = gamePageItem.KindID.ToString( ).Trim( ); ddlNode.SelectedValue = gamePageItem.NodeID.ToString( ).Trim( ); ddlOperateType.SelectedValue = gamePageItem.OperateType.ToString( ).Trim( ); CtrlHelper.SetText(txtSortID, gamePageItem.SortID.ToString( ).Trim( )); CtrlHelper.SetText(txtResponseUrl, gamePageItem.ResponseUrl.ToString( ).Trim( )); rbtnNullity.SelectedValue = gamePageItem.Nullity.ToString( ).Trim( ); }
/// <summary> /// 数据保存 /// </summary> protected void btnSave_Click(object sender, EventArgs e) { SpreadConfig config = new SpreadConfig(); if (IntParam > 0) { AuthUserOperationPermission(Permission.Edit); config = FacadeManage.aideTreasureFacade.GetSpreadConfig(IntParam); } else { AuthUserOperationPermission(Permission.Add); if (FacadeManage.aideTreasureFacade.SpreadConfigCount() >= 5) { ShowError("推广配置最多配置5个"); return; } } config.PresentDiamond = CtrlHelper.GetInt(txtDiamond, 0); config.PresentPropID = Convert.ToInt32(ddlPropID.SelectedValue); config.PresentPropNum = config.PresentPropID > 0 ? CtrlHelper.GetInt(txtPropNum, 0) : 0; config.PresentPropName = config.PresentPropID == 0 ? "" : ddlPropID.SelectedItem.Text; config.SpreadNum = CtrlHelper.GetInt(txtSpreadNum, 0); config.UpdateTime = DateTime.Now; int result = IntParam > 0 ? FacadeManage.aideTreasureFacade.UpdateSpreadConfig(config) : FacadeManage.aideTreasureFacade.InsertSpreadConfig(config); if (result > 0) { ShowInfo("操作成功", "SpreadConfigList.aspx", 1200); } else { ShowError("操作失败"); } }