示例#1
0
文件: Start.cs 项目: kyjb2000/uo-mes
 protected virtual void AssignStartDetailToStartDetail(StartDetail s, StartDetail t)
 {
     t.ContainerName       = s.ContainerName;
     t.ContainerLevel_Name = s.ContainerLevel_Name;
     t.DueDate             = s.DueDate;
     t.Product_Revision    = s.Product_Revision;
     t.Qty      = s.Qty;
     t.UOM_Name = s.UOM_Name;
 }
示例#2
0
文件: Start.cs 项目: kyjb2000/uo-mes
 public void UpdateDetails(StartDetail s)
 {
     foreach (StartDetail t in Details)
     {
         if (t.ServiceDetailID == s.ServiceDetailID)
         {
             AssignStartDetailToStartDetail(s, t);
         }
     }
 }
示例#3
0
 protected void btnAddNewDetail_Click(object sender, EventArgs e)
 {
     Start s = MESPageService as Start;
     StartDetail sd = new StartDetail();
     sd.ContainerName = "NewLot"+s.SelectDetails().Count;
     sd.ContainerLevel_Name = "Lot";
     sd.DueDate = DateTime.Now;
     sd.Product_Revision = "ProductA(r2)";
     sd.UOM_Name = "Piece";
     sd.ContainerStatus_Name = "Active";
     s.InsertDetail(sd);
     GridView1.DataBind();
 }
示例#4
0
文件: Start.cs 项目: kyjb2000/uo-mes
        public void DeleteDetail(StartDetail s)
        {
            int i = -1;

            foreach (StartDetail t in Details)
            {
                if (t.ServiceDetailID == s.ServiceDetailID)
                {
                    i = Details.IndexOf(t);
                    break;
                }
            }
            if (-1 != i)
            {
                Details.RemoveAt(i);
            }
        }
示例#5
0
        public void T020_Start_LOT2()
        {
            Start s = new Start();
            s.Factory_Name = "F1";
            s.MfgOrder_Name = "MfgOrder_PA_r2";
            s.Workflow_Revision = "WF_First(r1)";
            s.WorkflowStep = s.Workflow.FirstStep;
            s.StartReason_Name = "Engineer";

            StartDetail d = new StartDetail();
            d.ContainerName = "LOT2";
            d.ContainerLevel_Name = "Lot";
            d.ContainerStatus_Name = "Active";
            d.Product_Revision = "ProductA(r2)";

            s.InsertDetail(d);
            Assert.IsTrue(s.ExecuteService(), s.CompletionMessage);
        }
示例#6
0
文件: Start.cs 项目: kyjb2000/uo-mes
 protected virtual void AssignStartDetailToStartHistoryDetail(StartDetail s, StartHistoryDetail t)
 {
     t.ContainerName   = s.ContainerName;
     t.ContainerLevel  = ResolveCDO("ContainerLevel", s.ContainerLevel_Name) as ContainerLevel;
     t.ContainerStatus = ResolveCDO("ContainerStatus", s.ContainerStatus_Name) as ContainerStatus;
     t.DueDate         = s.DueDate;
     t.Qty             = s.Qty;
     t.UOM             = ResolveCDO("UOM", s.UOM_Name) as UOM;
     t.Product         = ResolveCDO("Product", s.Product_Revision) as Product;
     if (t.Product != null)
     {
         if (t.Qty == 0)
         {
             t.Qty = t.Product.StdStartedQty;
             t.UOM = t.Product.StdStartedUOM;
         }
     }
 }
示例#7
0
文件: Start.cs 项目: Eric-Guo/uo-mes
 protected virtual void AssignStartDetailToStartHistoryDetail(StartDetail s, StartHistoryDetail t)
 {
     t.ContainerName = s.ContainerName;
     t.ContainerLevel = ResolveCDO("ContainerLevel", s.ContainerLevel_Name) as ContainerLevel;
     t.ContainerStatus = ResolveCDO("ContainerStatus", s.ContainerStatus_Name) as ContainerStatus;
     t.DueDate = s.DueDate;
     t.Qty = s.Qty;
     t.UOM = ResolveCDO("UOM", s.UOM_Name) as UOM;
     t.Product = ResolveCDO("Product", s.Product_Revision) as Product;
     if (t.Product != null)
     {
         if (t.Qty == 0)
         {
             t.Qty = t.Product.StdStartedQty;
             t.UOM = t.Product.StdStartedUOM;
         }
     }
 }
示例#8
0
文件: Start.cs 项目: Eric-Guo/uo-mes
 protected virtual void AssignStartDetailToStartDetail(StartDetail s, StartDetail t)
 {
     t.ContainerName = s.ContainerName;
     t.ContainerLevel_Name = s.ContainerLevel_Name;
     t.DueDate = s.DueDate;
     t.Product_Revision = s.Product_Revision;
     t.Qty = s.Qty;
     t.UOM_Name = s.UOM_Name;
 }
示例#9
0
文件: Start.cs 项目: Eric-Guo/uo-mes
 public void UpdateDetails(StartDetail s)
 {
     foreach (StartDetail t in Details)
     {
         if (t.ServiceDetailID == s.ServiceDetailID)
         {
             AssignStartDetailToStartDetail(s, t);
         }
     }
 }
示例#10
0
文件: Start.cs 项目: Eric-Guo/uo-mes
 public void InsertDetail(StartDetail s)
 {
     s.ServiceDetailID = detailIDCount++;
     Details.Add(s);
 }
示例#11
0
文件: Start.cs 项目: Eric-Guo/uo-mes
 public void DeleteDetail(StartDetail s)
 {
     int i = -1;
     foreach (StartDetail t in Details)
         if (t.ServiceDetailID == s.ServiceDetailID)
         {
             i = Details.IndexOf(t);
             break;
         }
     if(-1 != i)
         Details.RemoveAt(i);
 }
示例#12
0
文件: Start.cs 项目: kyjb2000/uo-mes
 public void InsertDetail(StartDetail s)
 {
     s.ServiceDetailID = detailIDCount++;
     Details.Add(s);
 }