Aggiunti campi in gestione porto: flag_incoterms - costo - assicurazione - rischi
All checks were successful
IntegryManagementSystem_Multi/pipeline/head This commit looks good
All checks were successful
IntegryManagementSystem_Multi/pipeline/head This commit looks good
This commit is contained in:
@@ -1,11 +1,14 @@
|
||||
package it.integry.ems_model.entity;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonTypeName;
|
||||
import com.fasterxml.jackson.annotation.JsonValue;
|
||||
import it.integry.ems_model.annotation.Master;
|
||||
import it.integry.ems_model.annotation.PK;
|
||||
import it.integry.ems_model.annotation.SqlField;
|
||||
import it.integry.ems_model.annotation.Table;
|
||||
import it.integry.ems_model.base.EntityBase;
|
||||
import it.integry.ems_model.entity._enum.FlagEvaso;
|
||||
import it.integry.ems_model.entity._enum.IBaseEnum;
|
||||
import org.apache.logging.log4j.LogManager;
|
||||
import org.apache.logging.log4j.Logger;
|
||||
import org.kie.api.definition.type.PropertyReactive;
|
||||
@@ -44,6 +47,18 @@ public class GtbPorto extends EntityBase {
|
||||
@SqlField(value = "flag_fattura_vettore", nullable = false)
|
||||
private Boolean flagFatturaVettore;
|
||||
|
||||
@SqlField(value = "flag_incoterms", nullable = false)
|
||||
private Boolean flagIncoterms;
|
||||
|
||||
@SqlField(value = "costo", maxLength = 1)
|
||||
private Costo costo;
|
||||
|
||||
@SqlField(value = "assicurazione", maxLength = 1)
|
||||
private Assicurazione assicurazione;
|
||||
|
||||
@SqlField(value = "rischi", maxLength = 1)
|
||||
private Rischi rischi;
|
||||
|
||||
public GtbPorto() {
|
||||
super(logger);
|
||||
}
|
||||
@@ -107,4 +122,177 @@ public class GtbPorto extends EntityBase {
|
||||
this.flagFatturaVettore = flagFatturaVettore;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Boolean getFlagIncoterms() {
|
||||
return flagIncoterms;
|
||||
}
|
||||
|
||||
public void setFlagIncoterms(Boolean flagIncoterms) {
|
||||
this.flagIncoterms = flagIncoterms;
|
||||
}
|
||||
|
||||
public Costo getCosto() {
|
||||
return costo;
|
||||
}
|
||||
|
||||
public void setCosto(Costo costo) {
|
||||
this.costo = costo;
|
||||
}
|
||||
|
||||
public enum Costo implements IBaseEnum<GtbPorto.Costo> {
|
||||
ACQUIRENTE('A'), VENDITORE('V');
|
||||
|
||||
private final Character value;
|
||||
|
||||
Costo(Character value) {
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
public static Costo from(Object value) {
|
||||
Character castValue = null;
|
||||
|
||||
if (value instanceof Character)
|
||||
castValue = (Character) value;
|
||||
else if (value instanceof String)
|
||||
castValue = ((String) value).charAt(0);
|
||||
|
||||
for (Costo b : Costo.values()) {
|
||||
if (b.value == castValue)
|
||||
return b;
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
@JsonValue
|
||||
public Character getValue() {
|
||||
return this.value;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Object get() {
|
||||
return this.value;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Costo fromInternal(Object val) {
|
||||
return from(val);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return String.valueOf(value);
|
||||
}
|
||||
|
||||
}
|
||||
public Assicurazione getAssicurazione() {
|
||||
return assicurazione;
|
||||
}
|
||||
|
||||
public void setAssicurazione(Assicurazione assicurazione) {
|
||||
this.assicurazione = assicurazione;
|
||||
}
|
||||
|
||||
public enum Assicurazione implements IBaseEnum<GtbPorto.Assicurazione> {
|
||||
ACQUIRENTE('A'), VENDITORE('V');
|
||||
|
||||
private final Character value;
|
||||
|
||||
Assicurazione(Character value) {
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
public static Assicurazione from(Object value) {
|
||||
Character castValue = null;
|
||||
|
||||
if (value instanceof Character)
|
||||
castValue = (Character) value;
|
||||
else if (value instanceof String)
|
||||
castValue = ((String) value).charAt(0);
|
||||
|
||||
for (Assicurazione b : Assicurazione.values()) {
|
||||
if (b.value == castValue)
|
||||
return b;
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
@JsonValue
|
||||
public Character getValue() {
|
||||
return this.value;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Object get() {
|
||||
return this.value;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Assicurazione fromInternal(Object val) {
|
||||
return from(val);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return String.valueOf(value);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public Rischi getRischi() {
|
||||
return rischi;
|
||||
}
|
||||
|
||||
public void setRischi(Rischi rischi) {
|
||||
this.rischi = rischi;
|
||||
}
|
||||
|
||||
public enum Rischi implements IBaseEnum<GtbPorto.Rischi> {
|
||||
ACQUIRENTE('A'), VENDITORE('V');
|
||||
|
||||
private final Character value;
|
||||
|
||||
Rischi(Character value) {
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
public static Rischi from(Object value) {
|
||||
Character castValue = null;
|
||||
|
||||
if (value instanceof Character)
|
||||
castValue = (Character) value;
|
||||
else if (value instanceof String)
|
||||
castValue = ((String) value).charAt(0);
|
||||
|
||||
for (Rischi b : Rischi.values()) {
|
||||
if (b.value == castValue)
|
||||
return b;
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
@JsonValue
|
||||
public Character getValue() {
|
||||
return this.value;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Object get() {
|
||||
return this.value;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Rischi fromInternal(Object val) {
|
||||
return from(val);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return String.valueOf(value);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user