Beispiel #1
0
        protected void Save_B_Click(object sender, EventArgs e)
        {
            M_PayPlat wxpay = B_PayPlat.GetModelForWx();

            if (wxpay == null)
            {
                wxpay = new M_PayPlat();
            }
            wxpay.PayPlatName = "微信支付";
            wxpay.payType     = AppID_T.Text;
            wxpay.PayPlatinfo = Secret_T.Text;
            wxpay.AccountID   = MchID_T.Text;
            wxpay.PayClass    = 21;
            wxpay.MD5Key      = Key_T.Text;
            if (wxpay.PayPlatID == 0)
            {
                bll.insert(wxpay);
            }
            else
            {
                bll.UpdateByID(wxpay);
            }
            WxPayConfig.UpdateByMod(wxpay);
            function.WriteSuccessMsg("保存成功!");
        }
Beispiel #2
0
        public void WechatPlat_Submit(M_PayPlat model)
        {
            M_PayPlat info = B_PayPlat.GetModelForWx();

            info.APPID     = model.APPID;
            info.Secret    = model.Secret;
            info.AccountID = model.AccountID;
            info.MD5Key    = model.MD5Key;
            platBll.UpdateByID(info);
            WriteOK("操作成功", "WechatPlat");
        }
Beispiel #3
0
        public void MyBind()
        {
            M_PayPlat wxpay = B_PayPlat.GetModelForWx();

            if (wxpay != null)
            {
                AppID_T.Text  = wxpay.payType;     //appid
                Secret_T.Text = wxpay.PayPlatinfo; //Secret
                MchID_T.Text  = wxpay.AccountID;
                Key_T.Text    = wxpay.MD5Key;
                // Cert_T.Text = wxpay.SellerEmail;//证书路径
                //CertPWD_T.Text = wxpay.leadtoGroup;//证书密码
            }
        }
Beispiel #4
0
        //=======【基本信息设置】=====================================

        /* 微信公众号信息配置
         * APPID:绑定支付的APPID(必须配置)
         * MCHID:商户号(必须配置)
         * KEY:商户支付密钥,参考开户邮件设置(必须配置)
         * APPSECRET:公众帐号secert(仅JSAPI支付的时候需要配置)
         */
        static WxPayConfig()
        {
            UpdateByMod(B_PayPlat.GetModelForWx());
        }
Beispiel #5
0
        public IActionResult WechatPlat()
        {
            M_PayPlat model = B_PayPlat.GetModelForWx();

            return(View(model));
        }