protected void Page_Load(object sender, EventArgs e)
        {
            if (Session["isLoggedIn"] == null)
            {
                Response.Redirect("Default.aspx");
            }
            ws = new IntWebService1();
            loggedInUser = (User)Session["loggedInUser"];

            PopulateInvoice();
        }
示例#2
0
 /// <summary>
 /// Create a new User object.
 /// </summary>
 /// <param name="id">Initial value of the Id property.</param>
 /// <param name="name">Initial value of the Name property.</param>
 /// <param name="email">Initial value of the Email property.</param>
 /// <param name="username">Initial value of the Username property.</param>
 /// <param name="password">Initial value of the Password property.</param>
 /// <param name="lastLogin">Initial value of the LastLogin property.</param>
 public static User CreateUser(global::System.Int32 id, global::System.String name, global::System.String email, global::System.String username, global::System.String password, global::System.DateTime lastLogin)
 {
     User user = new User();
     user.Id = id;
     user.Name = name;
     user.Email = email;
     user.Username = username;
     user.Password = password;
     user.LastLogin = lastLogin;
     return user;
 }
示例#3
0
        protected void Page_Load(object sender, EventArgs e)
        {
            if (Session["isLoggedIn"] == null)
            {
                Response.Redirect("Default.aspx");
            }

            ws = new IntWebService1();
            loggedInUser = (User)Session["loggedInUser"];
            if (!IsPostBack)
            {
                lblUsername.Text = loggedInUser.Name;
                GridView1.DataSource = ws.GetProducts();
                GridView1.DataBind();
            }
            ShowCartGrid();
        }
示例#4
0
 /// <summary>
 /// Deprecated Method for adding a new object to the Users EntitySet. Consider using the .Add method of the associated ObjectSet&lt;T&gt; property instead.
 /// </summary>
 public void AddToUsers(User user)
 {
     base.AddObject("Users", user);
 }