Hidistro.UI.SaleSystem.CodeBehind/VDistributorDescription.cs

(完整代码) 2KB

namespace Hidistro.UI.SaleSystem.CodeBehind
{
    using Hidistro.Core;
    using Hidistro.Core.Entities;
    using Hidistro.Entities.Members;
    using Hidistro.SaleSystem.Vshop;
    using Hidistro.UI.Common.Controls;
    using System;
    using System.Web;
    using System.Web.UI;
    using System.Web.UI.HtmlControls;
    using System.Web.UI.WebControls;

    [ParseChildren(true)]
    public class VDistributorDescription : VMemberTemplatedWebControl
    {
        protected string IsEnable = "0";
        private Literal litApplicationDescription;
        private HtmlInputHidden litIsEnable;
        private HtmlInputHidden litRMsg;
        protected string RMsg = "您未达到开店条件,最低消费金额需要达到{0}元才能申请,你当前累计消费金额为{1}元";

        protected override void AttachChildControls()
        {
            this.litIsEnable = (HtmlInputHidden) this.FindControl("litIsEnable");
            this.litRMsg = (HtmlInputHidden) this.FindControl("litRMsg");
            this.litApplicationDescription = (Literal) this.FindControl("litApplicationDescription");
            SiteSettings masterSettings = SettingsManager.GetMasterSettings(true);
            this.litApplicationDescription.Text = HttpUtility.HtmlDecode(masterSettings.DistributorDescription);
            PageTitle.AddSiteNameTitle("分销说明信息");
            this.Page.Session["stylestatus"] = "2";
            if (DistributorsBrower.GetUserIdDistributors(Globals.GetCurrentMemberUserId()) != null)
            {
                this.IsEnable = "1";
            }
            else
            {
                int finishedOrderMoney = masterSettings.FinishedOrderMoney;
                MemberInfo currentMember = MemberProcessor.GetCurrentMember();
                this.RMsg = string.Format(this.RMsg, finishedOrderMoney, currentMember.Expenditure);
                if (currentMember.Expenditure >= finishedOrderMoney)
                {
                    this.IsEnable = "2";
                }
            }
            this.litIsEnable.Value = this.IsEnable;
            this.litRMsg.Value = this.RMsg;
        }

        protected override void OnInit(EventArgs e)
        {
            if (this.SkinName == null)
            {
                this.SkinName = "Skin-VDistributorDesciption.html";
            }
            base.OnInit(e);
        }
    }
}

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。