Ejemplo n.º 1
0
 protected void btnAddNewDetail_Click(object sender, EventArgs e)
 {
     Serialize service = MESPageService as Serialize;
     SerializeDetail sd = new SerializeDetail();
     sd.ChildContainerName = txtContainer.Text + '-' + service.SelectDetails().Count;
     service.InsertDetail(sd);
     GridView1.DataBind();
 }
Ejemplo n.º 2
0
 public void UpdateDetails(SerializeDetail s)
 {
     foreach (SerializeDetail t in SerializeDetails)
     {
         if (t.ServiceDetailID == s.ServiceDetailID)
         {
             AssignSerializeDetailToSerializeDetail(s, t);
         }
     }
 }
Ejemplo n.º 3
0
        public void DeleteDetail(SerializeDetail s)
        {
            int i = -1;

            foreach (SerializeDetail t in SerializeDetails)
            {
                if (t.ServiceDetailID == s.ServiceDetailID)
                {
                    i = SerializeDetails.IndexOf(t);
                    break;
                }
            }
            if (-1 != i)
            {
                SerializeDetails.RemoveAt(i);
            }
        }
Ejemplo n.º 4
0
 public void InsertDetail(SerializeDetail s)
 {
     s.ServiceDetailID = detailIDCount++;
     SerializeDetails.Add(s);
 }
Ejemplo n.º 5
0
 protected virtual void AssignSerializeDetailsToSerializeHistoryDetail(SerializeDetail s, SerializeHistoryDetail t)
 {
     t.ChildContainerName = s.ChildContainerName;
     t.ChildQty           = s.ChildQty;
 }
Ejemplo n.º 6
0
 protected virtual void AssignSerializeDetailsToChildContainer(SerializeDetail s, Container t)
 {
     t.ContainerName = s.ChildContainerName;
     t.Qty           = s.ChildQty;
     t.Parent        = this.Container;
 }
Ejemplo n.º 7
0
 public void DeleteDetail(SerializeDetail s)
 {
     int i = -1;
     foreach (SerializeDetail t in SerializeDetails)
         if (t.ServiceDetailID == s.ServiceDetailID)
         {
             i = SerializeDetails.IndexOf(t);
             break;
         }
     if(-1 != i)
         SerializeDetails.RemoveAt(i);
 }
Ejemplo n.º 8
0
 protected virtual void AssignSerializeDetailToSerializeDetail(SerializeDetail s, SerializeDetail t)
 {
     t.ChildContainerName = s.ChildContainerName;
     t.ChildQty = s.ChildQty;
 }
Ejemplo n.º 9
0
 protected virtual void AssignSerializeDetailsToChildContainer(SerializeDetail s, Container t)
 {
     t.ContainerName = s.ChildContainerName;
     t.Qty = s.ChildQty;
     t.Parent = this.Container;
 }
Ejemplo n.º 10
0
 public void UpdateDetails(SerializeDetail s)
 {
     foreach (SerializeDetail t in SerializeDetails)
     {
         if (t.ServiceDetailID == s.ServiceDetailID)
         {
             AssignSerializeDetailToSerializeDetail(s, t);
         }
     }
 }
Ejemplo n.º 11
0
 public void InsertDetail(SerializeDetail s)
 {
     s.ServiceDetailID = detailIDCount++;
     SerializeDetails.Add(s);
 }