diff --git a/MESWebSite/Excel/装配Bom导入模板.xlsx b/MESWebSite/Excel/装配Bom导入模板.xlsx new file mode 100644 index 0000000..1b1182f Binary files /dev/null and b/MESWebSite/Excel/装配Bom导入模板.xlsx differ diff --git a/MESWebSite/HttpHandlers/Bom_MKHandler.ashx.cs b/MESWebSite/HttpHandlers/Bom_MKHandler.ashx.cs index 86f79e7..0b49593 100644 --- a/MESWebSite/HttpHandlers/Bom_MKHandler.ashx.cs +++ b/MESWebSite/HttpHandlers/Bom_MKHandler.ashx.cs @@ -2,8 +2,11 @@ using MESClassLibrary.BLL.BasicInfo; using MESClassLibrary.EFModel; using MESWebSite.CommonClass; +using NPOI.SS.UserModel; +using NPOI.XSSF.UserModel; using System; using System.Collections.Generic; +using System.IO; using System.Linq; using System.Web; @@ -37,7 +40,10 @@ namespace MESWebSite.HttpHandlers case "DelInfo": DelInfo(); break; - + case "QueryExcel": + QueryExcel(); + break; + default: break; @@ -83,8 +89,36 @@ namespace MESWebSite.HttpHandlers string IsPartAssemble = Request.Params["IsPartAssemble"]; string StationNo = Request.Params["StationNo"]; string LineName = Request.Params["LineName"]; + string LeftCount = Request.Params["LeftCount"]; + string RightCount = Request.Params["RightCount"]; + string ProductName1 = Request.Params["ProductName1"]; + string ProductName2 = Request.Params["ProductName2"]; + + if(string.IsNullOrEmpty(LeftCount)) + { + LeftCount = "0"; + } + if (string.IsNullOrEmpty(RightCount)) + { + RightCount = "0"; + } + string lineName = ""; + BasicBLL lineNameDB = new BasicBLL(); + var lineNameList = lineNameDB.Search(p => p.LineName == LineName); + if (lineNameList != null && lineNameList.Count > 0) + { + lineName = lineNameList[0].LineName; + } + + if (string.IsNullOrEmpty(lineName)) + { + Response.Write(ResponseResult.Fail("产线不存在!")); + Response.End(); + return; + } + string stationNo = ""; BasicBLL stationDB = new BasicBLL(); var stationList = stationDB.Search(p => p.StationNo == StationNo); @@ -100,6 +134,44 @@ namespace MESWebSite.HttpHandlers return; } + //一个总成对应一个半成品 + BasicBLL partAssembleNum = new BasicBLL(); + int id_mk = int.Parse(BomID); + var partAssembleList = partAssembleNum.Search(p => p.PartNo1 == PartNo1 && p.IsPartAssemble == 1 && p.BomID != id_mk); + if (partAssembleList != null && partAssembleList.Count == 1 && IsPartAssemble == "1") + { + Response.Write(ResponseResult.Fail("一个总成只能配置一个半成品!")); + Response.End(); + return; + } + + //查询产品描述 + BasicBLL productDesc = new BasicBLL(); + var productDescList = productDesc.Search(p => p.PartNo == PartNo1); + if (productDescList != null && productDescList.Count >= 1 ) + { + ProductName1 = productDescList[0].ProductName; + } + else + { + Response.Write(ResponseResult.Fail("总成零件号:" + PartNo1 +" 产品信息不存在")); + Response.End(); + return; + } + + productDescList = productDesc.Search(p => p.PartNo == PartNo2); + if (productDescList != null && productDescList.Count >= 1) + { + ProductName2 = productDescList[0].ProductName; + } + else + { + Response.Write(ResponseResult.Fail("子零件号:" + PartNo2 + " 产品信息不存在")); + Response.End(); + return; + } + + Bom_MKBLL bll = new Bom_MKBLL(); tb_Bom_MK md = new tb_Bom_MK(); @@ -107,7 +179,12 @@ namespace MESWebSite.HttpHandlers md.PartNo2 = PartNo2; md.LineName = LineName; md.StationNo = StationNo; - if(IsPartAssemble == "1") + md.LeftCount = int.Parse(LeftCount); + md.RightCount = int.Parse(RightCount); + md.PartDesc1 = ProductName1; + md.PartDesc2 = ProductName2; + + if (IsPartAssemble == "1") { md.IsPartAssemble = 1; } @@ -129,6 +206,15 @@ namespace MESWebSite.HttpHandlers if (BomID == "0") { + BasicBLL partNoBindDB = new BasicBLL(); + var partNo1List = partNoBindDB.Search(p => p.PartNo1 == PartNo1 && p.PartNo2 == PartNo2 && p.LineName == LineName && p.StationNo == StationNo); + if (partNo1List != null && partNo1List.Count > 0) + { + Response.Write(ResponseResult.Fail("BOM总成零件号与子零件号绑定关系在系统中已存在")); + Response.End(); + return; + } + //新增 //md.BomID = Guid.NewGuid().ToString(); Response.Write(bll.AddInfo(md) == true ? ResponseResult.Success() : ResponseResult.Fail("添加失败")); @@ -158,5 +244,37 @@ namespace MESWebSite.HttpHandlers } + void QueryExcel() + { + string PartNo1 = Request.Params["PartNo1"]; + string LineName = Request.Params["LineName"]; + + Bom_MKBLL bll = new Bom_MKBLL(); + + List> list = bll.SearchForExcel(PartNo1, LineName); + XSSFWorkbook book = new XSSFWorkbook(); + ISheet sheet = book.CreateSheet("Sheet1"); + + for (int i = 0; i < list.Count; i++) + { + IRow row = sheet.CreateRow(i); + + for (int k = 0; k < list[i].Count; k++) + { + row.CreateCell(k).SetCellValue(list[i][k].ToString()); + } + + } + + // 写入到客户端 + MemoryStream ms = new MemoryStream(); + book.Write(ms); + Response.AddHeader("Content-Disposition", string.Format("attachment; filename={0}.xlsx", DateTime.Now.ToString("yyyyMMddHHmmssfff"))); + Response.BinaryWrite(ms.ToArray()); + book = null; + ms.Close(); + ms.Dispose(); + } + } } \ No newline at end of file diff --git a/MESWebSite/HttpHandlers/ConfigHandler.ashx b/MESWebSite/HttpHandlers/ConfigHandler.ashx new file mode 100644 index 0000000..210020a --- /dev/null +++ b/MESWebSite/HttpHandlers/ConfigHandler.ashx @@ -0,0 +1 @@ +<%@ WebHandler Language="C#" CodeBehind="ConfigHandler.ashx.cs" Class="MESWebSite.HttpHandlers.ConfigHandler" %> diff --git a/MESWebSite/HttpHandlers/ConfigHandler.ashx.cs b/MESWebSite/HttpHandlers/ConfigHandler.ashx.cs new file mode 100644 index 0000000..519f5f3 --- /dev/null +++ b/MESWebSite/HttpHandlers/ConfigHandler.ashx.cs @@ -0,0 +1,132 @@ +using MESClassLibrary.BLL.BasicInfo; +using MESClassLibrary.EFModel; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Web; + +namespace MESWebSite.HttpHandlers +{ + /// + /// ConfigHandler 的摘要说明 + /// + public class ConfigHandler : IHttpHandler + { + + HttpRequest Request = null; + HttpResponse Response = null; + + public void ProcessRequest(HttpContext context) + { + context.Response.ContentType = "text/plain"; + Request = context.Request; + Response = context.Response; + + string method = Request.Params["method"]; + switch (method) + { + + case "QueryList": + QueryList(); + break; + case "SaveInfo": + SaveInfo(); + break; + case "DelInfo": + DelInfo(); + break; + case "QueryForCombobox": + QueryForCombobox(); + break; + default: + break; + + } + + } + public bool IsReusable + { + get + { + return false; + } + } + + void QueryList() + { + string page = Request.Params["page"]; + string pagesize = Request.Params["rows"]; + string name = Request.Params["name"]; + + if (string.IsNullOrEmpty(page)) + { + page = "0"; + } + if (string.IsNullOrEmpty(pagesize)) + { + pagesize = "15"; + } + ConfigBLL bll = new ConfigBLL(); + Response.Write(bll.SearchInfo(page, pagesize, name)); + Response.End(); + + + } + void SaveInfo() + { + string ID = Request.Params["ID"]; + string name = Request.Params["name"]; + string value = Request.Params["value"]; + string des = Request.Params["des"]; + + ConfigBLL bll = new ConfigBLL(); + tb_Config md = new tb_Config(); + + //md.name = name; + if(value != "true" && value != "false") + { + Response.Write("false"); + Response.End(); + return; + } + md.value = value; + //md.des = des; + + + + if (ID == "0") + { + //新增 + md.ID = Guid.NewGuid().ToString(); + Response.Write(bll.AddInfo(md) == true ? "true" : "false"); + } + else + { + //修改 + md.ID = ID; + Response.Write(bll.UpdateInfo(md) == true ? "true" : "false"); + } + Response.End(); + } + void DelInfo() + { + string ID = Request.Params["ID"]; + + ConfigBLL bll = new ConfigBLL(); + tb_Config md = new tb_Config(); + + md.ID = ID; + //Response.Write(bll.DelInfo(md) == true ? "true" : "false"); + Response.Write("false"); + Response.End(); + + } + void QueryForCombobox() + { + PlaceBLL bll = new PlaceBLL(); + Response.Write(bll.GetComboboxData()); + Response.End(); + + } + } +} \ No newline at end of file diff --git a/MESWebSite/HttpHandlers/ZP_MK_PlanHandler.ashx.cs b/MESWebSite/HttpHandlers/ZP_MK_PlanHandler.ashx.cs index 75d0df8..589c248 100644 --- a/MESWebSite/HttpHandlers/ZP_MK_PlanHandler.ashx.cs +++ b/MESWebSite/HttpHandlers/ZP_MK_PlanHandler.ashx.cs @@ -40,11 +40,12 @@ namespace MESWebSite.HttpHandlers string StartTime = GetParam("StartTime"); string EndTime = GetParam("EndTime"); string PartNo = GetParam("PartNo"); + string State = GetParam("State"); int page = Page.To32Int(); int pageSize = Rows.To32Int(); ZP_MK_PlanBLL bll = new ZP_MK_PlanBLL(); - string reslut = bll.SearchInfoAll(page, pageSize, StartTime, EndTime, PartNo); + string reslut = bll.SearchInfoAll(page, pageSize, StartTime, EndTime, PartNo, State); Response.Write(reslut); Response.End(); } @@ -126,17 +127,7 @@ namespace MESWebSite.HttpHandlers Station = station, }; - - //DataTable dt = bll.SearchOrderNo(DateTime.Now.ToString("yyyMMdd")); - //if (dt != null && dt.Rows.Count > 0) - //{ - // string old = dt.Rows[0]["OrderNo"].ToString(); - // zpp.OrderNo = DateTime.Now.ToString("yyyMMdd") + (Convert.ToInt32(old.Substring(old.Length - 4, 4))+1).ToString().PadLeft(4,'0'); - //} - //else - //{ - // zpp.OrderNo = DateTime.Now.ToString("yyyMMdd") + "0001"; - //} + if (id == "0") { diff --git a/MESWebSite/MESWebSite.csproj b/MESWebSite/MESWebSite.csproj index ccaf66e..86a2684 100644 --- a/MESWebSite/MESWebSite.csproj +++ b/MESWebSite/MESWebSite.csproj @@ -121,6 +121,7 @@ + @@ -840,6 +841,8 @@ + + @@ -1094,6 +1097,9 @@ BucketStateHandler.ashx + + ConfigHandler.ashx + XDProductHandler.ashx @@ -1363,6 +1369,13 @@ BucketState.aspx + + Config.aspx + ASPXCodeBehind + + + Config.aspx + XDStockArea.aspx ASPXCodeBehind diff --git a/MESWebSite/MESWebSite.csproj.user b/MESWebSite/MESWebSite.csproj.user index ced2bb3..9b19fce 100644 --- a/MESWebSite/MESWebSite.csproj.user +++ b/MESWebSite/MESWebSite.csproj.user @@ -1,7 +1,7 @@ - + - D:\Project\2、北汽模塑一厂\SVN\Code\MESWebSite\Properties\PublishProfiles\BBMPT1.pubxml + D:\job\BBMPT1\MESWebSite\Properties\PublishProfiles\FolderProfile.pubxml ProjectFiles Debug|Any CPU true diff --git a/MESWebSite/Manage/Bom_MK.aspx b/MESWebSite/Manage/Bom_MK.aspx index bd4c6b8..637c35d 100644 --- a/MESWebSite/Manage/Bom_MK.aspx +++ b/MESWebSite/Manage/Bom_MK.aspx @@ -77,6 +77,12 @@ 删除 + + 导出 + + + 导入 + @@ -153,7 +159,29 @@ data-options="valueField: 'StationID',textField: 'StationNo'"> * - + + + +

