예제 #1
0
        protected void Page_Load(object sender, EventArgs e)
        {
            Logic = new AddServices_Logic();
            string s = Request["Type"];

            if (!IsPostBack && s == "Edit")
            {
                string ss    = Request["Id"];
                int    Id    = Convert.ToInt32(ss);
                var    model = Logic.GetService(Id);

                TextBoxSub.Text              = model.Subject;
                TextBox_RSub.Text            = model.RightSub;
                TextBox1.Text                = model.discription;
                TextBox_SEO_D.Text           = model.SEO_discription;
                TextBox_SEO_K.Text           = model.SEO_Keyword;
                TextBox_VideoLink.Text       = model.VideoLink;
                TextBox_VideoSub1.Text       = model.VideoSub1;
                TextBox_VideoSub2.Text       = model.VideoSub2;
                HiddenField_BackGround.Value = model.Background_Id.ToString();
                HiddenField_LeftPic.Value    = model.LeftPic_Id.ToString();
                HiddenField_RightPic.Value   = model.RightPic_Id.ToString();
                HiddenField_VideoBack.Value  = model.VideoBackground_Id.ToString();

                if (model.Show == 1)
                {
                    CheckBox_Show.Checked = true;
                }
            }
        }