ATEZ Integration MIC, TC, MODAL
This commit is contained in:
15
Aviso/ATEZ/frmATEZ_EZA.Designer.vb
generated
15
Aviso/ATEZ/frmATEZ_EZA.Designer.vb
generated
@@ -56,9 +56,11 @@ Partial Class frmATEZ_EZA
|
||||
Me.btnPrio_Export = New System.Windows.Forms.Button()
|
||||
Me.btnPrio_ftz = New System.Windows.Forms.Button()
|
||||
Me.Panel1 = New System.Windows.Forms.Panel()
|
||||
Me.PictureBox1 = New System.Windows.Forms.PictureBox()
|
||||
Me.pnlHead.SuspendLayout()
|
||||
CType(Me.dgvAnhaenge, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
Me.Panel1.SuspendLayout()
|
||||
CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
Me.SuspendLayout()
|
||||
'
|
||||
'btnSend
|
||||
@@ -83,6 +85,7 @@ Partial Class frmATEZ_EZA
|
||||
'
|
||||
Me.pnlHead.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink
|
||||
Me.pnlHead.BackColor = System.Drawing.Color.White
|
||||
Me.pnlHead.Controls.Add(Me.PictureBox1)
|
||||
Me.pnlHead.Controls.Add(Me.Button1)
|
||||
Me.pnlHead.Controls.Add(Me.Button2)
|
||||
Me.pnlHead.Controls.Add(Me.Label1)
|
||||
@@ -447,6 +450,16 @@ Partial Class frmATEZ_EZA
|
||||
Me.Panel1.Size = New System.Drawing.Size(470, 54)
|
||||
Me.Panel1.TabIndex = 164
|
||||
'
|
||||
'PictureBox1
|
||||
'
|
||||
Me.PictureBox1.BackgroundImage = Global.AVISO.My.Resources.Resources.dakosy_de
|
||||
Me.PictureBox1.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom
|
||||
Me.PictureBox1.Location = New System.Drawing.Point(572, 34)
|
||||
Me.PictureBox1.Name = "PictureBox1"
|
||||
Me.PictureBox1.Size = New System.Drawing.Size(100, 50)
|
||||
Me.PictureBox1.TabIndex = 164
|
||||
Me.PictureBox1.TabStop = False
|
||||
'
|
||||
'frmATEZ_EZA
|
||||
'
|
||||
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
|
||||
@@ -470,6 +483,7 @@ Partial Class frmATEZ_EZA
|
||||
Me.pnlHead.PerformLayout()
|
||||
CType(Me.dgvAnhaenge, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
Me.Panel1.ResumeLayout(False)
|
||||
CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
Me.ResumeLayout(False)
|
||||
|
||||
End Sub
|
||||
@@ -505,4 +519,5 @@ Partial Class frmATEZ_EZA
|
||||
Friend WithEvents btnPrio_Export As Button
|
||||
Friend WithEvents btnPrio_ftz As Button
|
||||
Friend WithEvents Panel1 As Panel
|
||||
Friend WithEvents PictureBox1 As PictureBox
|
||||
End Class
|
||||
|
||||
@@ -27,7 +27,6 @@ Public Class frmATEZ_EZA
|
||||
Dim NCTS As DAKOSY_Worker.cDakosyNCTSOut = Nothing
|
||||
Dim openExisting As Boolean = False
|
||||
Dim id As Integer = -1
|
||||
Dim dgv As DataGridView = Nothing
|
||||
Dim atez_data As cATEZ_NCTS_DATA
|
||||
' Dim atez = New cATEZ_NCTS_IN("ATEZ")
|
||||
Dim allSelected As Boolean = False
|
||||
@@ -35,12 +34,11 @@ Public Class frmATEZ_EZA
|
||||
Property BezugsNr As String = ""
|
||||
Property SENDUNG As VERAG_PROG_ALLGEMEIN.cSendungen
|
||||
|
||||
Sub New(AVISO As VERAG_PROG_ALLGEMEIN.cAviso, SENDUNG As VERAG_PROG_ALLGEMEIN.cSendungen, JAHR As Integer, Optional _dgv As DataGridView = Nothing)
|
||||
Sub New(AVISO As VERAG_PROG_ALLGEMEIN.cAviso, SENDUNG As VERAG_PROG_ALLGEMEIN.cSendungen, JAHR As Integer)
|
||||
|
||||
' Dieser Aufruf ist für den Designer erforderlich.
|
||||
InitializeComponent()
|
||||
|
||||
If _dgv IsNot Nothing Then Me.dgv = _dgv
|
||||
Me.AVISO = AVISO
|
||||
Me.SENDUNG = SENDUNG
|
||||
Me.JAHR = JAHR
|
||||
@@ -154,9 +152,11 @@ Public Class frmATEZ_EZA
|
||||
'If btnPrio_CommInv.Tag = 1 Then combineItemsPriorityDocumentType = "packing_list"
|
||||
|
||||
|
||||
Dim environment = cRelayHubEnvironment.TEST
|
||||
Dim ATEZ_RH_EZA As New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubJobOrderRequest With {
|
||||
.environment = environment,
|
||||
.referenceNo = ioReference,
|
||||
.outputApplication = "dakosy/sftp/verg",'.outputApplication = "dakosy/sftp/vera",
|
||||
.outputApplication = cRelayHubOutputApplication.Dakosy, '"dakosy/sftp/verg",'.outputApplication = "dakosy/sftp/vera",
|
||||
.regimeType = "IMPORT",' .customer = "AVISO",
|
||||
.dispatchCountry = "TR",'"TR",
|
||||
.destinationCountry = "DE", 'Default, wird später überschrieben!! (Pflichtfeld)
|
||||
@@ -813,7 +813,7 @@ Public Class frmATEZ_EZA
|
||||
End Sub
|
||||
|
||||
Private Sub Button1_Click_1(sender As Object, e As EventArgs) Handles Button1.Click
|
||||
cRelayHubToken.DeleteStore()
|
||||
cRelayHubToken.DeleteAllStores()
|
||||
End Sub
|
||||
|
||||
Private Sub Button2_Click(sender As Object, e As EventArgs) Handles btnAgg_Tnr.Click, btnAgg_desc.Click, btnAgg_Origin.Click, btnAgg_Unit.Click
|
||||
|
||||
487
Aviso/ATEZ/frmATEZ_MIC.Designer.vb
generated
Normal file
487
Aviso/ATEZ/frmATEZ_MIC.Designer.vb
generated
Normal file
@@ -0,0 +1,487 @@
|
||||
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()>
|
||||
Partial Class frmATEZ_MIC
|
||||
Inherits System.Windows.Forms.Form
|
||||
|
||||
'Das Formular überschreibt den Löschvorgang, um die Komponentenliste zu bereinigen.
|
||||
<System.Diagnostics.DebuggerNonUserCode()>
|
||||
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
|
||||
Try
|
||||
If disposing AndAlso components IsNot Nothing Then
|
||||
components.Dispose()
|
||||
End If
|
||||
Finally
|
||||
MyBase.Dispose(disposing)
|
||||
End Try
|
||||
End Sub
|
||||
|
||||
'Wird vom Windows Form-Designer benötigt.
|
||||
Private components As System.ComponentModel.IContainer
|
||||
|
||||
'Hinweis: Die folgende Prozedur ist für den Windows Form-Designer erforderlich.
|
||||
'Das Bearbeiten ist mit dem Windows Form-Designer möglich.
|
||||
'Das Bearbeiten mit dem Code-Editor ist nicht möglich.
|
||||
<System.Diagnostics.DebuggerStepThrough()>
|
||||
Private Sub InitializeComponent()
|
||||
Me.components = New System.ComponentModel.Container()
|
||||
Dim resources As System.ComponentModel.ComponentResourceManager = New System.ComponentModel.ComponentResourceManager(GetType(frmATEZ_MIC))
|
||||
Me.btnSend = New System.Windows.Forms.Button()
|
||||
Me.pnlHead = New System.Windows.Forms.Panel()
|
||||
Me.PictureBox1 = New System.Windows.Forms.PictureBox()
|
||||
Me.Button1 = New System.Windows.Forms.Button()
|
||||
Me.Button2 = New System.Windows.Forms.Button()
|
||||
Me.Label1 = New System.Windows.Forms.Label()
|
||||
Me.lblInfo = New System.Windows.Forms.Label()
|
||||
Me.Label8 = New System.Windows.Forms.Label()
|
||||
Me.cboStammreferenz = New VERAG_PROG_ALLGEMEIN.MyComboBox()
|
||||
Me.txtLKWId = New VERAG_PROG_ALLGEMEIN.MyTextBox()
|
||||
Me.Label3 = New System.Windows.Forms.Label()
|
||||
Me.Label9 = New System.Windows.Forms.Label()
|
||||
Me.sbAdressierteZollstelle = New VERAG_PROG_ALLGEMEIN.MySearchBox()
|
||||
Me.lblBezugsnummer = New System.Windows.Forms.Label()
|
||||
Me.Button3 = New System.Windows.Forms.Button()
|
||||
Me.Label6 = New System.Windows.Forms.Label()
|
||||
Me.lblAnh = New System.Windows.Forms.Label()
|
||||
Me.btnAgg_Tnr = New System.Windows.Forms.Button()
|
||||
Me.Label2 = New System.Windows.Forms.Label()
|
||||
Me.btnAgg_Origin = New System.Windows.Forms.Button()
|
||||
Me.btnAgg_Unit = New System.Windows.Forms.Button()
|
||||
Me.btnAgg_desc = New System.Windows.Forms.Button()
|
||||
Me.dgvAnhaenge = New VERAG_PROG_ALLGEMEIN.MyDatagridview(Me.components)
|
||||
Me.columnName = New System.Windows.Forms.DataGridViewTextBoxColumn()
|
||||
Me.btnPrio_CommInv = New System.Windows.Forms.Button()
|
||||
Me.Label5 = New System.Windows.Forms.Label()
|
||||
Me.btnPrio_eFatura = New System.Windows.Forms.Button()
|
||||
Me.btnPrio_Export = New System.Windows.Forms.Button()
|
||||
Me.btnPrio_ftz = New System.Windows.Forms.Button()
|
||||
Me.Panel1 = New System.Windows.Forms.Panel()
|
||||
Me.pnlHead.SuspendLayout()
|
||||
CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.dgvAnhaenge, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
Me.Panel1.SuspendLayout()
|
||||
Me.SuspendLayout()
|
||||
'
|
||||
'btnSend
|
||||
'
|
||||
Me.btnSend.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.btnSend.BackColor = System.Drawing.Color.White
|
||||
Me.btnSend.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Center
|
||||
Me.btnSend.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!)
|
||||
Me.btnSend.Image = Global.AVISO.My.Resources.Resources.ico_atez_declarantAI
|
||||
Me.btnSend.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
|
||||
Me.btnSend.Location = New System.Drawing.Point(473, 343)
|
||||
Me.btnSend.Margin = New System.Windows.Forms.Padding(2)
|
||||
Me.btnSend.Name = "btnSend"
|
||||
Me.btnSend.Padding = New System.Windows.Forms.Padding(5, 0, 5, 0)
|
||||
Me.btnSend.Size = New System.Drawing.Size(205, 58)
|
||||
Me.btnSend.TabIndex = 26
|
||||
Me.btnSend.Text = "An ATEZ senden >>"
|
||||
Me.btnSend.TextAlign = System.Drawing.ContentAlignment.MiddleRight
|
||||
Me.btnSend.UseVisualStyleBackColor = False
|
||||
'
|
||||
'pnlHead
|
||||
'
|
||||
Me.pnlHead.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink
|
||||
Me.pnlHead.BackColor = System.Drawing.Color.White
|
||||
Me.pnlHead.Controls.Add(Me.PictureBox1)
|
||||
Me.pnlHead.Controls.Add(Me.Button1)
|
||||
Me.pnlHead.Controls.Add(Me.Button2)
|
||||
Me.pnlHead.Controls.Add(Me.Label1)
|
||||
Me.pnlHead.Controls.Add(Me.lblInfo)
|
||||
Me.pnlHead.Controls.Add(Me.Label8)
|
||||
Me.pnlHead.Controls.Add(Me.cboStammreferenz)
|
||||
Me.pnlHead.Controls.Add(Me.txtLKWId)
|
||||
Me.pnlHead.Controls.Add(Me.Label3)
|
||||
Me.pnlHead.Controls.Add(Me.Label9)
|
||||
Me.pnlHead.Controls.Add(Me.sbAdressierteZollstelle)
|
||||
Me.pnlHead.Controls.Add(Me.lblBezugsnummer)
|
||||
Me.pnlHead.Location = New System.Drawing.Point(3, 2)
|
||||
Me.pnlHead.Name = "pnlHead"
|
||||
Me.pnlHead.Size = New System.Drawing.Size(675, 151)
|
||||
Me.pnlHead.TabIndex = 112
|
||||
'
|
||||
'PictureBox1
|
||||
'
|
||||
Me.PictureBox1.BackgroundImage = Global.AVISO.My.Resources.Resources.mic_nl
|
||||
Me.PictureBox1.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom
|
||||
Me.PictureBox1.Location = New System.Drawing.Point(572, 34)
|
||||
Me.PictureBox1.Name = "PictureBox1"
|
||||
Me.PictureBox1.Size = New System.Drawing.Size(100, 50)
|
||||
Me.PictureBox1.TabIndex = 159
|
||||
Me.PictureBox1.TabStop = False
|
||||
'
|
||||
'Button1
|
||||
'
|
||||
Me.Button1.Location = New System.Drawing.Point(553, 117)
|
||||
Me.Button1.Name = "Button1"
|
||||
Me.Button1.Size = New System.Drawing.Size(122, 23)
|
||||
Me.Button1.TabIndex = 153
|
||||
Me.Button1.Text = "Clear Token Cache"
|
||||
Me.Button1.UseVisualStyleBackColor = True
|
||||
'
|
||||
'Button2
|
||||
'
|
||||
Me.Button2.Location = New System.Drawing.Point(610, 96)
|
||||
Me.Button2.Name = "Button2"
|
||||
Me.Button2.Size = New System.Drawing.Size(65, 23)
|
||||
Me.Button2.TabIndex = 158
|
||||
Me.Button2.Text = "json"
|
||||
Me.Button2.UseVisualStyleBackColor = True
|
||||
'
|
||||
'Label1
|
||||
'
|
||||
Me.Label1.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.Label1.AutoSize = True
|
||||
Me.Label1.BackColor = System.Drawing.Color.White
|
||||
Me.Label1.Location = New System.Drawing.Point(387, 13)
|
||||
Me.Label1.Name = "Label1"
|
||||
Me.Label1.Size = New System.Drawing.Size(89, 13)
|
||||
Me.Label1.TabIndex = 106
|
||||
Me.Label1.Text = "Bezugsnummer:"
|
||||
'
|
||||
'lblInfo
|
||||
'
|
||||
Me.lblInfo.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
|
||||
Me.lblInfo.ForeColor = System.Drawing.Color.Red
|
||||
Me.lblInfo.Location = New System.Drawing.Point(3, 32)
|
||||
Me.lblInfo.Name = "lblInfo"
|
||||
Me.lblInfo.Size = New System.Drawing.Size(460, 21)
|
||||
Me.lblInfo.TabIndex = 148
|
||||
'
|
||||
'Label8
|
||||
'
|
||||
Me.Label8.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.Label8.AutoSize = True
|
||||
Me.Label8.Location = New System.Drawing.Point(6, 61)
|
||||
Me.Label8.Name = "Label8"
|
||||
Me.Label8.Size = New System.Drawing.Size(86, 13)
|
||||
Me.Label8.TabIndex = 146
|
||||
Me.Label8.Text = "Stammreferenz:"
|
||||
Me.Label8.TextAlign = System.Drawing.ContentAlignment.TopRight
|
||||
Me.Label8.Visible = False
|
||||
'
|
||||
'cboStammreferenz
|
||||
'
|
||||
Me.cboStammreferenz._allowedValuesFreiText = Nothing
|
||||
Me.cboStammreferenz._allowFreiText = False
|
||||
Me.cboStammreferenz._value = ""
|
||||
Me.cboStammreferenz.BackColor = System.Drawing.Color.FromArgb(CType(CType(224, Byte), Integer), CType(CType(224, Byte), Integer), CType(CType(224, Byte), Integer))
|
||||
Me.cboStammreferenz.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList
|
||||
Me.cboStammreferenz.FlatStyle = System.Windows.Forms.FlatStyle.Flat
|
||||
Me.cboStammreferenz.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!)
|
||||
Me.cboStammreferenz.FormattingEnabled = True
|
||||
Me.cboStammreferenz.Location = New System.Drawing.Point(151, 56)
|
||||
Me.cboStammreferenz.Name = "cboStammreferenz"
|
||||
Me.cboStammreferenz.Size = New System.Drawing.Size(255, 24)
|
||||
Me.cboStammreferenz.TabIndex = 145
|
||||
Me.cboStammreferenz.Visible = False
|
||||
'
|
||||
'txtLKWId
|
||||
'
|
||||
Me.txtLKWId._DateTimeOnly = False
|
||||
Me.txtLKWId._numbersOnly = False
|
||||
Me.txtLKWId._numbersOnlyKommastellen = ""
|
||||
Me.txtLKWId._numbersOnlyTrennzeichen = True
|
||||
Me.txtLKWId._Prozent = False
|
||||
Me.txtLKWId._ShortDateNew = False
|
||||
Me.txtLKWId._ShortDateOnly = False
|
||||
Me.txtLKWId._TimeOnly = False
|
||||
Me.txtLKWId._TimeOnly_Seconds = False
|
||||
Me.txtLKWId._value = ""
|
||||
Me.txtLKWId._Waehrung = False
|
||||
Me.txtLKWId._WaehrungZeichen = True
|
||||
Me.txtLKWId.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!)
|
||||
Me.txtLKWId.ForeColor = System.Drawing.Color.Black
|
||||
Me.txtLKWId.Location = New System.Drawing.Point(151, 86)
|
||||
Me.txtLKWId.MaxLineLength = -1
|
||||
Me.txtLKWId.MaxLines_Warning = ""
|
||||
Me.txtLKWId.MaxLines_Warning_Label = Nothing
|
||||
Me.txtLKWId.Name = "txtLKWId"
|
||||
Me.txtLKWId.Size = New System.Drawing.Size(255, 23)
|
||||
Me.txtLKWId.TabIndex = 144
|
||||
'
|
||||
'Label3
|
||||
'
|
||||
Me.Label3.AutoSize = True
|
||||
Me.Label3.Location = New System.Drawing.Point(6, 91)
|
||||
Me.Label3.Name = "Label3"
|
||||
Me.Label3.Size = New System.Drawing.Size(48, 13)
|
||||
Me.Label3.TabIndex = 113
|
||||
Me.Label3.Text = "LKW-KZ:"
|
||||
'
|
||||
'Label9
|
||||
'
|
||||
Me.Label9.AutoSize = True
|
||||
Me.Label9.Location = New System.Drawing.Point(6, 117)
|
||||
Me.Label9.Name = "Label9"
|
||||
Me.Label9.Size = New System.Drawing.Size(117, 13)
|
||||
Me.Label9.TabIndex = 110
|
||||
Me.Label9.Text = "Adressierte-Zollstelle:"
|
||||
'
|
||||
'sbAdressierteZollstelle
|
||||
'
|
||||
Me.sbAdressierteZollstelle._allowFreitext = False
|
||||
Me.sbAdressierteZollstelle._AllowSetValue = False
|
||||
Me.sbAdressierteZollstelle._allowSpaceAsSplitter = False
|
||||
Me.sbAdressierteZollstelle._autoSizeGross = False
|
||||
Me.sbAdressierteZollstelle._hideIfListEmpty = True
|
||||
Me.sbAdressierteZollstelle._value = ""
|
||||
Me.sbAdressierteZollstelle.conn_art = "FMZOLL"
|
||||
Me.sbAdressierteZollstelle.dgvpos = "LEFT"
|
||||
Me.sbAdressierteZollstelle.DISPLAY_PARAM = Nothing
|
||||
Me.sbAdressierteZollstelle.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!)
|
||||
Me.sbAdressierteZollstelle.INVISIBLE_COLUMNS = Nothing
|
||||
Me.sbAdressierteZollstelle.key_visible = False
|
||||
Me.sbAdressierteZollstelle.KEYPARAM = Nothing
|
||||
Me.sbAdressierteZollstelle.Location = New System.Drawing.Point(151, 112)
|
||||
Me.sbAdressierteZollstelle.Name = "sbAdressierteZollstelle"
|
||||
Me.sbAdressierteZollstelle.searchActive = True
|
||||
Me.sbAdressierteZollstelle.Size = New System.Drawing.Size(255, 23)
|
||||
Me.sbAdressierteZollstelle.SQL_ORDER_BY = Nothing
|
||||
Me.sbAdressierteZollstelle.SQL_SELECT = Nothing
|
||||
Me.sbAdressierteZollstelle.SQL_WHERE = Nothing
|
||||
Me.sbAdressierteZollstelle.SQL_WhereParamList = Nothing
|
||||
Me.sbAdressierteZollstelle.TabIndex = 111
|
||||
Me.sbAdressierteZollstelle.usrcntl = Nothing
|
||||
'
|
||||
'lblBezugsnummer
|
||||
'
|
||||
Me.lblBezugsnummer.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.lblBezugsnummer.BackColor = System.Drawing.Color.White
|
||||
Me.lblBezugsnummer.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
|
||||
Me.lblBezugsnummer.Location = New System.Drawing.Point(475, 8)
|
||||
Me.lblBezugsnummer.Name = "lblBezugsnummer"
|
||||
Me.lblBezugsnummer.Size = New System.Drawing.Size(193, 23)
|
||||
Me.lblBezugsnummer.TabIndex = 107
|
||||
Me.lblBezugsnummer.Text = "4800/000000/17 AAA"
|
||||
Me.lblBezugsnummer.TextAlign = System.Drawing.ContentAlignment.MiddleRight
|
||||
'
|
||||
'Button3
|
||||
'
|
||||
Me.Button3.Location = New System.Drawing.Point(473, 157)
|
||||
Me.Button3.Name = "Button3"
|
||||
Me.Button3.Size = New System.Drawing.Size(205, 25)
|
||||
Me.Button3.TabIndex = 152
|
||||
Me.Button3.Text = "alle Anhänge auswählen"
|
||||
Me.Button3.UseVisualStyleBackColor = True
|
||||
'
|
||||
'Label6
|
||||
'
|
||||
Me.Label6.Location = New System.Drawing.Point(9, 168)
|
||||
Me.Label6.Name = "Label6"
|
||||
Me.Label6.Size = New System.Drawing.Size(135, 13)
|
||||
Me.Label6.TabIndex = 147
|
||||
Me.Label6.Text = "Dokumente:"
|
||||
'
|
||||
'lblAnh
|
||||
'
|
||||
Me.lblAnh.Location = New System.Drawing.Point(332, 168)
|
||||
Me.lblAnh.Name = "lblAnh"
|
||||
Me.lblAnh.Size = New System.Drawing.Size(135, 13)
|
||||
Me.lblAnh.TabIndex = 151
|
||||
Me.lblAnh.Visible = False
|
||||
'
|
||||
'btnAgg_Tnr
|
||||
'
|
||||
Me.btnAgg_Tnr.BackColor = System.Drawing.Color.DeepSkyBlue
|
||||
Me.btnAgg_Tnr.Location = New System.Drawing.Point(76, 3)
|
||||
Me.btnAgg_Tnr.Name = "btnAgg_Tnr"
|
||||
Me.btnAgg_Tnr.Size = New System.Drawing.Size(83, 23)
|
||||
Me.btnAgg_Tnr.TabIndex = 154
|
||||
Me.btnAgg_Tnr.Tag = "1"
|
||||
Me.btnAgg_Tnr.Text = "Tarifnummer"
|
||||
Me.btnAgg_Tnr.UseVisualStyleBackColor = False
|
||||
'
|
||||
'Label2
|
||||
'
|
||||
Me.Label2.Font = New System.Drawing.Font("Segoe UI", 8.0!)
|
||||
Me.Label2.Location = New System.Drawing.Point(3, 8)
|
||||
Me.Label2.Name = "Label2"
|
||||
Me.Label2.Size = New System.Drawing.Size(103, 17)
|
||||
Me.Label2.TabIndex = 149
|
||||
Me.Label2.Text = "Aggregieren:"
|
||||
'
|
||||
'btnAgg_Origin
|
||||
'
|
||||
Me.btnAgg_Origin.BackColor = System.Drawing.Color.DeepSkyBlue
|
||||
Me.btnAgg_Origin.Location = New System.Drawing.Point(162, 3)
|
||||
Me.btnAgg_Origin.Name = "btnAgg_Origin"
|
||||
Me.btnAgg_Origin.Size = New System.Drawing.Size(92, 23)
|
||||
Me.btnAgg_Origin.TabIndex = 155
|
||||
Me.btnAgg_Origin.Tag = "1"
|
||||
Me.btnAgg_Origin.Text = "Ursprungsland"
|
||||
Me.btnAgg_Origin.UseVisualStyleBackColor = False
|
||||
'
|
||||
'btnAgg_Unit
|
||||
'
|
||||
Me.btnAgg_Unit.Location = New System.Drawing.Point(257, 3)
|
||||
Me.btnAgg_Unit.Name = "btnAgg_Unit"
|
||||
Me.btnAgg_Unit.Size = New System.Drawing.Size(79, 23)
|
||||
Me.btnAgg_Unit.TabIndex = 156
|
||||
Me.btnAgg_Unit.Tag = "0"
|
||||
Me.btnAgg_Unit.Text = "Maßeinheit"
|
||||
Me.btnAgg_Unit.UseVisualStyleBackColor = True
|
||||
'
|
||||
'btnAgg_desc
|
||||
'
|
||||
Me.btnAgg_desc.Location = New System.Drawing.Point(339, 3)
|
||||
Me.btnAgg_desc.Name = "btnAgg_desc"
|
||||
Me.btnAgg_desc.Size = New System.Drawing.Size(126, 23)
|
||||
Me.btnAgg_desc.TabIndex = 157
|
||||
Me.btnAgg_desc.Tag = "0"
|
||||
Me.btnAgg_desc.Text = "Warenbeschreibung"
|
||||
Me.btnAgg_desc.UseVisualStyleBackColor = True
|
||||
'
|
||||
'dgvAnhaenge
|
||||
'
|
||||
Me.dgvAnhaenge.AKTUALISIERUNGS_INTERVALL = -1
|
||||
Me.dgvAnhaenge.AllowUserToAddRows = False
|
||||
Me.dgvAnhaenge.AllowUserToDeleteRows = False
|
||||
Me.dgvAnhaenge.AllowUserToResizeColumns = False
|
||||
Me.dgvAnhaenge.AllowUserToResizeRows = False
|
||||
Me.dgvAnhaenge.BackgroundColor = System.Drawing.Color.White
|
||||
Me.dgvAnhaenge.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize
|
||||
Me.dgvAnhaenge.Columns.AddRange(New System.Windows.Forms.DataGridViewColumn() {Me.columnName})
|
||||
Me.dgvAnhaenge.Location = New System.Drawing.Point(3, 184)
|
||||
Me.dgvAnhaenge.Name = "dgvAnhaenge"
|
||||
Me.dgvAnhaenge.ReadOnly = True
|
||||
Me.dgvAnhaenge.RowHeadersVisible = False
|
||||
Me.dgvAnhaenge.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect
|
||||
Me.dgvAnhaenge.Size = New System.Drawing.Size(675, 158)
|
||||
Me.dgvAnhaenge.TabIndex = 112
|
||||
'
|
||||
'columnName
|
||||
'
|
||||
Me.columnName.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill
|
||||
Me.columnName.HeaderText = "Name"
|
||||
Me.columnName.Name = "columnName"
|
||||
Me.columnName.ReadOnly = True
|
||||
'
|
||||
'btnPrio_CommInv
|
||||
'
|
||||
Me.btnPrio_CommInv.BackColor = System.Drawing.Color.White
|
||||
Me.btnPrio_CommInv.Location = New System.Drawing.Point(76, 28)
|
||||
Me.btnPrio_CommInv.Name = "btnPrio_CommInv"
|
||||
Me.btnPrio_CommInv.Size = New System.Drawing.Size(116, 23)
|
||||
Me.btnPrio_CommInv.TabIndex = 159
|
||||
Me.btnPrio_CommInv.Tag = "0"
|
||||
Me.btnPrio_CommInv.Text = "Handelsrechnung"
|
||||
Me.btnPrio_CommInv.UseVisualStyleBackColor = False
|
||||
'
|
||||
'Label5
|
||||
'
|
||||
Me.Label5.Font = New System.Drawing.Font("Segoe UI", 8.0!)
|
||||
Me.Label5.Location = New System.Drawing.Point(3, 33)
|
||||
Me.Label5.Name = "Label5"
|
||||
Me.Label5.Size = New System.Drawing.Size(103, 17)
|
||||
Me.Label5.TabIndex = 160
|
||||
Me.Label5.Text = "Priorität:"
|
||||
'
|
||||
'btnPrio_eFatura
|
||||
'
|
||||
Me.btnPrio_eFatura.BackColor = System.Drawing.Color.White
|
||||
Me.btnPrio_eFatura.Location = New System.Drawing.Point(195, 28)
|
||||
Me.btnPrio_eFatura.Name = "btnPrio_eFatura"
|
||||
Me.btnPrio_eFatura.Size = New System.Drawing.Size(69, 23)
|
||||
Me.btnPrio_eFatura.TabIndex = 161
|
||||
Me.btnPrio_eFatura.Tag = "0"
|
||||
Me.btnPrio_eFatura.Text = "eFatura"
|
||||
Me.btnPrio_eFatura.UseVisualStyleBackColor = False
|
||||
'
|
||||
'btnPrio_Export
|
||||
'
|
||||
Me.btnPrio_Export.BackColor = System.Drawing.Color.White
|
||||
Me.btnPrio_Export.Location = New System.Drawing.Point(267, 28)
|
||||
Me.btnPrio_Export.Name = "btnPrio_Export"
|
||||
Me.btnPrio_Export.Size = New System.Drawing.Size(69, 23)
|
||||
Me.btnPrio_Export.TabIndex = 162
|
||||
Me.btnPrio_Export.Tag = "0"
|
||||
Me.btnPrio_Export.Text = "Ausfuhr"
|
||||
Me.btnPrio_Export.UseVisualStyleBackColor = False
|
||||
'
|
||||
'btnPrio_ftz
|
||||
'
|
||||
Me.btnPrio_ftz.BackColor = System.Drawing.Color.White
|
||||
Me.btnPrio_ftz.Location = New System.Drawing.Point(339, 28)
|
||||
Me.btnPrio_ftz.Name = "btnPrio_ftz"
|
||||
Me.btnPrio_ftz.Size = New System.Drawing.Size(69, 23)
|
||||
Me.btnPrio_ftz.TabIndex = 163
|
||||
Me.btnPrio_ftz.Tag = "0"
|
||||
Me.btnPrio_ftz.Text = "FTZ"
|
||||
Me.btnPrio_ftz.UseVisualStyleBackColor = False
|
||||
'
|
||||
'Panel1
|
||||
'
|
||||
Me.Panel1.BackColor = System.Drawing.SystemColors.InactiveBorder
|
||||
Me.Panel1.Controls.Add(Me.btnPrio_CommInv)
|
||||
Me.Panel1.Controls.Add(Me.btnAgg_Tnr)
|
||||
Me.Panel1.Controls.Add(Me.btnPrio_ftz)
|
||||
Me.Panel1.Controls.Add(Me.Label2)
|
||||
Me.Panel1.Controls.Add(Me.btnPrio_Export)
|
||||
Me.Panel1.Controls.Add(Me.btnAgg_Origin)
|
||||
Me.Panel1.Controls.Add(Me.btnPrio_eFatura)
|
||||
Me.Panel1.Controls.Add(Me.btnAgg_Unit)
|
||||
Me.Panel1.Controls.Add(Me.Label5)
|
||||
Me.Panel1.Controls.Add(Me.btnAgg_desc)
|
||||
Me.Panel1.Location = New System.Drawing.Point(0, 343)
|
||||
Me.Panel1.Name = "Panel1"
|
||||
Me.Panel1.Size = New System.Drawing.Size(470, 54)
|
||||
Me.Panel1.TabIndex = 164
|
||||
'
|
||||
'frmATEZ_MIC
|
||||
'
|
||||
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
|
||||
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
|
||||
Me.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink
|
||||
Me.BackColor = System.Drawing.SystemColors.InactiveBorder
|
||||
Me.ClientSize = New System.Drawing.Size(680, 409)
|
||||
Me.Controls.Add(Me.Button3)
|
||||
Me.Controls.Add(Me.lblAnh)
|
||||
Me.Controls.Add(Me.pnlHead)
|
||||
Me.Controls.Add(Me.Label6)
|
||||
Me.Controls.Add(Me.btnSend)
|
||||
Me.Controls.Add(Me.dgvAnhaenge)
|
||||
Me.Controls.Add(Me.Panel1)
|
||||
Me.Font = New System.Drawing.Font("Segoe UI", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
|
||||
Me.Icon = CType(resources.GetObject("$this.Icon"), System.Drawing.Icon)
|
||||
Me.Name = "frmATEZ_MIC"
|
||||
Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
|
||||
Me.Text = "ATEZ UK"
|
||||
Me.pnlHead.ResumeLayout(False)
|
||||
Me.pnlHead.PerformLayout()
|
||||
CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.dgvAnhaenge, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
Me.Panel1.ResumeLayout(False)
|
||||
Me.ResumeLayout(False)
|
||||
|
||||
End Sub
|
||||
Friend WithEvents btnSend As Button
|
||||
Friend WithEvents pnlHead As Panel
|
||||
Friend WithEvents lblInfo As Label
|
||||
Friend WithEvents Label6 As Label
|
||||
Friend WithEvents Label8 As Label
|
||||
Friend WithEvents cboStammreferenz As VERAG_PROG_ALLGEMEIN.MyComboBox
|
||||
Friend WithEvents txtLKWId As VERAG_PROG_ALLGEMEIN.MyTextBox
|
||||
Friend WithEvents Label3 As Label
|
||||
Friend WithEvents dgvAnhaenge As VERAG_PROG_ALLGEMEIN.MyDatagridview
|
||||
Friend WithEvents columnName As DataGridViewTextBoxColumn
|
||||
Friend WithEvents Label9 As Label
|
||||
Friend WithEvents sbAdressierteZollstelle As VERAG_PROG_ALLGEMEIN.MySearchBox
|
||||
Friend WithEvents Label1 As Label
|
||||
Friend WithEvents lblBezugsnummer As Label
|
||||
Friend WithEvents lblAnh As Label
|
||||
Friend WithEvents Button3 As Button
|
||||
Friend WithEvents Button1 As Button
|
||||
Friend WithEvents btnAgg_Tnr As Button
|
||||
Friend WithEvents Label2 As Label
|
||||
Friend WithEvents btnAgg_Origin As Button
|
||||
Friend WithEvents btnAgg_Unit As Button
|
||||
Friend WithEvents btnAgg_desc As Button
|
||||
Friend WithEvents Button2 As Button
|
||||
Friend WithEvents btnPrio_CommInv As Button
|
||||
Friend WithEvents Label5 As Label
|
||||
Friend WithEvents btnPrio_eFatura As Button
|
||||
Friend WithEvents btnPrio_Export As Button
|
||||
Friend WithEvents btnPrio_ftz As Button
|
||||
Friend WithEvents Panel1 As Panel
|
||||
Friend WithEvents PictureBox1 As PictureBox
|
||||
End Class
|
||||
1256
Aviso/ATEZ/frmATEZ_MIC.resx
Normal file
1256
Aviso/ATEZ/frmATEZ_MIC.resx
Normal file
File diff suppressed because it is too large
Load Diff
715
Aviso/ATEZ/frmATEZ_MIC.vb
Normal file
715
Aviso/ATEZ/frmATEZ_MIC.vb
Normal file
@@ -0,0 +1,715 @@
|
||||
|
||||
Imports com.esendex.sdk.optouts.models
|
||||
Imports DAKOSY_Worker
|
||||
Imports DAKOSY_Worker.eZollTypes
|
||||
Imports SDL
|
||||
Imports VERAG_PROG_ALLGEMEIN
|
||||
Imports VERAG_PROG_ALLGEMEIN.cRelayHub
|
||||
|
||||
|
||||
Public Class frmATEZ_MIC
|
||||
|
||||
Dim ART As String = ""
|
||||
Dim FilialenNr As Integer
|
||||
Dim AbfertigungsNr As Integer
|
||||
Dim JAHR As Integer = Now.ToString("yy")
|
||||
Public isSTAMMREF As Boolean = False
|
||||
Public STAMMREF As String = ""
|
||||
Public CopyFromZA_Id As Integer = -1
|
||||
Dim FIRMA_DY = VERAG_PROG_ALLGEMEIN.cAllgemein.FIRMA
|
||||
Dim ZOLL_SYSTEM = "MODALTRANS"
|
||||
Dim DY As DAKOSY_Worker.cDakosy_Zollanmeldungen = Nothing
|
||||
Public ATT As List(Of String)
|
||||
Dim AVISO As New cAviso
|
||||
Dim zusatz As String
|
||||
Dim cDy_ART As String = If(FIRMA_DY = "ATILLA", "T2", "T1")
|
||||
Dim VermerkeDAL As New cVermerkeDAL
|
||||
Dim NCTS As DAKOSY_Worker.cDakosyNCTSOut = Nothing
|
||||
Dim openExisting As Boolean = False
|
||||
Dim id As Integer = -1
|
||||
Dim dgv As DataGridView = Nothing
|
||||
Dim atez_data As cATEZ_NCTS_DATA
|
||||
' Dim atez = New cATEZ_NCTS_IN("ATEZ")
|
||||
Dim allSelected As Boolean = False
|
||||
|
||||
Property BezugsNr As String = ""
|
||||
Property SENDUNG As VERAG_PROG_ALLGEMEIN.cSendungen
|
||||
|
||||
Sub New(AVISO As VERAG_PROG_ALLGEMEIN.cAviso, SENDUNG As VERAG_PROG_ALLGEMEIN.cSendungen, JAHR As Integer, Optional _dgv As DataGridView = Nothing)
|
||||
|
||||
' Dieser Aufruf ist für den Designer erforderlich.
|
||||
InitializeComponent()
|
||||
|
||||
If _dgv IsNot Nothing Then Me.dgv = _dgv
|
||||
Me.AVISO = AVISO
|
||||
Me.SENDUNG = SENDUNG
|
||||
Me.JAHR = JAHR
|
||||
|
||||
If SENDUNG IsNot Nothing Then
|
||||
Me.FilialenNr = SENDUNG.FilialenNr
|
||||
Me.AbfertigungsNr = SENDUNG.AbfertigungsNr
|
||||
End If
|
||||
|
||||
' Fügen Sie Initialisierungen nach dem InitializeComponent()-Aufruf hinzu.
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
Sub New(_id As Integer, AVISO As VERAG_PROG_ALLGEMEIN.cAviso, SENDUNG As VERAG_PROG_ALLGEMEIN.cSendungen, JAHR As Integer)
|
||||
|
||||
' Dieser Aufruf ist für den Designer erforderlich.
|
||||
InitializeComponent()
|
||||
openExisting = True
|
||||
id = _id
|
||||
|
||||
Me.AVISO = AVISO
|
||||
Me.SENDUNG = SENDUNG
|
||||
Me.JAHR = JAHR
|
||||
|
||||
If SENDUNG IsNot Nothing Then
|
||||
Me.FilialenNr = SENDUNG.FilialenNr
|
||||
Me.AbfertigungsNr = SENDUNG.AbfertigungsNr
|
||||
End If
|
||||
|
||||
|
||||
' Fügen Sie Initialisierungen nach dem InitializeComponent()-Aufruf hinzu.
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles btnSend.Click, Button2.Click
|
||||
Try
|
||||
If Not checkMandatoryField() Then Exit Sub
|
||||
|
||||
Me.Cursor = Cursors.WaitCursor
|
||||
lblInfo.Text = ""
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' Referenz
|
||||
'----------------------------------------------------------------------
|
||||
Dim ioReferenceLRN As String = lblBezugsnummer.Text
|
||||
Dim ioReference As String = lblBezugsnummer.Text & Now.ToString("ddMMyyyy_HHmmss")
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' RelayHub Request - MIC NL Import
|
||||
'----------------------------------------------------------------------
|
||||
'Dim environment = If(VERAG_PROG_ALLGEMEIN.cAllgemein.TESTSYSTEM, cRelayHubEnvironment.TEST, cRelayHubEnvironment.PROD)
|
||||
Dim environment = cRelayHubEnvironment.TEST
|
||||
Dim ATEZ_RH_EZA As New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubJobOrderRequest With {
|
||||
.environment = environment,
|
||||
.referenceNo = ioReference,
|
||||
.outputApplication = cRelayHubOutputApplication.MIC_NL_IMPORT,
|
||||
.dispatchCountry = "TR",
|
||||
.destinationCountry = "NL",
|
||||
.additionalData = New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubAdditionalData With {
|
||||
.micImportShipment = New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubMicImportShipment With {
|
||||
.partyId = "party-id-003",
|
||||
.shipmentId = ioReferenceLRN
|
||||
},
|
||||
.declaration = New List(Of VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubDeclaration) From {
|
||||
New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubDeclaration With {
|
||||
.addresses = New List(Of VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubAddress)
|
||||
}
|
||||
}
|
||||
},
|
||||
.additionalSettings = New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubAdditionalSettings With {
|
||||
.disableOutbound = False,
|
||||
.disableValidation = False
|
||||
}
|
||||
}
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' Dokumente
|
||||
'----------------------------------------------------------------------
|
||||
ATEZ_RH_EZA.documents = New List(Of VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubDocument)
|
||||
|
||||
For Each r As DataGridViewRow In dgvAnhaenge.Rows
|
||||
Dim isSelected As Boolean = If(DBNull.Value Is r.Cells("anh_selekt").Value, False, r.Cells("anh_selekt").Value)
|
||||
|
||||
If isSelected Then
|
||||
Dim DOC As New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubDocument
|
||||
DOC.fileType = VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHub_sendToRelayHub_JobOrderRequest.getRelayHub_AnhDesc(r.Cells("anh_Art").Value)
|
||||
DOC.type = "base64"
|
||||
DOC.filename = r.Cells("anh_Name").Value
|
||||
|
||||
Try
|
||||
Dim dateiBytes As Byte() = IO.File.ReadAllBytes(VERAG_PROG_ALLGEMEIN.cDATENSERVER.GET_PDFPath_BY_DocID(r.Cells("anh_docId").Value))
|
||||
DOC.base64String = Convert.ToBase64String(dateiBytes)
|
||||
ATEZ_RH_EZA.documents.Add(DOC)
|
||||
Catch ex As Exception
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
||||
End Try
|
||||
End If
|
||||
Next
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' Empfänger / Consignee - CN
|
||||
'----------------------------------------------------------------------
|
||||
If SENDUNG.tblSnd_EmpfaengerKdNr > 0 Then
|
||||
Dim AD As New cAdressen(SENDUNG.tblSnd_EmpfaengerKdNr)
|
||||
Dim KD As New cKunde(SENDUNG.tblSnd_EmpfaengerKdNr)
|
||||
Dim CN As New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubAddress
|
||||
|
||||
CN.addressType = "CN"
|
||||
CN.participantEORI = If(KD.EORITIN, "")
|
||||
CN.participantSubsidiaryNumber = If(KD.EORITIN_NL, "")
|
||||
CN.companyName = AD.Name_1
|
||||
CN.streetAndNumber = AD.Straße
|
||||
CN.postalCode = AD.PLZ
|
||||
CN.city = AD.Ort
|
||||
CN.countryCode = SDL.cProgramFunctions.getISO2Land(AD.LandKz)
|
||||
|
||||
ATEZ_RH_EZA.additionalData.declaration(0).addresses.Add(CN)
|
||||
If Not String.IsNullOrWhiteSpace(CN.countryCode) Then ATEZ_RH_EZA.destinationCountry = CN.countryCode
|
||||
End If
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' Absender / Consignor - CZ
|
||||
'----------------------------------------------------------------------
|
||||
If SENDUNG.tblSnd_AbsenderKdNr > 0 Then
|
||||
Dim AD As New cAdressen(SENDUNG.tblSnd_AbsenderKdNr)
|
||||
Dim KD As New cKunde(SENDUNG.tblSnd_AbsenderKdNr)
|
||||
Dim CZ As New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubAddress
|
||||
|
||||
CZ.addressType = "CZ"
|
||||
CZ.participantEORI = If(KD.EORITIN, "")
|
||||
CZ.participantSubsidiaryNumber = If(KD.EORITIN_NL, "")
|
||||
CZ.companyName = AD.Name_1
|
||||
CZ.streetAndNumber = AD.Straße
|
||||
CZ.postalCode = AD.PLZ
|
||||
CZ.city = AD.Ort
|
||||
CZ.countryCode = SDL.cProgramFunctions.getISO2Land(AD.LandKz)
|
||||
|
||||
ATEZ_RH_EZA.additionalData.declaration(0).addresses.Add(CZ)
|
||||
If Not String.IsNullOrWhiteSpace(CZ.countryCode) Then ATEZ_RH_EZA.dispatchCountry = CZ.countryCode
|
||||
End If
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' Pflichtfelder
|
||||
'----------------------------------------------------------------------
|
||||
ATEZ_RH_EZA.dispatchCountry = If(ATEZ_RH_EZA.dispatchCountry, "").Trim().ToUpperInvariant()
|
||||
ATEZ_RH_EZA.destinationCountry = If(ATEZ_RH_EZA.destinationCountry, "").Trim().ToUpperInvariant()
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' JSON anzeigen
|
||||
'----------------------------------------------------------------------
|
||||
If sender Is Button2 Then
|
||||
MsgBox(VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHub_sendToRelayHub_JobOrderRequest.getJSON(ATEZ_RH_EZA))
|
||||
Me.Cursor = Cursors.Default
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' Senden
|
||||
'----------------------------------------------------------------------
|
||||
Dim RESP = VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHub_sendToRelayHub_JobOrderRequest.query_declarations(ATEZ_RH_EZA)
|
||||
|
||||
If RESP.Success Then
|
||||
MsgBox("Erfolgreich an RelayHub / MIC gesendet!" & vbNewLine & "Job Order: " & If(RESP.Data?.jobOrderNo, "") & vbNewLine & "Processing ID: " & If(RESP.Data?.jobOrderProcessingId, ""))
|
||||
Me.Close()
|
||||
Else
|
||||
MsgBox("ERROR" & vbNewLine & RESP.Details, MsgBoxStyle.OkOnly, RESP.Message)
|
||||
End If
|
||||
|
||||
Me.Cursor = Cursors.Default
|
||||
|
||||
Catch ex As Exception
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
||||
Me.Cursor = Cursors.Default
|
||||
End Try
|
||||
End Sub
|
||||
Private Function getTelefon() As String
|
||||
Dim defaultDW = "200"
|
||||
Select Case VERAG_PROG_ALLGEMEIN.cAllgemein.FIRMA
|
||||
Case "ATILLA" : Return "0043 7711 28450"
|
||||
Case "AMBAR" : Return "0049 8651 9962492"
|
||||
Case "UNISPED" : defaultDW = "800"
|
||||
Case "IMEX" : defaultDW = "602"
|
||||
Case "VERAG" : defaultDW = "200"
|
||||
End Select
|
||||
|
||||
Dim dw = VERAG_PROG_ALLGEMEIN.cAllgemein.MITARBEITER.mit_durchwahl
|
||||
Return "0049 8503 7973999 " &
|
||||
If(String.IsNullOrEmpty(dw) OrElse dw.Length >= 5, defaultDW, dw)
|
||||
End Function
|
||||
Private Function getDefaultMail_FIRMA() As String
|
||||
Select Case VERAG_PROG_ALLGEMEIN.cAllgemein.FIRMA
|
||||
Case "VERAG" : Return "quickstop@verag.ag"
|
||||
Case "IMEX" : Return "steuerbescheide@imex-group.at"
|
||||
Case "UNISPED" : Return "office@unisped.at"
|
||||
Case "AMBAR" : Return "office@ambarlog.com"
|
||||
End Select
|
||||
Return "quickstop@verag.ag"
|
||||
End Function
|
||||
'Private Function sendAtezData(atezData As cATEZ_NCTS_DATA, atez As cATEZ_NCTS_IN) As Boolean
|
||||
|
||||
' Dim failreDesc As String
|
||||
|
||||
' Dim authResp = atez.authenticate("NCTS")
|
||||
' If authResp <> "200" Then
|
||||
|
||||
' failreDesc = "Authentifizierung fehlgeschlagen"
|
||||
' lblInfo.Text = failreDesc & " - " & authResp & vbNewLine & "Vorgang abgebrochen" & vbNewLine & " Bitte wiederholen!"
|
||||
' Dim resultAuthentifizierung As MsgBoxResult = MsgBox("Fehler beim Authentifizieren" & vbNewLine & failreDesc & vbNewLine & "Soll NCTS als Entwurf gespeichert werden?", vbYesNoCancel)
|
||||
|
||||
' If resultAuthentifizierung = vbYes Then
|
||||
' atezData.status = "Draft"
|
||||
' atezData.fehlerbeschreibung = failreDesc
|
||||
' Return atezData.SAVE()
|
||||
' Else
|
||||
' atezData.status = "Failure"
|
||||
' atezData.fehlerbeschreibung = failreDesc
|
||||
' Return atezData.SAVE()
|
||||
' End If
|
||||
|
||||
' Return False
|
||||
' End If
|
||||
|
||||
' atezData.sessionId = atez.sessionID
|
||||
|
||||
|
||||
' If Not atez.setJsonNCTS(atezData) Then
|
||||
' MsgBox("Fehler beim Erstellen der Daten" & vbNewLine & "Vorgang abgebrochen!")
|
||||
' atezData.status = "Failure"
|
||||
' atezData.fehlerbeschreibung = "Fehler beim Erstellen der Daten"
|
||||
' Return atezData.SAVE
|
||||
' End If
|
||||
|
||||
' If checkAttachment() Then
|
||||
' If Not atez.setJsonPDF(atezData, dgvAnhaenge) Then
|
||||
' MsgBox("Fehler beim Erstellen der PDF-Daten!" & vbNewLine & "Vorgang abgebrochen!")
|
||||
' atezData.status = "Failure"
|
||||
' atezData.fehlerbeschreibung = "Fehler beim Erstellen der PDF-Daten!"
|
||||
' Return atezData.SAVE
|
||||
' End If
|
||||
' End If
|
||||
|
||||
|
||||
' Dim azetId = atez.SendRequestWithAuthHeader("application/json", failreDesc, "/api/integrations/verag", "POST")
|
||||
|
||||
' If failreDesc <> "" Then
|
||||
' If atezData.status = "Draft" Then
|
||||
' MsgBox("Fehler beim Senden" & vbNewLine & failreDesc)
|
||||
' atezData.fehlerbeschreibung = failreDesc
|
||||
' Return atezData.SAVE()
|
||||
|
||||
' End If
|
||||
' Dim result As MsgBoxResult = MsgBox("Fehler beim Senden" & vbNewLine & failreDesc & vbNewLine & "Soll NCTS als Entwurf gespeichert werden?", vbYesNoCancel)
|
||||
' If result = vbYes Then
|
||||
' atezData.status = "Draft"
|
||||
' atezData.fehlerbeschreibung = failreDesc
|
||||
' Return atezData.SAVE()
|
||||
' Else
|
||||
' atezData.status = "Failure"
|
||||
' atezData.fehlerbeschreibung = failreDesc
|
||||
' Return atezData.SAVE()
|
||||
' End If
|
||||
|
||||
' lblInfo.Text = "Fehler in der API "
|
||||
|
||||
' Else
|
||||
|
||||
' If azetId = "-1" Then
|
||||
' atezData.fehlerbeschreibung = "Request has been sent, but no header received!"
|
||||
' Else
|
||||
' atezData.fehlerbeschreibung = ""
|
||||
' End If
|
||||
' atezData.status = "Sent"
|
||||
' atezData.atezId = IIf(azetId IsNot Nothing, azetId, "")
|
||||
' Return atezData.SAVE()
|
||||
|
||||
' End If
|
||||
|
||||
'End Function
|
||||
|
||||
Function getBezugsnr(ByRef BezugsNr)
|
||||
Dim BezugsNrTmp = ""
|
||||
BezugsNrTmp = SENDUNG.FilialenNr & "/" & SENDUNG.AbfertigungsNr
|
||||
BezugsNr = BezugsNrTmp
|
||||
zusatz = "A"
|
||||
|
||||
If dgv IsNot Nothing AndAlso dgv.Rows.Count > 0 Then
|
||||
BezugsNr = BezugsNrTmp & "/" & zusatz
|
||||
For Each r As DataGridViewRow In dgv.Rows
|
||||
If r.Cells("BezugsNr").Value = BezugsNr Then
|
||||
|
||||
If zusatz.Length = 1 Then
|
||||
zusatz = Chr(Asc(zusatz.ToString) + 1)
|
||||
Else
|
||||
zusatz = zusatz.Substring(0, 1) & Chr(Asc(zusatz.Substring(0, 2).ToString) + 1)
|
||||
End If
|
||||
|
||||
If zusatz = "Z" Then zusatz = "AA"
|
||||
End If
|
||||
BezugsNr = BezugsNrTmp & "/" & zusatz
|
||||
Next
|
||||
|
||||
End If
|
||||
|
||||
While DAKOSY_Worker.cDakosy_Zollanmeldungen.ExistsBezugsNr(BezugsNr) 'IsNot Nothing
|
||||
BezugsNr = BezugsNrTmp & "/" & zusatz
|
||||
|
||||
If zusatz.Length = 1 Then
|
||||
zusatz = Chr(Asc(zusatz.ToString) + 1)
|
||||
Else
|
||||
zusatz = zusatz.Substring(0, 1) & Chr(Asc(zusatz.Substring(0, 2).ToString) + 1)
|
||||
End If
|
||||
|
||||
If zusatz = "Z" Then zusatz = "AA"
|
||||
End While
|
||||
|
||||
lblBezugsnummer.Text = BezugsNr
|
||||
Return BezugsNr
|
||||
End Function
|
||||
|
||||
|
||||
Private Sub frmATEZNCTS_Load(sender As Object, e As EventArgs) Handles MyBase.Load
|
||||
|
||||
'Select Case FIRMA_DY
|
||||
' Case "VERAG" : txtDyMandant.Text = "VERG"
|
||||
' txtDyNiederlassung.Text = VERAG_PROG_ALLGEMEIN.cAllgemein.NIEDERLASSUNG
|
||||
|
||||
' Select Case FilialenNr
|
||||
' Case "5103" : txtDyNiederlassung.Text = "WAI"
|
||||
|
||||
' End Select
|
||||
|
||||
|
||||
' Case "ATILLA" : txtDyMandant.Text = "ATIL" : txtDyNiederlassung.Text = "SUW"
|
||||
' Case "UNISPED" : txtDyMandant.Text = "UNAT" : txtDyNiederlassung.Text = "ATSPED"
|
||||
' Case "IMEX" : txtDyMandant.Text = "IMEX" : txtDyNiederlassung.Text = "IME"
|
||||
' Case "AMBAR" : txtDyMandant.Text = "ATIL" : txtDyNiederlassung.Text = "AMBWO"
|
||||
'End Select
|
||||
FIRMA_DY = cDakosyFunftions.getFirma_DY(FilialenNr.ToString, Me, "EZA")
|
||||
'txtDyMandant.Text = cDakosyFunftions.getIOPartner(FIRMA_DY, "EZA")
|
||||
'txtDyNiederlassung.Text = cDakosyFunftions.getDivision(FIRMA_DY, "EZA")
|
||||
|
||||
'Label4.Text = If(VERAG_PROG_ALLGEMEIN.cAllgemein.MITARBEITER.mit_DAKOSY_SB, "-").ToString
|
||||
|
||||
initSeachboxes()
|
||||
lblAnh.Visible = True
|
||||
|
||||
|
||||
If openExisting Then
|
||||
|
||||
If id > 0 Then
|
||||
' atez_data = New cATEZ_NCTS_DATA(id)
|
||||
initAttachment()
|
||||
If atez_data.atezId <> "" Then
|
||||
lblInfo.Text = "Atez-ID " & atez_data.atezId
|
||||
Else
|
||||
lblInfo.Text = "Status: " & IIf(atez_data.fehlerbeschreibung <> "", atez_data.status & "- " & atez_data.fehlerbeschreibung, atez_data.status)
|
||||
End If
|
||||
|
||||
|
||||
lblBezugsnummer.Text = atez_data.VERAG_LRN
|
||||
|
||||
'cboStammreferenz.fillWithSQL("SELECT [dySr_Stammreferenz],[dySr_Bezeichnung] FROM [tblDakosy_Stammreferenzen] WHERE dySr_Land='DE' AND dySr_Verfahren='EZA' and dySr_dy_Mandant='" & txtDyMandant.Text & "' and dySr_dy_Niederlassung IN ('','" & txtDyNiederlassung.Text & "' " & If(txtDyMandant.Text = "UNAT", ", 'ATSPED' ", "") & ") and dySr_visible=1", False, "FMZOLL", True)
|
||||
'cboStammreferenz.changeItem(atez_data.DAKOSY_TemplateCode)
|
||||
'cboProzedur.changeItem(atez_data.DAKOSY_Procedure)
|
||||
|
||||
txtLKWId.Text = atez_data.LicensePlateContainerNo
|
||||
|
||||
'sbBestimmungsZollstelle.SET_VALUE(atez_data.DestinationCustomsOffice)
|
||||
sbAdressierteZollstelle.SET_VALUE(atez_data.DepartureCustomsOffice)
|
||||
|
||||
|
||||
|
||||
|
||||
If atez_data.status = "Draft" Then
|
||||
btnSend.Text = "An ATEZ senden -->"
|
||||
pnlHead.Enabled = True
|
||||
btnSend.Enabled = True
|
||||
'initAttachment()
|
||||
|
||||
Else
|
||||
btnSend.Text = "JSON"
|
||||
pnlHead.Enabled = False
|
||||
dgvAnhaenge.ReadOnly = True
|
||||
btnSend.Enabled = True
|
||||
|
||||
|
||||
End If
|
||||
|
||||
|
||||
Else
|
||||
btnSend.Enabled = False
|
||||
End If
|
||||
|
||||
Else
|
||||
' atez_data = New cATEZ_NCTS_DATA()
|
||||
initAttachment()
|
||||
'Button1.Text = "An ATEZ senden -->"
|
||||
pnlHead.Enabled = True
|
||||
|
||||
'cboStammreferenz.fillWithSQL("SELECT [dySr_Stammreferenz],[dySr_Bezeichnung] FROM [tblDakosy_Stammreferenzen] WHERE dySr_Land='DE' AND dySr_Verfahren='EZA' and dySr_dy_Mandant='" & txtDyMandant.Text & "' and dySr_dy_Niederlassung IN ('','" & txtDyNiederlassung.Text & "' " & If(txtDyMandant.Text = "UNAT", ", 'ATSPED' ", "") & ") and dySr_visible=1", False, "FMZOLL", True)
|
||||
'cboStammreferenz.changeItem("")
|
||||
|
||||
getBezugsnr(BezugsNr)
|
||||
txtLKWId.Text = AVISO.LKW_Nr
|
||||
|
||||
' sbBestimmungsZollstelle.SET_VALUE(SENDUNG.NCTS_Bestimmungszollstelle)
|
||||
|
||||
If AVISO.Grenzstelle.Replace("???", "") = "" Then
|
||||
sbAdressierteZollstelle.SET_VALUE(AVISO.Zollstelle)
|
||||
Else
|
||||
|
||||
Dim GRZ As New VERAG_PROG_ALLGEMEIN.cGrenzstelle(AVISO.Grenzstelle)
|
||||
If GRZ IsNot Nothing AndAlso GRZ.hasEntry Then
|
||||
If GRZ.grz_ZollamtDST IsNot Nothing Then
|
||||
sbAdressierteZollstelle.SET_VALUE(GRZ.grz_ZollamtDST)
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
|
||||
|
||||
End If
|
||||
'initAttachment()
|
||||
End Sub
|
||||
|
||||
Sub initAttachment()
|
||||
Dim hSQL As String = " SELECT [anh_id],anh_Datum,[anh_Name],[anh_docId],
|
||||
|
||||
case WHEN [anh_size] > 0 Then ROUND([anh_size] / 1000000,2) End as anh_size,
|
||||
[anh_Art],[anh_Typ] FROM [tblAvisoAnhaenge]
|
||||
WHERE [anh_AvisoId]=" & AVISO.AvisoID & "AND (anh_SendungsId is null OR anh_SendungsId <=0 OR anh_SendungsId='" & SENDUNG.tblSnd_SendungID & "') And anh_Typ NOT IN ('MSG', 'SONSTIGES')
|
||||
ORDER BY anh_SendungsId desc,
|
||||
case
|
||||
when [anh_Art] = 'ATR-EUR1' then 0
|
||||
when [anh_Art] = 'Rechnung' then 1
|
||||
when [anh_Art] = 'eFatura' then 1.1
|
||||
when [anh_Art] = 'CMR' then 2
|
||||
when [anh_Art] = 'Ausfuhr' then 3
|
||||
when [anh_Art] = 'Vorpapier' then 4
|
||||
when [anh_Art] = 'Packliste' then 5
|
||||
when [anh_Art] = 'Auftrag' then 6
|
||||
when [anh_Art] = 'Auftrag' then 7
|
||||
when [anh_Art] = 'Dispoliste' then 8
|
||||
when [anh_Art] = 'Vorkasse' then 9
|
||||
when [anh_Art] = 'Überweisungsbeleg' then 10
|
||||
when [anh_Art] = 'Vollmacht' then 11
|
||||
when [anh_Art] = 'ATB' then 12
|
||||
when [anh_Art] = 'ATA' then 13
|
||||
when [anh_Art] = 'Sonstiges' then 99
|
||||
when [anh_Art] ='' then 15
|
||||
|
||||
END, [anh_Reihenfolge],[anh_id]"
|
||||
|
||||
Dim dt = VermerkeDAL.Anzeigen_Vermerke(hSQL)
|
||||
|
||||
Dim col As DataColumn
|
||||
col = dt.Columns.Add("anh_selekt", GetType(Boolean))
|
||||
col.SetOrdinal(0)
|
||||
dgvAnhaenge.Columns.Clear()
|
||||
dgvAnhaenge.DataSource = dt
|
||||
If dgvAnhaenge.RowCount = 0 Then dgvAnhaenge.Columns.Clear() : Exit Sub
|
||||
|
||||
With dgvAnhaenge
|
||||
|
||||
.Enabled = True
|
||||
.ReadOnly = False
|
||||
|
||||
.RowTemplate.MinimumHeight = 30
|
||||
.AutoSizeRowsMode = DataGridViewAutoSizeRowsMode.AllCells
|
||||
.Columns("anh_id").Visible = False 'VermerkID nicht anzeigenconMenuVermerke
|
||||
.Columns("anh_docId").Visible = False 'AvisoID nicht anzeigen
|
||||
' .Columns("anh_Art").Visible = False 'AvisoID nicht anzeigen
|
||||
|
||||
.Columns("anh_selekt").Width = 25
|
||||
.Columns("anh_selekt").HeaderText = ""
|
||||
.Columns("anh_selekt").DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter
|
||||
|
||||
.Columns("anh_Datum").MinimumWidth = 50
|
||||
.Columns("anh_Datum").HeaderText = "Datum"
|
||||
.Columns("anh_Datum").DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter
|
||||
.Columns("anh_Datum").ReadOnly = True
|
||||
|
||||
|
||||
.Columns("anh_Name").MinimumWidth = 150
|
||||
.Columns("anh_Name").HeaderText = "Name"
|
||||
.Columns("anh_Name").AutoSizeMode = DataGridViewAutoSizeColumnMode.Fill
|
||||
.Columns("anh_Name").ReadOnly = True
|
||||
|
||||
.Columns("anh_Art").MinimumWidth = 50
|
||||
.Columns("anh_Art").HeaderText = "Art"
|
||||
.Columns("anh_Art").DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter
|
||||
.Columns("anh_Art").ReadOnly = True
|
||||
|
||||
.Columns("anh_Typ").Width = 50
|
||||
.Columns("anh_Typ").HeaderText = "Typ"
|
||||
.Columns("anh_Typ").DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter
|
||||
.Columns("anh_Typ").ReadOnly = True
|
||||
|
||||
.Columns("anh_size").Width = 50
|
||||
.Columns("anh_size").HeaderText = "Größe in MB"
|
||||
.Columns("anh_size").DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter
|
||||
.Columns("anh_size").ReadOnly = True
|
||||
|
||||
End With
|
||||
|
||||
For Each doc As DataGridViewRow In dgvAnhaenge.Rows
|
||||
|
||||
If Not IsDBNull(doc.Cells("anh_size").Value) AndAlso doc.Cells("anh_size").Value > 0 Then
|
||||
Dim size = (doc.Cells("anh_size").Value)
|
||||
If size < 1 Then
|
||||
doc.DefaultCellStyle.BackColor = Color.LightGreen
|
||||
ElseIf size > 1 AndAlso size < 5 Then
|
||||
doc.DefaultCellStyle.BackColor = Color.LightYellow
|
||||
Else
|
||||
doc.DefaultCellStyle.BackColor = Color.IndianRed
|
||||
End If
|
||||
End If
|
||||
|
||||
Next
|
||||
|
||||
If atez_data IsNot Nothing AndAlso atez_data.selectedDocuments <> "" Then
|
||||
|
||||
For Each doc As DataGridViewRow In dgvAnhaenge.Rows
|
||||
If atez_data.selectedDocuments.Contains(doc.Cells("anh_docId").Value) Then doc.Cells("anh_selekt").Value = True
|
||||
|
||||
Next
|
||||
End If
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
Sub initSeachboxes()
|
||||
|
||||
sbAdressierteZollstelle.initSearchBox(Me.FindForm, "[Code] ,[Code] as Nr,Description as Dienststelle,left(Code,2) as Land,[Description] +' (' +left(Code,2)+')' as display FROM [tbl_DY_ZollDE_C0141_Zollstellen]", {" [Code]", "Description"}, " (StartDate is null OR StartDate< GETDATE()) AND (EndDate is null OR EndDate> GETDATE()) ", " left(Code,2),[Description]", "Code", "display", "FMZOLL", , 400, 200, {"display", "Code"})
|
||||
'sbBestimmungsZollstelle.initSearchBox(Me.FindForm, "[Code] ,[Code] as Nr,Description as Dienststelle,left(Code,2) as Land,[Description] +' (' +left(Code,2)+')' as display FROM [tbl_DY_ZollDE_C0141_Zollstellen]", {" [Code]", "Description"}, " (StartDate is null OR StartDate< GETDATE()) AND (EndDate is null OR EndDate> GETDATE()) ", " left(Code,2),[Description]", "Code", "display", "FMZOLL", , 400, 200, {"display", "Code"})
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
|
||||
Public Function checkAttachment() As Boolean
|
||||
|
||||
Dim selectedDocuments As Boolean = False
|
||||
|
||||
For Each Row In dgvAnhaenge.Rows
|
||||
|
||||
selectedDocuments = IIf(DBNull.Value Is Row.Cells("anh_selekt").Value, False, Row.Cells("anh_selekt").Value)
|
||||
If selectedDocuments Then Exit For
|
||||
Next
|
||||
|
||||
|
||||
'If Not selectedDocuments Then
|
||||
' lblInfo.Text = "kein Anhang selektiert"
|
||||
' Cursor = Cursors.Default
|
||||
' Return selectedDocuments
|
||||
'End If
|
||||
|
||||
Return selectedDocuments
|
||||
|
||||
End Function
|
||||
|
||||
Public Function checkMandatoryField() As Boolean
|
||||
|
||||
|
||||
'TODO
|
||||
Return True
|
||||
|
||||
|
||||
End Function
|
||||
|
||||
|
||||
|
||||
Private Sub dgvAnhaenge_CellDoubleClick(sender As Object, e As DataGridViewCellEventArgs) Handles dgvAnhaenge.CellDoubleClick
|
||||
Try
|
||||
|
||||
If dgvAnhaenge.SelectedRows.Count > 0 Then
|
||||
Dim docPath = VERAG_PROG_ALLGEMEIN.cDATENSERVER.GET_PDFPath_BY_DocID(dgvAnhaenge.SelectedRows(0).Cells("anh_docId").Value)
|
||||
If Not IO.File.Exists(docPath) Then
|
||||
MsgBox("Die Datei existiert nicht!")
|
||||
Else
|
||||
If docPath.ToString.ToLower.EndsWith(".msg") Then ' MSG - Mails --> lokale Kopie, sonst Fehler (bereits von Benutzer soUndSo geöffnet)
|
||||
Dim docPathTMP = VERAG_PROG_ALLGEMEIN.cFormularManager.getTMPPath_MSG()
|
||||
System.IO.File.Copy(docPath, docPathTMP)
|
||||
Process.Start(docPathTMP)
|
||||
Else
|
||||
Process.Start(docPath)
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
|
||||
Catch ex As Exception
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
||||
End Try
|
||||
End Sub
|
||||
|
||||
|
||||
|
||||
Private Sub dgvAnhaenge_CellClick(sender As Object, e As DataGridViewCellEventArgs) Handles dgvAnhaenge.CellClick
|
||||
|
||||
Dim countAnh As Double = 0
|
||||
If dgvAnhaenge.RowCount > 0 Then
|
||||
|
||||
If dgvAnhaenge.Columns(e.ColumnIndex).Name = "anh_selekt" Then
|
||||
|
||||
If Not IsDBNull(dgvAnhaenge.CurrentRow.Cells("anh_selekt").Value) AndAlso dgvAnhaenge.CurrentRow.Cells("anh_selekt").Value = True Then
|
||||
countAnh += IIf(dgvAnhaenge.CurrentRow.Cells("anh_size").Value IsNot DBNull.Value, dgvAnhaenge.CurrentRow.Cells("anh_size").Value, 0)
|
||||
End If
|
||||
|
||||
For Each Row As DataGridViewRow In dgvAnhaenge.Rows
|
||||
If Row.Cells("anh_selekt").Value IsNot DBNull.Value AndAlso Row.Cells("anh_selekt").Value = True AndAlso Row.Cells("anh_size").Value IsNot DBNull.Value Then
|
||||
countAnh += IIf(Row.Cells("anh_size").Value IsNot DBNull.Value, Row.Cells("anh_size").Value, 0)
|
||||
End If
|
||||
Next
|
||||
|
||||
lblAnh.Text = "Anhang in MB: " & countAnh.ToString
|
||||
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub Button3_Click(sender As Object, e As EventArgs) Handles Button3.Click
|
||||
If dgvAnhaenge.RowCount > 0 Then
|
||||
Dim countAnh As Double = 0
|
||||
For Each Row As DataGridViewRow In dgvAnhaenge.Rows
|
||||
If allSelected Then
|
||||
Row.Cells("anh_selekt").Value = True
|
||||
countAnh += IIf(Row.Cells("anh_size").Value IsNot DBNull.Value, Row.Cells("anh_size").Value, 0)
|
||||
Else
|
||||
Row.Cells("anh_selekt").Value = False
|
||||
countAnh = 0
|
||||
End If
|
||||
Next
|
||||
allSelected = Not allSelected
|
||||
lblAnh.Text = "Anhang in MB: " & countAnh.ToString
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub Button1_Click_1(sender As Object, e As EventArgs) Handles Button1.Click
|
||||
cRelayHubToken.DeleteAllStores()
|
||||
End Sub
|
||||
|
||||
Private Sub Button2_Click(sender As Object, e As EventArgs) Handles btnAgg_Tnr.Click, btnAgg_desc.Click, btnAgg_Origin.Click, btnAgg_Unit.Click
|
||||
If sender.Tag = 0 Then
|
||||
sender.Tag = 1
|
||||
sender.BackColor = Color.DeepSkyBlue
|
||||
Else
|
||||
sender.Tag = 0
|
||||
sender.BackColor = SystemColors.Control
|
||||
End If
|
||||
End Sub
|
||||
Private Sub Buttonprio_Click(sender As Object, e As EventArgs) Handles btnPrio_CommInv.Click, btnPrio_ftz.Click, btnPrio_eFatura.Click, btnPrio_Export.Click
|
||||
|
||||
If sender IsNot btnPrio_CommInv Then btnPrio_CommInv.Tag = 0 : btnPrio_CommInv.BackColor = SystemColors.Control
|
||||
If sender IsNot btnPrio_eFatura Then btnPrio_eFatura.Tag = 0 : btnPrio_eFatura.BackColor = SystemColors.Control
|
||||
If sender IsNot btnPrio_Export Then btnPrio_Export.Tag = 0 : btnPrio_Export.BackColor = SystemColors.Control
|
||||
If sender IsNot btnPrio_ftz Then btnPrio_ftz.Tag = 0 : btnPrio_ftz.BackColor = SystemColors.Control
|
||||
|
||||
|
||||
If sender.Tag = 0 Then
|
||||
sender.Tag = 1
|
||||
sender.BackColor = Color.DeepSkyBlue
|
||||
Else
|
||||
sender.Tag = 0
|
||||
sender.BackColor = SystemColors.Control
|
||||
End If
|
||||
End Sub
|
||||
End Class
|
||||
487
Aviso/ATEZ/frmATEZ_TELOTEC.Designer.vb
generated
Normal file
487
Aviso/ATEZ/frmATEZ_TELOTEC.Designer.vb
generated
Normal file
@@ -0,0 +1,487 @@
|
||||
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()>
|
||||
Partial Class frmATEZ_TELOTEC
|
||||
Inherits System.Windows.Forms.Form
|
||||
|
||||
'Das Formular überschreibt den Löschvorgang, um die Komponentenliste zu bereinigen.
|
||||
<System.Diagnostics.DebuggerNonUserCode()>
|
||||
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
|
||||
Try
|
||||
If disposing AndAlso components IsNot Nothing Then
|
||||
components.Dispose()
|
||||
End If
|
||||
Finally
|
||||
MyBase.Dispose(disposing)
|
||||
End Try
|
||||
End Sub
|
||||
|
||||
'Wird vom Windows Form-Designer benötigt.
|
||||
Private components As System.ComponentModel.IContainer
|
||||
|
||||
'Hinweis: Die folgende Prozedur ist für den Windows Form-Designer erforderlich.
|
||||
'Das Bearbeiten ist mit dem Windows Form-Designer möglich.
|
||||
'Das Bearbeiten mit dem Code-Editor ist nicht möglich.
|
||||
<System.Diagnostics.DebuggerStepThrough()>
|
||||
Private Sub InitializeComponent()
|
||||
Me.components = New System.ComponentModel.Container()
|
||||
Dim resources As System.ComponentModel.ComponentResourceManager = New System.ComponentModel.ComponentResourceManager(GetType(frmATEZ_TELOTEC))
|
||||
Me.btnSend = New System.Windows.Forms.Button()
|
||||
Me.pnlHead = New System.Windows.Forms.Panel()
|
||||
Me.PictureBox1 = New System.Windows.Forms.PictureBox()
|
||||
Me.Button1 = New System.Windows.Forms.Button()
|
||||
Me.Button2 = New System.Windows.Forms.Button()
|
||||
Me.Label1 = New System.Windows.Forms.Label()
|
||||
Me.lblInfo = New System.Windows.Forms.Label()
|
||||
Me.Label8 = New System.Windows.Forms.Label()
|
||||
Me.cboStammreferenz = New VERAG_PROG_ALLGEMEIN.MyComboBox()
|
||||
Me.txtLKWId = New VERAG_PROG_ALLGEMEIN.MyTextBox()
|
||||
Me.Label3 = New System.Windows.Forms.Label()
|
||||
Me.Label9 = New System.Windows.Forms.Label()
|
||||
Me.sbAdressierteZollstelle = New VERAG_PROG_ALLGEMEIN.MySearchBox()
|
||||
Me.lblBezugsnummer = New System.Windows.Forms.Label()
|
||||
Me.Button3 = New System.Windows.Forms.Button()
|
||||
Me.Label6 = New System.Windows.Forms.Label()
|
||||
Me.lblAnh = New System.Windows.Forms.Label()
|
||||
Me.btnAgg_Tnr = New System.Windows.Forms.Button()
|
||||
Me.Label2 = New System.Windows.Forms.Label()
|
||||
Me.btnAgg_Origin = New System.Windows.Forms.Button()
|
||||
Me.btnAgg_Unit = New System.Windows.Forms.Button()
|
||||
Me.btnAgg_desc = New System.Windows.Forms.Button()
|
||||
Me.dgvAnhaenge = New VERAG_PROG_ALLGEMEIN.MyDatagridview(Me.components)
|
||||
Me.columnName = New System.Windows.Forms.DataGridViewTextBoxColumn()
|
||||
Me.btnPrio_CommInv = New System.Windows.Forms.Button()
|
||||
Me.Label5 = New System.Windows.Forms.Label()
|
||||
Me.btnPrio_eFatura = New System.Windows.Forms.Button()
|
||||
Me.btnPrio_Export = New System.Windows.Forms.Button()
|
||||
Me.btnPrio_ftz = New System.Windows.Forms.Button()
|
||||
Me.Panel1 = New System.Windows.Forms.Panel()
|
||||
Me.pnlHead.SuspendLayout()
|
||||
CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.dgvAnhaenge, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
Me.Panel1.SuspendLayout()
|
||||
Me.SuspendLayout()
|
||||
'
|
||||
'btnSend
|
||||
'
|
||||
Me.btnSend.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.btnSend.BackColor = System.Drawing.Color.White
|
||||
Me.btnSend.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Center
|
||||
Me.btnSend.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!)
|
||||
Me.btnSend.Image = Global.AVISO.My.Resources.Resources.ico_atez_declarantAI
|
||||
Me.btnSend.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
|
||||
Me.btnSend.Location = New System.Drawing.Point(473, 343)
|
||||
Me.btnSend.Margin = New System.Windows.Forms.Padding(2)
|
||||
Me.btnSend.Name = "btnSend"
|
||||
Me.btnSend.Padding = New System.Windows.Forms.Padding(5, 0, 5, 0)
|
||||
Me.btnSend.Size = New System.Drawing.Size(205, 58)
|
||||
Me.btnSend.TabIndex = 26
|
||||
Me.btnSend.Text = "An ATEZ senden >>"
|
||||
Me.btnSend.TextAlign = System.Drawing.ContentAlignment.MiddleRight
|
||||
Me.btnSend.UseVisualStyleBackColor = False
|
||||
'
|
||||
'pnlHead
|
||||
'
|
||||
Me.pnlHead.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink
|
||||
Me.pnlHead.BackColor = System.Drawing.Color.White
|
||||
Me.pnlHead.Controls.Add(Me.PictureBox1)
|
||||
Me.pnlHead.Controls.Add(Me.Button1)
|
||||
Me.pnlHead.Controls.Add(Me.Button2)
|
||||
Me.pnlHead.Controls.Add(Me.Label1)
|
||||
Me.pnlHead.Controls.Add(Me.lblInfo)
|
||||
Me.pnlHead.Controls.Add(Me.Label8)
|
||||
Me.pnlHead.Controls.Add(Me.cboStammreferenz)
|
||||
Me.pnlHead.Controls.Add(Me.txtLKWId)
|
||||
Me.pnlHead.Controls.Add(Me.Label3)
|
||||
Me.pnlHead.Controls.Add(Me.Label9)
|
||||
Me.pnlHead.Controls.Add(Me.sbAdressierteZollstelle)
|
||||
Me.pnlHead.Controls.Add(Me.lblBezugsnummer)
|
||||
Me.pnlHead.Location = New System.Drawing.Point(3, 2)
|
||||
Me.pnlHead.Name = "pnlHead"
|
||||
Me.pnlHead.Size = New System.Drawing.Size(675, 151)
|
||||
Me.pnlHead.TabIndex = 112
|
||||
'
|
||||
'PictureBox1
|
||||
'
|
||||
Me.PictureBox1.BackgroundImage = Global.AVISO.My.Resources.Resources.modaltrans_uk
|
||||
Me.PictureBox1.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom
|
||||
Me.PictureBox1.Location = New System.Drawing.Point(572, 34)
|
||||
Me.PictureBox1.Name = "PictureBox1"
|
||||
Me.PictureBox1.Size = New System.Drawing.Size(100, 50)
|
||||
Me.PictureBox1.TabIndex = 159
|
||||
Me.PictureBox1.TabStop = False
|
||||
'
|
||||
'Button1
|
||||
'
|
||||
Me.Button1.Location = New System.Drawing.Point(553, 117)
|
||||
Me.Button1.Name = "Button1"
|
||||
Me.Button1.Size = New System.Drawing.Size(122, 23)
|
||||
Me.Button1.TabIndex = 153
|
||||
Me.Button1.Text = "Clear Token Cache"
|
||||
Me.Button1.UseVisualStyleBackColor = True
|
||||
'
|
||||
'Button2
|
||||
'
|
||||
Me.Button2.Location = New System.Drawing.Point(610, 96)
|
||||
Me.Button2.Name = "Button2"
|
||||
Me.Button2.Size = New System.Drawing.Size(65, 23)
|
||||
Me.Button2.TabIndex = 158
|
||||
Me.Button2.Text = "json"
|
||||
Me.Button2.UseVisualStyleBackColor = True
|
||||
'
|
||||
'Label1
|
||||
'
|
||||
Me.Label1.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.Label1.AutoSize = True
|
||||
Me.Label1.BackColor = System.Drawing.Color.White
|
||||
Me.Label1.Location = New System.Drawing.Point(387, 13)
|
||||
Me.Label1.Name = "Label1"
|
||||
Me.Label1.Size = New System.Drawing.Size(89, 13)
|
||||
Me.Label1.TabIndex = 106
|
||||
Me.Label1.Text = "Bezugsnummer:"
|
||||
'
|
||||
'lblInfo
|
||||
'
|
||||
Me.lblInfo.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
|
||||
Me.lblInfo.ForeColor = System.Drawing.Color.Red
|
||||
Me.lblInfo.Location = New System.Drawing.Point(3, 32)
|
||||
Me.lblInfo.Name = "lblInfo"
|
||||
Me.lblInfo.Size = New System.Drawing.Size(460, 21)
|
||||
Me.lblInfo.TabIndex = 148
|
||||
'
|
||||
'Label8
|
||||
'
|
||||
Me.Label8.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.Label8.AutoSize = True
|
||||
Me.Label8.Location = New System.Drawing.Point(6, 61)
|
||||
Me.Label8.Name = "Label8"
|
||||
Me.Label8.Size = New System.Drawing.Size(86, 13)
|
||||
Me.Label8.TabIndex = 146
|
||||
Me.Label8.Text = "Stammreferenz:"
|
||||
Me.Label8.TextAlign = System.Drawing.ContentAlignment.TopRight
|
||||
Me.Label8.Visible = False
|
||||
'
|
||||
'cboStammreferenz
|
||||
'
|
||||
Me.cboStammreferenz._allowedValuesFreiText = Nothing
|
||||
Me.cboStammreferenz._allowFreiText = False
|
||||
Me.cboStammreferenz._value = ""
|
||||
Me.cboStammreferenz.BackColor = System.Drawing.Color.FromArgb(CType(CType(224, Byte), Integer), CType(CType(224, Byte), Integer), CType(CType(224, Byte), Integer))
|
||||
Me.cboStammreferenz.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList
|
||||
Me.cboStammreferenz.FlatStyle = System.Windows.Forms.FlatStyle.Flat
|
||||
Me.cboStammreferenz.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!)
|
||||
Me.cboStammreferenz.FormattingEnabled = True
|
||||
Me.cboStammreferenz.Location = New System.Drawing.Point(151, 56)
|
||||
Me.cboStammreferenz.Name = "cboStammreferenz"
|
||||
Me.cboStammreferenz.Size = New System.Drawing.Size(255, 24)
|
||||
Me.cboStammreferenz.TabIndex = 145
|
||||
Me.cboStammreferenz.Visible = False
|
||||
'
|
||||
'txtLKWId
|
||||
'
|
||||
Me.txtLKWId._DateTimeOnly = False
|
||||
Me.txtLKWId._numbersOnly = False
|
||||
Me.txtLKWId._numbersOnlyKommastellen = ""
|
||||
Me.txtLKWId._numbersOnlyTrennzeichen = True
|
||||
Me.txtLKWId._Prozent = False
|
||||
Me.txtLKWId._ShortDateNew = False
|
||||
Me.txtLKWId._ShortDateOnly = False
|
||||
Me.txtLKWId._TimeOnly = False
|
||||
Me.txtLKWId._TimeOnly_Seconds = False
|
||||
Me.txtLKWId._value = ""
|
||||
Me.txtLKWId._Waehrung = False
|
||||
Me.txtLKWId._WaehrungZeichen = True
|
||||
Me.txtLKWId.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!)
|
||||
Me.txtLKWId.ForeColor = System.Drawing.Color.Black
|
||||
Me.txtLKWId.Location = New System.Drawing.Point(151, 86)
|
||||
Me.txtLKWId.MaxLineLength = -1
|
||||
Me.txtLKWId.MaxLines_Warning = ""
|
||||
Me.txtLKWId.MaxLines_Warning_Label = Nothing
|
||||
Me.txtLKWId.Name = "txtLKWId"
|
||||
Me.txtLKWId.Size = New System.Drawing.Size(255, 23)
|
||||
Me.txtLKWId.TabIndex = 144
|
||||
'
|
||||
'Label3
|
||||
'
|
||||
Me.Label3.AutoSize = True
|
||||
Me.Label3.Location = New System.Drawing.Point(6, 91)
|
||||
Me.Label3.Name = "Label3"
|
||||
Me.Label3.Size = New System.Drawing.Size(48, 13)
|
||||
Me.Label3.TabIndex = 113
|
||||
Me.Label3.Text = "LKW-KZ:"
|
||||
'
|
||||
'Label9
|
||||
'
|
||||
Me.Label9.AutoSize = True
|
||||
Me.Label9.Location = New System.Drawing.Point(6, 117)
|
||||
Me.Label9.Name = "Label9"
|
||||
Me.Label9.Size = New System.Drawing.Size(117, 13)
|
||||
Me.Label9.TabIndex = 110
|
||||
Me.Label9.Text = "Adressierte-Zollstelle:"
|
||||
'
|
||||
'sbAdressierteZollstelle
|
||||
'
|
||||
Me.sbAdressierteZollstelle._allowFreitext = False
|
||||
Me.sbAdressierteZollstelle._AllowSetValue = False
|
||||
Me.sbAdressierteZollstelle._allowSpaceAsSplitter = False
|
||||
Me.sbAdressierteZollstelle._autoSizeGross = False
|
||||
Me.sbAdressierteZollstelle._hideIfListEmpty = True
|
||||
Me.sbAdressierteZollstelle._value = ""
|
||||
Me.sbAdressierteZollstelle.conn_art = "FMZOLL"
|
||||
Me.sbAdressierteZollstelle.dgvpos = "LEFT"
|
||||
Me.sbAdressierteZollstelle.DISPLAY_PARAM = Nothing
|
||||
Me.sbAdressierteZollstelle.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!)
|
||||
Me.sbAdressierteZollstelle.INVISIBLE_COLUMNS = Nothing
|
||||
Me.sbAdressierteZollstelle.key_visible = False
|
||||
Me.sbAdressierteZollstelle.KEYPARAM = Nothing
|
||||
Me.sbAdressierteZollstelle.Location = New System.Drawing.Point(151, 112)
|
||||
Me.sbAdressierteZollstelle.Name = "sbAdressierteZollstelle"
|
||||
Me.sbAdressierteZollstelle.searchActive = True
|
||||
Me.sbAdressierteZollstelle.Size = New System.Drawing.Size(255, 23)
|
||||
Me.sbAdressierteZollstelle.SQL_ORDER_BY = Nothing
|
||||
Me.sbAdressierteZollstelle.SQL_SELECT = Nothing
|
||||
Me.sbAdressierteZollstelle.SQL_WHERE = Nothing
|
||||
Me.sbAdressierteZollstelle.SQL_WhereParamList = Nothing
|
||||
Me.sbAdressierteZollstelle.TabIndex = 111
|
||||
Me.sbAdressierteZollstelle.usrcntl = Nothing
|
||||
'
|
||||
'lblBezugsnummer
|
||||
'
|
||||
Me.lblBezugsnummer.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.lblBezugsnummer.BackColor = System.Drawing.Color.White
|
||||
Me.lblBezugsnummer.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
|
||||
Me.lblBezugsnummer.Location = New System.Drawing.Point(475, 8)
|
||||
Me.lblBezugsnummer.Name = "lblBezugsnummer"
|
||||
Me.lblBezugsnummer.Size = New System.Drawing.Size(193, 23)
|
||||
Me.lblBezugsnummer.TabIndex = 107
|
||||
Me.lblBezugsnummer.Text = "4800/000000/17 AAA"
|
||||
Me.lblBezugsnummer.TextAlign = System.Drawing.ContentAlignment.MiddleRight
|
||||
'
|
||||
'Button3
|
||||
'
|
||||
Me.Button3.Location = New System.Drawing.Point(473, 157)
|
||||
Me.Button3.Name = "Button3"
|
||||
Me.Button3.Size = New System.Drawing.Size(205, 25)
|
||||
Me.Button3.TabIndex = 152
|
||||
Me.Button3.Text = "alle Anhänge auswählen"
|
||||
Me.Button3.UseVisualStyleBackColor = True
|
||||
'
|
||||
'Label6
|
||||
'
|
||||
Me.Label6.Location = New System.Drawing.Point(9, 168)
|
||||
Me.Label6.Name = "Label6"
|
||||
Me.Label6.Size = New System.Drawing.Size(135, 13)
|
||||
Me.Label6.TabIndex = 147
|
||||
Me.Label6.Text = "Dokumente:"
|
||||
'
|
||||
'lblAnh
|
||||
'
|
||||
Me.lblAnh.Location = New System.Drawing.Point(332, 168)
|
||||
Me.lblAnh.Name = "lblAnh"
|
||||
Me.lblAnh.Size = New System.Drawing.Size(135, 13)
|
||||
Me.lblAnh.TabIndex = 151
|
||||
Me.lblAnh.Visible = False
|
||||
'
|
||||
'btnAgg_Tnr
|
||||
'
|
||||
Me.btnAgg_Tnr.BackColor = System.Drawing.Color.DeepSkyBlue
|
||||
Me.btnAgg_Tnr.Location = New System.Drawing.Point(76, 3)
|
||||
Me.btnAgg_Tnr.Name = "btnAgg_Tnr"
|
||||
Me.btnAgg_Tnr.Size = New System.Drawing.Size(83, 23)
|
||||
Me.btnAgg_Tnr.TabIndex = 154
|
||||
Me.btnAgg_Tnr.Tag = "1"
|
||||
Me.btnAgg_Tnr.Text = "Tarifnummer"
|
||||
Me.btnAgg_Tnr.UseVisualStyleBackColor = False
|
||||
'
|
||||
'Label2
|
||||
'
|
||||
Me.Label2.Font = New System.Drawing.Font("Segoe UI", 8.0!)
|
||||
Me.Label2.Location = New System.Drawing.Point(3, 8)
|
||||
Me.Label2.Name = "Label2"
|
||||
Me.Label2.Size = New System.Drawing.Size(103, 17)
|
||||
Me.Label2.TabIndex = 149
|
||||
Me.Label2.Text = "Aggregieren:"
|
||||
'
|
||||
'btnAgg_Origin
|
||||
'
|
||||
Me.btnAgg_Origin.BackColor = System.Drawing.Color.DeepSkyBlue
|
||||
Me.btnAgg_Origin.Location = New System.Drawing.Point(162, 3)
|
||||
Me.btnAgg_Origin.Name = "btnAgg_Origin"
|
||||
Me.btnAgg_Origin.Size = New System.Drawing.Size(92, 23)
|
||||
Me.btnAgg_Origin.TabIndex = 155
|
||||
Me.btnAgg_Origin.Tag = "1"
|
||||
Me.btnAgg_Origin.Text = "Ursprungsland"
|
||||
Me.btnAgg_Origin.UseVisualStyleBackColor = False
|
||||
'
|
||||
'btnAgg_Unit
|
||||
'
|
||||
Me.btnAgg_Unit.Location = New System.Drawing.Point(257, 3)
|
||||
Me.btnAgg_Unit.Name = "btnAgg_Unit"
|
||||
Me.btnAgg_Unit.Size = New System.Drawing.Size(79, 23)
|
||||
Me.btnAgg_Unit.TabIndex = 156
|
||||
Me.btnAgg_Unit.Tag = "0"
|
||||
Me.btnAgg_Unit.Text = "Maßeinheit"
|
||||
Me.btnAgg_Unit.UseVisualStyleBackColor = True
|
||||
'
|
||||
'btnAgg_desc
|
||||
'
|
||||
Me.btnAgg_desc.Location = New System.Drawing.Point(339, 3)
|
||||
Me.btnAgg_desc.Name = "btnAgg_desc"
|
||||
Me.btnAgg_desc.Size = New System.Drawing.Size(126, 23)
|
||||
Me.btnAgg_desc.TabIndex = 157
|
||||
Me.btnAgg_desc.Tag = "0"
|
||||
Me.btnAgg_desc.Text = "Warenbeschreibung"
|
||||
Me.btnAgg_desc.UseVisualStyleBackColor = True
|
||||
'
|
||||
'dgvAnhaenge
|
||||
'
|
||||
Me.dgvAnhaenge.AKTUALISIERUNGS_INTERVALL = -1
|
||||
Me.dgvAnhaenge.AllowUserToAddRows = False
|
||||
Me.dgvAnhaenge.AllowUserToDeleteRows = False
|
||||
Me.dgvAnhaenge.AllowUserToResizeColumns = False
|
||||
Me.dgvAnhaenge.AllowUserToResizeRows = False
|
||||
Me.dgvAnhaenge.BackgroundColor = System.Drawing.Color.White
|
||||
Me.dgvAnhaenge.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize
|
||||
Me.dgvAnhaenge.Columns.AddRange(New System.Windows.Forms.DataGridViewColumn() {Me.columnName})
|
||||
Me.dgvAnhaenge.Location = New System.Drawing.Point(3, 184)
|
||||
Me.dgvAnhaenge.Name = "dgvAnhaenge"
|
||||
Me.dgvAnhaenge.ReadOnly = True
|
||||
Me.dgvAnhaenge.RowHeadersVisible = False
|
||||
Me.dgvAnhaenge.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect
|
||||
Me.dgvAnhaenge.Size = New System.Drawing.Size(675, 158)
|
||||
Me.dgvAnhaenge.TabIndex = 112
|
||||
'
|
||||
'columnName
|
||||
'
|
||||
Me.columnName.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill
|
||||
Me.columnName.HeaderText = "Name"
|
||||
Me.columnName.Name = "columnName"
|
||||
Me.columnName.ReadOnly = True
|
||||
'
|
||||
'btnPrio_CommInv
|
||||
'
|
||||
Me.btnPrio_CommInv.BackColor = System.Drawing.Color.White
|
||||
Me.btnPrio_CommInv.Location = New System.Drawing.Point(76, 28)
|
||||
Me.btnPrio_CommInv.Name = "btnPrio_CommInv"
|
||||
Me.btnPrio_CommInv.Size = New System.Drawing.Size(116, 23)
|
||||
Me.btnPrio_CommInv.TabIndex = 159
|
||||
Me.btnPrio_CommInv.Tag = "0"
|
||||
Me.btnPrio_CommInv.Text = "Handelsrechnung"
|
||||
Me.btnPrio_CommInv.UseVisualStyleBackColor = False
|
||||
'
|
||||
'Label5
|
||||
'
|
||||
Me.Label5.Font = New System.Drawing.Font("Segoe UI", 8.0!)
|
||||
Me.Label5.Location = New System.Drawing.Point(3, 33)
|
||||
Me.Label5.Name = "Label5"
|
||||
Me.Label5.Size = New System.Drawing.Size(103, 17)
|
||||
Me.Label5.TabIndex = 160
|
||||
Me.Label5.Text = "Priorität:"
|
||||
'
|
||||
'btnPrio_eFatura
|
||||
'
|
||||
Me.btnPrio_eFatura.BackColor = System.Drawing.Color.White
|
||||
Me.btnPrio_eFatura.Location = New System.Drawing.Point(195, 28)
|
||||
Me.btnPrio_eFatura.Name = "btnPrio_eFatura"
|
||||
Me.btnPrio_eFatura.Size = New System.Drawing.Size(69, 23)
|
||||
Me.btnPrio_eFatura.TabIndex = 161
|
||||
Me.btnPrio_eFatura.Tag = "0"
|
||||
Me.btnPrio_eFatura.Text = "eFatura"
|
||||
Me.btnPrio_eFatura.UseVisualStyleBackColor = False
|
||||
'
|
||||
'btnPrio_Export
|
||||
'
|
||||
Me.btnPrio_Export.BackColor = System.Drawing.Color.White
|
||||
Me.btnPrio_Export.Location = New System.Drawing.Point(267, 28)
|
||||
Me.btnPrio_Export.Name = "btnPrio_Export"
|
||||
Me.btnPrio_Export.Size = New System.Drawing.Size(69, 23)
|
||||
Me.btnPrio_Export.TabIndex = 162
|
||||
Me.btnPrio_Export.Tag = "0"
|
||||
Me.btnPrio_Export.Text = "Ausfuhr"
|
||||
Me.btnPrio_Export.UseVisualStyleBackColor = False
|
||||
'
|
||||
'btnPrio_ftz
|
||||
'
|
||||
Me.btnPrio_ftz.BackColor = System.Drawing.Color.White
|
||||
Me.btnPrio_ftz.Location = New System.Drawing.Point(339, 28)
|
||||
Me.btnPrio_ftz.Name = "btnPrio_ftz"
|
||||
Me.btnPrio_ftz.Size = New System.Drawing.Size(69, 23)
|
||||
Me.btnPrio_ftz.TabIndex = 163
|
||||
Me.btnPrio_ftz.Tag = "0"
|
||||
Me.btnPrio_ftz.Text = "FTZ"
|
||||
Me.btnPrio_ftz.UseVisualStyleBackColor = False
|
||||
'
|
||||
'Panel1
|
||||
'
|
||||
Me.Panel1.BackColor = System.Drawing.SystemColors.InactiveBorder
|
||||
Me.Panel1.Controls.Add(Me.btnPrio_CommInv)
|
||||
Me.Panel1.Controls.Add(Me.btnAgg_Tnr)
|
||||
Me.Panel1.Controls.Add(Me.btnPrio_ftz)
|
||||
Me.Panel1.Controls.Add(Me.Label2)
|
||||
Me.Panel1.Controls.Add(Me.btnPrio_Export)
|
||||
Me.Panel1.Controls.Add(Me.btnAgg_Origin)
|
||||
Me.Panel1.Controls.Add(Me.btnPrio_eFatura)
|
||||
Me.Panel1.Controls.Add(Me.btnAgg_Unit)
|
||||
Me.Panel1.Controls.Add(Me.Label5)
|
||||
Me.Panel1.Controls.Add(Me.btnAgg_desc)
|
||||
Me.Panel1.Location = New System.Drawing.Point(0, 343)
|
||||
Me.Panel1.Name = "Panel1"
|
||||
Me.Panel1.Size = New System.Drawing.Size(470, 54)
|
||||
Me.Panel1.TabIndex = 164
|
||||
'
|
||||
'frmATEZ_UK_MODAL
|
||||
'
|
||||
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
|
||||
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
|
||||
Me.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink
|
||||
Me.BackColor = System.Drawing.SystemColors.InactiveBorder
|
||||
Me.ClientSize = New System.Drawing.Size(680, 409)
|
||||
Me.Controls.Add(Me.Button3)
|
||||
Me.Controls.Add(Me.lblAnh)
|
||||
Me.Controls.Add(Me.pnlHead)
|
||||
Me.Controls.Add(Me.Label6)
|
||||
Me.Controls.Add(Me.btnSend)
|
||||
Me.Controls.Add(Me.dgvAnhaenge)
|
||||
Me.Controls.Add(Me.Panel1)
|
||||
Me.Font = New System.Drawing.Font("Segoe UI", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
|
||||
Me.Icon = CType(resources.GetObject("$this.Icon"), System.Drawing.Icon)
|
||||
Me.Name = "frmATEZ_UK_MODAL"
|
||||
Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
|
||||
Me.Text = "ATEZ UK"
|
||||
Me.pnlHead.ResumeLayout(False)
|
||||
Me.pnlHead.PerformLayout()
|
||||
CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.dgvAnhaenge, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
Me.Panel1.ResumeLayout(False)
|
||||
Me.ResumeLayout(False)
|
||||
|
||||
End Sub
|
||||
Friend WithEvents btnSend As Button
|
||||
Friend WithEvents pnlHead As Panel
|
||||
Friend WithEvents lblInfo As Label
|
||||
Friend WithEvents Label6 As Label
|
||||
Friend WithEvents Label8 As Label
|
||||
Friend WithEvents cboStammreferenz As VERAG_PROG_ALLGEMEIN.MyComboBox
|
||||
Friend WithEvents txtLKWId As VERAG_PROG_ALLGEMEIN.MyTextBox
|
||||
Friend WithEvents Label3 As Label
|
||||
Friend WithEvents dgvAnhaenge As VERAG_PROG_ALLGEMEIN.MyDatagridview
|
||||
Friend WithEvents columnName As DataGridViewTextBoxColumn
|
||||
Friend WithEvents Label9 As Label
|
||||
Friend WithEvents sbAdressierteZollstelle As VERAG_PROG_ALLGEMEIN.MySearchBox
|
||||
Friend WithEvents Label1 As Label
|
||||
Friend WithEvents lblBezugsnummer As Label
|
||||
Friend WithEvents lblAnh As Label
|
||||
Friend WithEvents Button3 As Button
|
||||
Friend WithEvents Button1 As Button
|
||||
Friend WithEvents btnAgg_Tnr As Button
|
||||
Friend WithEvents Label2 As Label
|
||||
Friend WithEvents btnAgg_Origin As Button
|
||||
Friend WithEvents btnAgg_Unit As Button
|
||||
Friend WithEvents btnAgg_desc As Button
|
||||
Friend WithEvents Button2 As Button
|
||||
Friend WithEvents btnPrio_CommInv As Button
|
||||
Friend WithEvents Label5 As Label
|
||||
Friend WithEvents btnPrio_eFatura As Button
|
||||
Friend WithEvents btnPrio_Export As Button
|
||||
Friend WithEvents btnPrio_ftz As Button
|
||||
Friend WithEvents Panel1 As Panel
|
||||
Friend WithEvents PictureBox1 As PictureBox
|
||||
End Class
|
||||
1256
Aviso/ATEZ/frmATEZ_TELOTEC.resx
Normal file
1256
Aviso/ATEZ/frmATEZ_TELOTEC.resx
Normal file
File diff suppressed because it is too large
Load Diff
756
Aviso/ATEZ/frmATEZ_TELOTEC.vb
Normal file
756
Aviso/ATEZ/frmATEZ_TELOTEC.vb
Normal file
@@ -0,0 +1,756 @@
|
||||
|
||||
Imports com.esendex.sdk.optouts.models
|
||||
Imports DAKOSY_Worker
|
||||
Imports DAKOSY_Worker.eZollTypes
|
||||
Imports SDL
|
||||
Imports VERAG_PROG_ALLGEMEIN
|
||||
Imports VERAG_PROG_ALLGEMEIN.cRelayHub
|
||||
|
||||
|
||||
Public Class frmATEZ_TELOTEC
|
||||
|
||||
Dim ART As String = ""
|
||||
Dim FilialenNr As Integer
|
||||
Dim AbfertigungsNr As Integer
|
||||
Dim JAHR As Integer = Now.ToString("yy")
|
||||
Public isSTAMMREF As Boolean = False
|
||||
Public STAMMREF As String = ""
|
||||
Public CopyFromZA_Id As Integer = -1
|
||||
Dim FIRMA_DY = VERAG_PROG_ALLGEMEIN.cAllgemein.FIRMA
|
||||
Dim ZOLL_SYSTEM = "MODALTRANS"
|
||||
Dim DY As DAKOSY_Worker.cDakosy_Zollanmeldungen = Nothing
|
||||
Public ATT As List(Of String)
|
||||
Dim AVISO As New cAviso
|
||||
Dim zusatz As String
|
||||
Dim cDy_ART As String = If(FIRMA_DY = "ATILLA", "T2", "T1")
|
||||
Dim VermerkeDAL As New cVermerkeDAL
|
||||
Dim NCTS As DAKOSY_Worker.cDakosyNCTSOut = Nothing
|
||||
Dim openExisting As Boolean = False
|
||||
Dim id As Integer = -1
|
||||
Dim dgv As DataGridView = Nothing
|
||||
Dim atez_data As cATEZ_NCTS_DATA
|
||||
' Dim atez = New cATEZ_NCTS_IN("ATEZ")
|
||||
Dim allSelected As Boolean = False
|
||||
|
||||
Property BezugsNr As String = ""
|
||||
Property SENDUNG As VERAG_PROG_ALLGEMEIN.cSendungen
|
||||
|
||||
Sub New(AVISO As VERAG_PROG_ALLGEMEIN.cAviso, SENDUNG As VERAG_PROG_ALLGEMEIN.cSendungen, JAHR As Integer
|
||||
)
|
||||
|
||||
' Dieser Aufruf ist für den Designer erforderlich.
|
||||
InitializeComponent()
|
||||
Me.AVISO = AVISO
|
||||
Me.SENDUNG = SENDUNG
|
||||
Me.JAHR = JAHR
|
||||
|
||||
If SENDUNG IsNot Nothing Then
|
||||
Me.FilialenNr = SENDUNG.FilialenNr
|
||||
Me.AbfertigungsNr = SENDUNG.AbfertigungsNr
|
||||
End If
|
||||
|
||||
' Fügen Sie Initialisierungen nach dem InitializeComponent()-Aufruf hinzu.
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
Sub New(_id As Integer, AVISO As VERAG_PROG_ALLGEMEIN.cAviso, SENDUNG As VERAG_PROG_ALLGEMEIN.cSendungen, JAHR As Integer)
|
||||
|
||||
' Dieser Aufruf ist für den Designer erforderlich.
|
||||
InitializeComponent()
|
||||
openExisting = True
|
||||
id = _id
|
||||
|
||||
Me.AVISO = AVISO
|
||||
Me.SENDUNG = SENDUNG
|
||||
Me.JAHR = JAHR
|
||||
|
||||
If SENDUNG IsNot Nothing Then
|
||||
Me.FilialenNr = SENDUNG.FilialenNr
|
||||
Me.AbfertigungsNr = SENDUNG.AbfertigungsNr
|
||||
End If
|
||||
|
||||
|
||||
' Fügen Sie Initialisierungen nach dem InitializeComponent()-Aufruf hinzu.
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles btnSend.Click, Button2.Click
|
||||
Try
|
||||
If Not checkMandatoryField() Then Exit Sub
|
||||
|
||||
Me.Cursor = Cursors.WaitCursor
|
||||
lblInfo.Text = ""
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' Referenz
|
||||
'----------------------------------------------------------------------
|
||||
Dim ioReference As String = lblBezugsnummer.Text & Now.ToString("ddMMyyyy_HHmmss")
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' Aggregierung
|
||||
'----------------------------------------------------------------------
|
||||
Dim AdditionalSettings As New List(Of String)
|
||||
If btnAgg_desc.Tag = 1 Then AdditionalSettings.Add("description")
|
||||
If btnAgg_Tnr.Tag = 1 Then AdditionalSettings.Add("commodity_code")
|
||||
If btnAgg_Origin.Tag = 1 Then AdditionalSettings.Add("country_of_origin")
|
||||
If btnAgg_Unit.Tag = 1 Then AdditionalSettings.Add("unit_type")
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' RelayHub Request - Modaltrans UK
|
||||
'----------------------------------------------------------------------
|
||||
Dim ATEZ_RH_EZA As New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubJobOrderRequest With {
|
||||
.referenceNo = ioReference,
|
||||
.outputApplication = cRelayHubOutputApplication.Modaltrans,
|
||||
.regimeType = "IMPORT",
|
||||
.dispatchCountry = "TR",
|
||||
.destinationCountry = "GB",
|
||||
.additionalData = New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubAdditionalData With {
|
||||
.transaction = New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubTransaction With {
|
||||
.ioReference = ioReference
|
||||
},
|
||||
.declaration = New List(Of VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubDeclaration) From {
|
||||
New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubDeclaration With {
|
||||
.objectIdentification = New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubObjectIdentification With {
|
||||
.objectName = lblBezugsnummer.Text,
|
||||
.objectAlias = ioReference,
|
||||
.shipmentId = "123",
|
||||
.avisoId = "456"
|
||||
},
|
||||
.headerData = New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubHeaderData With {
|
||||
.agentContact = New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubAgentContact With {
|
||||
.contactPersonName = If(VERAG_PROG_ALLGEMEIN.cAllgemein.MITARBEITER.Fullname, ""),
|
||||
.contactPersonPhoneNumber = getTelefon(),
|
||||
.contactPersonPosition = "Customs Declarant",
|
||||
.contactPersonEmail = If(String.IsNullOrEmpty(VERAG_PROG_ALLGEMEIN.cAllgemein.MITARBEITER.mit_email), getDefaultMail_FIRMA(), VERAG_PROG_ALLGEMEIN.cAllgemein.MITARBEITER.mit_email)
|
||||
},
|
||||
.serviceCode = "cds",
|
||||
.docType = "import",
|
||||
.declarationType = "IMD",
|
||||
.declarantEori = "GB************",
|
||||
.procedureCodeRequested = "4000",
|
||||
.transportMeansArrivalIdentity = txtLKWId.Text,
|
||||
.transportMeansNationalityCode = If(AVISO.LKW_Nationalitaet, "")
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
.additionalSettings = New cRelayHubAdditionalSettings With {
|
||||
.combineOptions = AdditionalSettings,
|
||||
.disableOutbound = False,
|
||||
.disableDocumentConverter = False,
|
||||
.disableAiToCommon = False,
|
||||
.disableValidation = False,
|
||||
.targetLang = "en"
|
||||
}
|
||||
}
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' Vorpapier / T1
|
||||
'----------------------------------------------------------------------
|
||||
If If(SENDUNG.tblSnd_Vorpapier, "") <> "" Then
|
||||
ATEZ_RH_EZA.additionalData.declaration(0).headerData.previousAdministrativeReferenceType = "T1"
|
||||
ATEZ_RH_EZA.additionalData.declaration(0).headerData.previousAdministrativeReferenceNumber = SENDUNG.tblSnd_Vorpapier
|
||||
End If
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' Dokumente
|
||||
'----------------------------------------------------------------------
|
||||
ATEZ_RH_EZA.documents = New List(Of cRelayHub.cRelayHubDocument)
|
||||
|
||||
For Each r As DataGridViewRow In dgvAnhaenge.Rows
|
||||
Dim isSelected As Boolean = If(DBNull.Value Is r.Cells("anh_selekt").Value, False, r.Cells("anh_selekt").Value)
|
||||
|
||||
If isSelected Then
|
||||
Dim DOC As New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubDocument
|
||||
DOC.fileType = VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHub_sendToRelayHub_JobOrderRequest.getRelayHub_AnhDesc(r.Cells("anh_Art").Value)
|
||||
DOC.type = "base64"
|
||||
DOC.filename = r.Cells("anh_Name").Value
|
||||
|
||||
Try
|
||||
Dim dateiBytes As Byte() = IO.File.ReadAllBytes(VERAG_PROG_ALLGEMEIN.cDATENSERVER.GET_PDFPath_BY_DocID(r.Cells("anh_docId").Value))
|
||||
DOC.base64String = Convert.ToBase64String(dateiBytes)
|
||||
ATEZ_RH_EZA.documents.Add(DOC)
|
||||
Catch ex As Exception
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
||||
End Try
|
||||
End If
|
||||
Next
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' Adressen
|
||||
'----------------------------------------------------------------------
|
||||
ATEZ_RH_EZA.additionalData.declaration(0).addresses = New List(Of cRelayHub.cRelayHubAddress)
|
||||
|
||||
' Empfänger / Consignee
|
||||
If SENDUNG.tblSnd_EmpfaengerKdNr > 0 Then
|
||||
Dim AD As New cAdressen(SENDUNG.tblSnd_EmpfaengerKdNr)
|
||||
Dim KD As New cKunde(SENDUNG.tblSnd_EmpfaengerKdNr)
|
||||
Dim CN As New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubAddress
|
||||
|
||||
CN.addressType = "CN"
|
||||
CN.participantEORI = If(KD.EORITIN, "")
|
||||
CN.participantSubsidiaryNumber = If(KD.EORITIN_NL, "")
|
||||
CN.companyName = AD.Name_1
|
||||
CN.streetAndNumber = AD.Straße
|
||||
CN.postalCode = AD.PLZ
|
||||
CN.city = AD.Ort
|
||||
CN.countryCode = SDL.cProgramFunctions.getISO2Land(AD.LandKz)
|
||||
|
||||
ATEZ_RH_EZA.additionalData.declaration(0).addresses.Add(CN)
|
||||
ATEZ_RH_EZA.additionalData.declaration(0).headerData.destinationCountry = CN.countryCode
|
||||
ATEZ_RH_EZA.destinationCountry = CN.countryCode
|
||||
End If
|
||||
|
||||
' Absender / Consignor
|
||||
If SENDUNG.tblSnd_AbsenderKdNr > 0 Then
|
||||
Dim AD As New cAdressen(SENDUNG.tblSnd_AbsenderKdNr)
|
||||
Dim KD As New cKunde(SENDUNG.tblSnd_AbsenderKdNr)
|
||||
Dim CZ As New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubAddress
|
||||
|
||||
CZ.addressType = "CZ"
|
||||
CZ.participantEORI = If(KD.EORITIN, "")
|
||||
CZ.participantSubsidiaryNumber = If(KD.EORITIN_NL, "")
|
||||
CZ.companyName = AD.Name_1
|
||||
CZ.streetAndNumber = AD.Straße
|
||||
CZ.postalCode = AD.PLZ
|
||||
CZ.city = AD.Ort
|
||||
CZ.countryCode = SDL.cProgramFunctions.getISO2Land(AD.LandKz)
|
||||
|
||||
ATEZ_RH_EZA.additionalData.declaration(0).addresses.Add(CZ)
|
||||
ATEZ_RH_EZA.additionalData.declaration(0).headerData.departureCountry = CZ.countryCode
|
||||
ATEZ_RH_EZA.dispatchCountry = CZ.countryCode
|
||||
End If
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' Pflichtfelder absichern
|
||||
'----------------------------------------------------------------------
|
||||
ATEZ_RH_EZA.dispatchCountry = If(ATEZ_RH_EZA.dispatchCountry, "")
|
||||
ATEZ_RH_EZA.destinationCountry = If(ATEZ_RH_EZA.destinationCountry, "")
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' JSON anzeigen
|
||||
'----------------------------------------------------------------------
|
||||
If sender Is Button2 Then
|
||||
MsgBox(VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHub_sendToRelayHub_JobOrderRequest.getJSON(ATEZ_RH_EZA))
|
||||
Me.Cursor = Cursors.Default
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' Senden
|
||||
'----------------------------------------------------------------------
|
||||
Dim RESP = VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHub_sendToRelayHub_JobOrderRequest.query_declarations(ATEZ_RH_EZA)
|
||||
|
||||
If RESP.Success Then
|
||||
MsgBox("Erfolgreich an Modaltrans gesendet!")
|
||||
Me.Close()
|
||||
Else
|
||||
MsgBox("ERROR" & vbNewLine & RESP.Details, MsgBoxStyle.OkOnly, RESP.Message)
|
||||
End If
|
||||
|
||||
Me.Cursor = Cursors.Default
|
||||
|
||||
Catch ex As Exception
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
||||
Me.Cursor = Cursors.Default
|
||||
End Try
|
||||
End Sub
|
||||
|
||||
|
||||
Private Function getTelefon() As String
|
||||
Dim defaultDW = "200"
|
||||
Select Case VERAG_PROG_ALLGEMEIN.cAllgemein.FIRMA
|
||||
Case "ATILLA" : Return "0043 7711 28450"
|
||||
Case "AMBAR" : Return "0049 8651 9962492"
|
||||
Case "UNISPED" : defaultDW = "800"
|
||||
Case "IMEX" : defaultDW = "602"
|
||||
Case "VERAG" : defaultDW = "200"
|
||||
End Select
|
||||
|
||||
Dim dw = VERAG_PROG_ALLGEMEIN.cAllgemein.MITARBEITER.mit_durchwahl
|
||||
Return "0049 8503 7973999 " &
|
||||
If(String.IsNullOrEmpty(dw) OrElse dw.Length >= 5, defaultDW, dw)
|
||||
End Function
|
||||
Private Function getDefaultMail_FIRMA() As String
|
||||
Select Case VERAG_PROG_ALLGEMEIN.cAllgemein.FIRMA
|
||||
Case "VERAG" : Return "quickstop@verag.ag"
|
||||
Case "IMEX" : Return "steuerbescheide@imex-group.at"
|
||||
Case "UNISPED" : Return "office@unisped.at"
|
||||
Case "AMBAR" : Return "office@ambarlog.com"
|
||||
End Select
|
||||
Return "quickstop@verag.ag"
|
||||
End Function
|
||||
'Private Function sendAtezData(atezData As cATEZ_NCTS_DATA, atez As cATEZ_NCTS_IN) As Boolean
|
||||
|
||||
' Dim failreDesc As String
|
||||
|
||||
' Dim authResp = atez.authenticate("NCTS")
|
||||
' If authResp <> "200" Then
|
||||
|
||||
' failreDesc = "Authentifizierung fehlgeschlagen"
|
||||
' lblInfo.Text = failreDesc & " - " & authResp & vbNewLine & "Vorgang abgebrochen" & vbNewLine & " Bitte wiederholen!"
|
||||
' Dim resultAuthentifizierung As MsgBoxResult = MsgBox("Fehler beim Authentifizieren" & vbNewLine & failreDesc & vbNewLine & "Soll NCTS als Entwurf gespeichert werden?", vbYesNoCancel)
|
||||
|
||||
' If resultAuthentifizierung = vbYes Then
|
||||
' atezData.status = "Draft"
|
||||
' atezData.fehlerbeschreibung = failreDesc
|
||||
' Return atezData.SAVE()
|
||||
' Else
|
||||
' atezData.status = "Failure"
|
||||
' atezData.fehlerbeschreibung = failreDesc
|
||||
' Return atezData.SAVE()
|
||||
' End If
|
||||
|
||||
' Return False
|
||||
' End If
|
||||
|
||||
' atezData.sessionId = atez.sessionID
|
||||
|
||||
|
||||
' If Not atez.setJsonNCTS(atezData) Then
|
||||
' MsgBox("Fehler beim Erstellen der Daten" & vbNewLine & "Vorgang abgebrochen!")
|
||||
' atezData.status = "Failure"
|
||||
' atezData.fehlerbeschreibung = "Fehler beim Erstellen der Daten"
|
||||
' Return atezData.SAVE
|
||||
' End If
|
||||
|
||||
' If checkAttachment() Then
|
||||
' If Not atez.setJsonPDF(atezData, dgvAnhaenge) Then
|
||||
' MsgBox("Fehler beim Erstellen der PDF-Daten!" & vbNewLine & "Vorgang abgebrochen!")
|
||||
' atezData.status = "Failure"
|
||||
' atezData.fehlerbeschreibung = "Fehler beim Erstellen der PDF-Daten!"
|
||||
' Return atezData.SAVE
|
||||
' End If
|
||||
' End If
|
||||
|
||||
|
||||
' Dim azetId = atez.SendRequestWithAuthHeader("application/json", failreDesc, "/api/integrations/verag", "POST")
|
||||
|
||||
' If failreDesc <> "" Then
|
||||
' If atezData.status = "Draft" Then
|
||||
' MsgBox("Fehler beim Senden" & vbNewLine & failreDesc)
|
||||
' atezData.fehlerbeschreibung = failreDesc
|
||||
' Return atezData.SAVE()
|
||||
|
||||
' End If
|
||||
' Dim result As MsgBoxResult = MsgBox("Fehler beim Senden" & vbNewLine & failreDesc & vbNewLine & "Soll NCTS als Entwurf gespeichert werden?", vbYesNoCancel)
|
||||
' If result = vbYes Then
|
||||
' atezData.status = "Draft"
|
||||
' atezData.fehlerbeschreibung = failreDesc
|
||||
' Return atezData.SAVE()
|
||||
' Else
|
||||
' atezData.status = "Failure"
|
||||
' atezData.fehlerbeschreibung = failreDesc
|
||||
' Return atezData.SAVE()
|
||||
' End If
|
||||
|
||||
' lblInfo.Text = "Fehler in der API "
|
||||
|
||||
' Else
|
||||
|
||||
' If azetId = "-1" Then
|
||||
' atezData.fehlerbeschreibung = "Request has been sent, but no header received!"
|
||||
' Else
|
||||
' atezData.fehlerbeschreibung = ""
|
||||
' End If
|
||||
' atezData.status = "Sent"
|
||||
' atezData.atezId = IIf(azetId IsNot Nothing, azetId, "")
|
||||
' Return atezData.SAVE()
|
||||
|
||||
' End If
|
||||
|
||||
'End Function
|
||||
|
||||
Function getBezugsnr(ByRef BezugsNr)
|
||||
Dim BezugsNrTmp = ""
|
||||
BezugsNrTmp = SENDUNG.FilialenNr & "/" & SENDUNG.AbfertigungsNr
|
||||
BezugsNr = BezugsNrTmp
|
||||
zusatz = "A"
|
||||
|
||||
If dgv IsNot Nothing AndAlso dgv.Rows.Count > 0 Then
|
||||
BezugsNr = BezugsNrTmp & "/" & zusatz
|
||||
For Each r As DataGridViewRow In dgv.Rows
|
||||
If r.Cells("BezugsNr").Value = BezugsNr Then
|
||||
|
||||
If zusatz.Length = 1 Then
|
||||
zusatz = Chr(Asc(zusatz.ToString) + 1)
|
||||
Else
|
||||
zusatz = zusatz.Substring(0, 1) & Chr(Asc(zusatz.Substring(0, 2).ToString) + 1)
|
||||
End If
|
||||
|
||||
If zusatz = "Z" Then zusatz = "AA"
|
||||
End If
|
||||
BezugsNr = BezugsNrTmp & "/" & zusatz
|
||||
Next
|
||||
|
||||
End If
|
||||
|
||||
While DAKOSY_Worker.cDakosy_Zollanmeldungen.ExistsBezugsNr(BezugsNr) 'IsNot Nothing
|
||||
BezugsNr = BezugsNrTmp & "/" & zusatz
|
||||
|
||||
If zusatz.Length = 1 Then
|
||||
zusatz = Chr(Asc(zusatz.ToString) + 1)
|
||||
Else
|
||||
zusatz = zusatz.Substring(0, 1) & Chr(Asc(zusatz.Substring(0, 2).ToString) + 1)
|
||||
End If
|
||||
|
||||
If zusatz = "Z" Then zusatz = "AA"
|
||||
End While
|
||||
|
||||
lblBezugsnummer.Text = BezugsNr
|
||||
Return BezugsNr
|
||||
End Function
|
||||
|
||||
|
||||
Private Sub frmATEZNCTS_Load(sender As Object, e As EventArgs) Handles MyBase.Load
|
||||
|
||||
'Select Case FIRMA_DY
|
||||
' Case "VERAG" : txtDyMandant.Text = "VERG"
|
||||
' txtDyNiederlassung.Text = VERAG_PROG_ALLGEMEIN.cAllgemein.NIEDERLASSUNG
|
||||
|
||||
' Select Case FilialenNr
|
||||
' Case "5103" : txtDyNiederlassung.Text = "WAI"
|
||||
|
||||
' End Select
|
||||
|
||||
|
||||
' Case "ATILLA" : txtDyMandant.Text = "ATIL" : txtDyNiederlassung.Text = "SUW"
|
||||
' Case "UNISPED" : txtDyMandant.Text = "UNAT" : txtDyNiederlassung.Text = "ATSPED"
|
||||
' Case "IMEX" : txtDyMandant.Text = "IMEX" : txtDyNiederlassung.Text = "IME"
|
||||
' Case "AMBAR" : txtDyMandant.Text = "ATIL" : txtDyNiederlassung.Text = "AMBWO"
|
||||
'End Select
|
||||
FIRMA_DY = cDakosyFunftions.getFirma_DY(FilialenNr.ToString, Me, "EZA")
|
||||
'txtDyMandant.Text = cDakosyFunftions.getIOPartner(FIRMA_DY, "EZA")
|
||||
'txtDyNiederlassung.Text = cDakosyFunftions.getDivision(FIRMA_DY, "EZA")
|
||||
|
||||
'Label4.Text = If(VERAG_PROG_ALLGEMEIN.cAllgemein.MITARBEITER.mit_DAKOSY_SB, "-").ToString
|
||||
|
||||
initSeachboxes()
|
||||
lblAnh.Visible = True
|
||||
|
||||
|
||||
If openExisting Then
|
||||
|
||||
If id > 0 Then
|
||||
' atez_data = New cATEZ_NCTS_DATA(id)
|
||||
initAttachment()
|
||||
If atez_data.atezId <> "" Then
|
||||
lblInfo.Text = "Atez-ID " & atez_data.atezId
|
||||
Else
|
||||
lblInfo.Text = "Status: " & IIf(atez_data.fehlerbeschreibung <> "", atez_data.status & "- " & atez_data.fehlerbeschreibung, atez_data.status)
|
||||
End If
|
||||
|
||||
|
||||
lblBezugsnummer.Text = atez_data.VERAG_LRN
|
||||
|
||||
'cboStammreferenz.fillWithSQL("SELECT [dySr_Stammreferenz],[dySr_Bezeichnung] FROM [tblDakosy_Stammreferenzen] WHERE dySr_Land='DE' AND dySr_Verfahren='EZA' and dySr_dy_Mandant='" & txtDyMandant.Text & "' and dySr_dy_Niederlassung IN ('','" & txtDyNiederlassung.Text & "' " & If(txtDyMandant.Text = "UNAT", ", 'ATSPED' ", "") & ") and dySr_visible=1", False, "FMZOLL", True)
|
||||
'cboStammreferenz.changeItem(atez_data.DAKOSY_TemplateCode)
|
||||
'cboProzedur.changeItem(atez_data.DAKOSY_Procedure)
|
||||
|
||||
txtLKWId.Text = atez_data.LicensePlateContainerNo
|
||||
|
||||
'sbBestimmungsZollstelle.SET_VALUE(atez_data.DestinationCustomsOffice)
|
||||
sbAdressierteZollstelle.SET_VALUE(atez_data.DepartureCustomsOffice)
|
||||
|
||||
|
||||
|
||||
|
||||
If atez_data.status = "Draft" Then
|
||||
btnSend.Text = "An ATEZ senden -->"
|
||||
pnlHead.Enabled = True
|
||||
btnSend.Enabled = True
|
||||
'initAttachment()
|
||||
|
||||
Else
|
||||
btnSend.Text = "JSON"
|
||||
pnlHead.Enabled = False
|
||||
dgvAnhaenge.ReadOnly = True
|
||||
btnSend.Enabled = True
|
||||
|
||||
|
||||
End If
|
||||
|
||||
|
||||
Else
|
||||
btnSend.Enabled = False
|
||||
End If
|
||||
|
||||
Else
|
||||
' atez_data = New cATEZ_NCTS_DATA()
|
||||
initAttachment()
|
||||
'Button1.Text = "An ATEZ senden -->"
|
||||
pnlHead.Enabled = True
|
||||
|
||||
'cboStammreferenz.fillWithSQL("SELECT [dySr_Stammreferenz],[dySr_Bezeichnung] FROM [tblDakosy_Stammreferenzen] WHERE dySr_Land='DE' AND dySr_Verfahren='EZA' and dySr_dy_Mandant='" & txtDyMandant.Text & "' and dySr_dy_Niederlassung IN ('','" & txtDyNiederlassung.Text & "' " & If(txtDyMandant.Text = "UNAT", ", 'ATSPED' ", "") & ") and dySr_visible=1", False, "FMZOLL", True)
|
||||
'cboStammreferenz.changeItem("")
|
||||
|
||||
getBezugsnr(BezugsNr)
|
||||
txtLKWId.Text = AVISO.LKW_Nr
|
||||
|
||||
' sbBestimmungsZollstelle.SET_VALUE(SENDUNG.NCTS_Bestimmungszollstelle)
|
||||
|
||||
If AVISO.Grenzstelle.Replace("???", "") = "" Then
|
||||
sbAdressierteZollstelle.SET_VALUE(AVISO.Zollstelle)
|
||||
Else
|
||||
|
||||
Dim GRZ As New VERAG_PROG_ALLGEMEIN.cGrenzstelle(AVISO.Grenzstelle)
|
||||
If GRZ IsNot Nothing AndAlso GRZ.hasEntry Then
|
||||
If GRZ.grz_ZollamtDST IsNot Nothing Then
|
||||
sbAdressierteZollstelle.SET_VALUE(GRZ.grz_ZollamtDST)
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
|
||||
|
||||
End If
|
||||
'initAttachment()
|
||||
End Sub
|
||||
|
||||
Sub initAttachment()
|
||||
Dim hSQL As String = " SELECT [anh_id],anh_Datum,[anh_Name],[anh_docId],
|
||||
|
||||
case WHEN [anh_size] > 0 Then ROUND([anh_size] / 1000000,2) End as anh_size,
|
||||
[anh_Art],[anh_Typ] FROM [tblAvisoAnhaenge]
|
||||
WHERE [anh_AvisoId]=" & AVISO.AvisoID & "AND (anh_SendungsId is null OR anh_SendungsId <=0 OR anh_SendungsId='" & SENDUNG.tblSnd_SendungID & "') And anh_Typ NOT IN ('MSG', 'SONSTIGES')
|
||||
ORDER BY anh_SendungsId desc,
|
||||
case
|
||||
when [anh_Art] = 'ATR-EUR1' then 0
|
||||
when [anh_Art] = 'Rechnung' then 1
|
||||
when [anh_Art] = 'eFatura' then 1.1
|
||||
when [anh_Art] = 'CMR' then 2
|
||||
when [anh_Art] = 'Ausfuhr' then 3
|
||||
when [anh_Art] = 'Vorpapier' then 4
|
||||
when [anh_Art] = 'Packliste' then 5
|
||||
when [anh_Art] = 'Auftrag' then 6
|
||||
when [anh_Art] = 'Auftrag' then 7
|
||||
when [anh_Art] = 'Dispoliste' then 8
|
||||
when [anh_Art] = 'Vorkasse' then 9
|
||||
when [anh_Art] = 'Überweisungsbeleg' then 10
|
||||
when [anh_Art] = 'Vollmacht' then 11
|
||||
when [anh_Art] = 'ATB' then 12
|
||||
when [anh_Art] = 'ATA' then 13
|
||||
when [anh_Art] = 'Sonstiges' then 99
|
||||
when [anh_Art] ='' then 15
|
||||
|
||||
END, [anh_Reihenfolge],[anh_id]"
|
||||
|
||||
Dim dt = VermerkeDAL.Anzeigen_Vermerke(hSQL)
|
||||
|
||||
Dim col As DataColumn
|
||||
col = dt.Columns.Add("anh_selekt", GetType(Boolean))
|
||||
col.SetOrdinal(0)
|
||||
dgvAnhaenge.Columns.Clear()
|
||||
dgvAnhaenge.DataSource = dt
|
||||
If dgvAnhaenge.RowCount = 0 Then dgvAnhaenge.Columns.Clear() : Exit Sub
|
||||
|
||||
With dgvAnhaenge
|
||||
|
||||
.Enabled = True
|
||||
.ReadOnly = False
|
||||
|
||||
.RowTemplate.MinimumHeight = 30
|
||||
.AutoSizeRowsMode = DataGridViewAutoSizeRowsMode.AllCells
|
||||
.Columns("anh_id").Visible = False 'VermerkID nicht anzeigenconMenuVermerke
|
||||
.Columns("anh_docId").Visible = False 'AvisoID nicht anzeigen
|
||||
' .Columns("anh_Art").Visible = False 'AvisoID nicht anzeigen
|
||||
|
||||
.Columns("anh_selekt").Width = 25
|
||||
.Columns("anh_selekt").HeaderText = ""
|
||||
.Columns("anh_selekt").DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter
|
||||
|
||||
.Columns("anh_Datum").MinimumWidth = 50
|
||||
.Columns("anh_Datum").HeaderText = "Datum"
|
||||
.Columns("anh_Datum").DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter
|
||||
.Columns("anh_Datum").ReadOnly = True
|
||||
|
||||
|
||||
.Columns("anh_Name").MinimumWidth = 150
|
||||
.Columns("anh_Name").HeaderText = "Name"
|
||||
.Columns("anh_Name").AutoSizeMode = DataGridViewAutoSizeColumnMode.Fill
|
||||
.Columns("anh_Name").ReadOnly = True
|
||||
|
||||
.Columns("anh_Art").MinimumWidth = 50
|
||||
.Columns("anh_Art").HeaderText = "Art"
|
||||
.Columns("anh_Art").DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter
|
||||
.Columns("anh_Art").ReadOnly = True
|
||||
|
||||
.Columns("anh_Typ").Width = 50
|
||||
.Columns("anh_Typ").HeaderText = "Typ"
|
||||
.Columns("anh_Typ").DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter
|
||||
.Columns("anh_Typ").ReadOnly = True
|
||||
|
||||
.Columns("anh_size").Width = 50
|
||||
.Columns("anh_size").HeaderText = "Größe in MB"
|
||||
.Columns("anh_size").DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter
|
||||
.Columns("anh_size").ReadOnly = True
|
||||
|
||||
End With
|
||||
|
||||
For Each doc As DataGridViewRow In dgvAnhaenge.Rows
|
||||
|
||||
If Not IsDBNull(doc.Cells("anh_size").Value) AndAlso doc.Cells("anh_size").Value > 0 Then
|
||||
Dim size = (doc.Cells("anh_size").Value)
|
||||
If size < 1 Then
|
||||
doc.DefaultCellStyle.BackColor = Color.LightGreen
|
||||
ElseIf size > 1 AndAlso size < 5 Then
|
||||
doc.DefaultCellStyle.BackColor = Color.LightYellow
|
||||
Else
|
||||
doc.DefaultCellStyle.BackColor = Color.IndianRed
|
||||
End If
|
||||
End If
|
||||
|
||||
Next
|
||||
|
||||
If atez_data IsNot Nothing AndAlso atez_data.selectedDocuments <> "" Then
|
||||
|
||||
For Each doc As DataGridViewRow In dgvAnhaenge.Rows
|
||||
If atez_data.selectedDocuments.Contains(doc.Cells("anh_docId").Value) Then doc.Cells("anh_selekt").Value = True
|
||||
|
||||
Next
|
||||
End If
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
Sub initSeachboxes()
|
||||
|
||||
sbAdressierteZollstelle.initSearchBox(Me.FindForm, "[Code] ,[Code] as Nr,Description as Dienststelle,left(Code,2) as Land,[Description] +' (' +left(Code,2)+')' as display FROM [tbl_DY_ZollDE_C0141_Zollstellen]", {" [Code]", "Description"}, " (StartDate is null OR StartDate< GETDATE()) AND (EndDate is null OR EndDate> GETDATE()) ", " left(Code,2),[Description]", "Code", "display", "FMZOLL", , 400, 200, {"display", "Code"})
|
||||
'sbBestimmungsZollstelle.initSearchBox(Me.FindForm, "[Code] ,[Code] as Nr,Description as Dienststelle,left(Code,2) as Land,[Description] +' (' +left(Code,2)+')' as display FROM [tbl_DY_ZollDE_C0141_Zollstellen]", {" [Code]", "Description"}, " (StartDate is null OR StartDate< GETDATE()) AND (EndDate is null OR EndDate> GETDATE()) ", " left(Code,2),[Description]", "Code", "display", "FMZOLL", , 400, 200, {"display", "Code"})
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
|
||||
Public Function checkAttachment() As Boolean
|
||||
|
||||
Dim selectedDocuments As Boolean = False
|
||||
|
||||
For Each Row In dgvAnhaenge.Rows
|
||||
|
||||
selectedDocuments = IIf(DBNull.Value Is Row.Cells("anh_selekt").Value, False, Row.Cells("anh_selekt").Value)
|
||||
If selectedDocuments Then Exit For
|
||||
Next
|
||||
|
||||
|
||||
'If Not selectedDocuments Then
|
||||
' lblInfo.Text = "kein Anhang selektiert"
|
||||
' Cursor = Cursors.Default
|
||||
' Return selectedDocuments
|
||||
'End If
|
||||
|
||||
Return selectedDocuments
|
||||
|
||||
End Function
|
||||
|
||||
Public Function checkMandatoryField() As Boolean
|
||||
|
||||
|
||||
'TODO
|
||||
Return True
|
||||
|
||||
|
||||
End Function
|
||||
|
||||
|
||||
|
||||
Private Sub dgvAnhaenge_CellDoubleClick(sender As Object, e As DataGridViewCellEventArgs) Handles dgvAnhaenge.CellDoubleClick
|
||||
Try
|
||||
|
||||
If dgvAnhaenge.SelectedRows.Count > 0 Then
|
||||
Dim docPath = VERAG_PROG_ALLGEMEIN.cDATENSERVER.GET_PDFPath_BY_DocID(dgvAnhaenge.SelectedRows(0).Cells("anh_docId").Value)
|
||||
If Not IO.File.Exists(docPath) Then
|
||||
MsgBox("Die Datei existiert nicht!")
|
||||
Else
|
||||
If docPath.ToString.ToLower.EndsWith(".msg") Then ' MSG - Mails --> lokale Kopie, sonst Fehler (bereits von Benutzer soUndSo geöffnet)
|
||||
Dim docPathTMP = VERAG_PROG_ALLGEMEIN.cFormularManager.getTMPPath_MSG()
|
||||
System.IO.File.Copy(docPath, docPathTMP)
|
||||
Process.Start(docPathTMP)
|
||||
Else
|
||||
Process.Start(docPath)
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
|
||||
Catch ex As Exception
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
||||
End Try
|
||||
End Sub
|
||||
|
||||
|
||||
|
||||
Private Sub dgvAnhaenge_CellClick(sender As Object, e As DataGridViewCellEventArgs) Handles dgvAnhaenge.CellClick
|
||||
|
||||
Dim countAnh As Double = 0
|
||||
If dgvAnhaenge.RowCount > 0 Then
|
||||
|
||||
If dgvAnhaenge.Columns(e.ColumnIndex).Name = "anh_selekt" Then
|
||||
|
||||
If Not IsDBNull(dgvAnhaenge.CurrentRow.Cells("anh_selekt").Value) AndAlso dgvAnhaenge.CurrentRow.Cells("anh_selekt").Value = True Then
|
||||
countAnh += IIf(dgvAnhaenge.CurrentRow.Cells("anh_size").Value IsNot DBNull.Value, dgvAnhaenge.CurrentRow.Cells("anh_size").Value, 0)
|
||||
End If
|
||||
|
||||
For Each Row As DataGridViewRow In dgvAnhaenge.Rows
|
||||
If Row.Cells("anh_selekt").Value IsNot DBNull.Value AndAlso Row.Cells("anh_selekt").Value = True AndAlso Row.Cells("anh_size").Value IsNot DBNull.Value Then
|
||||
countAnh += IIf(Row.Cells("anh_size").Value IsNot DBNull.Value, Row.Cells("anh_size").Value, 0)
|
||||
End If
|
||||
Next
|
||||
|
||||
lblAnh.Text = "Anhang in MB: " & countAnh.ToString
|
||||
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub Button3_Click(sender As Object, e As EventArgs) Handles Button3.Click
|
||||
If dgvAnhaenge.RowCount > 0 Then
|
||||
Dim countAnh As Double = 0
|
||||
For Each Row As DataGridViewRow In dgvAnhaenge.Rows
|
||||
If allSelected Then
|
||||
Row.Cells("anh_selekt").Value = True
|
||||
countAnh += IIf(Row.Cells("anh_size").Value IsNot DBNull.Value, Row.Cells("anh_size").Value, 0)
|
||||
Else
|
||||
Row.Cells("anh_selekt").Value = False
|
||||
countAnh = 0
|
||||
End If
|
||||
Next
|
||||
allSelected = Not allSelected
|
||||
lblAnh.Text = "Anhang in MB: " & countAnh.ToString
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub Button1_Click_1(sender As Object, e As EventArgs) Handles Button1.Click
|
||||
cRelayHubToken.DeleteAllStores()
|
||||
End Sub
|
||||
|
||||
Private Sub Button2_Click(sender As Object, e As EventArgs) Handles btnAgg_Tnr.Click, btnAgg_desc.Click, btnAgg_Origin.Click, btnAgg_Unit.Click
|
||||
If sender.Tag = 0 Then
|
||||
sender.Tag = 1
|
||||
sender.BackColor = Color.DeepSkyBlue
|
||||
Else
|
||||
sender.Tag = 0
|
||||
sender.BackColor = SystemColors.Control
|
||||
End If
|
||||
End Sub
|
||||
Private Sub Buttonprio_Click(sender As Object, e As EventArgs) Handles btnPrio_CommInv.Click, btnPrio_ftz.Click, btnPrio_eFatura.Click, btnPrio_Export.Click
|
||||
|
||||
If sender IsNot btnPrio_CommInv Then btnPrio_CommInv.Tag = 0 : btnPrio_CommInv.BackColor = SystemColors.Control
|
||||
If sender IsNot btnPrio_eFatura Then btnPrio_eFatura.Tag = 0 : btnPrio_eFatura.BackColor = SystemColors.Control
|
||||
If sender IsNot btnPrio_Export Then btnPrio_Export.Tag = 0 : btnPrio_Export.BackColor = SystemColors.Control
|
||||
If sender IsNot btnPrio_ftz Then btnPrio_ftz.Tag = 0 : btnPrio_ftz.BackColor = SystemColors.Control
|
||||
|
||||
|
||||
If sender.Tag = 0 Then
|
||||
sender.Tag = 1
|
||||
sender.BackColor = Color.DeepSkyBlue
|
||||
Else
|
||||
sender.Tag = 0
|
||||
sender.BackColor = SystemColors.Control
|
||||
End If
|
||||
End Sub
|
||||
End Class
|
||||
487
Aviso/ATEZ/frmATEZ_UK_MODAL.Designer.vb
generated
Normal file
487
Aviso/ATEZ/frmATEZ_UK_MODAL.Designer.vb
generated
Normal file
@@ -0,0 +1,487 @@
|
||||
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()>
|
||||
Partial Class frmATEZ_UK_MODAL
|
||||
Inherits System.Windows.Forms.Form
|
||||
|
||||
'Das Formular überschreibt den Löschvorgang, um die Komponentenliste zu bereinigen.
|
||||
<System.Diagnostics.DebuggerNonUserCode()>
|
||||
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
|
||||
Try
|
||||
If disposing AndAlso components IsNot Nothing Then
|
||||
components.Dispose()
|
||||
End If
|
||||
Finally
|
||||
MyBase.Dispose(disposing)
|
||||
End Try
|
||||
End Sub
|
||||
|
||||
'Wird vom Windows Form-Designer benötigt.
|
||||
Private components As System.ComponentModel.IContainer
|
||||
|
||||
'Hinweis: Die folgende Prozedur ist für den Windows Form-Designer erforderlich.
|
||||
'Das Bearbeiten ist mit dem Windows Form-Designer möglich.
|
||||
'Das Bearbeiten mit dem Code-Editor ist nicht möglich.
|
||||
<System.Diagnostics.DebuggerStepThrough()>
|
||||
Private Sub InitializeComponent()
|
||||
Me.components = New System.ComponentModel.Container()
|
||||
Dim resources As System.ComponentModel.ComponentResourceManager = New System.ComponentModel.ComponentResourceManager(GetType(frmATEZ_UK_MODAL))
|
||||
Me.btnSend = New System.Windows.Forms.Button()
|
||||
Me.pnlHead = New System.Windows.Forms.Panel()
|
||||
Me.PictureBox1 = New System.Windows.Forms.PictureBox()
|
||||
Me.Button1 = New System.Windows.Forms.Button()
|
||||
Me.Button2 = New System.Windows.Forms.Button()
|
||||
Me.Label1 = New System.Windows.Forms.Label()
|
||||
Me.lblInfo = New System.Windows.Forms.Label()
|
||||
Me.Label8 = New System.Windows.Forms.Label()
|
||||
Me.cboStammreferenz = New VERAG_PROG_ALLGEMEIN.MyComboBox()
|
||||
Me.txtLKWId = New VERAG_PROG_ALLGEMEIN.MyTextBox()
|
||||
Me.Label3 = New System.Windows.Forms.Label()
|
||||
Me.Label9 = New System.Windows.Forms.Label()
|
||||
Me.sbAdressierteZollstelle = New VERAG_PROG_ALLGEMEIN.MySearchBox()
|
||||
Me.lblBezugsnummer = New System.Windows.Forms.Label()
|
||||
Me.Button3 = New System.Windows.Forms.Button()
|
||||
Me.Label6 = New System.Windows.Forms.Label()
|
||||
Me.lblAnh = New System.Windows.Forms.Label()
|
||||
Me.btnAgg_Tnr = New System.Windows.Forms.Button()
|
||||
Me.Label2 = New System.Windows.Forms.Label()
|
||||
Me.btnAgg_Origin = New System.Windows.Forms.Button()
|
||||
Me.btnAgg_Unit = New System.Windows.Forms.Button()
|
||||
Me.btnAgg_desc = New System.Windows.Forms.Button()
|
||||
Me.dgvAnhaenge = New VERAG_PROG_ALLGEMEIN.MyDatagridview(Me.components)
|
||||
Me.columnName = New System.Windows.Forms.DataGridViewTextBoxColumn()
|
||||
Me.btnPrio_CommInv = New System.Windows.Forms.Button()
|
||||
Me.Label5 = New System.Windows.Forms.Label()
|
||||
Me.btnPrio_eFatura = New System.Windows.Forms.Button()
|
||||
Me.btnPrio_Export = New System.Windows.Forms.Button()
|
||||
Me.btnPrio_ftz = New System.Windows.Forms.Button()
|
||||
Me.Panel1 = New System.Windows.Forms.Panel()
|
||||
Me.pnlHead.SuspendLayout()
|
||||
CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.dgvAnhaenge, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
Me.Panel1.SuspendLayout()
|
||||
Me.SuspendLayout()
|
||||
'
|
||||
'btnSend
|
||||
'
|
||||
Me.btnSend.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.btnSend.BackColor = System.Drawing.Color.White
|
||||
Me.btnSend.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Center
|
||||
Me.btnSend.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!)
|
||||
Me.btnSend.Image = Global.AVISO.My.Resources.Resources.ico_atez_declarantAI
|
||||
Me.btnSend.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
|
||||
Me.btnSend.Location = New System.Drawing.Point(473, 343)
|
||||
Me.btnSend.Margin = New System.Windows.Forms.Padding(2)
|
||||
Me.btnSend.Name = "btnSend"
|
||||
Me.btnSend.Padding = New System.Windows.Forms.Padding(5, 0, 5, 0)
|
||||
Me.btnSend.Size = New System.Drawing.Size(205, 58)
|
||||
Me.btnSend.TabIndex = 26
|
||||
Me.btnSend.Text = "An ATEZ senden >>"
|
||||
Me.btnSend.TextAlign = System.Drawing.ContentAlignment.MiddleRight
|
||||
Me.btnSend.UseVisualStyleBackColor = False
|
||||
'
|
||||
'pnlHead
|
||||
'
|
||||
Me.pnlHead.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink
|
||||
Me.pnlHead.BackColor = System.Drawing.Color.White
|
||||
Me.pnlHead.Controls.Add(Me.PictureBox1)
|
||||
Me.pnlHead.Controls.Add(Me.Button1)
|
||||
Me.pnlHead.Controls.Add(Me.Button2)
|
||||
Me.pnlHead.Controls.Add(Me.Label1)
|
||||
Me.pnlHead.Controls.Add(Me.lblInfo)
|
||||
Me.pnlHead.Controls.Add(Me.Label8)
|
||||
Me.pnlHead.Controls.Add(Me.cboStammreferenz)
|
||||
Me.pnlHead.Controls.Add(Me.txtLKWId)
|
||||
Me.pnlHead.Controls.Add(Me.Label3)
|
||||
Me.pnlHead.Controls.Add(Me.Label9)
|
||||
Me.pnlHead.Controls.Add(Me.sbAdressierteZollstelle)
|
||||
Me.pnlHead.Controls.Add(Me.lblBezugsnummer)
|
||||
Me.pnlHead.Location = New System.Drawing.Point(3, 2)
|
||||
Me.pnlHead.Name = "pnlHead"
|
||||
Me.pnlHead.Size = New System.Drawing.Size(675, 151)
|
||||
Me.pnlHead.TabIndex = 112
|
||||
'
|
||||
'PictureBox1
|
||||
'
|
||||
Me.PictureBox1.BackgroundImage = Global.AVISO.My.Resources.Resources.modaltrans_uk
|
||||
Me.PictureBox1.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom
|
||||
Me.PictureBox1.Location = New System.Drawing.Point(572, 34)
|
||||
Me.PictureBox1.Name = "PictureBox1"
|
||||
Me.PictureBox1.Size = New System.Drawing.Size(100, 50)
|
||||
Me.PictureBox1.TabIndex = 159
|
||||
Me.PictureBox1.TabStop = False
|
||||
'
|
||||
'Button1
|
||||
'
|
||||
Me.Button1.Location = New System.Drawing.Point(553, 117)
|
||||
Me.Button1.Name = "Button1"
|
||||
Me.Button1.Size = New System.Drawing.Size(122, 23)
|
||||
Me.Button1.TabIndex = 153
|
||||
Me.Button1.Text = "Clear Token Cache"
|
||||
Me.Button1.UseVisualStyleBackColor = True
|
||||
'
|
||||
'Button2
|
||||
'
|
||||
Me.Button2.Location = New System.Drawing.Point(610, 96)
|
||||
Me.Button2.Name = "Button2"
|
||||
Me.Button2.Size = New System.Drawing.Size(65, 23)
|
||||
Me.Button2.TabIndex = 158
|
||||
Me.Button2.Text = "json"
|
||||
Me.Button2.UseVisualStyleBackColor = True
|
||||
'
|
||||
'Label1
|
||||
'
|
||||
Me.Label1.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.Label1.AutoSize = True
|
||||
Me.Label1.BackColor = System.Drawing.Color.White
|
||||
Me.Label1.Location = New System.Drawing.Point(387, 13)
|
||||
Me.Label1.Name = "Label1"
|
||||
Me.Label1.Size = New System.Drawing.Size(89, 13)
|
||||
Me.Label1.TabIndex = 106
|
||||
Me.Label1.Text = "Bezugsnummer:"
|
||||
'
|
||||
'lblInfo
|
||||
'
|
||||
Me.lblInfo.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
|
||||
Me.lblInfo.ForeColor = System.Drawing.Color.Red
|
||||
Me.lblInfo.Location = New System.Drawing.Point(3, 32)
|
||||
Me.lblInfo.Name = "lblInfo"
|
||||
Me.lblInfo.Size = New System.Drawing.Size(460, 21)
|
||||
Me.lblInfo.TabIndex = 148
|
||||
'
|
||||
'Label8
|
||||
'
|
||||
Me.Label8.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.Label8.AutoSize = True
|
||||
Me.Label8.Location = New System.Drawing.Point(6, 61)
|
||||
Me.Label8.Name = "Label8"
|
||||
Me.Label8.Size = New System.Drawing.Size(86, 13)
|
||||
Me.Label8.TabIndex = 146
|
||||
Me.Label8.Text = "Stammreferenz:"
|
||||
Me.Label8.TextAlign = System.Drawing.ContentAlignment.TopRight
|
||||
Me.Label8.Visible = False
|
||||
'
|
||||
'cboStammreferenz
|
||||
'
|
||||
Me.cboStammreferenz._allowedValuesFreiText = Nothing
|
||||
Me.cboStammreferenz._allowFreiText = False
|
||||
Me.cboStammreferenz._value = ""
|
||||
Me.cboStammreferenz.BackColor = System.Drawing.Color.FromArgb(CType(CType(224, Byte), Integer), CType(CType(224, Byte), Integer), CType(CType(224, Byte), Integer))
|
||||
Me.cboStammreferenz.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList
|
||||
Me.cboStammreferenz.FlatStyle = System.Windows.Forms.FlatStyle.Flat
|
||||
Me.cboStammreferenz.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!)
|
||||
Me.cboStammreferenz.FormattingEnabled = True
|
||||
Me.cboStammreferenz.Location = New System.Drawing.Point(151, 56)
|
||||
Me.cboStammreferenz.Name = "cboStammreferenz"
|
||||
Me.cboStammreferenz.Size = New System.Drawing.Size(255, 24)
|
||||
Me.cboStammreferenz.TabIndex = 145
|
||||
Me.cboStammreferenz.Visible = False
|
||||
'
|
||||
'txtLKWId
|
||||
'
|
||||
Me.txtLKWId._DateTimeOnly = False
|
||||
Me.txtLKWId._numbersOnly = False
|
||||
Me.txtLKWId._numbersOnlyKommastellen = ""
|
||||
Me.txtLKWId._numbersOnlyTrennzeichen = True
|
||||
Me.txtLKWId._Prozent = False
|
||||
Me.txtLKWId._ShortDateNew = False
|
||||
Me.txtLKWId._ShortDateOnly = False
|
||||
Me.txtLKWId._TimeOnly = False
|
||||
Me.txtLKWId._TimeOnly_Seconds = False
|
||||
Me.txtLKWId._value = ""
|
||||
Me.txtLKWId._Waehrung = False
|
||||
Me.txtLKWId._WaehrungZeichen = True
|
||||
Me.txtLKWId.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!)
|
||||
Me.txtLKWId.ForeColor = System.Drawing.Color.Black
|
||||
Me.txtLKWId.Location = New System.Drawing.Point(151, 86)
|
||||
Me.txtLKWId.MaxLineLength = -1
|
||||
Me.txtLKWId.MaxLines_Warning = ""
|
||||
Me.txtLKWId.MaxLines_Warning_Label = Nothing
|
||||
Me.txtLKWId.Name = "txtLKWId"
|
||||
Me.txtLKWId.Size = New System.Drawing.Size(255, 23)
|
||||
Me.txtLKWId.TabIndex = 144
|
||||
'
|
||||
'Label3
|
||||
'
|
||||
Me.Label3.AutoSize = True
|
||||
Me.Label3.Location = New System.Drawing.Point(6, 91)
|
||||
Me.Label3.Name = "Label3"
|
||||
Me.Label3.Size = New System.Drawing.Size(48, 13)
|
||||
Me.Label3.TabIndex = 113
|
||||
Me.Label3.Text = "LKW-KZ:"
|
||||
'
|
||||
'Label9
|
||||
'
|
||||
Me.Label9.AutoSize = True
|
||||
Me.Label9.Location = New System.Drawing.Point(6, 117)
|
||||
Me.Label9.Name = "Label9"
|
||||
Me.Label9.Size = New System.Drawing.Size(117, 13)
|
||||
Me.Label9.TabIndex = 110
|
||||
Me.Label9.Text = "Adressierte-Zollstelle:"
|
||||
'
|
||||
'sbAdressierteZollstelle
|
||||
'
|
||||
Me.sbAdressierteZollstelle._allowFreitext = False
|
||||
Me.sbAdressierteZollstelle._AllowSetValue = False
|
||||
Me.sbAdressierteZollstelle._allowSpaceAsSplitter = False
|
||||
Me.sbAdressierteZollstelle._autoSizeGross = False
|
||||
Me.sbAdressierteZollstelle._hideIfListEmpty = True
|
||||
Me.sbAdressierteZollstelle._value = ""
|
||||
Me.sbAdressierteZollstelle.conn_art = "FMZOLL"
|
||||
Me.sbAdressierteZollstelle.dgvpos = "LEFT"
|
||||
Me.sbAdressierteZollstelle.DISPLAY_PARAM = Nothing
|
||||
Me.sbAdressierteZollstelle.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!)
|
||||
Me.sbAdressierteZollstelle.INVISIBLE_COLUMNS = Nothing
|
||||
Me.sbAdressierteZollstelle.key_visible = False
|
||||
Me.sbAdressierteZollstelle.KEYPARAM = Nothing
|
||||
Me.sbAdressierteZollstelle.Location = New System.Drawing.Point(151, 112)
|
||||
Me.sbAdressierteZollstelle.Name = "sbAdressierteZollstelle"
|
||||
Me.sbAdressierteZollstelle.searchActive = True
|
||||
Me.sbAdressierteZollstelle.Size = New System.Drawing.Size(255, 23)
|
||||
Me.sbAdressierteZollstelle.SQL_ORDER_BY = Nothing
|
||||
Me.sbAdressierteZollstelle.SQL_SELECT = Nothing
|
||||
Me.sbAdressierteZollstelle.SQL_WHERE = Nothing
|
||||
Me.sbAdressierteZollstelle.SQL_WhereParamList = Nothing
|
||||
Me.sbAdressierteZollstelle.TabIndex = 111
|
||||
Me.sbAdressierteZollstelle.usrcntl = Nothing
|
||||
'
|
||||
'lblBezugsnummer
|
||||
'
|
||||
Me.lblBezugsnummer.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||
Me.lblBezugsnummer.BackColor = System.Drawing.Color.White
|
||||
Me.lblBezugsnummer.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
|
||||
Me.lblBezugsnummer.Location = New System.Drawing.Point(475, 8)
|
||||
Me.lblBezugsnummer.Name = "lblBezugsnummer"
|
||||
Me.lblBezugsnummer.Size = New System.Drawing.Size(193, 23)
|
||||
Me.lblBezugsnummer.TabIndex = 107
|
||||
Me.lblBezugsnummer.Text = "4800/000000/17 AAA"
|
||||
Me.lblBezugsnummer.TextAlign = System.Drawing.ContentAlignment.MiddleRight
|
||||
'
|
||||
'Button3
|
||||
'
|
||||
Me.Button3.Location = New System.Drawing.Point(473, 157)
|
||||
Me.Button3.Name = "Button3"
|
||||
Me.Button3.Size = New System.Drawing.Size(205, 25)
|
||||
Me.Button3.TabIndex = 152
|
||||
Me.Button3.Text = "alle Anhänge auswählen"
|
||||
Me.Button3.UseVisualStyleBackColor = True
|
||||
'
|
||||
'Label6
|
||||
'
|
||||
Me.Label6.Location = New System.Drawing.Point(9, 168)
|
||||
Me.Label6.Name = "Label6"
|
||||
Me.Label6.Size = New System.Drawing.Size(135, 13)
|
||||
Me.Label6.TabIndex = 147
|
||||
Me.Label6.Text = "Dokumente:"
|
||||
'
|
||||
'lblAnh
|
||||
'
|
||||
Me.lblAnh.Location = New System.Drawing.Point(332, 168)
|
||||
Me.lblAnh.Name = "lblAnh"
|
||||
Me.lblAnh.Size = New System.Drawing.Size(135, 13)
|
||||
Me.lblAnh.TabIndex = 151
|
||||
Me.lblAnh.Visible = False
|
||||
'
|
||||
'btnAgg_Tnr
|
||||
'
|
||||
Me.btnAgg_Tnr.BackColor = System.Drawing.Color.DeepSkyBlue
|
||||
Me.btnAgg_Tnr.Location = New System.Drawing.Point(76, 3)
|
||||
Me.btnAgg_Tnr.Name = "btnAgg_Tnr"
|
||||
Me.btnAgg_Tnr.Size = New System.Drawing.Size(83, 23)
|
||||
Me.btnAgg_Tnr.TabIndex = 154
|
||||
Me.btnAgg_Tnr.Tag = "1"
|
||||
Me.btnAgg_Tnr.Text = "Tarifnummer"
|
||||
Me.btnAgg_Tnr.UseVisualStyleBackColor = False
|
||||
'
|
||||
'Label2
|
||||
'
|
||||
Me.Label2.Font = New System.Drawing.Font("Segoe UI", 8.0!)
|
||||
Me.Label2.Location = New System.Drawing.Point(3, 8)
|
||||
Me.Label2.Name = "Label2"
|
||||
Me.Label2.Size = New System.Drawing.Size(103, 17)
|
||||
Me.Label2.TabIndex = 149
|
||||
Me.Label2.Text = "Aggregieren:"
|
||||
'
|
||||
'btnAgg_Origin
|
||||
'
|
||||
Me.btnAgg_Origin.BackColor = System.Drawing.Color.DeepSkyBlue
|
||||
Me.btnAgg_Origin.Location = New System.Drawing.Point(162, 3)
|
||||
Me.btnAgg_Origin.Name = "btnAgg_Origin"
|
||||
Me.btnAgg_Origin.Size = New System.Drawing.Size(92, 23)
|
||||
Me.btnAgg_Origin.TabIndex = 155
|
||||
Me.btnAgg_Origin.Tag = "1"
|
||||
Me.btnAgg_Origin.Text = "Ursprungsland"
|
||||
Me.btnAgg_Origin.UseVisualStyleBackColor = False
|
||||
'
|
||||
'btnAgg_Unit
|
||||
'
|
||||
Me.btnAgg_Unit.Location = New System.Drawing.Point(257, 3)
|
||||
Me.btnAgg_Unit.Name = "btnAgg_Unit"
|
||||
Me.btnAgg_Unit.Size = New System.Drawing.Size(79, 23)
|
||||
Me.btnAgg_Unit.TabIndex = 156
|
||||
Me.btnAgg_Unit.Tag = "0"
|
||||
Me.btnAgg_Unit.Text = "Maßeinheit"
|
||||
Me.btnAgg_Unit.UseVisualStyleBackColor = True
|
||||
'
|
||||
'btnAgg_desc
|
||||
'
|
||||
Me.btnAgg_desc.Location = New System.Drawing.Point(339, 3)
|
||||
Me.btnAgg_desc.Name = "btnAgg_desc"
|
||||
Me.btnAgg_desc.Size = New System.Drawing.Size(126, 23)
|
||||
Me.btnAgg_desc.TabIndex = 157
|
||||
Me.btnAgg_desc.Tag = "0"
|
||||
Me.btnAgg_desc.Text = "Warenbeschreibung"
|
||||
Me.btnAgg_desc.UseVisualStyleBackColor = True
|
||||
'
|
||||
'dgvAnhaenge
|
||||
'
|
||||
Me.dgvAnhaenge.AKTUALISIERUNGS_INTERVALL = -1
|
||||
Me.dgvAnhaenge.AllowUserToAddRows = False
|
||||
Me.dgvAnhaenge.AllowUserToDeleteRows = False
|
||||
Me.dgvAnhaenge.AllowUserToResizeColumns = False
|
||||
Me.dgvAnhaenge.AllowUserToResizeRows = False
|
||||
Me.dgvAnhaenge.BackgroundColor = System.Drawing.Color.White
|
||||
Me.dgvAnhaenge.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize
|
||||
Me.dgvAnhaenge.Columns.AddRange(New System.Windows.Forms.DataGridViewColumn() {Me.columnName})
|
||||
Me.dgvAnhaenge.Location = New System.Drawing.Point(3, 184)
|
||||
Me.dgvAnhaenge.Name = "dgvAnhaenge"
|
||||
Me.dgvAnhaenge.ReadOnly = True
|
||||
Me.dgvAnhaenge.RowHeadersVisible = False
|
||||
Me.dgvAnhaenge.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect
|
||||
Me.dgvAnhaenge.Size = New System.Drawing.Size(675, 158)
|
||||
Me.dgvAnhaenge.TabIndex = 112
|
||||
'
|
||||
'columnName
|
||||
'
|
||||
Me.columnName.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill
|
||||
Me.columnName.HeaderText = "Name"
|
||||
Me.columnName.Name = "columnName"
|
||||
Me.columnName.ReadOnly = True
|
||||
'
|
||||
'btnPrio_CommInv
|
||||
'
|
||||
Me.btnPrio_CommInv.BackColor = System.Drawing.Color.White
|
||||
Me.btnPrio_CommInv.Location = New System.Drawing.Point(76, 28)
|
||||
Me.btnPrio_CommInv.Name = "btnPrio_CommInv"
|
||||
Me.btnPrio_CommInv.Size = New System.Drawing.Size(116, 23)
|
||||
Me.btnPrio_CommInv.TabIndex = 159
|
||||
Me.btnPrio_CommInv.Tag = "0"
|
||||
Me.btnPrio_CommInv.Text = "Handelsrechnung"
|
||||
Me.btnPrio_CommInv.UseVisualStyleBackColor = False
|
||||
'
|
||||
'Label5
|
||||
'
|
||||
Me.Label5.Font = New System.Drawing.Font("Segoe UI", 8.0!)
|
||||
Me.Label5.Location = New System.Drawing.Point(3, 33)
|
||||
Me.Label5.Name = "Label5"
|
||||
Me.Label5.Size = New System.Drawing.Size(103, 17)
|
||||
Me.Label5.TabIndex = 160
|
||||
Me.Label5.Text = "Priorität:"
|
||||
'
|
||||
'btnPrio_eFatura
|
||||
'
|
||||
Me.btnPrio_eFatura.BackColor = System.Drawing.Color.White
|
||||
Me.btnPrio_eFatura.Location = New System.Drawing.Point(195, 28)
|
||||
Me.btnPrio_eFatura.Name = "btnPrio_eFatura"
|
||||
Me.btnPrio_eFatura.Size = New System.Drawing.Size(69, 23)
|
||||
Me.btnPrio_eFatura.TabIndex = 161
|
||||
Me.btnPrio_eFatura.Tag = "0"
|
||||
Me.btnPrio_eFatura.Text = "eFatura"
|
||||
Me.btnPrio_eFatura.UseVisualStyleBackColor = False
|
||||
'
|
||||
'btnPrio_Export
|
||||
'
|
||||
Me.btnPrio_Export.BackColor = System.Drawing.Color.White
|
||||
Me.btnPrio_Export.Location = New System.Drawing.Point(267, 28)
|
||||
Me.btnPrio_Export.Name = "btnPrio_Export"
|
||||
Me.btnPrio_Export.Size = New System.Drawing.Size(69, 23)
|
||||
Me.btnPrio_Export.TabIndex = 162
|
||||
Me.btnPrio_Export.Tag = "0"
|
||||
Me.btnPrio_Export.Text = "Ausfuhr"
|
||||
Me.btnPrio_Export.UseVisualStyleBackColor = False
|
||||
'
|
||||
'btnPrio_ftz
|
||||
'
|
||||
Me.btnPrio_ftz.BackColor = System.Drawing.Color.White
|
||||
Me.btnPrio_ftz.Location = New System.Drawing.Point(339, 28)
|
||||
Me.btnPrio_ftz.Name = "btnPrio_ftz"
|
||||
Me.btnPrio_ftz.Size = New System.Drawing.Size(69, 23)
|
||||
Me.btnPrio_ftz.TabIndex = 163
|
||||
Me.btnPrio_ftz.Tag = "0"
|
||||
Me.btnPrio_ftz.Text = "FTZ"
|
||||
Me.btnPrio_ftz.UseVisualStyleBackColor = False
|
||||
'
|
||||
'Panel1
|
||||
'
|
||||
Me.Panel1.BackColor = System.Drawing.SystemColors.InactiveBorder
|
||||
Me.Panel1.Controls.Add(Me.btnPrio_CommInv)
|
||||
Me.Panel1.Controls.Add(Me.btnAgg_Tnr)
|
||||
Me.Panel1.Controls.Add(Me.btnPrio_ftz)
|
||||
Me.Panel1.Controls.Add(Me.Label2)
|
||||
Me.Panel1.Controls.Add(Me.btnPrio_Export)
|
||||
Me.Panel1.Controls.Add(Me.btnAgg_Origin)
|
||||
Me.Panel1.Controls.Add(Me.btnPrio_eFatura)
|
||||
Me.Panel1.Controls.Add(Me.btnAgg_Unit)
|
||||
Me.Panel1.Controls.Add(Me.Label5)
|
||||
Me.Panel1.Controls.Add(Me.btnAgg_desc)
|
||||
Me.Panel1.Location = New System.Drawing.Point(0, 343)
|
||||
Me.Panel1.Name = "Panel1"
|
||||
Me.Panel1.Size = New System.Drawing.Size(470, 54)
|
||||
Me.Panel1.TabIndex = 164
|
||||
'
|
||||
'frmATEZ_UK_MODAL
|
||||
'
|
||||
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
|
||||
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
|
||||
Me.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink
|
||||
Me.BackColor = System.Drawing.SystemColors.InactiveBorder
|
||||
Me.ClientSize = New System.Drawing.Size(680, 409)
|
||||
Me.Controls.Add(Me.Button3)
|
||||
Me.Controls.Add(Me.lblAnh)
|
||||
Me.Controls.Add(Me.pnlHead)
|
||||
Me.Controls.Add(Me.Label6)
|
||||
Me.Controls.Add(Me.btnSend)
|
||||
Me.Controls.Add(Me.dgvAnhaenge)
|
||||
Me.Controls.Add(Me.Panel1)
|
||||
Me.Font = New System.Drawing.Font("Segoe UI", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
|
||||
Me.Icon = CType(resources.GetObject("$this.Icon"), System.Drawing.Icon)
|
||||
Me.Name = "frmATEZ_UK_MODAL"
|
||||
Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
|
||||
Me.Text = "ATEZ UK"
|
||||
Me.pnlHead.ResumeLayout(False)
|
||||
Me.pnlHead.PerformLayout()
|
||||
CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.dgvAnhaenge, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
Me.Panel1.ResumeLayout(False)
|
||||
Me.ResumeLayout(False)
|
||||
|
||||
End Sub
|
||||
Friend WithEvents btnSend As Button
|
||||
Friend WithEvents pnlHead As Panel
|
||||
Friend WithEvents lblInfo As Label
|
||||
Friend WithEvents Label6 As Label
|
||||
Friend WithEvents Label8 As Label
|
||||
Friend WithEvents cboStammreferenz As VERAG_PROG_ALLGEMEIN.MyComboBox
|
||||
Friend WithEvents txtLKWId As VERAG_PROG_ALLGEMEIN.MyTextBox
|
||||
Friend WithEvents Label3 As Label
|
||||
Friend WithEvents dgvAnhaenge As VERAG_PROG_ALLGEMEIN.MyDatagridview
|
||||
Friend WithEvents columnName As DataGridViewTextBoxColumn
|
||||
Friend WithEvents Label9 As Label
|
||||
Friend WithEvents sbAdressierteZollstelle As VERAG_PROG_ALLGEMEIN.MySearchBox
|
||||
Friend WithEvents Label1 As Label
|
||||
Friend WithEvents lblBezugsnummer As Label
|
||||
Friend WithEvents lblAnh As Label
|
||||
Friend WithEvents Button3 As Button
|
||||
Friend WithEvents Button1 As Button
|
||||
Friend WithEvents btnAgg_Tnr As Button
|
||||
Friend WithEvents Label2 As Label
|
||||
Friend WithEvents btnAgg_Origin As Button
|
||||
Friend WithEvents btnAgg_Unit As Button
|
||||
Friend WithEvents btnAgg_desc As Button
|
||||
Friend WithEvents Button2 As Button
|
||||
Friend WithEvents btnPrio_CommInv As Button
|
||||
Friend WithEvents Label5 As Label
|
||||
Friend WithEvents btnPrio_eFatura As Button
|
||||
Friend WithEvents btnPrio_Export As Button
|
||||
Friend WithEvents btnPrio_ftz As Button
|
||||
Friend WithEvents Panel1 As Panel
|
||||
Friend WithEvents PictureBox1 As PictureBox
|
||||
End Class
|
||||
1256
Aviso/ATEZ/frmATEZ_UK_MODAL.resx
Normal file
1256
Aviso/ATEZ/frmATEZ_UK_MODAL.resx
Normal file
File diff suppressed because it is too large
Load Diff
760
Aviso/ATEZ/frmATEZ_UK_MODAL.vb
Normal file
760
Aviso/ATEZ/frmATEZ_UK_MODAL.vb
Normal file
@@ -0,0 +1,760 @@
|
||||
|
||||
Imports com.esendex.sdk.optouts.models
|
||||
Imports DAKOSY_Worker
|
||||
Imports DAKOSY_Worker.eZollTypes
|
||||
Imports SDL
|
||||
Imports VERAG_PROG_ALLGEMEIN
|
||||
Imports VERAG_PROG_ALLGEMEIN.cRelayHub
|
||||
|
||||
|
||||
Public Class frmATEZ_UK_MODAL
|
||||
|
||||
Dim ART As String = ""
|
||||
Dim FilialenNr As Integer
|
||||
Dim AbfertigungsNr As Integer
|
||||
Dim JAHR As Integer = Now.ToString("yy")
|
||||
Public isSTAMMREF As Boolean = False
|
||||
Public STAMMREF As String = ""
|
||||
Public CopyFromZA_Id As Integer = -1
|
||||
Dim FIRMA_DY = VERAG_PROG_ALLGEMEIN.cAllgemein.FIRMA
|
||||
Dim ZOLL_SYSTEM = "MODALTRANS"
|
||||
Dim DY As DAKOSY_Worker.cDakosy_Zollanmeldungen = Nothing
|
||||
Public ATT As List(Of String)
|
||||
Dim AVISO As New cAviso
|
||||
Dim zusatz As String
|
||||
Dim cDy_ART As String = If(FIRMA_DY = "ATILLA", "T2", "T1")
|
||||
Dim VermerkeDAL As New cVermerkeDAL
|
||||
Dim NCTS As DAKOSY_Worker.cDakosyNCTSOut = Nothing
|
||||
Dim openExisting As Boolean = False
|
||||
Dim id As Integer = -1
|
||||
Dim dgv As DataGridView = Nothing
|
||||
Dim atez_data As cATEZ_NCTS_DATA
|
||||
' Dim atez = New cATEZ_NCTS_IN("ATEZ")
|
||||
Dim allSelected As Boolean = False
|
||||
|
||||
Property BezugsNr As String = ""
|
||||
Property SENDUNG As VERAG_PROG_ALLGEMEIN.cSendungen
|
||||
|
||||
Sub New(AVISO As VERAG_PROG_ALLGEMEIN.cAviso, SENDUNG As VERAG_PROG_ALLGEMEIN.cSendungen, JAHR As Integer, Optional _dgv As DataGridView = Nothing)
|
||||
|
||||
' Dieser Aufruf ist für den Designer erforderlich.
|
||||
InitializeComponent()
|
||||
|
||||
If _dgv IsNot Nothing Then Me.dgv = _dgv
|
||||
Me.AVISO = AVISO
|
||||
Me.SENDUNG = SENDUNG
|
||||
Me.JAHR = JAHR
|
||||
|
||||
If SENDUNG IsNot Nothing Then
|
||||
Me.FilialenNr = SENDUNG.FilialenNr
|
||||
Me.AbfertigungsNr = SENDUNG.AbfertigungsNr
|
||||
End If
|
||||
|
||||
' Fügen Sie Initialisierungen nach dem InitializeComponent()-Aufruf hinzu.
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
Sub New(_id As Integer, AVISO As VERAG_PROG_ALLGEMEIN.cAviso, SENDUNG As VERAG_PROG_ALLGEMEIN.cSendungen, JAHR As Integer)
|
||||
|
||||
' Dieser Aufruf ist für den Designer erforderlich.
|
||||
InitializeComponent()
|
||||
openExisting = True
|
||||
id = _id
|
||||
|
||||
Me.AVISO = AVISO
|
||||
Me.SENDUNG = SENDUNG
|
||||
Me.JAHR = JAHR
|
||||
|
||||
If SENDUNG IsNot Nothing Then
|
||||
Me.FilialenNr = SENDUNG.FilialenNr
|
||||
Me.AbfertigungsNr = SENDUNG.AbfertigungsNr
|
||||
End If
|
||||
|
||||
|
||||
' Fügen Sie Initialisierungen nach dem InitializeComponent()-Aufruf hinzu.
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles btnSend.Click, Button2.Click
|
||||
Try
|
||||
If Not checkMandatoryField() Then Exit Sub
|
||||
|
||||
Me.Cursor = Cursors.WaitCursor
|
||||
lblInfo.Text = ""
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' Referenz
|
||||
'----------------------------------------------------------------------
|
||||
Dim ioReference As String = lblBezugsnummer.Text & Now.ToString("ddMMyyyy_HHmmss")
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' Aggregierung
|
||||
'----------------------------------------------------------------------
|
||||
Dim AdditionalSettings As New List(Of String)
|
||||
If btnAgg_desc.Tag = 1 Then AdditionalSettings.Add("description")
|
||||
If btnAgg_Tnr.Tag = 1 Then AdditionalSettings.Add("commodity_code")
|
||||
If btnAgg_Origin.Tag = 1 Then AdditionalSettings.Add("country_of_origin")
|
||||
If btnAgg_Unit.Tag = 1 Then AdditionalSettings.Add("unit_type")
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' RelayHub Request - Modaltrans UK
|
||||
'----------------------------------------------------------------------
|
||||
|
||||
Dim environment = cRelayHubEnvironment.TEST
|
||||
Dim ATEZ_RH_EZA As New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubJobOrderRequest With {
|
||||
.environment = environment,
|
||||
.referenceNo = ioReference,
|
||||
.outputApplication = cRelayHubOutputApplication.Modaltrans,
|
||||
.regimeType = "IMPORT",
|
||||
.dispatchCountry = "TR",
|
||||
.destinationCountry = "GB",
|
||||
.additionalData = New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubAdditionalData With {
|
||||
.transaction = New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubTransaction With {
|
||||
.ioReference = ioReference
|
||||
},
|
||||
.declaration = New List(Of VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubDeclaration) From {
|
||||
New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubDeclaration With {
|
||||
.objectIdentification = New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubObjectIdentification With {
|
||||
.objectName = lblBezugsnummer.Text,
|
||||
.objectAlias = ioReference,
|
||||
.shipmentId = "123",
|
||||
.avisoId = "456"
|
||||
},
|
||||
.headerData = New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubHeaderData With {
|
||||
.agentContact = New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubAgentContact With {
|
||||
.contactPersonName = If(VERAG_PROG_ALLGEMEIN.cAllgemein.MITARBEITER.Fullname, ""),
|
||||
.contactPersonPhoneNumber = getTelefon(),
|
||||
.contactPersonPosition = "Customs Declarant",
|
||||
.contactPersonEmail = If(String.IsNullOrEmpty(VERAG_PROG_ALLGEMEIN.cAllgemein.MITARBEITER.mit_email), getDefaultMail_FIRMA(), VERAG_PROG_ALLGEMEIN.cAllgemein.MITARBEITER.mit_email)
|
||||
},
|
||||
.serviceCode = "cds",
|
||||
.docType = "import",
|
||||
.declarationType = "IMD",
|
||||
.declarantEori = "GB************",
|
||||
.procedureCodeRequested = "4000",
|
||||
.transportMeansArrivalIdentity = txtLKWId.Text,
|
||||
.transportMeansNationalityCode = If(AVISO.LKW_Nationalitaet, "")
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
.additionalSettings = New cRelayHubAdditionalSettings With {
|
||||
.combineOptions = AdditionalSettings,
|
||||
.disableOutbound = False,
|
||||
.disableDocumentConverter = False,
|
||||
.disableAiToCommon = False,
|
||||
.disableValidation = False,
|
||||
.targetLang = "en"
|
||||
}
|
||||
}
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' Vorpapier / T1
|
||||
'----------------------------------------------------------------------
|
||||
If If(SENDUNG.tblSnd_Vorpapier, "") <> "" Then
|
||||
ATEZ_RH_EZA.additionalData.declaration(0).headerData.previousAdministrativeReferenceType = "T1"
|
||||
ATEZ_RH_EZA.additionalData.declaration(0).headerData.previousAdministrativeReferenceNumber = SENDUNG.tblSnd_Vorpapier
|
||||
End If
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' Dokumente
|
||||
'----------------------------------------------------------------------
|
||||
ATEZ_RH_EZA.documents = New List(Of cRelayHub.cRelayHubDocument)
|
||||
|
||||
For Each r As DataGridViewRow In dgvAnhaenge.Rows
|
||||
Dim isSelected As Boolean = If(DBNull.Value Is r.Cells("anh_selekt").Value, False, r.Cells("anh_selekt").Value)
|
||||
|
||||
If isSelected Then
|
||||
Dim DOC As New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubDocument
|
||||
DOC.fileType = VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHub_sendToRelayHub_JobOrderRequest.getRelayHub_AnhDesc(r.Cells("anh_Art").Value)
|
||||
DOC.type = "base64"
|
||||
DOC.filename = r.Cells("anh_Name").Value
|
||||
|
||||
Try
|
||||
Dim dateiBytes As Byte() = IO.File.ReadAllBytes(VERAG_PROG_ALLGEMEIN.cDATENSERVER.GET_PDFPath_BY_DocID(r.Cells("anh_docId").Value))
|
||||
DOC.base64String = Convert.ToBase64String(dateiBytes)
|
||||
ATEZ_RH_EZA.documents.Add(DOC)
|
||||
Catch ex As Exception
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
||||
End Try
|
||||
End If
|
||||
Next
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' Adressen
|
||||
'----------------------------------------------------------------------
|
||||
ATEZ_RH_EZA.additionalData.declaration(0).addresses = New List(Of cRelayHub.cRelayHubAddress)
|
||||
|
||||
' Empfänger / Consignee
|
||||
If SENDUNG.tblSnd_EmpfaengerKdNr > 0 Then
|
||||
Dim AD As New cAdressen(SENDUNG.tblSnd_EmpfaengerKdNr)
|
||||
Dim KD As New cKunde(SENDUNG.tblSnd_EmpfaengerKdNr)
|
||||
Dim CN As New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubAddress
|
||||
|
||||
CN.addressType = "CN"
|
||||
CN.participantEORI = If(KD.EORITIN, "")
|
||||
CN.participantSubsidiaryNumber = If(KD.EORITIN_NL, "")
|
||||
CN.companyName = AD.Name_1
|
||||
CN.streetAndNumber = AD.Straße
|
||||
CN.postalCode = AD.PLZ
|
||||
CN.city = AD.Ort
|
||||
CN.countryCode = SDL.cProgramFunctions.getISO2Land(AD.LandKz)
|
||||
|
||||
ATEZ_RH_EZA.additionalData.declaration(0).addresses.Add(CN)
|
||||
ATEZ_RH_EZA.additionalData.declaration(0).headerData.destinationCountry = CN.countryCode
|
||||
ATEZ_RH_EZA.destinationCountry = CN.countryCode
|
||||
End If
|
||||
|
||||
' Absender / Consignor
|
||||
If SENDUNG.tblSnd_AbsenderKdNr > 0 Then
|
||||
Dim AD As New cAdressen(SENDUNG.tblSnd_AbsenderKdNr)
|
||||
Dim KD As New cKunde(SENDUNG.tblSnd_AbsenderKdNr)
|
||||
Dim CZ As New VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHubAddress
|
||||
|
||||
CZ.addressType = "CZ"
|
||||
CZ.participantEORI = If(KD.EORITIN, "")
|
||||
CZ.participantSubsidiaryNumber = If(KD.EORITIN_NL, "")
|
||||
CZ.companyName = AD.Name_1
|
||||
CZ.streetAndNumber = AD.Straße
|
||||
CZ.postalCode = AD.PLZ
|
||||
CZ.city = AD.Ort
|
||||
CZ.countryCode = SDL.cProgramFunctions.getISO2Land(AD.LandKz)
|
||||
|
||||
ATEZ_RH_EZA.additionalData.declaration(0).addresses.Add(CZ)
|
||||
ATEZ_RH_EZA.additionalData.declaration(0).headerData.departureCountry = CZ.countryCode
|
||||
ATEZ_RH_EZA.dispatchCountry = CZ.countryCode
|
||||
End If
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' Pflichtfelder absichern
|
||||
'----------------------------------------------------------------------
|
||||
ATEZ_RH_EZA.dispatchCountry = If(ATEZ_RH_EZA.dispatchCountry, "")
|
||||
ATEZ_RH_EZA.destinationCountry = If(ATEZ_RH_EZA.destinationCountry, "")
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' JSON anzeigen
|
||||
'----------------------------------------------------------------------
|
||||
If sender Is Button2 Then
|
||||
MsgBox(VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHub_sendToRelayHub_JobOrderRequest.getJSON(ATEZ_RH_EZA))
|
||||
Me.Cursor = Cursors.Default
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
'----------------------------------------------------------------------
|
||||
' Senden
|
||||
'----------------------------------------------------------------------
|
||||
Dim RESP = VERAG_PROG_ALLGEMEIN.cRelayHub.cRelayHub_sendToRelayHub_JobOrderRequest.query_declarations(ATEZ_RH_EZA)
|
||||
|
||||
If RESP.Success Then
|
||||
MsgBox("Erfolgreich an Modaltrans gesendet!")
|
||||
Me.Close()
|
||||
Else
|
||||
MsgBox("ERROR" & vbNewLine & RESP.Details, MsgBoxStyle.OkOnly, RESP.Message)
|
||||
End If
|
||||
|
||||
Me.Cursor = Cursors.Default
|
||||
|
||||
Catch ex As Exception
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
||||
Me.Cursor = Cursors.Default
|
||||
End Try
|
||||
End Sub
|
||||
|
||||
|
||||
Private Function getTelefon() As String
|
||||
Dim defaultDW = "200"
|
||||
Select Case VERAG_PROG_ALLGEMEIN.cAllgemein.FIRMA
|
||||
Case "ATILLA" : Return "0043 7711 28450"
|
||||
Case "AMBAR" : Return "0049 8651 9962492"
|
||||
Case "UNISPED" : defaultDW = "800"
|
||||
Case "IMEX" : defaultDW = "602"
|
||||
Case "VERAG" : defaultDW = "200"
|
||||
End Select
|
||||
|
||||
Dim dw = VERAG_PROG_ALLGEMEIN.cAllgemein.MITARBEITER.mit_durchwahl
|
||||
Return "0049 8503 7973999 " &
|
||||
If(String.IsNullOrEmpty(dw) OrElse dw.Length >= 5, defaultDW, dw)
|
||||
End Function
|
||||
Private Function getDefaultMail_FIRMA() As String
|
||||
Select Case VERAG_PROG_ALLGEMEIN.cAllgemein.FIRMA
|
||||
Case "VERAG" : Return "quickstop@verag.ag"
|
||||
Case "IMEX" : Return "steuerbescheide@imex-group.at"
|
||||
Case "UNISPED" : Return "office@unisped.at"
|
||||
Case "AMBAR" : Return "office@ambarlog.com"
|
||||
End Select
|
||||
Return "quickstop@verag.ag"
|
||||
End Function
|
||||
'Private Function sendAtezData(atezData As cATEZ_NCTS_DATA, atez As cATEZ_NCTS_IN) As Boolean
|
||||
|
||||
' Dim failreDesc As String
|
||||
|
||||
' Dim authResp = atez.authenticate("NCTS")
|
||||
' If authResp <> "200" Then
|
||||
|
||||
' failreDesc = "Authentifizierung fehlgeschlagen"
|
||||
' lblInfo.Text = failreDesc & " - " & authResp & vbNewLine & "Vorgang abgebrochen" & vbNewLine & " Bitte wiederholen!"
|
||||
' Dim resultAuthentifizierung As MsgBoxResult = MsgBox("Fehler beim Authentifizieren" & vbNewLine & failreDesc & vbNewLine & "Soll NCTS als Entwurf gespeichert werden?", vbYesNoCancel)
|
||||
|
||||
' If resultAuthentifizierung = vbYes Then
|
||||
' atezData.status = "Draft"
|
||||
' atezData.fehlerbeschreibung = failreDesc
|
||||
' Return atezData.SAVE()
|
||||
' Else
|
||||
' atezData.status = "Failure"
|
||||
' atezData.fehlerbeschreibung = failreDesc
|
||||
' Return atezData.SAVE()
|
||||
' End If
|
||||
|
||||
' Return False
|
||||
' End If
|
||||
|
||||
' atezData.sessionId = atez.sessionID
|
||||
|
||||
|
||||
' If Not atez.setJsonNCTS(atezData) Then
|
||||
' MsgBox("Fehler beim Erstellen der Daten" & vbNewLine & "Vorgang abgebrochen!")
|
||||
' atezData.status = "Failure"
|
||||
' atezData.fehlerbeschreibung = "Fehler beim Erstellen der Daten"
|
||||
' Return atezData.SAVE
|
||||
' End If
|
||||
|
||||
' If checkAttachment() Then
|
||||
' If Not atez.setJsonPDF(atezData, dgvAnhaenge) Then
|
||||
' MsgBox("Fehler beim Erstellen der PDF-Daten!" & vbNewLine & "Vorgang abgebrochen!")
|
||||
' atezData.status = "Failure"
|
||||
' atezData.fehlerbeschreibung = "Fehler beim Erstellen der PDF-Daten!"
|
||||
' Return atezData.SAVE
|
||||
' End If
|
||||
' End If
|
||||
|
||||
|
||||
' Dim azetId = atez.SendRequestWithAuthHeader("application/json", failreDesc, "/api/integrations/verag", "POST")
|
||||
|
||||
' If failreDesc <> "" Then
|
||||
' If atezData.status = "Draft" Then
|
||||
' MsgBox("Fehler beim Senden" & vbNewLine & failreDesc)
|
||||
' atezData.fehlerbeschreibung = failreDesc
|
||||
' Return atezData.SAVE()
|
||||
|
||||
' End If
|
||||
' Dim result As MsgBoxResult = MsgBox("Fehler beim Senden" & vbNewLine & failreDesc & vbNewLine & "Soll NCTS als Entwurf gespeichert werden?", vbYesNoCancel)
|
||||
' If result = vbYes Then
|
||||
' atezData.status = "Draft"
|
||||
' atezData.fehlerbeschreibung = failreDesc
|
||||
' Return atezData.SAVE()
|
||||
' Else
|
||||
' atezData.status = "Failure"
|
||||
' atezData.fehlerbeschreibung = failreDesc
|
||||
' Return atezData.SAVE()
|
||||
' End If
|
||||
|
||||
' lblInfo.Text = "Fehler in der API "
|
||||
|
||||
' Else
|
||||
|
||||
' If azetId = "-1" Then
|
||||
' atezData.fehlerbeschreibung = "Request has been sent, but no header received!"
|
||||
' Else
|
||||
' atezData.fehlerbeschreibung = ""
|
||||
' End If
|
||||
' atezData.status = "Sent"
|
||||
' atezData.atezId = IIf(azetId IsNot Nothing, azetId, "")
|
||||
' Return atezData.SAVE()
|
||||
|
||||
' End If
|
||||
|
||||
'End Function
|
||||
|
||||
Function getBezugsnr(ByRef BezugsNr)
|
||||
Dim BezugsNrTmp = ""
|
||||
BezugsNrTmp = SENDUNG.FilialenNr & "/" & SENDUNG.AbfertigungsNr
|
||||
BezugsNr = BezugsNrTmp
|
||||
zusatz = "A"
|
||||
|
||||
If dgv IsNot Nothing AndAlso dgv.Rows.Count > 0 Then
|
||||
BezugsNr = BezugsNrTmp & "/" & zusatz
|
||||
For Each r As DataGridViewRow In dgv.Rows
|
||||
If r.Cells("BezugsNr").Value = BezugsNr Then
|
||||
|
||||
If zusatz.Length = 1 Then
|
||||
zusatz = Chr(Asc(zusatz.ToString) + 1)
|
||||
Else
|
||||
zusatz = zusatz.Substring(0, 1) & Chr(Asc(zusatz.Substring(0, 2).ToString) + 1)
|
||||
End If
|
||||
|
||||
If zusatz = "Z" Then zusatz = "AA"
|
||||
End If
|
||||
BezugsNr = BezugsNrTmp & "/" & zusatz
|
||||
Next
|
||||
|
||||
End If
|
||||
|
||||
While DAKOSY_Worker.cDakosy_Zollanmeldungen.ExistsBezugsNr(BezugsNr) 'IsNot Nothing
|
||||
BezugsNr = BezugsNrTmp & "/" & zusatz
|
||||
|
||||
If zusatz.Length = 1 Then
|
||||
zusatz = Chr(Asc(zusatz.ToString) + 1)
|
||||
Else
|
||||
zusatz = zusatz.Substring(0, 1) & Chr(Asc(zusatz.Substring(0, 2).ToString) + 1)
|
||||
End If
|
||||
|
||||
If zusatz = "Z" Then zusatz = "AA"
|
||||
End While
|
||||
|
||||
lblBezugsnummer.Text = BezugsNr
|
||||
Return BezugsNr
|
||||
End Function
|
||||
|
||||
|
||||
Private Sub frmATEZNCTS_Load(sender As Object, e As EventArgs) Handles MyBase.Load
|
||||
|
||||
'Select Case FIRMA_DY
|
||||
' Case "VERAG" : txtDyMandant.Text = "VERG"
|
||||
' txtDyNiederlassung.Text = VERAG_PROG_ALLGEMEIN.cAllgemein.NIEDERLASSUNG
|
||||
|
||||
' Select Case FilialenNr
|
||||
' Case "5103" : txtDyNiederlassung.Text = "WAI"
|
||||
|
||||
' End Select
|
||||
|
||||
|
||||
' Case "ATILLA" : txtDyMandant.Text = "ATIL" : txtDyNiederlassung.Text = "SUW"
|
||||
' Case "UNISPED" : txtDyMandant.Text = "UNAT" : txtDyNiederlassung.Text = "ATSPED"
|
||||
' Case "IMEX" : txtDyMandant.Text = "IMEX" : txtDyNiederlassung.Text = "IME"
|
||||
' Case "AMBAR" : txtDyMandant.Text = "ATIL" : txtDyNiederlassung.Text = "AMBWO"
|
||||
'End Select
|
||||
FIRMA_DY = cDakosyFunftions.getFirma_DY(FilialenNr.ToString, Me, "EZA")
|
||||
'txtDyMandant.Text = cDakosyFunftions.getIOPartner(FIRMA_DY, "EZA")
|
||||
'txtDyNiederlassung.Text = cDakosyFunftions.getDivision(FIRMA_DY, "EZA")
|
||||
|
||||
'Label4.Text = If(VERAG_PROG_ALLGEMEIN.cAllgemein.MITARBEITER.mit_DAKOSY_SB, "-").ToString
|
||||
|
||||
initSeachboxes()
|
||||
lblAnh.Visible = True
|
||||
|
||||
|
||||
If openExisting Then
|
||||
|
||||
If id > 0 Then
|
||||
' atez_data = New cATEZ_NCTS_DATA(id)
|
||||
initAttachment()
|
||||
If atez_data.atezId <> "" Then
|
||||
lblInfo.Text = "Atez-ID " & atez_data.atezId
|
||||
Else
|
||||
lblInfo.Text = "Status: " & IIf(atez_data.fehlerbeschreibung <> "", atez_data.status & "- " & atez_data.fehlerbeschreibung, atez_data.status)
|
||||
End If
|
||||
|
||||
|
||||
lblBezugsnummer.Text = atez_data.VERAG_LRN
|
||||
|
||||
'cboStammreferenz.fillWithSQL("SELECT [dySr_Stammreferenz],[dySr_Bezeichnung] FROM [tblDakosy_Stammreferenzen] WHERE dySr_Land='DE' AND dySr_Verfahren='EZA' and dySr_dy_Mandant='" & txtDyMandant.Text & "' and dySr_dy_Niederlassung IN ('','" & txtDyNiederlassung.Text & "' " & If(txtDyMandant.Text = "UNAT", ", 'ATSPED' ", "") & ") and dySr_visible=1", False, "FMZOLL", True)
|
||||
'cboStammreferenz.changeItem(atez_data.DAKOSY_TemplateCode)
|
||||
'cboProzedur.changeItem(atez_data.DAKOSY_Procedure)
|
||||
|
||||
txtLKWId.Text = atez_data.LicensePlateContainerNo
|
||||
|
||||
'sbBestimmungsZollstelle.SET_VALUE(atez_data.DestinationCustomsOffice)
|
||||
sbAdressierteZollstelle.SET_VALUE(atez_data.DepartureCustomsOffice)
|
||||
|
||||
|
||||
|
||||
|
||||
If atez_data.status = "Draft" Then
|
||||
btnSend.Text = "An ATEZ senden -->"
|
||||
pnlHead.Enabled = True
|
||||
btnSend.Enabled = True
|
||||
'initAttachment()
|
||||
|
||||
Else
|
||||
btnSend.Text = "JSON"
|
||||
pnlHead.Enabled = False
|
||||
dgvAnhaenge.ReadOnly = True
|
||||
btnSend.Enabled = True
|
||||
|
||||
|
||||
End If
|
||||
|
||||
|
||||
Else
|
||||
btnSend.Enabled = False
|
||||
End If
|
||||
|
||||
Else
|
||||
' atez_data = New cATEZ_NCTS_DATA()
|
||||
initAttachment()
|
||||
'Button1.Text = "An ATEZ senden -->"
|
||||
pnlHead.Enabled = True
|
||||
|
||||
'cboStammreferenz.fillWithSQL("SELECT [dySr_Stammreferenz],[dySr_Bezeichnung] FROM [tblDakosy_Stammreferenzen] WHERE dySr_Land='DE' AND dySr_Verfahren='EZA' and dySr_dy_Mandant='" & txtDyMandant.Text & "' and dySr_dy_Niederlassung IN ('','" & txtDyNiederlassung.Text & "' " & If(txtDyMandant.Text = "UNAT", ", 'ATSPED' ", "") & ") and dySr_visible=1", False, "FMZOLL", True)
|
||||
'cboStammreferenz.changeItem("")
|
||||
|
||||
getBezugsnr(BezugsNr)
|
||||
txtLKWId.Text = AVISO.LKW_Nr
|
||||
|
||||
' sbBestimmungsZollstelle.SET_VALUE(SENDUNG.NCTS_Bestimmungszollstelle)
|
||||
|
||||
If AVISO.Grenzstelle.Replace("???", "") = "" Then
|
||||
sbAdressierteZollstelle.SET_VALUE(AVISO.Zollstelle)
|
||||
Else
|
||||
|
||||
Dim GRZ As New VERAG_PROG_ALLGEMEIN.cGrenzstelle(AVISO.Grenzstelle)
|
||||
If GRZ IsNot Nothing AndAlso GRZ.hasEntry Then
|
||||
If GRZ.grz_ZollamtDST IsNot Nothing Then
|
||||
sbAdressierteZollstelle.SET_VALUE(GRZ.grz_ZollamtDST)
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
|
||||
|
||||
End If
|
||||
'initAttachment()
|
||||
End Sub
|
||||
|
||||
Sub initAttachment()
|
||||
Dim hSQL As String = " SELECT [anh_id],anh_Datum,[anh_Name],[anh_docId],
|
||||
|
||||
case WHEN [anh_size] > 0 Then ROUND([anh_size] / 1000000,2) End as anh_size,
|
||||
[anh_Art],[anh_Typ] FROM [tblAvisoAnhaenge]
|
||||
WHERE [anh_AvisoId]=" & AVISO.AvisoID & "AND (anh_SendungsId is null OR anh_SendungsId <=0 OR anh_SendungsId='" & SENDUNG.tblSnd_SendungID & "') And anh_Typ NOT IN ('MSG', 'SONSTIGES')
|
||||
ORDER BY anh_SendungsId desc,
|
||||
case
|
||||
when [anh_Art] = 'ATR-EUR1' then 0
|
||||
when [anh_Art] = 'Rechnung' then 1
|
||||
when [anh_Art] = 'eFatura' then 1.1
|
||||
when [anh_Art] = 'CMR' then 2
|
||||
when [anh_Art] = 'Ausfuhr' then 3
|
||||
when [anh_Art] = 'Vorpapier' then 4
|
||||
when [anh_Art] = 'Packliste' then 5
|
||||
when [anh_Art] = 'Auftrag' then 6
|
||||
when [anh_Art] = 'Auftrag' then 7
|
||||
when [anh_Art] = 'Dispoliste' then 8
|
||||
when [anh_Art] = 'Vorkasse' then 9
|
||||
when [anh_Art] = 'Überweisungsbeleg' then 10
|
||||
when [anh_Art] = 'Vollmacht' then 11
|
||||
when [anh_Art] = 'ATB' then 12
|
||||
when [anh_Art] = 'ATA' then 13
|
||||
when [anh_Art] = 'Sonstiges' then 99
|
||||
when [anh_Art] ='' then 15
|
||||
|
||||
END, [anh_Reihenfolge],[anh_id]"
|
||||
|
||||
Dim dt = VermerkeDAL.Anzeigen_Vermerke(hSQL)
|
||||
|
||||
Dim col As DataColumn
|
||||
col = dt.Columns.Add("anh_selekt", GetType(Boolean))
|
||||
col.SetOrdinal(0)
|
||||
dgvAnhaenge.Columns.Clear()
|
||||
dgvAnhaenge.DataSource = dt
|
||||
If dgvAnhaenge.RowCount = 0 Then dgvAnhaenge.Columns.Clear() : Exit Sub
|
||||
|
||||
With dgvAnhaenge
|
||||
|
||||
.Enabled = True
|
||||
.ReadOnly = False
|
||||
|
||||
.RowTemplate.MinimumHeight = 30
|
||||
.AutoSizeRowsMode = DataGridViewAutoSizeRowsMode.AllCells
|
||||
.Columns("anh_id").Visible = False 'VermerkID nicht anzeigenconMenuVermerke
|
||||
.Columns("anh_docId").Visible = False 'AvisoID nicht anzeigen
|
||||
' .Columns("anh_Art").Visible = False 'AvisoID nicht anzeigen
|
||||
|
||||
.Columns("anh_selekt").Width = 25
|
||||
.Columns("anh_selekt").HeaderText = ""
|
||||
.Columns("anh_selekt").DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter
|
||||
|
||||
.Columns("anh_Datum").MinimumWidth = 50
|
||||
.Columns("anh_Datum").HeaderText = "Datum"
|
||||
.Columns("anh_Datum").DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter
|
||||
.Columns("anh_Datum").ReadOnly = True
|
||||
|
||||
|
||||
.Columns("anh_Name").MinimumWidth = 150
|
||||
.Columns("anh_Name").HeaderText = "Name"
|
||||
.Columns("anh_Name").AutoSizeMode = DataGridViewAutoSizeColumnMode.Fill
|
||||
.Columns("anh_Name").ReadOnly = True
|
||||
|
||||
.Columns("anh_Art").MinimumWidth = 50
|
||||
.Columns("anh_Art").HeaderText = "Art"
|
||||
.Columns("anh_Art").DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter
|
||||
.Columns("anh_Art").ReadOnly = True
|
||||
|
||||
.Columns("anh_Typ").Width = 50
|
||||
.Columns("anh_Typ").HeaderText = "Typ"
|
||||
.Columns("anh_Typ").DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter
|
||||
.Columns("anh_Typ").ReadOnly = True
|
||||
|
||||
.Columns("anh_size").Width = 50
|
||||
.Columns("anh_size").HeaderText = "Größe in MB"
|
||||
.Columns("anh_size").DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter
|
||||
.Columns("anh_size").ReadOnly = True
|
||||
|
||||
End With
|
||||
|
||||
For Each doc As DataGridViewRow In dgvAnhaenge.Rows
|
||||
|
||||
If Not IsDBNull(doc.Cells("anh_size").Value) AndAlso doc.Cells("anh_size").Value > 0 Then
|
||||
Dim size = (doc.Cells("anh_size").Value)
|
||||
If size < 1 Then
|
||||
doc.DefaultCellStyle.BackColor = Color.LightGreen
|
||||
ElseIf size > 1 AndAlso size < 5 Then
|
||||
doc.DefaultCellStyle.BackColor = Color.LightYellow
|
||||
Else
|
||||
doc.DefaultCellStyle.BackColor = Color.IndianRed
|
||||
End If
|
||||
End If
|
||||
|
||||
Next
|
||||
|
||||
If atez_data IsNot Nothing AndAlso atez_data.selectedDocuments <> "" Then
|
||||
|
||||
For Each doc As DataGridViewRow In dgvAnhaenge.Rows
|
||||
If atez_data.selectedDocuments.Contains(doc.Cells("anh_docId").Value) Then doc.Cells("anh_selekt").Value = True
|
||||
|
||||
Next
|
||||
End If
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
Sub initSeachboxes()
|
||||
|
||||
sbAdressierteZollstelle.initSearchBox(Me.FindForm, "[Code] ,[Code] as Nr,Description as Dienststelle,left(Code,2) as Land,[Description] +' (' +left(Code,2)+')' as display FROM [tbl_DY_ZollDE_C0141_Zollstellen]", {" [Code]", "Description"}, " (StartDate is null OR StartDate< GETDATE()) AND (EndDate is null OR EndDate> GETDATE()) ", " left(Code,2),[Description]", "Code", "display", "FMZOLL", , 400, 200, {"display", "Code"})
|
||||
'sbBestimmungsZollstelle.initSearchBox(Me.FindForm, "[Code] ,[Code] as Nr,Description as Dienststelle,left(Code,2) as Land,[Description] +' (' +left(Code,2)+')' as display FROM [tbl_DY_ZollDE_C0141_Zollstellen]", {" [Code]", "Description"}, " (StartDate is null OR StartDate< GETDATE()) AND (EndDate is null OR EndDate> GETDATE()) ", " left(Code,2),[Description]", "Code", "display", "FMZOLL", , 400, 200, {"display", "Code"})
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
|
||||
Public Function checkAttachment() As Boolean
|
||||
|
||||
Dim selectedDocuments As Boolean = False
|
||||
|
||||
For Each Row In dgvAnhaenge.Rows
|
||||
|
||||
selectedDocuments = IIf(DBNull.Value Is Row.Cells("anh_selekt").Value, False, Row.Cells("anh_selekt").Value)
|
||||
If selectedDocuments Then Exit For
|
||||
Next
|
||||
|
||||
|
||||
'If Not selectedDocuments Then
|
||||
' lblInfo.Text = "kein Anhang selektiert"
|
||||
' Cursor = Cursors.Default
|
||||
' Return selectedDocuments
|
||||
'End If
|
||||
|
||||
Return selectedDocuments
|
||||
|
||||
End Function
|
||||
|
||||
Public Function checkMandatoryField() As Boolean
|
||||
|
||||
|
||||
'TODO
|
||||
Return True
|
||||
|
||||
|
||||
End Function
|
||||
|
||||
|
||||
|
||||
Private Sub dgvAnhaenge_CellDoubleClick(sender As Object, e As DataGridViewCellEventArgs) Handles dgvAnhaenge.CellDoubleClick
|
||||
Try
|
||||
|
||||
If dgvAnhaenge.SelectedRows.Count > 0 Then
|
||||
Dim docPath = VERAG_PROG_ALLGEMEIN.cDATENSERVER.GET_PDFPath_BY_DocID(dgvAnhaenge.SelectedRows(0).Cells("anh_docId").Value)
|
||||
If Not IO.File.Exists(docPath) Then
|
||||
MsgBox("Die Datei existiert nicht!")
|
||||
Else
|
||||
If docPath.ToString.ToLower.EndsWith(".msg") Then ' MSG - Mails --> lokale Kopie, sonst Fehler (bereits von Benutzer soUndSo geöffnet)
|
||||
Dim docPathTMP = VERAG_PROG_ALLGEMEIN.cFormularManager.getTMPPath_MSG()
|
||||
System.IO.File.Copy(docPath, docPathTMP)
|
||||
Process.Start(docPathTMP)
|
||||
Else
|
||||
Process.Start(docPath)
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
|
||||
Catch ex As Exception
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
||||
End Try
|
||||
End Sub
|
||||
|
||||
|
||||
|
||||
Private Sub dgvAnhaenge_CellClick(sender As Object, e As DataGridViewCellEventArgs) Handles dgvAnhaenge.CellClick
|
||||
|
||||
Dim countAnh As Double = 0
|
||||
If dgvAnhaenge.RowCount > 0 Then
|
||||
|
||||
If dgvAnhaenge.Columns(e.ColumnIndex).Name = "anh_selekt" Then
|
||||
|
||||
If Not IsDBNull(dgvAnhaenge.CurrentRow.Cells("anh_selekt").Value) AndAlso dgvAnhaenge.CurrentRow.Cells("anh_selekt").Value = True Then
|
||||
countAnh += IIf(dgvAnhaenge.CurrentRow.Cells("anh_size").Value IsNot DBNull.Value, dgvAnhaenge.CurrentRow.Cells("anh_size").Value, 0)
|
||||
End If
|
||||
|
||||
For Each Row As DataGridViewRow In dgvAnhaenge.Rows
|
||||
If Row.Cells("anh_selekt").Value IsNot DBNull.Value AndAlso Row.Cells("anh_selekt").Value = True AndAlso Row.Cells("anh_size").Value IsNot DBNull.Value Then
|
||||
countAnh += IIf(Row.Cells("anh_size").Value IsNot DBNull.Value, Row.Cells("anh_size").Value, 0)
|
||||
End If
|
||||
Next
|
||||
|
||||
lblAnh.Text = "Anhang in MB: " & countAnh.ToString
|
||||
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub Button3_Click(sender As Object, e As EventArgs) Handles Button3.Click
|
||||
If dgvAnhaenge.RowCount > 0 Then
|
||||
Dim countAnh As Double = 0
|
||||
For Each Row As DataGridViewRow In dgvAnhaenge.Rows
|
||||
If allSelected Then
|
||||
Row.Cells("anh_selekt").Value = True
|
||||
countAnh += IIf(Row.Cells("anh_size").Value IsNot DBNull.Value, Row.Cells("anh_size").Value, 0)
|
||||
Else
|
||||
Row.Cells("anh_selekt").Value = False
|
||||
countAnh = 0
|
||||
End If
|
||||
Next
|
||||
allSelected = Not allSelected
|
||||
lblAnh.Text = "Anhang in MB: " & countAnh.ToString
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub Button1_Click_1(sender As Object, e As EventArgs) Handles Button1.Click
|
||||
cRelayHubToken.DeleteAllStores()
|
||||
End Sub
|
||||
|
||||
Private Sub Button2_Click(sender As Object, e As EventArgs) Handles btnAgg_Tnr.Click, btnAgg_desc.Click, btnAgg_Origin.Click, btnAgg_Unit.Click
|
||||
If sender.Tag = 0 Then
|
||||
sender.Tag = 1
|
||||
sender.BackColor = Color.DeepSkyBlue
|
||||
Else
|
||||
sender.Tag = 0
|
||||
sender.BackColor = SystemColors.Control
|
||||
End If
|
||||
End Sub
|
||||
Private Sub Buttonprio_Click(sender As Object, e As EventArgs) Handles btnPrio_CommInv.Click, btnPrio_ftz.Click, btnPrio_eFatura.Click, btnPrio_Export.Click
|
||||
|
||||
If sender IsNot btnPrio_CommInv Then btnPrio_CommInv.Tag = 0 : btnPrio_CommInv.BackColor = SystemColors.Control
|
||||
If sender IsNot btnPrio_eFatura Then btnPrio_eFatura.Tag = 0 : btnPrio_eFatura.BackColor = SystemColors.Control
|
||||
If sender IsNot btnPrio_Export Then btnPrio_Export.Tag = 0 : btnPrio_Export.BackColor = SystemColors.Control
|
||||
If sender IsNot btnPrio_ftz Then btnPrio_ftz.Tag = 0 : btnPrio_ftz.BackColor = SystemColors.Control
|
||||
|
||||
|
||||
If sender.Tag = 0 Then
|
||||
sender.Tag = 1
|
||||
sender.BackColor = Color.DeepSkyBlue
|
||||
Else
|
||||
sender.Tag = 0
|
||||
sender.BackColor = SystemColors.Control
|
||||
End If
|
||||
End Sub
|
||||
End Class
|
||||
Reference in New Issue
Block a user