Fix material convertsion and units detection.

This commit is contained in:
Daniel Kraus
2015-08-10 06:55:57 +02:00
parent 6c9f003134
commit 947b53cf97
5 changed files with 44 additions and 12 deletions

View File

@ -139,7 +139,6 @@ namespace zaaReloaded2.Controller.Elements
{
items.AddRange(CollectByName(formatter, itemName));
}
}
return items;
}
@ -158,6 +157,9 @@ namespace zaaReloaded2.Controller.Elements
.Where(i => !i.HasBeenUsed && !i.IsBlacklisted && i.LabItem.QualifiedName.StartsWith(material))
.ToList();
newItems.ForEach(i => i.HasBeenUsed = true);
// Include the material prefix only if this item was collected by a
// general wildcard ("*" rather than "SU-*" etc.).
newItems.ForEach(i => i.IncludeMaterial = String.IsNullOrEmpty(material));
items.AddRange(newItems);
}
return items;