KVI,NCTS Fremd

This commit is contained in:
2026-04-07 10:10:12 +02:00
parent 0c7e19fe4c
commit c8d81b07d8
11 changed files with 965 additions and 46 deletions

View File

@@ -1134,6 +1134,26 @@ Namespace My.Resources
End Get
End Property
'''<summary>
''' Sucht eine lokalisierte Ressource vom Typ System.Byte[].
'''</summary>
Friend ReadOnly Property KVI_report() As Byte()
Get
Dim obj As Object = ResourceManager.GetObject("KVI_report", resourceCulture)
Return CType(obj,Byte())
End Get
End Property
'''<summary>
''' Sucht eine lokalisierte Ressource vom Typ System.Byte[].
'''</summary>
Friend ReadOnly Property KVI_report_general() As Byte()
Get
Dim obj As Object = ResourceManager.GetObject("KVI_report_general", resourceCulture)
Return CType(obj,Byte())
End Get
End Property
'''<summary>
''' Sucht eine lokalisierte Ressource vom Typ System.Drawing.Bitmap.
'''</summary>

View File

@@ -976,4 +976,10 @@
<data name="VERAG_CBAM_Report_Template" type="System.Resources.ResXFileRef, System.Windows.Forms">
<value>..\Resources\VERAG_CBAM_Report_Template.xlsx;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="KVI_report" type="System.Resources.ResXFileRef, System.Windows.Forms">
<value>..\Resources\KVI_report.xlsx;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="KVI_report_general" type="System.Resources.ResXFileRef, System.Windows.Forms">
<value>..\Resources\KVI_report_general.xlsx;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
</root>

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@@ -4971,6 +4971,8 @@
<None Include="Resources\Kostenkalkulation_CS.xlsx" />
<None Include="Resources\Kostenkalkulation_AG.xlsx" />
<None Include="Resources\Kostenkalkulation_IMEX.xlsx" />
<None Include="Resources\KVI_report.xlsx" />
<None Include="Resources\KVI_report_general.xlsx" />
<None Include="Resources\LKW_Liste.xlsx" />
<None Include="Resources\MDM_Schreiben\GOBOX_UMSTELLUNG.dotx">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>

View File

@@ -64,6 +64,7 @@ Partial Class usrCntlSpeditionsBuchSuche
Me.dgvLKW = New VERAG_PROG_ALLGEMEIN.MyDatagridview(Me.components)
Me.pnlOpt = New System.Windows.Forms.Panel()
Me.Panel3 = New System.Windows.Forms.Panel()
Me.Button2 = New System.Windows.Forms.Button()
Me.cbxSpedBerichtBar = New System.Windows.Forms.CheckBox()
Me.Label31 = New System.Windows.Forms.Label()
Me.Button8 = New System.Windows.Forms.Button()
@@ -93,6 +94,7 @@ Partial Class usrCntlSpeditionsBuchSuche
Me.cboHandlingssatz = New VERAG_PROG_ALLGEMEIN.MyComboBox()
Me.MenuStrip1 = New System.Windows.Forms.MenuStrip()
Me.KundenauswertungenToolStripMenuItem1 = New System.Windows.Forms.ToolStripMenuItem()
Me.ToolStripMenuItem2 = New System.Windows.Forms.ToolStripMenuItem()
Me.ZFFriedrichshafenAGZeitraumAuswählenToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem()
Me.ZFSteyrZeitraumAuswählenToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem()
Me.ZFThyrnauZeitraumAuswählenToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem()
@@ -209,7 +211,6 @@ Partial Class usrCntlSpeditionsBuchSuche
Me.Label45 = New System.Windows.Forms.Label()
Me.cboFilialeHandling = New VERAG_PROG_ALLGEMEIN.MyComboBox()
Me.SplitContainer = New System.Windows.Forms.SplitContainer()
Me.Button2 = New System.Windows.Forms.Button()
Me.cntxtCntxtSpeditionsbuch.SuspendLayout()
Me.pnlRechts.SuspendLayout()
CType(Me.DataGridView, System.ComponentModel.ISupportInitialize).BeginInit()
@@ -802,6 +803,19 @@ Partial Class usrCntlSpeditionsBuchSuche
Me.Panel3.Size = New System.Drawing.Size(386, 186)
Me.Panel3.TabIndex = 95
'
'Button2
'
Me.Button2.FlatStyle = System.Windows.Forms.FlatStyle.Flat
Me.Button2.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
Me.Button2.Location = New System.Drawing.Point(308, 159)
Me.Button2.Margin = New System.Windows.Forms.Padding(0)
Me.Button2.Name = "Button2"
Me.Button2.Size = New System.Drawing.Size(62, 25)
Me.Button2.TabIndex = 93
Me.Button2.Text = "Jahr"
Me.Button2.TextAlign = System.Drawing.ContentAlignment.MiddleRight
Me.Button2.UseVisualStyleBackColor = True
'
'cbxSpedBerichtBar
'
Me.cbxSpedBerichtBar.AutoSize = True
@@ -1172,25 +1186,32 @@ Partial Class usrCntlSpeditionsBuchSuche
Me.MenuStrip1.Items.AddRange(New System.Windows.Forms.ToolStripItem() {Me.KundenauswertungenToolStripMenuItem1})
Me.MenuStrip1.Location = New System.Drawing.Point(322, 156)
Me.MenuStrip1.Name = "MenuStrip1"
Me.MenuStrip1.Size = New System.Drawing.Size(163, 27)
Me.MenuStrip1.Size = New System.Drawing.Size(283, 27)
Me.MenuStrip1.TabIndex = 89
Me.MenuStrip1.Text = "Kundenauswertungen"
'
'KundenauswertungenToolStripMenuItem1
'
Me.KundenauswertungenToolStripMenuItem1.BackColor = System.Drawing.Color.FromArgb(CType(CType(0, Byte), Integer), CType(CType(54, Byte), Integer), CType(CType(128, Byte), Integer))
Me.KundenauswertungenToolStripMenuItem1.DropDownItems.AddRange(New System.Windows.Forms.ToolStripItem() {Me.ZFFriedrichshafenAGZeitraumAuswählenToolStripMenuItem, Me.ZFSteyrZeitraumAuswählenToolStripMenuItem, Me.ZFThyrnauZeitraumAuswählenToolStripMenuItem, Me.AuswertungDiversZeitraumAuswählenToolStripMenuItem})
Me.KundenauswertungenToolStripMenuItem1.DropDownItems.AddRange(New System.Windows.Forms.ToolStripItem() {Me.ToolStripMenuItem2, Me.ZFFriedrichshafenAGZeitraumAuswählenToolStripMenuItem, Me.ZFSteyrZeitraumAuswählenToolStripMenuItem, Me.ZFThyrnauZeitraumAuswählenToolStripMenuItem, Me.AuswertungDiversZeitraumAuswählenToolStripMenuItem})
Me.KundenauswertungenToolStripMenuItem1.Font = New System.Drawing.Font("Segoe UI", 10.0!)
Me.KundenauswertungenToolStripMenuItem1.ForeColor = System.Drawing.Color.White
Me.KundenauswertungenToolStripMenuItem1.Name = "KundenauswertungenToolStripMenuItem1"
Me.KundenauswertungenToolStripMenuItem1.Size = New System.Drawing.Size(155, 23)
Me.KundenauswertungenToolStripMenuItem1.Text = "Kundenauswertungen"
'
'ToolStripMenuItem2
'
Me.ToolStripMenuItem2.Image = CType(resources.GetObject("ToolStripMenuItem2.Image"), System.Drawing.Image)
Me.ToolStripMenuItem2.Name = "ToolStripMenuItem2"
Me.ToolStripMenuItem2.Size = New System.Drawing.Size(316, 30)
Me.ToolStripMenuItem2.Text = "Kanadevia (Zeitraum auswählen)"
'
'ZFFriedrichshafenAGZeitraumAuswählenToolStripMenuItem
'
Me.ZFFriedrichshafenAGZeitraumAuswählenToolStripMenuItem.Image = CType(resources.GetObject("ZFFriedrichshafenAGZeitraumAuswählenToolStripMenuItem.Image"), System.Drawing.Image)
Me.ZFFriedrichshafenAGZeitraumAuswählenToolStripMenuItem.Name = "ZFFriedrichshafenAGZeitraumAuswählenToolStripMenuItem"
Me.ZFFriedrichshafenAGZeitraumAuswählenToolStripMenuItem.Size = New System.Drawing.Size(308, 24)
Me.ZFFriedrichshafenAGZeitraumAuswählenToolStripMenuItem.Size = New System.Drawing.Size(316, 30)
Me.ZFFriedrichshafenAGZeitraumAuswählenToolStripMenuItem.Text = "ZF Passau (Zeitraum auswählen)"
Me.ZFFriedrichshafenAGZeitraumAuswählenToolStripMenuItem.Visible = False
'
@@ -1198,14 +1219,14 @@ Partial Class usrCntlSpeditionsBuchSuche
'
Me.ZFSteyrZeitraumAuswählenToolStripMenuItem.Image = Global.SDL.My.Resources.Resources.Excel_logo
Me.ZFSteyrZeitraumAuswählenToolStripMenuItem.Name = "ZFSteyrZeitraumAuswählenToolStripMenuItem"
Me.ZFSteyrZeitraumAuswählenToolStripMenuItem.Size = New System.Drawing.Size(308, 24)
Me.ZFSteyrZeitraumAuswählenToolStripMenuItem.Size = New System.Drawing.Size(316, 30)
Me.ZFSteyrZeitraumAuswählenToolStripMenuItem.Text = "ZF Steyr (Zeitraum auswählen)"
'
'ZFThyrnauZeitraumAuswählenToolStripMenuItem
'
Me.ZFThyrnauZeitraumAuswählenToolStripMenuItem.Image = Global.SDL.My.Resources.Resources.Excel_logo
Me.ZFThyrnauZeitraumAuswählenToolStripMenuItem.Name = "ZFThyrnauZeitraumAuswählenToolStripMenuItem"
Me.ZFThyrnauZeitraumAuswählenToolStripMenuItem.Size = New System.Drawing.Size(308, 24)
Me.ZFThyrnauZeitraumAuswählenToolStripMenuItem.Size = New System.Drawing.Size(316, 30)
Me.ZFThyrnauZeitraumAuswählenToolStripMenuItem.Text = "ZF Thyrnau (Zeitraum auswählen)"
Me.ZFThyrnauZeitraumAuswählenToolStripMenuItem.Visible = False
'
@@ -1213,7 +1234,7 @@ Partial Class usrCntlSpeditionsBuchSuche
'
Me.AuswertungDiversZeitraumAuswählenToolStripMenuItem.Image = Global.SDL.My.Resources.Resources.Excel_logo
Me.AuswertungDiversZeitraumAuswählenToolStripMenuItem.Name = "AuswertungDiversZeitraumAuswählenToolStripMenuItem"
Me.AuswertungDiversZeitraumAuswählenToolStripMenuItem.Size = New System.Drawing.Size(308, 24)
Me.AuswertungDiversZeitraumAuswählenToolStripMenuItem.Size = New System.Drawing.Size(316, 30)
Me.AuswertungDiversZeitraumAuswählenToolStripMenuItem.Text = "Flender Bocholt (Zeitraum auswählen)"
Me.AuswertungDiversZeitraumAuswählenToolStripMenuItem.Visible = False
'
@@ -2902,19 +2923,6 @@ Partial Class usrCntlSpeditionsBuchSuche
Me.SplitContainer.SplitterWidth = 2
Me.SplitContainer.TabIndex = 3
'
'Button2
'
Me.Button2.FlatStyle = System.Windows.Forms.FlatStyle.Flat
Me.Button2.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
Me.Button2.Location = New System.Drawing.Point(308, 159)
Me.Button2.Margin = New System.Windows.Forms.Padding(0)
Me.Button2.Name = "Button2"
Me.Button2.Size = New System.Drawing.Size(62, 25)
Me.Button2.TabIndex = 93
Me.Button2.Text = "Jahr"
Me.Button2.TextAlign = System.Drawing.ContentAlignment.MiddleRight
Me.Button2.UseVisualStyleBackColor = True
'
'usrCntlSpeditionsBuchSuche
'
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None
@@ -3143,4 +3151,5 @@ Partial Class usrCntlSpeditionsBuchSuche
Friend WithEvents ToolStripMenuItem19 As ToolStripMenuItem
Friend WithEvents ToolStripMenuItem1 As ToolStripMenuItem
Friend WithEvents Button2 As Button
Friend WithEvents ToolStripMenuItem2 As ToolStripMenuItem
End Class

View File

@@ -127,6 +127,89 @@
<value>431, 17</value>
</metadata>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="ToolStripMenuItem2.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAAAABGdBTUEAALGOfPtRkwAAACBjSFJNAACH
DwAAjA8AAP1SAACBQAAAfXkAAOmLAAA85QAAGcxzPIV3AAAKOWlDQ1BQaG90b3Nob3AgSUNDIHByb2Zp
bGUAAEjHnZZ3VFTXFofPvXd6oc0wAlKG3rvAANJ7k15FYZgZYCgDDjM0sSGiAhFFRJoiSFDEgNFQJFZE
sRAUVLAHJAgoMRhFVCxvRtaLrqy89/Ly++Osb+2z97n77L3PWhcAkqcvl5cGSwGQyhPwgzyc6RGRUXTs
AIABHmCAKQBMVka6X7B7CBDJy82FniFyAl8EAfB6WLwCcNPQM4BOB/+fpFnpfIHomAARm7M5GSwRF4g4
JUuQLrbPipgalyxmGCVmvihBEcuJOWGRDT77LLKjmNmpPLaIxTmns1PZYu4V8bZMIUfEiK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wAxTAh4/e4oXr17i2Qvn4GXvL1+9xPMXg441Pg9XBTeQwCAZPvHNbOIr+GiyA39p
ALtlhfCJ3z/43AkaHOBXyPV5PTRknfisCVOnn6bwjczTLHfxNBI+nphws6PyLnR6GleLwT2NMQ7BZUld
AUVxVh8zwssM8zQmRbuWeZrMAx9SYUsNqZuruGtL3m0sSajN2/suc22WxAeB5niba4uEQBMJd+7a3uXd
GmiwubacBeThcGrW8FA7/7+REUz+dte2fG8RqZoqeTBfavzTZio7tp3yG9fT4lrNGGPLprk5+8uXyhy+
dEX3rGG+dC5NVIXZfKmchMyXGmQkMti9qYy88iPpbbsvZUDmunMa13LnrWpcR9qD1ZT+0WpSbMmlsqN1
tO74Tlq1r4w779WHa8frGqtnxm/KzZRUplnSd1vGpe8qoXnly0igXfTrQKZg/8/4D84DciO4yFz1AAAA
AElFTkSuQmCC
</value>
</data>
<data name="ZFFriedrichshafenAGZeitraumAuswählenToolStripMenuItem.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAAAABGdBTUEAALGOfPtRkwAAACBjSFJNAACH

View File

@@ -3174,5 +3174,293 @@ Public Class usrCntlSpeditionsBuchSuche
Me.Cursor = Cursors.Default
End Sub
Private Sub ToolStripMenuItem2_Click(sender As Object, e As EventArgs) Handles ToolStripMenuItem2.Click
lblKdAusFortschritt.Text = "lädt..."
Me.Cursor = Cursors.WaitCursor
Try
Dim kdnrsrch = 770931
Dim dt As DataTable = SQL.loadDgvBySql("SELECT CAST([FilialenNr] as varchar) + '/' + CAST([AbfertigungsNr] as varchar) Abfertigungsnummer
,cast([Abfertigungsdatum] as date)Abfertigungsdatum
,Absender,Empfänger
,Rechnungsbetrag Betrag
,BelegNr
,[FilialenNr],[AbfertigungsNr],Speditionsbuch.Abfertigungsart,Abfertigungsbezeichnung,Speditionsbuch.Zollsystem_Land,isnull(KdAuftragsNr,'')KdAuftragsNr
FROM Speditionsbuch INNER JOIN [Abfertigungsarten] ON Speditionsbuch.Abfertigungsart=Abfertigungsarten.Abfertigungsart
where (EmpfängerKundenNr IN (" & kdnrsrch & ") OR VermittlerKundenNr IN (" & kdnrsrch & ")) and Abfertigungsdatum BETWEEN '" & txtAbfertDat.Text & "' AND '" & txtAbfertDatBis.Text & "' And isAbfertigung =1 ", "FMZOLL") 'Speditionsbuch.Abfertigungsart IN (1,3,29,38,66,46,47,37,39)
Dim Path = ""
If dt IsNot Nothing And dt.Rows.Count > 0 Then
Dim sPath As String = Environment.GetFolderPath(Environment.SpecialFolder.Personal) & "\VERAG\SR\"
If Not My.Computer.FileSystem.DirectoryExists(sPath) Then
My.Computer.FileSystem.CreateDirectory(sPath)
End If
Dim exclApp As Object 'as Application
Dim Datei As Object 'as WorkBook
Dim Blatt As Object 'Microsoft.Office.Interop.Excel.Worksheet 'As Object 'as Worksheet
exclApp = CreateObject("Excel.Application")
If cbxDetailbericht.Checked Then
With exclApp
.Visible = False
Try
Path = sPath & "KVI_" & txtAbfertDat.Text & "-" & txtAbfertDatBis.Text & "" & " .xlsx"
While System.IO.File.Exists(Path)
Path = sPath & "KVI_" & txtAbfertDat.Text & "-" & txtAbfertDatBis.Text & "_" & Now.ToString("ddMMyyyyHHmmss") & ".xlsx"
End While
My.Computer.FileSystem.WriteAllBytes(Path, My.Resources.KVI_report, False)
Catch ex As System.Exception
' MsgBox(ex.Message)
MsgBox("ERROR 01: " & ex.Message & vbNewLine & ex.StackTrace)
Me.Cursor = Cursors.Default
Exit Sub
End Try
Datei = .Workbooks.Open(Path) 'Anpassen
Blatt = Datei.Worksheets(1) 'Anpassen
'Blatt.Range("I1").Value = txtAbfertDat.Text & "-" & txtAbfertDatBis.Text
Dim cnt = 2
For Each r In dt.Rows
Dim ZOLLANMELDUNG As New DAKOSY_Worker.cZollsysteme_Aktenbeschriftung
Try
Dim zS = If(r("Zollsystem_Land") IsNot DBNull.Value, r("Zollsystem_Land").ToString(), "")
If ZOLLANMELDUNG.getDataByBezugsnummer(r("FilialenNr") & "/" & r("AbfertigungsNr"), r("Abfertigungsart"), "", False, zS) Then
If ZOLLANMELDUNG.dtWARENPOS.Rows.Count > 0 Then
Dim rowcounter As Integer = 0
For Each row As DataRow In ZOLLANMELDUNG.dtWARENPOS.Rows
Dim ZollInProzent As Double = 0
If If(ZOLLANMELDUNG.RechnungspreisohneWahrung, "") <> "" Then
ZollInProzent = ZOLLANMELDUNG.ABGABEN_ZOLL / ZOLLANMELDUNG.RechnungspreisohneWahrung * 100
End If
Dim KdAtrNr = r("KDAuftragsNr")
If kdnrsrch = 770931 Then ' Sonderfall Kanadevia
If KdAtrNr.ToString.Contains("/") Then
KdAtrNr = KdAtrNr.ToString.Split("/")(0) 'nur vorderer Teil nehmen
End If
End If
Blatt.Range("A" & cnt).Value = cnt - 1
Blatt.Range("B" & cnt).Value = r("Abfertigungsdatum")
Blatt.Range("C" & cnt).Value = VERAG_PROG_ALLGEMEIN.cAllgemein.getFirmaFromFiliale(r("FilialenNr"))
Blatt.Range("D" & cnt).Value = ZOLLANMELDUNG.Empfaenger
Blatt.Range("E" & cnt).Value = r("FilialenNr") & "/" & r("AbfertigungsNr")
Blatt.Range("F" & cnt).Value = KdAtrNr
Blatt.Range("G" & cnt).Value = r("BelegNr")
Blatt.Range("H" & cnt).Value = row.Item("PosNr")
Blatt.Range("I" & cnt).Value = row.Item("WarenNr")
Blatt.Range("J" & cnt).Value = "-"
Blatt.Range("K" & cnt).Value = row.Item("WarenBez")
Blatt.Range("L" & cnt).Value = ""
Blatt.Range("M" & cnt).Value = ZOLLANMELDUNG.Waehrungscode
Blatt.Range("N" & cnt).Value = ZOLLANMELDUNG.Geschaeftsart
Blatt.Range("O" & cnt).Value = ZOLLANMELDUNG.Zollstelle_Eingang
Blatt.Range("P" & cnt).Value = ""
Blatt.Range("Q" & cnt).Value = row.Item("Netto")
Blatt.Range("R" & cnt).Value = row.Item("PosWert")
Blatt.Range("S" & cnt).Value = IIf(rowcounter = 0, ZOLLANMELDUNG.ABGABEN_EUST, "")
Blatt.Range("T" & cnt).Value = IIf(rowcounter = 0, ZOLLANMELDUNG.ABGABEN_ZOLL, "")
Blatt.Range("U" & cnt).Value = IIf(rowcounter = 0, ZollInProzent.ToString("N2") & " %", "")
Blatt.Range("V" & cnt).Value = IIf(ZOLLANMELDUNG.VerBestLandZst.ToString.Count > 1, ZOLLANMELDUNG.VerBestLandZst.ToString.Substring(0, 2), "")
Blatt.Range("W" & cnt).Value = ZOLLANMELDUNG.Absender
Blatt.Range("X" & cnt).Value = row.Item("Herkunft")
Blatt.Range("Y" & cnt).Value = ZOLLANMELDUNG.Incoterms
Blatt.Range("Z" & cnt).Value = row.Item("Verfahren")
Blatt.Range("AA" & cnt).Value = row.Item("Preferenz")
Blatt.Range("AB" & cnt).Value = IIf(row.Item("isCBAM"), "Y", "N")
If If(ZOLLANMELDUNG.ATCMRN, "") <> "" AndAlso Blatt.Range("G" & cnt).Value = "" Then
Blatt.Range("G" & cnt).Value = ZOLLANMELDUNG.ATCMRN
End If
cnt += 1
rowcounter += 1
Next
Else
Dim ZollInProzent As Double = 0
If If(ZOLLANMELDUNG.RechnungspreisohneWahrung, "") <> "" Then
ZollInProzent = ZOLLANMELDUNG.ABGABEN_ZOLL / ZOLLANMELDUNG.RechnungspreisohneWahrung * 100
End If
Dim KdAtrNr = r("KDAuftragsNr")
If kdnrsrch = 770931 Then ' Sonderfall Kanadevia
If KdAtrNr.ToString.Contains("/") Then
KdAtrNr = KdAtrNr.ToString.Split("/")(0) 'nur vorderer Teil nehmen
End If
End If
Blatt.Range("A" & cnt).Value = cnt - 1
Blatt.Range("B" & cnt).Value = r("Abfertigungsdatum")
Blatt.Range("C" & cnt).Value = VERAG_PROG_ALLGEMEIN.cAllgemein.getFirmaFromFiliale(r("FilialenNr"))
Blatt.Range("D" & cnt).Value = ZOLLANMELDUNG.Empfaenger
Blatt.Range("E" & cnt).Value = r("FilialenNr") & "/" & r("AbfertigungsNr")
Blatt.Range("F" & cnt).Value = KdAtrNr
Blatt.Range("G" & cnt).Value = r("BelegNr")
Blatt.Range("H" & cnt).Value = ""
Blatt.Range("I" & cnt).Value = ""
Blatt.Range("J" & cnt).Value = "-"
Blatt.Range("K" & cnt).Value = ""
Blatt.Range("L" & cnt).Value = ""
Blatt.Range("M" & cnt).Value = ZOLLANMELDUNG.Waehrungscode
Blatt.Range("N" & cnt).Value = ZOLLANMELDUNG.Geschaeftsart
Blatt.Range("O" & cnt).Value = ZOLLANMELDUNG.Zollstelle_Eingang
Blatt.Range("P" & cnt).Value = ""
Blatt.Range("Q" & cnt).Value = ""
Blatt.Range("R" & cnt).Value = ""
Blatt.Range("S" & cnt).Value = ZOLLANMELDUNG.ABGABEN_EUST
Blatt.Range("T" & cnt).Value = ZOLLANMELDUNG.ABGABEN_ZOLL
Blatt.Range("U" & cnt).Value = ZollInProzent.ToString("N2") & " %"
Blatt.Range("V" & cnt).Value = IIf(ZOLLANMELDUNG.VerBestLandZst.ToString.Count > 1, ZOLLANMELDUNG.VerBestLandZst.ToString.Substring(0, 2), "")
Blatt.Range("W" & cnt).Value = ZOLLANMELDUNG.Absender
Blatt.Range("X" & cnt).Value = ""
Blatt.Range("Y" & cnt).Value = ZOLLANMELDUNG.Incoterms
Blatt.Range("Z" & cnt).Value = ""
Blatt.Range("AA" & cnt).Value = ""
Blatt.Range("AB" & cnt).Value = ""
If If(ZOLLANMELDUNG.ATCMRN, "") <> "" AndAlso Blatt.Range("G" & cnt).Value = "" Then
Blatt.Range("G" & cnt).Value = ZOLLANMELDUNG.ATCMRN
End If
cnt += 1
End If
End If
Catch ex As Exception
MsgBox(ex.Message & ex.StackTrace)
End Try
lblKdAusFortschritt.Text = (cnt - 2) & "/" & dt.Rows.Count
Me.Refresh()
Next
Datei.Save
If False Then
Blatt.PrintOutEx()
Else
'Process.Start(Path)
.Visible = True
End If
End With
Else
With exclApp
.Visible = False
Try
Path = sPath & "KVI_" & txtAbfertDat.Text & "-" & txtAbfertDatBis.Text & "" & " .xlsx"
While System.IO.File.Exists(Path)
Path = sPath & "KVI_" & txtAbfertDat.Text & "-" & txtAbfertDatBis.Text & "_" & Now.ToString("ddMMyyyyHHmmss") & ".xlsx"
End While
My.Computer.FileSystem.WriteAllBytes(Path, My.Resources.KVI_report_general, False)
Catch ex As System.Exception
' MsgBox(ex.Message)
MsgBox("ERROR 01: " & ex.Message & vbNewLine & ex.StackTrace)
Me.Cursor = Cursors.Default
Exit Sub
End Try
Datei = .Workbooks.Open(Path) 'Anpassen
Blatt = Datei.Worksheets(1) 'Anpassen
Blatt.Range("I1").Value = txtAbfertDat.Text & "-" & txtAbfertDatBis.Text
Dim cnt = 3
For Each r In dt.Rows
Blatt.Range("A" & cnt).Value = cnt - 2
Blatt.Range("B" & cnt).Value = r("Abfertigungsnummer")
' Blatt.Range("C" & cnt).Value = r("RechnungsNr")
Blatt.Range("C" & cnt).Value = r("Abfertigungsdatum")
Blatt.Range("D" & cnt).Value = r("Abfertigungsbezeichnung")
Blatt.Range("E" & cnt).Value = r("Absender")
Blatt.Range("F" & cnt).Value = r("Empfänger")
Blatt.Range("H" & cnt).Value = "" 'r("Betrag")
Dim KdAtrNr = r("KDAuftragsNr")
If kdnrsrch = 770931 Then ' Sonderfall Kanadevia
If KdAtrNr.ToString.Contains("/") Then
KdAtrNr = KdAtrNr.ToString.Split("/")(0) 'nur vorderer Teil nehmen
End If
End If
Blatt.Range("G" & cnt).Value = KdAtrNr
Dim ZOLLANMELDUNG As New DAKOSY_Worker.cZollsysteme_Aktenbeschriftung
Try
Dim zS = If(r("Zollsystem_Land") IsNot DBNull.Value, r("Zollsystem_Land").ToString(), "")
If ZOLLANMELDUNG.getDataByBezugsnummer(r("FilialenNr") & "/" & r("AbfertigungsNr"), r("Abfertigungsart"), "", False, zS) Then
Blatt.Range("H" & cnt).Value = ZOLLANMELDUNG.RechnungspreisohneWahrung
Blatt.Range("I" & cnt).Value = ZOLLANMELDUNG.Handelsrechnung.Replace(", ", "," & vbNewLine)
Blatt.Range("K" & cnt).Value = ZOLLANMELDUNG.ABGABEN_ZOLL
Blatt.Range("L" & cnt).Value = ZOLLANMELDUNG.ANZ_POS
'----------------------------------NEW
Blatt.Range("M" & cnt).Value = ZOLLANMELDUNG.Anmelder
Blatt.Range("N" & cnt).Value = ZOLLANMELDUNG.Warenbezeichung
Blatt.Range("O" & cnt).Value = ZOLLANMELDUNG.VerBestLandZst
'----------------------------------
If If(ZOLLANMELDUNG.ATCMRN, "") <> "" Then
Blatt.Range("J" & cnt).Value = ZOLLANMELDUNG.ATCMRN
End If
End If
Catch ex As Exception
MsgBox(ex.Message & ex.StackTrace)
End Try
lblKdAusFortschritt.Text = (cnt - 2) & "/" & dt.Rows.Count
Me.Refresh()
cnt += 1
Next
Datei.Save
If False Then
Blatt.PrintOutEx()
Else
'Process.Start(Path)
.Visible = True
End If
End With
End If
End If
lblKdAusFortschritt.Text = "fertig"
Catch ex As Exception
MsgBox(ex.Message & ex.StackTrace)
lblKdAusFortschritt.Text = "Fehler"
End Try
Me.Cursor = Cursors.Default
End Sub
End Class

View File

@@ -345,6 +345,7 @@ Public Class cNCTS_FREMD
Property ncts_Eroeffnung As Object = Nothing
Property ncts_Ankunft As Object = Nothing
Property ncts_Erledigung As Object = Nothing
Property ncts_statusFremd As Object = Nothing
Property ncts_GUARANTEE As New List(Of cNCTS_FREMD_Guarantee)
@@ -708,6 +709,7 @@ Public Class cNCTS_FREMD
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("ncts_Eroeffnung", ncts_Eroeffnung))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("ncts_Ankunft", ncts_Ankunft))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("ncts_Erledigung", ncts_Erledigung))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("ncts_statusFremd", ncts_statusFremd))

View File

@@ -1,4 +1,5 @@
Imports Newtonsoft.Json
Imports com.sun.tools.javac.code.Symbol
Imports Newtonsoft.Json
Imports Newtonsoft.Json.Linq
Public Class cModalTransNCTS
@@ -154,6 +155,166 @@ Public Class cModalTransNCTS
End Class
Public Class cMT_NCTS_GET_DeclarationResponse
Public Property transaction_id As Integer?
Public Property reference As String
Public Property doc_type As String
Public Property doc_date As String
Public Property vehicle_code As String
Public Property vehicle_coun As String
Public Property trailer_code As String
Public Property trailer_coun As String
Public Property border_cross_vehicle As String
Public Property container As String
Public Property seal_info As String
Public Property security As Boolean?
Public Property tanker As Boolean?
Public Property is_aeo As Boolean?
Public Property aeo_location As String
Public Property transit_date As String
Public Property departure_custom_code As String
Public Property dispatch_country_id As String
Public Property load_place As String
Public Property goods_location As String
Public Property arrival_custom_code As String
Public Property destination_country_id As String
Public Property unload_place As String
Public Property border_custom_code As String
Public Property transit_customs_codes As String
Public Property transit_countries_codes As String
Public Property carrier_name As String
Public Property carrier_address As String
Public Property carrier_postcode As String
Public Property carrier_city As String
Public Property carrier_country_id As String
Public Property carrier_taxno As String
Public Property carrier_eori_code As String
Public Property custom_line As String
Public Property custom_staff_name As String
Public Property trans_method As String
Public Property roro_operator_code As String
Public Property guarantee_price As Decimal?
Public Property guarantee_curr As String
Public Property status As String
Public Property lrn_no As String
Public Property lrn As String
Public Property mrn As String
Public Property mrn_no As String
Public Property lrn_url As String
Public Property manifesto_price As Decimal?
Public Property manifesto_curr As String
Public Property position_no As String
Public Property remote_ref As String
Public Property notes As String
Public Property letter_grn As String
Public Property guarantor_name As String
Public Property guarantor_city As String
Public Property guarantor_taxno As String
Public Property guarantor_address As String
Public Property guarantor_postcode As String
Public Property guarantor_eori_code As String
Public Property guarantor_country_id As String
Public Property mrn_date As String
Public Property stamp_duty As String
Public Property ncts5_checker As Boolean?
Public Property released_at As String
Public Property goods_attributes As List(Of cMT_NCTS_GoodsAttribute)
Public Class cMT_NCTS_GoodsAttribute
Public Property line_no As Integer?
Public Property gtip_code As String
Public Property commodity As String
Public Property brut_wg As Decimal?
Public Property net_wg As Decimal?
Public Property invoice_amount As Decimal?
Public Property invoice_curr As String
Public Property exp_customs_type As String
Public Property exp_customs_partial As Boolean?
Public Property exp_customs_no As String
Public Property manifesto_type As String
Public Property dep_country_id As String
Public Property arv_country_id As String
Public Property sender_taxno As String
Public Property sender_name As String
Public Property sender_address As String
Public Property sender_postcode As String
Public Property sender_city As String
Public Property sender_country_id As String
Public Property sender_eori_code As String
Public Property consignee_taxno As String
Public Property consignee_name As String
Public Property consignee_address As String
Public Property consignee_postcode As String
Public Property consignee_city As String
Public Property consignee_country_id As String
Public Property consignee_eori_code As String
Public Property packs_attributes As List(Of cMT_NCTS_PackAttribute)
Public Property documents_attributes As List(Of cMT_NCTS_DocumentAttribute)
Public Property produced_documents_attributes As List(Of cMT_NCTS_ProducedDocumentAttribute)
End Class
Public Class cMT_NCTS_PackAttribute
Public Property pack_type As String
Public Property pack_count As Integer?
Public Property notes As String
End Class
Public Class cMT_NCTS_DocumentAttribute
Public Property doc_type As String
Public Property doc_no As String
Public Property pre_post As String
End Class
Public Class cMT_NCTS_ProducedDocumentAttribute
Public Property code As String
Public Property reference As String
Public Property status As String
Public Property reason As String
Public Property quantity As Decimal?
End Class
End Class
Public Class cMT_NCTS_GET_TimelineResponse
Public Property transaction_id As Integer?
Public Property reference As String
Public Property doc_type As String
Public Property doc_date As String
Public Property transit_date As String
Public Property status As String
Public Property lrn As String
Public Property mrn As String
Public Property manifesto_price As Decimal?
Public Property manifesto_curr As String
Public Property guarantee_price As Decimal?
Public Property guarantee_diff As Decimal?
Public Property guarantee_curr As String
Public Property seal_no As String
Public Property lrn_date As String
Public Property mrn_date As String
Public Property manifesto_closed_date As String
Public Property vahicle_arrived_date As String
Public Property custom_staff_name As String
Public Property custom_line As String
Public Property timelines As List(Of cMT_NCTS_GET_TimelineItem)
Public Class cMT_NCTS_GET_TimelineItem
Public Property timeline_id As String
Public Property status_date As String
Public Property status_code As String
Public Property notes As String
Public Property source As String
Public Property country_id As String
End Class
End Class
Public Class cMT_NCTS_ApiClient
Private http As New Chilkat.Http()
Private authToken As String
@@ -389,31 +550,28 @@ Public Class cModalTransNCTS
Return result
End Function
' GET Declaration by ID / MRN / LRN / Ref
Public Function GetNCTSDeclaration(identifier As String) As cMT_NCTS_DeclarationRequest
Public Function GetNCTSDeclarationByMRN(mrn As String) As cMT_NCTS_GET_DeclarationResponse
If Not cModalTransBase.Authenticate(authToken) Then
Console.WriteLine("❌ Authentifizierung fehlgeschlagen.")
Return Nothing
End If
http.SetRequestHeader("Authorization", "Bearer " & authToken)
Dim url = $"{cModalTransBase.baseUrl}/api/v1/ncts_declarations/{identifier}"
Dim url = $"{cModalTransBase.baseUrl}/api/v1/ncts_declarations/{mrn}"
Dim resp = http.QuickGetObj(url)
If resp Is Nothing Then
Console.WriteLine("❌ Keine Verbindung: " & http.LastErrorText)
Return Nothing
End If
Select Case resp.StatusCode
Case 200
Try
Dim json = JsonConvert.DeserializeObject(Of JObject)(resp.BodyStr)
Dim data = json.SelectToken("declaration_data")
Console.WriteLine("✅ NCTS-Anmeldung erfolgreich abgerufen.")
Return data.ToObject(Of cMT_NCTS_DeclarationRequest)()
Dim result = JsonConvert.DeserializeObject(Of cMT_NCTS_GET_DeclarationResponse)(resp.BodyStr)
Console.WriteLine("✅ NCTS-Anmeldung erfolgreich abgerufen (MRN).")
Return result
Catch ex As Exception
Console.WriteLine("❌ Fehler beim Parsen: " & ex.Message)
Console.WriteLine(resp.BodyStr)
End Try
Case 401
Console.WriteLine("❌ Zugriff verweigert (401)")
@@ -422,12 +580,160 @@ Public Class cModalTransNCTS
Case Else
Console.WriteLine($"❌ Fehler ({resp.StatusCode}): {resp.BodyStr}")
End Select
Return Nothing
End Function
Public Function ConvertModaltransToNCTSFremd(nctsTmp As cMT_NCTS_GET_DeclarationResponse,
Optional OverrideNCTSFin As Boolean = False,
Optional PartnerSystem As String = "MODALTRANS") As VERAG_PROG_ALLGEMEIN.cNCTS_FREMD
If nctsTmp Is Nothing Then Return Nothing
If String.IsNullOrWhiteSpace(If(nctsTmp.mrn, "")) Then Return Nothing
Dim nctsFremd As VERAG_PROG_ALLGEMEIN.cNCTS_FREMD = VERAG_PROG_ALLGEMEIN.cNCTS_FREMD.LOADByMRN(nctsTmp.mrn, True)
If nctsFremd Is Nothing Then nctsFremd = New VERAG_PROG_ALLGEMEIN.cNCTS_FREMD
If Not OverrideNCTSFin Then
If If(nctsFremd.ncts_Status, 0) = 60 Then
Return nctsFremd
End If
End If
nctsFremd.ncts_Partnersystem = PartnerSystem
nctsFremd.ncts_MRN = nctsTmp.mrn
nctsFremd.ncts_ObjectName = If(If(nctsTmp.lrn, "") <> "", nctsTmp.lrn, nctsTmp.reference)
nctsFremd.ncts_Trans_Referenz = nctsTmp.reference
nctsFremd.ncts_Declarationtype = nctsTmp.doc_type
nctsFremd.ncts_TransitDeclarationType = nctsTmp.doc_type
nctsFremd.ncts_statusFremd = nctsTmp.status
nctsFremd.ncts_CustomsOfficeOfDeparture = nctsTmp.departure_custom_code
nctsFremd.ncts_CustomsOfficeOfDestinationDeclared = nctsTmp.arrival_custom_code
nctsFremd.ncts_CustomsOfficeOfExitForTransitDeclared = nctsTmp.border_custom_code
nctsFremd.ncts_CountryOfDispatch = nctsTmp.dispatch_country_id
nctsFremd.ncts_CountryOfDestination = nctsTmp.destination_country_id
nctsFremd.ncts_PlaceOfLoading_Location = nctsTmp.load_place
nctsFremd.ncts_PlaceOfUnLoading_Location = nctsTmp.unload_place
nctsFremd.ncts_LocationOfGoods_AdditionalIdentifier = nctsTmp.goods_location
' nctsFremd.ncts_ModeOfTransportAtTheBorder = nctsTmp.trans_method
' nctsFremd.ncts_InlandModeOfTransport = nctsTmp.trans_method
'nctsFremd.ncts_GrossMass = nctsTmp.
'''
nctsFremd.ncts_Consignor_Name = nctsTmp.carrier_name
nctsFremd.ncts_Carrier_AdressCode = Nothing
nctsFremd.ncts_Carrier_IdentificationNumber = nctsTmp.carrier_eori_code
nctsFremd.ncts_Carrier_ContactPerson_Name = nctsTmp.custom_staff_name
nctsFremd.ncts_Carrier_ContactPerson_EMailAddress = Nothing
nctsFremd.ncts_Carrier_ContactPerson_PhoneNumber = Nothing
nctsFremd.ncts_Consignee_Name = Nothing
nctsFremd.ncts_ActiveBorderTransportMeans_1_IdentificationNumber = nctsTmp.trailer_code
nctsFremd.ncts_ActiveBorderTransportMeans_1_Nationality = nctsTmp.trailer_coun
nctsFremd.ncts_DepartureTransportMeans_1_IdentificationNumber = nctsTmp.vehicle_code
nctsFremd.ncts_DepartureTransportMeans_1_Nationality = nctsTmp.vehicle_coun
nctsFremd.ncts_ContainerIndicator = nctsTmp.container
nctsFremd.ncts_Security = nctsTmp.security
nctsFremd.ncts_NachrichtenSenderTIN = Nothing
nctsFremd.ncts_NachrichtenSenderNLNR = Nothing
nctsFremd.ncts_NachrichtenempfaengerDST = Nothing
nctsFremd.ncts_Trans_DatumZeit = If(IsDate(nctsTmp.doc_date), CDate(nctsTmp.doc_date), Now)
If IsDate(nctsTmp.transit_date) Then
nctsFremd.ncts_Eroeffnung = CDate(nctsTmp.transit_date)
'If If(nctsFremd.ncts_LimitDate, "").ToString = "" Then
' nctsFremd.ncts_LimitDate = CDate(nctsTmp.limi).AddDays(10)
'End If
ElseIf IsDate(nctsTmp.doc_date) Then
nctsFremd.ncts_Eroeffnung = CDate(nctsTmp.doc_date)
If If(nctsFremd.ncts_LimitDate, "").ToString = "" Then
nctsFremd.ncts_LimitDate = CDate(nctsTmp.doc_date).AddDays(10)
End If
End If
Dim statusNeu As Integer = 0
Select Case UCase(If(nctsTmp.status, ""))
Case "DRAFT", "SENT"
statusNeu = 10
Case "IN_USE", "MRN", "REL_TRA", "MRN_ALL", "MRN_NOTIFIED", "GUAINF", "CTR_DEC", "CTRINFDEP", "WRT_NOT", "MRN_OK", "TRUCK_RELEASED", "TRUCK_IS_READY"
statusNeu = 50
Case "ARR_ADV", "AT_ARRIVAL_POINT"
statusNeu = 53
If If(nctsFremd.ncts_Ankunft, "").ToString = "" Then
End If
Case "TRANSIT_CLOSE", "RELEASED", "COMPLETED"
statusNeu = 60
If If(nctsFremd.ncts_Ankunft, "").ToString = "" Then
End If
If If(nctsFremd.ncts_Erledigung, "").ToString = "" Then
End If
Case "CANCELLED"
statusNeu = 90
Case Else
statusNeu = If(IsNumeric(nctsFremd.ncts_Status), CInt(nctsFremd.ncts_Status), 0)
If statusNeu = 0 Then statusNeu = 50
End Select
nctsFremd.ncts_Status = statusNeu
nctsFremd.ncts_Status_KEWILL_Equivalent = statusNeu
nctsFremd.LOAD_Guarantee()
nctsFremd.ncts_GUARANTEE.Clear()
If nctsTmp.guarantee_price.HasValue AndAlso nctsTmp.guarantee_price.Value > 0 AndAlso If(nctsTmp.letter_grn, "") <> "" Then
Dim grt As New VERAG_PROG_ALLGEMEIN.cNCTS_FREMD_Guarantee
grt.nctsGRT_Type = Nothing
grt.nctsGRT_AccessCode = Nothing
grt.nctsGRT_GRN = nctsTmp.letter_grn
grt.nctsGRT_AmountToBeCoveredFremdWaehrung = nctsTmp.guarantee_price.Value
grt.nctsGRT_Currency = nctsTmp.guarantee_curr
Console.WriteLine("guarantee_curr:" & nctsTmp.guarantee_curr)
If grt.nctsGRT_AmountToBeCoveredFremdWaehrung IsNot Nothing Then
If If(grt.nctsGRT_Currency, "") <> "" AndAlso If(grt.nctsGRT_Currency, "") <> "EUR" Then
Dim betragEUR = VERAG_PROG_ALLGEMEIN.cEZB_Waehrungskurse.EXCHANGE_CURTOEUR(
grt.nctsGRT_AmountToBeCoveredFremdWaehrung,
grt.nctsGRT_Currency,
nctsFremd.ncts_Trans_DatumZeit.ToShortDateString
)
grt.nctsGRT_AmountToBeCovered = If(betragEUR > 0, betragEUR, grt.nctsGRT_AmountToBeCoveredFremdWaehrung)
Else
grt.nctsGRT_AmountToBeCovered = grt.nctsGRT_AmountToBeCoveredFremdWaehrung
End If
End If
nctsFremd.ncts_GUARANTEE.Add(grt)
End If
'Status updaten:
If UpdateNCTSFremdStatusFromTimelines(nctsFremd.ncts_MRN, nctsFremd, False) Then
nctsFremd.SAVE_ALL()
End If
Return nctsFremd
End Function
' LIST all declarations
Public Function GetNCTSDeclarations(Optional page As Integer = 1) As List(Of cMT_NCTS_DeclarationResponse)
Public Function GetNCTSDeclarations(fromDate As DateTime, Optional page As Integer = 1) As List(Of cMT_NCTS_DeclarationResponse)
Dim list As New List(Of cMT_NCTS_DeclarationResponse)()
If Not cModalTransBase.Authenticate(authToken) Then
@@ -436,38 +742,239 @@ Public Class cModalTransNCTS
End If
http.SetRequestHeader("Authorization", "Bearer " & authToken)
Dim url = $"{cModalTransBase.baseUrl}/api/v1/ncts_declarations?page={page}"
Dim resp = http.QuickGetObj(url)
Dim fromDateStr As String = fromDate.ToString("yyyy-MM-dd")
Dim url As String = cModalTransBase.baseUrl & "/api/v1/ncts_declarations?from_date=" & fromDateStr & "&page=" & page.ToString()
http.SetRequestHeader("Authorization", "Bearer " & authToken)
Dim resp As Chilkat.HttpResponse = http.QuickGetObj(url)
If resp Is Nothing Then
Console.WriteLine("❌ Keine Verbindung: " & http.LastErrorText)
Return list
End If
If resp Is Nothing Then
Console.WriteLine("❌ Keine Verbindung: " & http.LastErrorText)
Return list
End If
Select Case resp.StatusCode
Case 200
Try
Dim json = JsonConvert.DeserializeObject(Of JObject)(resp.BodyStr)
Dim data = json.SelectToken("data")
If data IsNot Nothing Then
list = data.ToObject(Of List(Of cMT_NCTS_DeclarationResponse))()
Console.WriteLine("✅ Liste der NCTS-Anmeldungen erfolgreich abgerufen.")
Dim token As JToken = JToken.Parse(resp.BodyStr)
If TypeOf token Is JArray Then
list = token.ToObject(Of List(Of cMT_NCTS_DeclarationResponse))()
ElseIf TypeOf token Is JObject Then
Dim obj As JObject = CType(token, JObject)
Dim dataToken As JToken = obj.SelectToken("data")
If dataToken IsNot Nothing AndAlso TypeOf dataToken Is JArray Then
list = dataToken.ToObject(Of List(Of cMT_NCTS_DeclarationResponse))()
Else
Console.WriteLine("⚠️ Antwort ist ein Objekt, aber kein Array unter 'data' gefunden.")
End If
Else
Console.WriteLine("⚠️ Unbekanntes JSON-Format in der Listenantwort.")
End If
Catch ex As Exception
Console.WriteLine("❌ Fehler beim Parsen der Liste: " & ex.Message)
Console.WriteLine(resp.BodyStr)
End Try
Case 401
Console.WriteLine("❌ Zugriff verweigert (401)")
Console.WriteLine("❌ Zugriff verweigert bitte Authentifizierung prüfen.")
Case Else
Console.WriteLine($"❌ Fehler ({resp.StatusCode}): {resp.BodyStr}")
Console.WriteLine("❌ Fehler (" & resp.StatusCode.ToString() & "): " & resp.BodyStr)
End Select
Return list
End Function
Public Function GetAllNCTSDeclarations(fromDate As DateTime) As List(Of cMT_NCTS_DeclarationResponse)
Dim allItems As New List(Of cMT_NCTS_DeclarationResponse)()
Dim currentPage As Integer = 1
Do
Dim pageItems As List(Of cMT_NCTS_DeclarationResponse) = GetNCTSDeclarations(fromDate, currentPage)
If pageItems Is Nothing OrElse pageItems.Count = 0 Then
Exit Do
End If
allItems.AddRange(pageItems)
Console.WriteLine("Seite " & currentPage.ToString() & ": " & pageItems.Count.ToString() & " Einträge geladen.")
currentPage += 1
Loop
Console.WriteLine("Gesamt geladen: " & allItems.Count.ToString() & " Einträge.")
Return allItems
End Function
Public Function GetNCTSDeclarationTimelinesByMRN(mrn As String) As cMT_NCTS_GET_TimelineResponse
If Not cModalTransBase.Authenticate(authToken) Then
Console.WriteLine("❌ Authentifizierung fehlgeschlagen.")
Return Nothing
End If
http.SetRequestHeader("Authorization", "Bearer " & authToken)
Dim url = $"{cModalTransBase.baseUrl}/api/v1/ncts_declarations/{mrn}/timelines"
Dim resp = http.QuickGetObj(url)
If resp Is Nothing Then
Console.WriteLine("❌ Keine Verbindung: " & http.LastErrorText)
Return Nothing
End If
Select Case resp.StatusCode
Case 200
Try
Dim result = JsonConvert.DeserializeObject(Of cMT_NCTS_GET_TimelineResponse)(resp.BodyStr)
Console.WriteLine("✅ NCTS-Timelines erfolgreich abgerufen.")
Return result
Catch ex As Exception
Console.WriteLine("❌ Fehler beim Parsen der Timeline-Antwort: " & ex.Message)
Console.WriteLine(resp.BodyStr)
End Try
Case 400
Console.WriteLine("⚠️ Ungültige Anfrage (400): " & resp.BodyStr)
Case 403
Console.WriteLine("❌ Zugriff verweigert (403): " & resp.BodyStr)
Case 404
Console.WriteLine("⚠️ Anmeldung nicht gefunden (404): " & resp.BodyStr)
Case Else
Console.WriteLine("❌ Fehler (" & resp.StatusCode.ToString() & "): " & resp.BodyStr)
End Select
Return Nothing
End Function
Public Function UpdateNCTSFremdStatusFromTimelines(mrn As String,
ByRef nctsFremd As VERAG_PROG_ALLGEMEIN.cNCTS_FREMD,
Optional OverrideNCTSFin As Boolean = False) As Boolean
Try
If String.IsNullOrWhiteSpace(mrn) Then Return False
If nctsFremd Is Nothing Then Return False
Console.WriteLine("Status Update before:" & If(nctsFremd.ncts_Status, ""))
If Not OverrideNCTSFin Then
If IsNumeric(nctsFremd.ncts_Status) AndAlso (CInt(nctsFremd.ncts_Status) = 60 Or CInt(nctsFremd.ncts_Status) = 90) Then
Return True
End If
End If
Dim tl = GetNCTSDeclarationTimelinesByMRN(mrn)
If tl Is Nothing Then Return False
nctsFremd.ncts_MRN = mrn
Dim dtMrn As DateTime?
Dim dtLrn As DateTime?
Dim dtArrived As DateTime?
Dim dtClosed As DateTime?
If IsDate(tl.mrn_date) Then dtMrn = CDate(tl.mrn_date)
If IsDate(tl.lrn_date) Then dtLrn = CDate(tl.lrn_date)
If IsDate(tl.vahicle_arrived_date) Then dtArrived = CDate(tl.vahicle_arrived_date)
If IsDate(tl.manifesto_closed_date) Then dtClosed = CDate(tl.manifesto_closed_date)
If dtMrn.HasValue Then
nctsFremd.ncts_Eroeffnung = dtMrn.Value
If If(nctsFremd.ncts_LimitDate, "").ToString() = "" Then
nctsFremd.ncts_LimitDate = dtMrn.Value.AddDays(10)
End If
ElseIf dtLrn.HasValue Then
If If(nctsFremd.ncts_Eroeffnung, "").ToString() = "" Then nctsFremd.ncts_Eroeffnung = dtLrn.Value
If If(nctsFremd.ncts_LimitDate, "").ToString() = "" Then
nctsFremd.ncts_LimitDate = dtLrn.Value.AddDays(10)
End If
End If
Dim statusNeu As Integer = If(IsNumeric(nctsFremd.ncts_Status), CInt(nctsFremd.ncts_Status), 0)
Select Case UCase(If(tl.status, ""))
Case "IN_USE", "MRN_NOTIFIED", "WRT_NOT", "GUAINF", "CTR_DEC", "CTRINFDEP", "MRN_ALL", "REL_TRA"
statusNeu = 50
If dtMrn.HasValue Then nctsFremd.ncts_Eroeffnung = dtMrn.Value
Case "ARR_ADV", "ARRIVED"
statusNeu = 53
If If(nctsFremd.ncts_Ankunft, "").ToString() = "" Then
If dtArrived.HasValue Then
nctsFremd.ncts_Ankunft = dtArrived.Value
ElseIf dtMrn.HasValue Then
nctsFremd.ncts_Ankunft = dtMrn.Value
End If
End If
Case "TRANSIT_CLOSE", "RELEASED"
statusNeu = 60
If If(nctsFremd.ncts_Ankunft, "").ToString() = "" Then
If dtArrived.HasValue Then
nctsFremd.ncts_Ankunft = dtArrived.Value
ElseIf dtMrn.HasValue Then
nctsFremd.ncts_Ankunft = dtMrn.Value
End If
End If
If If(nctsFremd.ncts_Erledigung, "").ToString() = "" Then
If dtClosed.HasValue Then
nctsFremd.ncts_Erledigung = dtClosed.Value
ElseIf dtArrived.HasValue Then
nctsFremd.ncts_Erledigung = dtArrived.Value
ElseIf dtMrn.HasValue Then
nctsFremd.ncts_Erledigung = dtMrn.Value
End If
End If
Case "CANCELLED"
statusNeu = 90
End Select
If tl.timelines IsNot Nothing Then
For Each t In tl.timelines.OrderBy(Function(x) If(IsDate(x.status_date), CDate(x.status_date), Date.MinValue))
Select Case UCase(If(t.status_code, ""))
Case "TRUCK_IS_READY", "MRN"
If If(nctsFremd.ncts_Eroeffnung, "").ToString() = "" AndAlso IsDate(t.status_date) Then
nctsFremd.ncts_Eroeffnung = CDate(t.status_date)
End If
If statusNeu < 50 Then statusNeu = 50
Case "ARR_ADV", "AT_ARRIVAL_POINT", "ARRIVED"
If If(nctsFremd.ncts_Ankunft, "").ToString() = "" AndAlso IsDate(t.status_date) Then
nctsFremd.ncts_Ankunft = CDate(t.status_date)
End If
If statusNeu < 53 Then statusNeu = 53
Case "TRANSIT_CLOSE", "RELEASED", "COMPLETED"
If If(nctsFremd.ncts_Ankunft, "").ToString() = "" AndAlso IsDate(t.status_date) Then
nctsFremd.ncts_Ankunft = CDate(t.status_date)
End If
If If(nctsFremd.ncts_Erledigung, "").ToString() = "" AndAlso IsDate(t.status_date) Then
nctsFremd.ncts_Erledigung = CDate(t.status_date)
End If
statusNeu = 60
Case "CANCELLED"
statusNeu = 90
End Select
Next
End If
If statusNeu > 0 Then
nctsFremd.ncts_Status = statusNeu
nctsFremd.ncts_Status_KEWILL_Equivalent = statusNeu
End If
Console.WriteLine("Status Update after:" & If(nctsFremd.ncts_Status, ""))
Return True
Catch ex As Exception
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodBase.GetCurrentMethod.Name, VERAG_PROG_ALLGEMEIN.ERROR_OP.MAIL)
End Try
Return False
End Function
End Class
Public Shared Function ceateAndSend_NCTS_FromSENDUNG(LRN As String, SND As cSendungen) As Boolean
If SND.tblSnd_AvisoID <= 0 Then Return False
Dim AVISO As cAviso = (New cAvisoDAL).LesenAviso(SND.tblSnd_AvisoID, "")
@@ -686,4 +1193,6 @@ Public Class cModalTransNCTS
Console.WriteLine("❌ Keine Antwort erhalten.")
End If
End Sub
End Class