work in progress 6.4
This commit is contained in:
parent
231f17c959
commit
4865e3c080
@ -26,12 +26,12 @@
|
||||
<value>1000</value>
|
||||
</setting>
|
||||
<setting name="LockingServerAddress" serializeAs="String">
|
||||
<!--value>http://192.168.2.24/LockingService/LockingService.svc</value-->
|
||||
<value>http://heupferd/bsmd.LockingService/LockingService.svc</value>
|
||||
<value>http://192.168.2.24/LockingService/LockingService.svc</value>
|
||||
<!--value>http://heupferd/bsmd.LockingService/LockingService.svc</value-->
|
||||
</setting>
|
||||
<setting name="ConnectionString" serializeAs="String">
|
||||
<!--value>Initial Catalog=nsw;Data Source=192.168.2.24\SQLEXPRESS;Uid=dfuser;pwd=dfpasswd;Persist Security Info=False;Connection Reset=false</value-->
|
||||
<value>Data Source=(localdb)\MSSQLLocalDB;Initial Catalog=E:\DATA\DB\NSW.MDF;Integrated Security=True;Connect Timeout=30;Encrypt=False;TrustServerCertificate=False;ApplicationIntent=ReadWrite;MultiSubnetFailover=False</value>
|
||||
<value>Initial Catalog=nsw;Data Source=192.168.2.24\SQLEXPRESS;Uid=dfuser;pwd=dfpasswd;Persist Security Info=False;Connection Reset=false</value>
|
||||
<!--value>Data Source=(localdb)\MSSQLLocalDB;Initial Catalog=E:\DATA\DB\NSW.MDF;Integrated Security=True;Connect Timeout=30;Encrypt=False;TrustServerCertificate=False;ApplicationIntent=ReadWrite;MultiSubnetFailover=False</value-->
|
||||
</setting>
|
||||
</ENI2.Properties.Settings>
|
||||
</applicationSettings>
|
||||
|
||||
@ -35,7 +35,7 @@
|
||||
<CreateWebPageOnPublish>true</CreateWebPageOnPublish>
|
||||
<WebPage>publish.html</WebPage>
|
||||
<ApplicationRevision>0</ApplicationRevision>
|
||||
<ApplicationVersion>6.2.1.%2a</ApplicationVersion>
|
||||
<ApplicationVersion>6.4.0.%2a</ApplicationVersion>
|
||||
<UseApplicationTrust>false</UseApplicationTrust>
|
||||
<CreateDesktopShortcut>true</CreateDesktopShortcut>
|
||||
<PublishWizardCompleted>true</PublishWizardCompleted>
|
||||
|
||||
@ -136,6 +136,20 @@ namespace ENI2
|
||||
return result;
|
||||
}
|
||||
|
||||
public static string GetPortAreaFromCode(string code)
|
||||
{
|
||||
string result = null;
|
||||
string query = string.Format("SELECT PortArea from INFO_PortArea WHERE Code = '{0}'", code);
|
||||
SQLiteCommand cmd = new SQLiteCommand(query, _con);
|
||||
IDataReader reader = cmd.ExecuteReader();
|
||||
if(reader.Read())
|
||||
{
|
||||
if (!reader.IsDBNull(0)) result = reader.GetString(0);
|
||||
}
|
||||
reader.Close();
|
||||
return result;
|
||||
}
|
||||
|
||||
public static Dictionary<string, string> getTransportModes()
|
||||
{
|
||||
Dictionary<string, string> result = new Dictionary<string, string>();
|
||||
|
||||
Binary file not shown.
@ -508,13 +508,23 @@ namespace bsmd.ReportGenerator
|
||||
#endregion
|
||||
|
||||
#region LADG
|
||||
/*
|
||||
|
||||
if((message != null) && (message.MessageNotificationClass == Message.NotificationClass.LADG))
|
||||
{
|
||||
BSMDDocument.CreateLADGTable(document, message);
|
||||
return;
|
||||
}
|
||||
*/
|
||||
|
||||
#endregion
|
||||
|
||||
#region SERV
|
||||
|
||||
if ((message != null) && (message.MessageNotificationClass == Message.NotificationClass.SERV))
|
||||
{
|
||||
BSMDDocument.CreateSERVTable(document, message);
|
||||
return;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
if (messageParagraph.MessageText != null) // komplette Nachricht (z.B. STAT)
|
||||
@ -531,9 +541,19 @@ namespace bsmd.ReportGenerator
|
||||
|
||||
#endregion
|
||||
|
||||
#region NOA_NOD
|
||||
|
||||
if ((message != null) && (message.MessageNotificationClass == Message.NotificationClass.NOA_NOD))
|
||||
{
|
||||
BSMDDocument.CreateCallPurposeTable(document, message);
|
||||
return;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region BPOL
|
||||
|
||||
if((message != null) && (message.MessageNotificationClass == Message.NotificationClass.BPOL))
|
||||
if ((message != null) && (message.MessageNotificationClass == Message.NotificationClass.BPOL))
|
||||
{
|
||||
BSMDDocument.CreatePortOfItineraryTable(document, message);
|
||||
}
|
||||
@ -825,6 +845,7 @@ namespace bsmd.ReportGenerator
|
||||
Table table = document.LastSection.AddTable();
|
||||
table.Rows.VerticalAlignment = VerticalAlignment.Center;
|
||||
table.Borders.Visible = true;
|
||||
table.Borders.Color = Colors.LightGray;
|
||||
|
||||
Column column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
@ -835,7 +856,7 @@ namespace bsmd.ReportGenerator
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(2);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(4);
|
||||
column.Width = Unit.FromCentimeter(5.28);
|
||||
|
||||
Row hRow = table.AddRow();
|
||||
hRow.Cells[1].AddParagraph("handling type");
|
||||
@ -857,6 +878,39 @@ namespace bsmd.ReportGenerator
|
||||
|
||||
#endregion
|
||||
|
||||
#region SERV
|
||||
|
||||
private static void CreateSERVTable(Document document, Message message)
|
||||
{
|
||||
Table table = document.LastSection.AddTable();
|
||||
table.Rows.VerticalAlignment = VerticalAlignment.Center;
|
||||
table.Borders.Visible = true;
|
||||
table.Borders.Color = Colors.LightGray;
|
||||
|
||||
table.AddColumn(30);
|
||||
table.AddColumn(90);
|
||||
table.AddColumn(200);
|
||||
table.AddColumn(170);
|
||||
|
||||
Row hRow = table.AddRow();
|
||||
hRow.Cells[1].AddParagraph("Name");
|
||||
hRow.Cells[2].AddParagraph("Beneficiary");
|
||||
hRow.Cells[3].AddParagraph("Invoice recipient");
|
||||
|
||||
for (int i = 0; i < message.Elements.Count; i++)
|
||||
{
|
||||
Row row = table.AddRow();
|
||||
SERV serv = message.Elements[i] as SERV;
|
||||
row.Cells[0].AddParagraph((i + 1).ToString());
|
||||
row.Cells[1].AddParagraph(serv.ServiceName ?? "");
|
||||
row.Cells[2].AddParagraph(serv.ServiceBeneficiary ?? "");
|
||||
row.Cells[3].AddParagraph(serv.ServiceInvoiceRecipient ?? "");
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region SEC
|
||||
|
||||
private static void CreateLast10PortFacilitiesTable(Document document, Message message)
|
||||
@ -869,6 +923,7 @@ namespace bsmd.ReportGenerator
|
||||
table.Format.Font.Size = 8;
|
||||
table.Rows.VerticalAlignment = VerticalAlignment.Center;
|
||||
table.Borders.Visible = true;
|
||||
table.Borders.Color = Colors.LightGray;
|
||||
|
||||
Column column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(0.8);
|
||||
@ -883,9 +938,9 @@ namespace bsmd.ReportGenerator
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(2);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(0.8);
|
||||
column.Width = Unit.FromCentimeter(1.0);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(4);
|
||||
column.Width = Unit.FromCentimeter(3.0);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
|
||||
@ -930,6 +985,7 @@ namespace bsmd.ReportGenerator
|
||||
table.Format.Font.Size = 8;
|
||||
table.Rows.VerticalAlignment = VerticalAlignment.Center;
|
||||
table.Borders.Visible = true;
|
||||
table.Borders.Color = Colors.LightGray;
|
||||
|
||||
Column column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(0.8);
|
||||
@ -942,13 +998,14 @@ namespace bsmd.ReportGenerator
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1.5);
|
||||
column.Width = Unit.FromCentimeter(2.2);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1.5);
|
||||
column.Width = Unit.FromCentimeter(2.2);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1.5);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(3);
|
||||
// summe 490 pt = 17,29cm
|
||||
|
||||
Row hRow = table.AddRow();
|
||||
hRow.Cells[1].AddParagraph("Location");
|
||||
@ -1028,13 +1085,11 @@ namespace bsmd.ReportGenerator
|
||||
Table table = document.LastSection.AddTable();
|
||||
table.Rows.VerticalAlignment = VerticalAlignment.Center;
|
||||
table.Borders.Visible = true;
|
||||
table.Borders.Color = Colors.LightGray;
|
||||
|
||||
Column column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(2);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(6);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(8);
|
||||
table.AddColumn(30);
|
||||
table.AddColumn(290);
|
||||
table.AddColumn(170);
|
||||
|
||||
Row hRow = table.AddRow();
|
||||
hRow.Cells[1].AddParagraph("Name / type of fuel");
|
||||
@ -1059,15 +1114,13 @@ namespace bsmd.ReportGenerator
|
||||
Table table = document.LastSection.AddTable();
|
||||
table.Rows.VerticalAlignment = VerticalAlignment.Center;
|
||||
table.Borders.Visible = true;
|
||||
table.Borders.Color = Colors.LightGray;
|
||||
|
||||
Column column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(2);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(6);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(8);
|
||||
table.AddColumn(30);
|
||||
table.AddColumn(290);
|
||||
table.AddColumn(170);
|
||||
|
||||
Row hRow = table.AddRow();
|
||||
Row hRow = table.AddRow();
|
||||
hRow.Cells[1].AddParagraph("Name / type of fuel");
|
||||
hRow.Cells[2].AddParagraph("Bunker fuel amount in tons");
|
||||
|
||||
@ -1083,7 +1136,7 @@ namespace bsmd.ReportGenerator
|
||||
|
||||
#endregion
|
||||
|
||||
#region CreateWASTable
|
||||
#region WAS
|
||||
|
||||
private static void CreateWASTable(Document document, Message message)
|
||||
{
|
||||
@ -1092,11 +1145,10 @@ namespace bsmd.ReportGenerator
|
||||
Table table = document.LastSection.AddTable();
|
||||
table.Rows.VerticalAlignment = VerticalAlignment.Center;
|
||||
table.Borders.Visible = true;
|
||||
table.Borders.Color = Colors.LightGray;
|
||||
|
||||
Column column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(10);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(6);
|
||||
table.AddColumn(290);
|
||||
table.AddColumn(200);
|
||||
|
||||
Row row = table.AddRow();
|
||||
|
||||
@ -1125,20 +1177,16 @@ namespace bsmd.ReportGenerator
|
||||
table = document.LastSection.AddTable();
|
||||
table.Rows.VerticalAlignment = VerticalAlignment.Top;
|
||||
table.Borders.Visible = true;
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(4);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(2);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(2);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(2);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(2);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(2);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(2);
|
||||
table.Borders.Color = Colors.LightGray;
|
||||
|
||||
table.AddColumn(100);
|
||||
table.AddColumn(65);
|
||||
table.AddColumn(65);
|
||||
table.AddColumn(65);
|
||||
table.AddColumn(65);
|
||||
table.AddColumn(65);
|
||||
table.AddColumn(65);
|
||||
|
||||
|
||||
row = table.AddRow();
|
||||
row.Cells[0].AddParagraph("TYPE");
|
||||
@ -1233,39 +1281,25 @@ namespace bsmd.ReportGenerator
|
||||
Table table = document.LastSection.AddTable();
|
||||
table.Rows.VerticalAlignment = VerticalAlignment.Center;
|
||||
table.Borders.Visible = true;
|
||||
table.Borders.Color = Colors.LightGray;
|
||||
|
||||
Column column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(2);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(2);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(2);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
table.AddColumn(20); // lfd. Nr.
|
||||
table.AddColumn(50); // Name
|
||||
table.AddColumn(30); // Flag
|
||||
table.AddColumn(60); // Company
|
||||
table.AddColumn(70); // Street
|
||||
table.AddColumn(40); // Postal code
|
||||
table.AddColumn(25); // Country
|
||||
table.AddColumn(60); // Phone
|
||||
table.AddColumn(60); // Fax
|
||||
table.AddColumn(70); // EMail
|
||||
table.AddColumn(30); // Gross ton
|
||||
table.AddColumn(30); // Length
|
||||
table.AddColumn(30); // Beam
|
||||
table.AddColumn(60); // Purpose of call
|
||||
table.AddColumn(35); // Draft
|
||||
table.AddColumn(70); // Remarks
|
||||
// 770
|
||||
|
||||
Row opRow = table.AddRow();
|
||||
opRow.Cells[2].AddParagraph("Operator");
|
||||
@ -1274,18 +1308,18 @@ namespace bsmd.ReportGenerator
|
||||
Row hRow = table.AddRow();
|
||||
hRow.Cells[1].AddParagraph("Name");
|
||||
hRow.Cells[2].AddParagraph("Flag");
|
||||
hRow.Cells[3].AddParagraph("Company Name");
|
||||
hRow.Cells[3].AddParagraph("Company name");
|
||||
hRow.Cells[4].AddParagraph("Street / No.");
|
||||
hRow.Cells[5].AddParagraph("Postal Code");
|
||||
hRow.Cells[6].AddParagraph("Country");
|
||||
hRow.Cells[6].AddParagraph("Co.");
|
||||
hRow.Cells[7].AddParagraph("Phone");
|
||||
hRow.Cells[8].AddParagraph("Fax");
|
||||
hRow.Cells[9].AddParagraph("Email");
|
||||
hRow.Cells[10].AddParagraph("Gross ton.");
|
||||
hRow.Cells[11].AddParagraph("Length(m)");
|
||||
hRow.Cells[12].AddParagraph("Beam(m)");
|
||||
hRow.Cells[11].AddParagraph("Len (m)");
|
||||
hRow.Cells[12].AddParagraph("Beam (m)");
|
||||
hRow.Cells[13].AddParagraph("Purpose of call");
|
||||
hRow.Cells[14].AddParagraph("Draft(m)");
|
||||
hRow.Cells[14].AddParagraph("Dr. (m)");
|
||||
hRow.Cells[15].AddParagraph("Remarks");
|
||||
|
||||
for (int i = 0; i < message.Elements.Count; i++)
|
||||
@ -1303,10 +1337,10 @@ namespace bsmd.ReportGenerator
|
||||
row.Cells[8].AddParagraph(towa.TowageOnArrivalOperatorFax ?? "");
|
||||
row.Cells[9].AddParagraph(towa.TowageOnArrivalOperatorEmail ?? "");
|
||||
row.Cells[10].AddParagraph(towa.TowageOnArrivalGrossTonnage.HasValue ? towa.TowageOnArrivalGrossTonnage.Value.ToString() : "");
|
||||
row.Cells[11].AddParagraph(towa.TowageOnArrivalLengthOverall_MTR.HasValue ? towa.TowageOnArrivalLengthOverall_MTR.Value.ToString() : "");
|
||||
row.Cells[12].AddParagraph(towa.TowageOnArrivalBeam_MTR.HasValue ? towa.TowageOnArrivalBeam_MTR.Value.ToString() : "");
|
||||
row.Cells[11].AddParagraph(towa.TowageOnArrivalLengthOverall_MTR.HasValue ? towa.TowageOnArrivalLengthOverall_MTR.Value.ToString("N1") : "");
|
||||
row.Cells[12].AddParagraph(towa.TowageOnArrivalBeam_MTR.HasValue ? towa.TowageOnArrivalBeam_MTR.Value.ToString("N1") : "");
|
||||
row.Cells[13].AddParagraph(towa.TowageOnArrivalPurposeOfCall ?? "");
|
||||
row.Cells[14].AddParagraph(towa.TowageOnArrivalDraught_DMT.HasValue ? towa.TowageOnArrivalDraught_DMT.Value.ToString() : "");
|
||||
row.Cells[14].AddParagraph(towa.TowageOnArrivalDraught_DMT.HasValue ? towa.TowageOnArrivalDraught_DMT.Value.ToString("N1") : "");
|
||||
row.Cells[15].AddParagraph(towa.TowageOnArrivalRemarks ?? "");
|
||||
}
|
||||
}
|
||||
@ -1320,37 +1354,23 @@ namespace bsmd.ReportGenerator
|
||||
Table table = document.LastSection.AddTable();
|
||||
table.Rows.VerticalAlignment = VerticalAlignment.Center;
|
||||
table.Borders.Visible = true;
|
||||
table.Borders.Color = Colors.LightGray;
|
||||
|
||||
Column column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(2);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(2);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(2);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
column = table.AddColumn();
|
||||
column.Width = Unit.FromCentimeter(1);
|
||||
table.AddColumn(20); // lfd. Nr.
|
||||
table.AddColumn(50); // Name
|
||||
table.AddColumn(30); // Flag
|
||||
table.AddColumn(60); // Company
|
||||
table.AddColumn(70); // Street
|
||||
table.AddColumn(40); // Postal code
|
||||
table.AddColumn(25); // Country
|
||||
table.AddColumn(60); // Phone
|
||||
table.AddColumn(60); // Fax
|
||||
table.AddColumn(70); // EMail
|
||||
table.AddColumn(30); // Length
|
||||
table.AddColumn(30); // Beam
|
||||
table.AddColumn(35); // Draft
|
||||
table.AddColumn(160); // Remarks
|
||||
// 770
|
||||
|
||||
Row opRow = table.AddRow();
|
||||
opRow.Cells[2].AddParagraph("Operator");
|
||||
@ -1362,13 +1382,13 @@ namespace bsmd.ReportGenerator
|
||||
hRow.Cells[3].AddParagraph("Company Name");
|
||||
hRow.Cells[4].AddParagraph("Street / No.");
|
||||
hRow.Cells[5].AddParagraph("Postal Code");
|
||||
hRow.Cells[6].AddParagraph("Country");
|
||||
hRow.Cells[6].AddParagraph("Co.");
|
||||
hRow.Cells[7].AddParagraph("Phone");
|
||||
hRow.Cells[8].AddParagraph("Fax");
|
||||
hRow.Cells[9].AddParagraph("Email");
|
||||
hRow.Cells[10].AddParagraph("Length(m)");
|
||||
hRow.Cells[11].AddParagraph("Beam(m)");
|
||||
hRow.Cells[12].AddParagraph("Draft(m)");
|
||||
hRow.Cells[10].AddParagraph("Len (m)");
|
||||
hRow.Cells[11].AddParagraph("Beam (m)");
|
||||
hRow.Cells[12].AddParagraph("Dr. (m)");
|
||||
hRow.Cells[13].AddParagraph("Remarks");
|
||||
|
||||
for (int i = 0; i < message.Elements.Count; i++)
|
||||
@ -1394,6 +1414,38 @@ namespace bsmd.ReportGenerator
|
||||
|
||||
#endregion
|
||||
|
||||
#region CallPurpose
|
||||
|
||||
static void CreateCallPurposeTable(Document document, Message message)
|
||||
{
|
||||
if (message.Elements[0] is NOA_NOD noa_nod && noa_nod.CallPurposes.Count > 0)
|
||||
{
|
||||
document.LastSection.AddParagraph("Call purposes", "Heading3");
|
||||
|
||||
Table table = document.LastSection.AddTable();
|
||||
table.Rows.VerticalAlignment = VerticalAlignment.Center;
|
||||
table.Borders.Visible = true;
|
||||
table.Borders.Color = Colors.LightGray;
|
||||
|
||||
table.AddColumn(30);
|
||||
table.AddColumn(460);
|
||||
|
||||
Row hRow = table.AddRow();
|
||||
hRow.Cells[1].AddParagraph("Purpose (description)");
|
||||
|
||||
for (int i = 0; i < noa_nod.CallPurposes.Count; i++)
|
||||
{
|
||||
Row row = table.AddRow();
|
||||
row.Cells[0].AddParagraph((i + 1).ToString());
|
||||
row.Cells[1].AddParagraph(noa_nod.CallPurposes[i].CallPurposeDescription ?? "");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Default message output
|
||||
|
||||
private static void AddActualTableParagraph(Document document, IMessageParagraph paragraph, bool isSubTable)
|
||||
{
|
||||
|
||||
@ -1452,6 +1504,8 @@ namespace bsmd.ReportGenerator
|
||||
|
||||
#endregion
|
||||
|
||||
#endregion
|
||||
|
||||
#region Spezialbehandlung Ersetzen einzelner Felder durch Klartexte
|
||||
/// <summary>
|
||||
/// Auf besonderen Wunsch einer einzelnen Dame :D
|
||||
@ -1459,7 +1513,7 @@ namespace bsmd.ReportGenerator
|
||||
/// <param name="propertyName">Name des Felds (ohne Klassenname)</param>
|
||||
/// <param name="value">Aktueller Wert / Wert aus der DB</param>
|
||||
/// <returns>ggf. ersetzter Wert</returns>
|
||||
|
||||
|
||||
|
||||
private static string DatabaseEntity_ReportReplacer(string propertyName, string value)
|
||||
{
|
||||
@ -1541,6 +1595,31 @@ namespace bsmd.ReportGenerator
|
||||
}
|
||||
}
|
||||
break;
|
||||
case "ShippingArea":
|
||||
{
|
||||
switch(value)
|
||||
{
|
||||
case "0": result = "North Sea / Baltic"; break;
|
||||
case "1": result = "Europe"; break;
|
||||
case "2": result = "Overseas"; break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case "PortArea":
|
||||
{
|
||||
string portArea = LocalizedLookup.GetPortAreaFromCode(value);
|
||||
if (!portArea.IsNullOrEmpty()) result = portArea;
|
||||
}
|
||||
break;
|
||||
case "FumigatedBulkCargo":
|
||||
{
|
||||
switch(value)
|
||||
{
|
||||
case "0": result = "No"; break;
|
||||
case "1": result = "Yes"; break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@ -1563,7 +1642,7 @@ namespace bsmd.ReportGenerator
|
||||
if (LocalizedLookup.getCargoCodesNST().ContainsKey(value))
|
||||
result = LocalizedLookup.getCargoCodesNST()[value];
|
||||
|
||||
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
@ -241,7 +241,11 @@ namespace bsmd.ReportGenerator
|
||||
{
|
||||
if (aMessage.InternalStatus == Message.BSMDStatus.REPORT)
|
||||
{
|
||||
if ((aMessage.MessageNotificationClass != Message.NotificationClass.VISIT) && (aMessage.MessageNotificationClass != Message.NotificationClass.TRANSIT))
|
||||
if (
|
||||
(aMessage.MessageNotificationClass != Message.NotificationClass.VISIT) &&
|
||||
(aMessage.MessageNotificationClass != Message.NotificationClass.TRANSIT) &&
|
||||
(aMessage.Elements.Count > 0)
|
||||
)
|
||||
reportMessages.Add(aMessage);
|
||||
aMessage.InternalStatus = aMessage.LastStatus.HasValue ? aMessage.LastStatus.Value : Message.BSMDStatus.PREPARE;
|
||||
DBManager.Instance.Save(aMessage);
|
||||
|
||||
@ -1365,7 +1365,7 @@ namespace bsmd.database
|
||||
if (core == null) return;
|
||||
using (SqlCommand cmd = new SqlCommand())
|
||||
{
|
||||
cmd.CommandText = "SELECT COUNT(*) FROM MessageHeader WHERE MessageHeader.MessageCoreId = @ID AND MessageHeader.NotificationClass > 2 AND MessageHeader.NotificationClass < 28";
|
||||
cmd.CommandText = "SELECT COUNT(*) FROM MessageHeader WHERE MessageHeader.MessageCoreId = @ID AND MessageHeader.NotificationClass > 1 AND MessageHeader.NotificationClass < 28";
|
||||
cmd.Parameters.AddWithValue("@ID", core.Id);
|
||||
int total = this.PerformReadIntQuery(cmd) ?? 0;
|
||||
|
||||
|
||||
@ -236,6 +236,7 @@ namespace bsmd.database
|
||||
}
|
||||
}
|
||||
|
||||
/* table now created manually
|
||||
[Browsable(false)]
|
||||
public override List<IMessageParagraph> ChildParagraphs
|
||||
{
|
||||
@ -247,6 +248,7 @@ namespace bsmd.database
|
||||
return result;
|
||||
}
|
||||
}
|
||||
*/
|
||||
|
||||
#endregion
|
||||
|
||||
|
||||
@ -2,6 +2,6 @@
|
||||
|
||||
[assembly: AssemblyCompany("schick Informatik")]
|
||||
[assembly: AssemblyProduct("BSMD NSW interface")]
|
||||
[assembly: AssemblyInformationalVersion("6.2.1")]
|
||||
[assembly: AssemblyInformationalVersion("6.4.0")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2014-2021 schick Informatik")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
@ -1,4 +1,4 @@
|
||||
using System.Reflection;
|
||||
|
||||
[assembly: AssemblyVersion("6.2.1.*")]
|
||||
[assembly: AssemblyVersion("6.4.0.*")]
|
||||
|
||||
|
||||
@ -109,10 +109,12 @@ namespace bsmd.database
|
||||
public double? WasteDisposalAmount_MTQ { get; set; }
|
||||
|
||||
[ShowReport]
|
||||
[Validation(ValidationCode.NOT_NULL)]
|
||||
[ENI2Validation]
|
||||
public double? WasteCapacity_MTQ { get; set; }
|
||||
|
||||
[ShowReport]
|
||||
[Validation(ValidationCode.NOT_NULL)]
|
||||
[ENI2Validation]
|
||||
public double? WasteAmountRetained_MTQ { get; set; }
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user