Ejemplo n.º 1
0
        private void LinkButtonAddToCart_Click(object sender, CommandEventArgs e)
        {
            ShoppinAction action = new ShoppinAction(Context);

            action.AddItemToCart(e.CommandArgument.ToString());
            this.CurrentController.NextView = action.NextViewToDisplay;
        }
Ejemplo n.º 2
0
 protected void RepeaterItem_ItemCommand(object source, System.Web.UI.WebControls.RepeaterCommandEventArgs e)
 {
     if (e.CommandName == "ShowItem")
     {
         CatalogAction action = new CatalogAction(Context);
         action.ShowItem(e.CommandArgument.ToString());
         this.CurrentController.NextView = action.NextViewToDisplay;
     }
     else if (e.CommandName == "AddToCart")
     {
         ShoppinAction action = new ShoppinAction(Context);
         action.AddItemToCart(e.CommandArgument.ToString());
         this.CurrentController.NextView = action.NextViewToDisplay;
     }
 }