This commit is contained in:
SiboVG 2023-04-10 23:52:47 +02:00
parent dab6ec3642
commit b57ad3d393

View File

@ -45,7 +45,6 @@ public class MaterialDTO {
density = theDensity; density = theDensity;
type = theType; type = theType;
uom = theUom; uom = theUom;
type.getORMaterialType().getUnitGroup().setDefaultUnit(getUom());
} }
public String getName() { public String getName() {
@ -70,7 +69,6 @@ public class MaterialDTO {
public void setType(final MaterialTypeDTO theType) { public void setType(final MaterialTypeDTO theType) {
type = theType; type = theType;
type.getORMaterialType().getUnitGroup().setDefaultUnit(getUom());
} }
public String getUom() { public String getUom() {
@ -79,7 +77,6 @@ public class MaterialDTO {
public void setUom(final String theUom) { public void setUom(final String theUom) {
uom = theUom; uom = theUom;
type.getORMaterialType().getUnitGroup().setDefaultUnit(theUom);
} }
Material asMaterial() { Material asMaterial() {
@ -104,7 +101,6 @@ public class MaterialDTO {
// in SI units, so we need to convert it to SI units // in SI units, so we need to convert it to SI units
Unit uomUnit = type.getORMaterialType().getUnitGroup().getUnit(getUom()); Unit uomUnit = type.getORMaterialType().getUnitGroup().getUnit(getUom());
density = uomUnit.fromUnit(density); density = uomUnit.fromUnit(density);
//type.getORMaterialType().getUnitGroup().setDefaultUnit(uomUnit);
} }
} }
} }