Exemplo n.º 1
0
        protected void Page_Load(object sender, EventArgs e)
        {
            string RoleID;

            if (Session["RoleId"] != null)
            {
                RoleID = Session["RoleId"].ToString();
            }
            else
            {
                if (Request.Cookies["remember"] != null)
                {
                    RoleID = Request.Cookies["remember"].Value;
                }
                else
                {
                    RoleID = "-1";
                }
            }
            ShowAdditionalNavBar(RoleID);

            string token = Request.QueryString["Token"];

            if (token == null)
            {
                Response.Redirect("../RedeemToken/RedeemTokenPage.aspx");
            }
            else
            {
                Show          currentShow   = ShowController.GetShowByToken(token);
                User          currentSeller = UserController.GetUserById(currentShow.SellerId);
                Models.Review currentReview = ReviewController.GetReviewByToken(token);

                showButton(currentReview);
                showRating(currentReview);

                lblShowName.Text        = currentShow.Name;
                lblShowSellerName.Text  = currentSeller.Name;
                lblShowDescription.Text = currentShow.Description;
            }
        }