public void AddWswShortage(WswShortage shortage) { var row = this.Results.AddRow(shortage.ShortPartNumber); this.Results.SetGridTextValue(row.RowIndex, this.Results.ColumnIndex("shortPartNumber"), shortage.ShortPartNumber); this.Results.SetGridTextValue(row.RowIndex, this.Results.ColumnIndex("description"), shortage.ShortPartDescription); this.Results.SetGridTextValue(row.RowIndex, this.Results.ColumnIndex("category"), shortage.ShortageCategory); this.Results.SetGridTextValue(row.RowIndex, this.Results.ColumnIndex("reqt"), shortage.Required.ToString()); this.Results.SetGridTextValue(row.RowIndex, this.Results.ColumnIndex("stock"), shortage.Stock.ToString()); this.Results.SetGridTextValue(row.RowIndex, this.Results.ColumnIndex("avail"), shortage.AdjustedAvailable.ToString()); this.Results.SetGridTextValue(row.RowIndex, this.Results.ColumnIndex("res"), shortage.QtyReserved.ToString()); this.Results.SetGridTextValue(row.RowIndex, this.Results.ColumnIndex("canBuild"), shortage.CanBuild.ToString()); if (shortage.IsBoardShortage()) { this.BoardShortage = true; } else if (shortage.IsMetalworkShortage()) { this.MetalworkShortage = true; } else if (shortage.IsProcurementShortage()) { this.ProcurementShortage = true; } if (!string.IsNullOrEmpty(shortage.CrfStory)) { this.AddToNotes(shortage.ShortPartNumber, shortage.CrfStory); } }
public void SetUp() { var shortage = new WswShortage { PartNumber = "SK DISPLAY/3", ShortPartDescription = "MOLD 371/P", ShortageCategory = "CP", Required = 12, Stock = 0, AdjustedAvailable = 0, QtyReserved = 0 }; this.Sut.AddWswShortage(shortage); }
public void SetUp() { var shortage = new WswShortage { PartNumber = "S3 302/C", ShortPartNumber = "MCP 2466/2", ShortPartDescription = "SERIES 3 CABINET", ShortageCategory = "PROC", Required = 8, Stock = 11, AdjustedAvailable = 10, QtyReserved = 0 }; this.Sut.AddWswShortage(shortage); }
public void SetUp() { var shortage = new WswShortage { PartNumber = "S3 301/C", ShortPartNumber = "301 TOP", ShortPartDescription = "301 TOP", ShortageCategory = "EP", Required = 46, Stock = 9, AdjustedAvailable = 4, QtyReserved = 9 }; this.Sut.AddWswShortage(shortage); }