+ 左侧数量: +

+ + + + + + + +

+ 右侧数量: +

+ + + + + + + @@ -164,6 +192,34 @@ + + + + + + + diff --git a/MESWebSite/Manage/Bom_MK.aspx.cs b/MESWebSite/Manage/Bom_MK.aspx.cs index 9d22bf4..aa01a3a 100644 --- a/MESWebSite/Manage/Bom_MK.aspx.cs +++ b/MESWebSite/Manage/Bom_MK.aspx.cs @@ -1,9 +1,17 @@ -using System; +using MESClassLibrary.BLL.BasicInfo; +using MESClassLibrary.BLL.Log; +using MESClassLibrary.EFModel; +using System; using System.Collections.Generic; +using System.Data.OleDb; +using System.Data; using System.Linq; +using System.Reflection; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; +using System.IO; +using MESClassLibrary.BLL; namespace MESWebSite.Manage { @@ -16,5 +24,263 @@ namespace MESWebSite.Manage Response.Write(""); } } + + + protected void ImportExcel_Click(object sender, EventArgs e) + { + try + { + if (input01.PostedFile.ContentLength > 0) + { + string strUrl = "../Excel/"; + if (Directory.Exists(Server.MapPath(strUrl)) == false) + { + Directory.CreateDirectory(Server.MapPath(strUrl)); + } + String fileExtension = System.IO.Path.GetExtension(input01.PostedFile.FileName).ToLower(); + String fileName = DateTime.Now.ToString("yyyyMMddHHmmssfff") + fileExtension; + input01.PostedFile.SaveAs(Server.MapPath(strUrl) + fileName); + string excelPath = Server.MapPath(strUrl) + fileName; + DataTable dt = null; + + #region 校验文件 + + try + { + dt = GetExcelTableByOleDB(excelPath, "Sheet1"); + if (dt != null && dt.Rows.Count > 1) + { + + } + else + { + ClientScript.RegisterStartupScript(this.GetType(), "tishi", ""); + return; + } + } + catch (Exception ex) + { + LogErrBLL.AddInfo(ex.ToString(), MethodBase.GetCurrentMethod()); + return; + } + + #endregion + + Bom_MKBLL bll = new Bom_MKBLL(); + List list = new List(); + tb_Bom_MK md = new tb_Bom_MK(); + + ProductBLL pbll = new ProductBLL(); + LineBLL linebll = new LineBLL(); + StationBLL stationbll = new StationBLL(); + BasicBLL partNoBindDB = new BasicBLL(); + + + #region 校验数据 + + if (dt != null && dt.Rows.Count > 0) + { + for (int i = 1; i < dt.Rows.Count; i++) + { + #region 值校验 + + string PartNo1 = dt.Rows[i][0].ToString(); + if (PartNo1 == "") + { + ClientScript.RegisterStartupScript(this.GetType(), "tishi", ""); + return; + } + string PartNo2 = dt.Rows[i][1].ToString(); + if (PartNo2 == "") + { + ClientScript.RegisterStartupScript(this.GetType(), "tishi", ""); + return; + } + + string LineName = dt.Rows[i][2].ToString(); + if (LineName == "") + { + ClientScript.RegisterStartupScript(this.GetType(), "tishi", ""); + return; + } + + string StationNo = dt.Rows[i][3].ToString(); + if (StationNo == "") + { + ClientScript.RegisterStartupScript(this.GetType(), "tishi", ""); + return; + } + + string LeftCount = dt.Rows[i][4].ToString(); + if (LeftCount == "") + { + ClientScript.RegisterStartupScript(this.GetType(), "tishi", ""); + return; + } + + string RightCount = dt.Rows[i][5].ToString(); + if (RightCount == "") + { + ClientScript.RegisterStartupScript(this.GetType(), "tishi", ""); + return; + } + + #endregion + + #region 逻辑校验 + + if (!pbll.IsExist(PartNo1)) + { + ClientScript.RegisterStartupScript(this.GetType(), "提示", ""); + return; + } + + if (!pbll.IsExist(PartNo2)) + { + ClientScript.RegisterStartupScript(this.GetType(), "提示", ""); + return; + } + + if (!linebll.IsExist(LineName)) + { + ClientScript.RegisterStartupScript(this.GetType(), "提示", ""); + return; + } + + if (!stationbll.IsExist(StationNo)) + { + ClientScript.RegisterStartupScript(this.GetType(), "提示", ""); + return; + } + + var partNo1List = partNoBindDB.Search(p => p.PartNo1 == PartNo1 && p.PartNo2 == PartNo2 && p.LineName == LineName && p.StationNo == StationNo); + if (partNo1List != null && partNo1List.Count > 0) + { + ClientScript.RegisterStartupScript(this.GetType(), "提示", ""); + return; + } + + #endregion + + var info = Request.Cookies.Get("LoginUserInfo"); + if (info != null) + { + md.UserID = info["UserID"].ToUpper(); + } + + + md.PartNo1 = PartNo1; + md.PartNo2 = PartNo2; + md.LineName = LineName; + md.StationNo = StationNo; + md.LeftCount = int.Parse(LeftCount); + md.RightCount = int.Parse(RightCount); + + list.Add(md); + } + } + + #endregion + + #region 存储数据 + + try + { + bool flag = false; + if (list.Count > 0) + { + foreach (var item in list) + { + flag = bll.AddInfo(item); + } + } + if (flag == true) + { + ClientScript.RegisterStartupScript(this.GetType(), "提示", ""); + } + else + { + ClientScript.RegisterStartupScript(this.GetType(), "提示", ""); + } + + } + catch (Exception ex) + { + LogErrBLL.AddInfo(ex.ToString(), MethodBase.GetCurrentMethod()); + } + + #endregion + } + } + catch (Exception ex) + { + LogErrBLL.AddInfo(ex.ToString(), MethodBase.GetCurrentMethod()); + } + } + + public DataTable GetExcelTableByOleDB(string strExcelPath, string tableName) + { + OleDbConnection objConn = null; + try + { + DataTable dtExcel = new DataTable(); + //数据表 + DataSet ds = new DataSet(); + //获取文件扩展名 + string strExtension = System.IO.Path.GetExtension(strExcelPath); + string strFileName = System.IO.Path.GetFileName(strExcelPath); + //Excel的连接 + + switch (strExtension) + { + case ".xls": + objConn = new OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + strExcelPath + ";" + "Extended Properties=\"Excel 8.0;HDR=NO;IMEX=1;\""); + break; + case ".xlsx": + objConn = new OleDbConnection("Provider=Microsoft.ACE.OLEDB.12.0;Data Source=" + strExcelPath + ";" + "Extended Properties=\"Excel 12.0;HDR=NO;IMEX=1;\""); + break; + + default: + objConn = null; + break; + } + if (objConn == null) + { + return null; + } + try + { + objConn.Open(); + } + catch (Exception ex) + { + + } + + //获取Excel中所有Sheet表的信息 + //System.Data.DataTable schemaTable = objConn.GetOleDbSchemaTable(System.Data.OleDb.OleDbSchemaGuid.Tables, null); + //获取Excel的第一个Sheet表名 + //string tableName = schemaTable.Rows[0][2].ToString().Trim(); + string strSql = "select * from [" + tableName + "$]"; + //获取Excel指定Sheet表中的信息 + OleDbCommand objCmd = new OleDbCommand(strSql, objConn); + OleDbDataAdapter myData = new OleDbDataAdapter(strSql, objConn); + myData.Fill(ds, tableName);//填充数据 + objConn.Close(); + //dtExcel即为excel文件中指定表中存储的信息 + dtExcel = ds.Tables[tableName]; + return dtExcel; + } + catch (Exception ex) + { + if (objConn != null) + { + objConn.Close(); + } + + return null; + } + } + } } \ No newline at end of file diff --git a/MESWebSite/Manage/Bom_MK.aspx.designer.cs b/MESWebSite/Manage/Bom_MK.aspx.designer.cs index 427fc22..b8f0584 100644 --- a/MESWebSite/Manage/Bom_MK.aspx.designer.cs +++ b/MESWebSite/Manage/Bom_MK.aspx.designer.cs @@ -23,6 +23,24 @@ namespace MESWebSite.Manage /// protected global::System.Web.UI.HtmlControls.HtmlForm form1; + /// + /// ProductName1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::System.Web.UI.HtmlControls.HtmlInputText ProductName1; + + /// + /// ProductName2 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::System.Web.UI.HtmlControls.HtmlInputText ProductName2; + /// /// lblMessage 控件。 /// @@ -32,6 +50,42 @@ namespace MESWebSite.Manage /// protected global::System.Web.UI.WebControls.Label lblMessage; + /// + /// Label1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::System.Web.UI.WebControls.Label Label1; + + /// + /// Label2 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::System.Web.UI.WebControls.Label Label2; + + /// + /// ImportExcel 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::System.Web.UI.WebControls.Button ImportExcel; + + /// + /// input01 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::System.Web.UI.HtmlControls.HtmlInputFile input01; + /// /// UserID 控件。 /// diff --git a/MESWebSite/Manage/Config.aspx b/MESWebSite/Manage/Config.aspx new file mode 100644 index 0000000..7c9174a --- /dev/null +++ b/MESWebSite/Manage/Config.aspx @@ -0,0 +1,354 @@ +<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Config.aspx.cs" Inherits="MESWebSite.Manage.Config" %> + + + + + + + + + + + + + + + + 配置信息 + + +
+
+ + + + + + + + + + + + +
配置信息 + 配置项: + 查询 + 新增 + + 编辑 + + 删除 +
+
+ +
+ + + + + + + + +
+ + diff --git a/MESWebSite/Manage/Config.aspx.cs b/MESWebSite/Manage/Config.aspx.cs new file mode 100644 index 0000000..d8112ab --- /dev/null +++ b/MESWebSite/Manage/Config.aspx.cs @@ -0,0 +1,20 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Web; +using System.Web.UI; +using System.Web.UI.WebControls; + +namespace MESWebSite.Manage +{ + public partial class Config : System.Web.UI.Page + { + protected void Page_Load(object sender, EventArgs e) + { + if (Request.Cookies["LoginUserInfo"] == null) + { + Response.Write(""); + } + } + } +} \ No newline at end of file diff --git a/MESWebSite/Manage/Config.aspx.designer.cs b/MESWebSite/Manage/Config.aspx.designer.cs new file mode 100644 index 0000000..e69bb7c --- /dev/null +++ b/MESWebSite/Manage/Config.aspx.designer.cs @@ -0,0 +1,44 @@ +//------------------------------------------------------------------------------ +// <自动生成> +// 此代码由工具生成。 +// +// 对此文件的更改可能导致不正确的行为,如果 +// 重新生成代码,则所做更改将丢失。 +// +//------------------------------------------------------------------------------ + +namespace MESWebSite.Manage +{ + + + public partial class Config + { + + /// + /// form1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::System.Web.UI.HtmlControls.HtmlForm form1; + + /// + /// lblMessage 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::System.Web.UI.WebControls.Label lblMessage; + + /// + /// UserID 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::System.Web.UI.HtmlControls.HtmlInputText UserID; + } +} diff --git a/MESWebSite/Manage/ZP_MK_Plan.aspx b/MESWebSite/Manage/ZP_MK_Plan.aspx index 2d34d91..7ee663a 100644 --- a/MESWebSite/Manage/ZP_MK_Plan.aspx +++ b/MESWebSite/Manage/ZP_MK_Plan.aspx @@ -57,10 +57,13 @@ - + +
门槛装配计划 零件号: 状态: + + 装配时间: @@ -290,6 +293,24 @@ return getTime(unixtime).substring(0, 19); } }, + { + field: 'State', title: '状态', sortable: 'true', width: 10, + formatter: function (value) { + if (value == 0) { + return "新建"; + } + else if (value == 1) { + return "启用"; + } + else if (value == 2) { + return "暂停"; + } + else { + return "完成"; + } + } + }, + ]], @@ -384,12 +405,14 @@ function SearchInfo() { var PartNo = $('#part_no_s').val(); + var State = $('#state_s').val(); var StartTime = $('#start_time').datebox('getValue'); var EndTime = $('#end_time').datebox('getValue'); dg.datagrid({ queryParams: { PartNo, + State, StartTime, EndTime } diff --git a/MESWebSite/Properties/PublishProfiles/FolderProfile.pubxml b/MESWebSite/Properties/PublishProfiles/FolderProfile.pubxml new file mode 100644 index 0000000..0246c1b --- /dev/null +++ b/MESWebSite/Properties/PublishProfiles/FolderProfile.pubxml @@ -0,0 +1,17 @@ + + + + + false + false + true + Release + Any CPU + FileSystem + D:\发布\Mes + FileSystem + <_TargetId>Folder + + \ No newline at end of file