вторая
This commit is contained in:
parent
34c284b74d
commit
5606c50ef1
@ -39,10 +39,8 @@ namespace PrecastConcretePlantFileImplement.Implements
|
||||
{
|
||||
return null;
|
||||
}
|
||||
return source.Components
|
||||
.FirstOrDefault(x => (!string.IsNullOrEmpty(model.ComponentName) && x.ComponentName ==
|
||||
model.ComponentName) ||
|
||||
(model.Id.HasValue && x.Id == model.Id))
|
||||
return source.Components.FirstOrDefault(x => (!string.IsNullOrEmpty(model.ComponentName) && x.ComponentName ==
|
||||
model.ComponentName) || (model.Id.HasValue && x.Id == model.Id))
|
||||
?.GetViewModel;
|
||||
}
|
||||
public ComponentViewModel? Insert(ComponentBindingModel model)
|
||||
|
@ -93,10 +93,6 @@ namespace PrecastConcretePlantFileImplement.Implements
|
||||
private OrderViewModel AddReinforcedName(OrderViewModel model)
|
||||
{
|
||||
var selectedReinforced = source.Reinforceds.FirstOrDefault(x => x.Id == model.ReinforcedId);
|
||||
if (selectedReinforced != null)
|
||||
{
|
||||
model.ReinforcedName = selectedReinforced.ReinforcedName;
|
||||
}
|
||||
model.ReinforcedName = selectedReinforced?.ReinforcedName;
|
||||
return model;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user