using BLL;
using Common;
using Lib;
using Model;
using System;
using System.Web.Mvc;
namespace wms.Areas.BasicInfo.Controllers
{
public class TrayManageController : MasterPage
{
// GET: BasicInfo/TrayManage
[LoginFilter]
public ActionResult TrayList()
{
ViewBag.LockList = LocalHelper.GetALockList(string.Empty);
return View();
}
///
/// 编辑新增视图加载时触发
///
/// 直接给视图变量赋值
public ActionResult AddTray()
{
try
{
string Palno = Request.QueryString.Get("Palno");
DALTray provider = new DALTray();
if (Palno != null)
{
Tray trayModel = provider.GetTrayModel(Palno);
ViewBag.LockList = LocalHelper.GetALockList(trayModel.ALockNo);
ViewBag.CreateTime = trayModel.CreateTime;
ViewBag.TrayList = trayModel;
}
else
{
// 绑定锁定属性下拉框
ViewBag.LockList = LocalHelper.GetALockList("N");
ViewBag.CreateTime = DateTime.Now.ToString();
ViewBag.TrayList = new Tray();
}
return View();
}
catch (System.Exception)
{
return View();
}
}
public ActionResult DeleteTray()
{
return View();
}
}
}