示例#1
0
        static SiteHelper()
        {
            ISysSettingService sysSettingService = IoC.Resolve <ISysSettingService>();

            SysSetting = sysSettingService.SeleteAll();
        }
示例#2
0
        private void Bind()
        {
            ISysSettingService sysSettingService = IoC.Resolve <ISysSettingService>();
            var rList = sysSettingService.SeleteAll();

            if (rList != null && rList.Count > 0)
            {
                foreach (var item in rList)
                {
                    switch (item.Key)
                    {
                    //平台名称
                    case "PTMC":
                        this.txtTitle.Text = item.Value;
                        break;

                    //网站开关
                    case "WZKG":
                        drpIsShowDialog.SelectedValue = item.Value;
                        break;

                    //网站关闭公告内容
                    case "WZGGKG":
                        this.txtContent.Text = item.Value;
                        break;

                    //中奖排行开关
                    case "ZJPHKG":
                        drpShangBanOpen.SelectedValue = item.Value;
                        break;

                    //会员上榜最低中奖金额
                    case "HYSPZDZJJE":
                        this.txtMinMonery.Text = item.Value;
                        break;

                    //虚拟上榜会员昵称
                    case "XNSPHYNC":
                        this.txtXuNiInContennt.Text = item.Value;
                        break;

                    case "CZXZ":    //充值限制
                        if (!string.IsNullOrEmpty(item.Value))
                        {
                            var ary = item.Value.Split(',');
                            this.txtInMinMonery.Text = ary[0];
                            this.txtInMaxMonery.Text = ary[1];
                        }
                        break;

                    case "TXXZ":    //提款限制
                        if (!string.IsNullOrEmpty(item.Value))
                        {
                            var ary = item.Value.Split(',');
                            this.txtOutMinMonery.Text = ary[0];
                            this.txtOutMaxMonery.Text = ary[1];
                        }
                        break;

                    case "ZCZSHD":     //充值赠送活动
                        if (!string.IsNullOrEmpty(item.Value))
                        {
                            var des = Newtonsoft.Json.JsonConvert.DeserializeObject <SettingDTO>(item.Value);
                            if (null != des)
                            {
                                chkopenZengSong.Checked = des.p1 == "0";    //0为开启
                                txtNewUserZenSong.Text  = des.p2;
                                txtNewUserBeiShu.Text   = des.p3;
                            }
                        }
                        break;

                    case "chongzhiBili":    //充值提款消费比例
                        if (!string.IsNullOrEmpty(item.Value))
                        {
                            txtRechangeMinBili.Text = item.Value;
                        }
                        break;

                    case "ZXLTPATH":    //跳转地址
                        this.txtUrl.Text = string.IsNullOrEmpty(item.Value)?"http://":item.Value;
                        break;

                    case "KHLJ":
                        this.txtKfAddress.Text = string.IsNullOrEmpty(item.Value) ? "http://" : item.Value;
                        break;

                    case "QLZHGZ":     //提现审核
                        this.txtShMonery.Text = item.Value;
                        break;

                    case "mobao_pay":     //摩宝支付
                        this.drpMb.SelectedValue = item.Value;
                        break;

                    case "zhifu_pay":     //智付支付
                        this.drpzhifu.SelectedValue = item.Value;
                        break;

                    case "my18_pay":     //ny18
                        this.drpMy18.SelectedValue = item.Value;
                        break;

                    case "ti_xian_isopen":     //是否开启提现
                        this.drptx.SelectedValue = item.Value;
                        break;

                    case "ti_xian_shi_bai_info":     //关闭提现功能原因
                        this.txtTxErrorMsg.Text = item.Value;
                        break;

                    case "zhb_rect_url":
                        this.lbzfb.Text = item.Value;
                        break;

                    case "wx_rect_url":
                        this.lbwx.Text = item.Value;
                        break;
                    }
                }
            }
        }