protected void AddBoxes_Click(object sender, EventArgs e)
{
if (Request.QueryString["ID"] != null)
{
if (txtBoxLocation.Text.Length > 1)
{
if (boxData != null)
{
boxData.Add(new KeyValuePair<string, int>(txtBoxLocation.Text, int.Parse(txtNumberOfBoxes.Text)));
}
else
{
boxData = new List<KeyValuePair<string, int>>();
boxData.Add(new KeyValuePair<string, int>(txtBoxLocation.Text, int.Parse(txtNumberOfBoxes.Text)));
}
}
Presenter.UpdateRecord();
txtBoxLocation.Text = "";
txtNumberOfBoxes.Text = "";
Presenter.GetRecordById(Request.QueryString["ID"]);
DrawBoxDetails();
}
else
{
Response.Redirect("search.aspx");
}
}