예제 #1
0
        protected void btnSave_Click(object sender, EventArgs e)
        {
            string str  = this.txtAliAppId.Text.Trim();
            string str2 = this.txtAliFollowTitle.Text.Trim();

            if (str.Length < 14)
            {
                this.ShowMsg("请输入正确的AppId信息!", false);
            }
            else if (str2.Length < 2)
            {
                this.ShowMsg("关注消息,请不要留空,2个字符以上!", false);
            }
            else
            {
                SiteSettings masterSettings = SettingsManager.GetMasterSettings(false);
                if (masterSettings.AlipayAppid != str)
                {
                    MemberHelper.ClearAllAlipayopenId();
                    ScanHelp.ClearScanBind("ALIPAY");
                }
                masterSettings.AlipayAppid           = str;
                masterSettings.AliOHFollowRelayTitle = str2;
                SettingsManager.Save(masterSettings);
                AlipayFuwuConfig.CommSetConfig(str, base.Server.MapPath("~/"), "GBK");
                this.ShowMsg("服务窗配置保存成功!", true);
                this.BindData();
            }
        }
예제 #2
0
        protected void btnSave_Click(object sender, System.EventArgs e)
        {
            SiteSettings masterSettings = SettingsManager.GetMasterSettings(false);

            if (masterSettings.WeixinAppId != this.txtAppId.Text.Trim())
            {
                WeiXinHelper.ClearWeiXinMediaID();
                MemberHelper.ClearAllOpenId();
                ScanHelp.ClearScanBind("WX");
            }
            masterSettings.WeixinAppId     = this.txtAppId.Text.Trim();
            masterSettings.WeixinAppSecret = this.txtAppSecret.Text.Trim();
            SettingsManager.Save(masterSettings);
            Globals.RefreshWeiXinToken();
            this.ShowMsgAndReUrl("修改成功", true, "WXConfigBindOK.aspx");
        }