WasteDisposalDelivery entfernt
This commit is contained in:
parent
5694a3bf89
commit
9f6a342c20
@ -1103,17 +1103,6 @@ namespace ENI2.Excel
|
||||
if (wasMessage.Elements.Count == 0) return;
|
||||
WAS was = wasMessage.Elements[0] as WAS;
|
||||
|
||||
if (was.WasteDisposalDelivery.HasValue) // TODO: CH schreibt für DK erforderlich -> nachfragen
|
||||
{
|
||||
switch (was.WasteDisposalDelivery)
|
||||
{
|
||||
case 0: WriteText("WAS.WasteDisposalDelivery", "ALL"); break;
|
||||
case 1: WriteText("WAS.WasteDisposalDelivery", "SOME"); break;
|
||||
case 2: WriteText("WAS.WasteDisposalDelivery", "NONE"); break;
|
||||
default: break;
|
||||
}
|
||||
}
|
||||
|
||||
WriteText("WAS.LastWasteDisposalPort", isRefSheet ? was.LastWasteDisposalPort : Locode.LocodeDB.LocationNameFromLocode(was.LastWasteDisposalPort));
|
||||
WriteText("WAS.WasteDisposalServiceProviderName", was.WasteDisposalServiceProviderText);
|
||||
WriteText("WAS.NextWasteDisposalPort", isRefSheet? was.NextWasteDisposalPort : Locode.LocodeDB.LocationNameFromLocode(was.NextWasteDisposalPort));
|
||||
|
||||
@ -1418,7 +1418,7 @@ namespace bsmd.ExcelReadService
|
||||
reader.Conf.ConfirmText(wastePort, waste.WasteDisposalPort, rs);
|
||||
|
||||
waste.WasteAmountGeneratedTillNextPort_MTQ = reader.ReadNumberDefaultZero(amountGen);
|
||||
waste.WasteDisposedAtLastPort_MTQ = reader.ReadNumberDefaultZero(wasteDis);
|
||||
// waste.WasteDisposedAtLastPort_MTQ = reader.ReadNumberDefaultZero(wasteDis);
|
||||
|
||||
/*
|
||||
if ((reader.Mode == ExcelReader.CountryMode.DE) &&
|
||||
@ -1447,7 +1447,7 @@ namespace bsmd.ExcelReadService
|
||||
highlightRow15 &= (waste.WasteAmountRetained_MTQ > 0);
|
||||
highlightRow15 &= (waste.WasteDisposalPort != "ZZUKN");
|
||||
highlightRow15 &= (waste.WasteAmountGeneratedTillNextPort_MTQ > 0);
|
||||
highlightRow15 &= (waste.WasteDisposedAtLastPort_MTQ > 0);
|
||||
// highlightRow15 &= (waste.WasteDisposedAtLastPort_MTQ > 0);
|
||||
|
||||
if(highlightRow15)
|
||||
{
|
||||
|
||||
@ -739,9 +739,7 @@ namespace bsmd.dakosy
|
||||
vList.Visit[0].WAS.WasteDisposalServiceProviderName[i].ServiceProviderName = ((WasteDisposalServiceProvider) was.WasteDisposalServiceProvider[i]).WasteDisposalServiceProviderName;
|
||||
}
|
||||
}
|
||||
vList.Visit[0].WAS.WasteDisposalDeliverySpecified = was.WasteDisposalDelivery.HasValue;
|
||||
byte wdd = was.WasteDisposalDelivery ?? 0;
|
||||
vList.Visit[0].WAS.WasteDisposalDelivery = WDDTypeFromNSWEnumeration(wdd);
|
||||
|
||||
if (was.Waste.Count > 0)
|
||||
{
|
||||
vList.Visit[0].WAS.Waste = new Waste[was.Waste.Count];
|
||||
|
||||
@ -131,11 +131,6 @@ namespace bsmd.database
|
||||
[DateOnly]
|
||||
public DateTime? LastWasteDisposalDate { get; set; }
|
||||
|
||||
[Obsolete]
|
||||
[ShowReport]
|
||||
[ENI2Validation]
|
||||
public byte? WasteDisposalDelivery { get; set; }
|
||||
|
||||
[LookupName("WAS.ConfirmationOfSufficiency")]
|
||||
[ENI2Validation]
|
||||
public bool? ConfirmationOfSufficiency { get; set; }
|
||||
@ -233,7 +228,6 @@ namespace bsmd.database
|
||||
scmd.Parameters.AddWithNullableValue("@P3", this.LastWasteDisposalPort);
|
||||
scmd.Parameters.AddWithNullableValue("@P4", this.ConfirmationOfCorrectness);
|
||||
scmd.Parameters.AddWithNullableValue("@P5", this.LastWasteDisposalDate);
|
||||
scmd.Parameters.AddWithNullableValue("@P6", this.WasteDisposalDelivery);
|
||||
scmd.Parameters.AddWithNullableValue("@P7", this.ConfirmationOfSufficiency);
|
||||
scmd.Parameters.AddWithNullableValue("@P8", this.NextWasteDisposalPort);
|
||||
|
||||
@ -242,14 +236,14 @@ namespace bsmd.database
|
||||
this.CreateId();
|
||||
scmd.Parameters.AddWithValue("@ID", this.Id);
|
||||
scmd.CommandText = string.Format("INSERT INTO {0} (Id, MessageHeaderId, WasteDisposalValidExemption, " +
|
||||
"LastWasteDisposalPort, ConfirmationOfCorrectness, LastWasteDisposalDate, WasteDisposalDelivery, " +
|
||||
"ConfirmationOfSufficiency, NextWasteDisposalPort) VALUES ( @ID, @P1, @P2, @P3, @P4, @P5, @P6, @P7, @P8 )", this.Tablename);
|
||||
"LastWasteDisposalPort, ConfirmationOfCorrectness, LastWasteDisposalDate, " +
|
||||
"ConfirmationOfSufficiency, NextWasteDisposalPort) VALUES ( @ID, @P1, @P2, @P3, @P4, @P5, @P7, @P8 )", this.Tablename);
|
||||
}
|
||||
else
|
||||
{
|
||||
scmd.Parameters.AddWithValue("ID", this.Id);
|
||||
scmd.CommandText = string.Format("UPDATE {0} SET WasteDisposalValidExemption = @P2, LastWasteDisposalPort = @P3, " +
|
||||
"ConfirmationOfCorrectness = @P4, LastWasteDisposalDate = @P5, WasteDisposalDelivery = @P6, ConfirmationOfSufficiency = @P7, " +
|
||||
"ConfirmationOfCorrectness = @P4, LastWasteDisposalDate = @P5, ConfirmationOfSufficiency = @P7, " +
|
||||
"NextWasteDisposalPort = @P8 WHERE Id = @ID", this.Tablename);
|
||||
}
|
||||
}
|
||||
@ -257,7 +251,7 @@ namespace bsmd.database
|
||||
public override void PrepareLoadCommand(System.Data.IDbCommand cmd, Message.LoadFilter filter, params object[] criteria)
|
||||
{
|
||||
string query = string.Format("SELECT Id, WasteDisposalValidExemption, LastWasteDisposalPort, ConfirmationOfCorrectness, " +
|
||||
"LastWasteDisposalDate, WasteDisposalDelivery, ConfirmationOfSufficiency, NextWasteDisposalPort " +
|
||||
"LastWasteDisposalDate, ConfirmationOfSufficiency, NextWasteDisposalPort " +
|
||||
"FROM {0} ", this.Tablename);
|
||||
|
||||
switch (filter)
|
||||
@ -290,9 +284,8 @@ namespace bsmd.database
|
||||
if (!reader.IsDBNull(2)) was.LastWasteDisposalPort = reader.GetString(2);
|
||||
if (!reader.IsDBNull(3)) was.ConfirmationOfCorrectness = reader.GetBoolean(3);
|
||||
if (!reader.IsDBNull(4)) was.LastWasteDisposalDate = reader.GetDateTime(4);
|
||||
if (!reader.IsDBNull(5)) was.WasteDisposalDelivery = reader.GetByte(5);
|
||||
if (!reader.IsDBNull(6)) was.ConfirmationOfSufficiency = reader.GetBoolean(6);
|
||||
if (!reader.IsDBNull(7)) was.NextWasteDisposalPort = reader.GetString(7);
|
||||
if (!reader.IsDBNull(5)) was.ConfirmationOfSufficiency = reader.GetBoolean(5);
|
||||
if (!reader.IsDBNull(6)) was.NextWasteDisposalPort = reader.GetString(6);
|
||||
result.Add(was);
|
||||
}
|
||||
reader.Close();
|
||||
|
||||
@ -34,10 +34,6 @@ namespace bsmd.database
|
||||
[Validation(ValidationCode.STRING_MAXLEN, 99)]
|
||||
public string WasteDisposalServiceProviderName { get; set; }
|
||||
|
||||
[Obsolete]
|
||||
[JsonIgnore]
|
||||
public byte? WasteDisposalDelivery { get; set; }
|
||||
|
||||
public string Identifier { get; set; }
|
||||
|
||||
[JsonIgnore]
|
||||
@ -54,27 +50,26 @@ namespace bsmd.database
|
||||
|
||||
scmd.Parameters.AddWithValue("@P1", this.WAS.Id);
|
||||
scmd.Parameters.AddWithNullableValue("@P2", this.WasteDisposalServiceProviderName);
|
||||
scmd.Parameters.AddWithNullableValue("@P3", this.WasteDisposalDelivery);
|
||||
scmd.Parameters.AddWithNullableValue("@P4", this.Identifier);
|
||||
|
||||
if (this.IsNew)
|
||||
{
|
||||
this.CreateId();
|
||||
scmd.Parameters.AddWithValue("@ID", this.Id);
|
||||
scmd.CommandText = string.Format("INSERT INTO {0} (Id, WASId, WasteDisposalServiceProviderName, WasteDisposalDelivery, Identifier) " +
|
||||
"VALUES ( @ID, @P1, @P2, @P3, @P4 )", this.Tablename);
|
||||
scmd.CommandText = string.Format("INSERT INTO {0} (Id, WASId, WasteDisposalServiceProviderName, Identifier) " +
|
||||
"VALUES ( @ID, @P1, @P2, @P4 )", this.Tablename);
|
||||
}
|
||||
else
|
||||
{
|
||||
scmd.Parameters.AddWithValue("ID", this.Id);
|
||||
scmd.CommandText = string.Format("UPDATE {0} SET WasteDisposalServiceProviderName = @P2, WasteDisposalDelivery = @P3 " +
|
||||
scmd.CommandText = string.Format("UPDATE {0} SET WasteDisposalServiceProviderName = @P2 " +
|
||||
"WHERE Id = @ID", this.Tablename);
|
||||
}
|
||||
}
|
||||
|
||||
public override void PrepareLoadCommand(System.Data.IDbCommand cmd, Message.LoadFilter filter, params object[] criteria)
|
||||
{
|
||||
string query = string.Format("SELECT Id, WasteDisposalServiceProviderName, WasteDisposalDelivery, Identifier FROM {0}", this.Tablename);
|
||||
string query = string.Format("SELECT Id, WasteDisposalServiceProviderName, Identifier FROM {0}", this.Tablename);
|
||||
|
||||
switch (filter)
|
||||
{
|
||||
@ -101,8 +96,7 @@ namespace bsmd.database
|
||||
|
||||
wdsp.id = reader.GetGuid(0);
|
||||
if (!reader.IsDBNull(1)) wdsp.WasteDisposalServiceProviderName = reader.GetString(1);
|
||||
if (!reader.IsDBNull(2)) wdsp.WasteDisposalDelivery = reader.GetByte(2);
|
||||
if (!reader.IsDBNull(3)) wdsp.Identifier = reader.GetString(3);
|
||||
if (!reader.IsDBNull(3)) wdsp.Identifier = reader.GetString(2);
|
||||
result.Add(wdsp);
|
||||
}
|
||||
reader.Close();
|
||||
|
||||
@ -1081,7 +1081,7 @@ namespace bsmd.dbh
|
||||
if (rww.WasteType.WasteCode == 2313) rww.WasteType.WasteCode = 2600; // Christin, 22.3.17
|
||||
rww.WasteType.WasteDescription = waste.WasteDescription;
|
||||
|
||||
rww.WasteDisposedAtLastPort_MTQ = decimal.Round((decimal) (waste.WasteDisposedAtLastPort_MTQ ?? 0), 3);
|
||||
// rww.WasteDisposedAtLastPort_MTQ = decimal.Round((decimal) (waste.WasteDisposedAtLastPort_MTQ ?? 0), 3);
|
||||
rww.WasteDisposalAmount_MTQ = decimal.Round((decimal)(waste.WasteDisposalAmount_MTQ ?? 0), 3);
|
||||
|
||||
rww.WasteDetails = new RootWASWasteWasteDetails();
|
||||
|
||||
Loading…
Reference in New Issue
Block a user