Files
cs-oo-project/Online Gokkantoor/Gui/addPloeg.aspx.cs
Beppe d883bce694 euh
2019-07-06 01:41:20 +02:00

37 lines
937 B
C#

using System;
using System.Web;
using System.Web.UI;
using Globals.classes;
using Logic;
namespace Gui
{
public partial class addPloeg : System.Web.UI.Page
{
LogicLayer logic;
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
logic = (LogicLayer)System.Web.HttpContext.Current.Application["logic"];
}
}
public void confirm_Click(object sender, EventArgs e)
{
Ploeg p = new Ploeg(naam.Text);
logic = (LogicLayer)System.Web.HttpContext.Current.Application["logic"];
logic.addPloeg(p);
logic.save();
HttpContext.Current.Application["logic"] = logic;
Response.Redirect("Admin.aspx");
}
public void ret_Click(object sender, EventArgs e)
{
Response.Redirect("Admin.aspx");
}
}
}