Weighing: Do not ignore gross and tare weight and show it on DeliveryNote

This commit is contained in:
2024-07-22 17:10:36 +02:00
parent 1141331608
commit fd0ed97305
26 changed files with 159 additions and 96 deletions

View File

@ -80,7 +80,7 @@ namespace Elwig.Services {
vm.IsGebunden = p.IsGebunden;
vm.ScaleId = p.ScaleId;
vm.WeighingId = p.WeighingId;
vm.WeighingData = p.WeighingData;
vm.ManualWeighingReason = p.WeighingReason;
}
@ -174,11 +174,11 @@ namespace Elwig.Services {
prd = prd.And(p => p.IsManualWeighing == false);
filter.RemoveAt(i--);
filterNames.Add("keine Handwiegung");
} else if (e.ToLower() is "bto" or "brut" or "brutt" or "brutto" or "!gerebelt") {
} else if (e.ToLower() == "!gerebelt") {
prd = prd.And(p => p.IsNetWeight == false);
filter.RemoveAt(i--);
filterNames.Add("brutto Wiegung");
} else if (e.ToLower() is "nto" or "net" or "nett" or "netto" or "gerebelt") {
} else if (e.ToLower() == "gerebelt") {
prd = prd.And(p => p.IsNetWeight == true);
filter.RemoveAt(i--);
filterNames.Add("netto Wiegung");
@ -465,7 +465,7 @@ namespace Elwig.Services {
Weight = (int)vm.Weight!,
IsManualWeighing = vm.IsManualWeighing,
ScaleId = vm.ScaleId,
WeighingId = vm.WeighingId,
WeighingData = vm.WeighingData,
WeighingReason = vm.ManualWeighingReason,
};