Fixed MRB Actions Convert bug
This commit is contained in:
parent
f0df620dc9
commit
40e7a3f8e0
@ -852,8 +852,8 @@ public class MRBService : IMRBService {
|
||||
convertToPart += partStr;
|
||||
}
|
||||
|
||||
dt.Rows.Add(action.Action, convertFromCustomer, convertFromPart, action.Quantity.ToString(),
|
||||
convertToCustomer, convertToPart,
|
||||
dt.Rows.Add(action.Action, convertFromCustomer, convertFromPart, action.LotNumber,
|
||||
action.Quantity.ToString(), convertToCustomer, convertToPart,
|
||||
DateTimeUtilities.GetDateAsStringMinDefault(action.AssignedDate),
|
||||
DateTimeUtilities.GetDateAsStringMaxDefault(action.CompletedDate),
|
||||
action.CompletedByUser is null ? "" : action.CompletedByUser.GetFullName());
|
||||
|
@ -215,9 +215,7 @@
|
||||
bool actionIsValid = mrbAction.Action.Equals("Block") || mrbAction.Action.Equals("Convert") ||
|
||||
mrbAction.Action.Equals("Other") || mrbAction.Action.Equals("Recall") || mrbAction.Action.Equals("Scrap") ||
|
||||
mrbAction.Action.Equals("Unblock") || mrbAction.Action.Equals("Waiver");
|
||||
actionIsValid = actionIsValid && !string.IsNullOrWhiteSpace(mrbAction.Customer) &&
|
||||
!string.IsNullOrWhiteSpace(mrbAction.PartNumber) &&
|
||||
!string.IsNullOrWhiteSpace(mrbAction.LotNumber);
|
||||
actionIsValid = actionIsValid && !string.IsNullOrWhiteSpace(mrbAction.LotNumber);
|
||||
actionIsValid = actionIsValid && mrbAction.Quantity > 0;
|
||||
|
||||
if (mrbAction.Action.Equals("Convert", StringComparison.InvariantCultureIgnoreCase)) {
|
||||
@ -225,6 +223,9 @@
|
||||
!string.IsNullOrWhiteSpace(convertFromPart) &&
|
||||
!string.IsNullOrWhiteSpace(convertToCustomer) &&
|
||||
!string.IsNullOrWhiteSpace(convertToPart);
|
||||
} else {
|
||||
actionIsValid = actionIsValid && !string.IsNullOrWhiteSpace(mrbAction.Customer) &&
|
||||
!string.IsNullOrWhiteSpace(mrbAction.PartNumber);
|
||||
}
|
||||
|
||||
if (mrbAction.Action.Equals("Scrap", StringComparison.InvariantCultureIgnoreCase))
|
||||
|
Loading…
x
Reference in New Issue
Block a user