コード例 #1
0
        public void UpdateTripsList(string name)
        {
            TripsList.Children.Clear();

            using (TripContext db = new TripContext())
            {
                var Trips = db.Trips.Where(t => t.Name == name).OrderByDescending(t => t.Id);

                foreach (Trip t in Trips)
                {
                    tripRow tr = new tripRow(t.Id, t.FromWhere, t.Destination, t.Name, t.Date, t.State);
                    TripsList.Children.Add(tr);
                }
            }
        }
コード例 #2
0
            public tripRow AddtripRow(string tripNumber, int cartonCount, string carrier, string trailer, System.DateTime trailerArrival, System.DateTime firstScanTime, System.DateTime osdCreated)
            {
                tripRow rowtripRow = ((tripRow)(this.NewRow()));

                object[] columnValuesArray = new object[] {
                    tripNumber,
                    cartonCount,
                    carrier,
                    trailer,
                    trailerArrival,
                    firstScanTime,
                    osdCreated
                };
                rowtripRow.ItemArray = columnValuesArray;
                this.Rows.Add(rowtripRow);
                return(rowtripRow);
            }
コード例 #3
0
 public tripRowChangeEvent(tripRow row, global::System.Data.DataRowAction action)
 {
     this.eventRow    = row;
     this.eventAction = action;
 }
コード例 #4
0
 public void RemovetripRow(tripRow row)
 {
     this.Rows.Remove(row);
 }
コード例 #5
0
 public void AddtripRow(tripRow row)
 {
     this.Rows.Add(row);
 }