diff --git a/SDL/Fakturierung/usrCntlFaktAbrechnung.vb b/SDL/Fakturierung/usrCntlFaktAbrechnung.vb index e157878e..6a7a6b1c 100644 --- a/SDL/Fakturierung/usrCntlFaktAbrechnung.vb +++ b/SDL/Fakturierung/usrCntlFaktAbrechnung.vb @@ -3989,7 +3989,7 @@ Nächste_Textzeile_lesen: ' RECHNUNG.DruckDatumZeit Private Sub Button9_Click(sender As Object, e As EventArgs) Handles Button9.Click If Not checkUIDNR() Then Exit Sub - getValues() + 'getValues() If RECHNUNG.Rechnungsart = "PROFORMA" And RECHNUNG.Sammelrechnung <> "0" Then MsgBox("Proforma-Rechnung nur bei Einzelrechnung möglich!") : Exit Sub If RECHNUNG.Sammelrechnung <> "0" Then MsgBox("Nur bei Einzelrechnung möglich!") : Exit Sub If RECHNUNG.Status <> 0 OrElse vbYes = MsgBox("Möchten Sie das PDF erstellen?" & vbNewLine & "Es wird eine Rechnungsnummer vergeben, die Rechnung gilt somit als gedruckt und kann nicht mehr bearbeitet werden.", vbYesNoCancel) Then @@ -4004,7 +4004,7 @@ Nächste_Textzeile_lesen: End Sub Private Sub Button4_Click(sender As Object, e As EventArgs) Handles Button4.Click - getValues() + 'getValues() If RECHNUNG.Sammelrechnung <> "0" Then MsgBox("Nur bei Einzelrechnung möglich!") : Exit Sub If RECHNUNG.Status <> 0 OrElse vbYes = MsgBox("Möchten Sie die Rechnung drucken?" & vbNewLine & "Es wird eine Rechnungsnummer vergeben, die Rechnung kann nicht mehr bearbeitet werden.", vbYesNoCancel) Then If RECHNUNG.Status <> 0 OrElse saveMe() Then @@ -4052,7 +4052,7 @@ Nächste_Textzeile_lesen: Private Sub Button8_Click(sender As Object, e As EventArgs) Handles Button8.Click, Button16.Click If Not checkUIDNR() Then Exit Sub - getValues() + 'getValues() If RECHNUNG.Sammelrechnung <> "0" Then MsgBox("Nur bei Einzelrechnung möglich!") : Exit Sub If RECHNUNG.Status <> 0 OrElse saveMe() Then ' Anhänge sichern, falls geändert diff --git a/SDL/Formulare/KDFormulare/FormulareBaukasten/usrcntlVollmacht_DE_indirekt.Designer.vb b/SDL/Formulare/KDFormulare/FormulareBaukasten/usrcntlVollmacht_DE_indirekt.Designer.vb index e46fdbf6..c5dab6ba 100644 --- a/SDL/Formulare/KDFormulare/FormulareBaukasten/usrcntlVollmacht_DE_indirekt.Designer.vb +++ b/SDL/Formulare/KDFormulare/FormulareBaukasten/usrcntlVollmacht_DE_indirekt.Designer.vb @@ -53,6 +53,10 @@ Partial Class usrcntlVollmacht_DE_indirekt Me.cboSprache = New VERAG_PROG_ALLGEMEIN.MyComboBox() Me.cbxEinmaligeVollmachtCarnetATA = New System.Windows.Forms.CheckBox() Me.txtEinmalig_CarnetATA = New VERAG_PROG_ALLGEMEIN.MyTextBox() + Me.datDatum = New System.Windows.Forms.DateTimePicker() + Me.txtOrt = New VERAG_PROG_ALLGEMEIN.MyTextBox() + Me.Label9 = New System.Windows.Forms.Label() + Me.cbxDatum = New System.Windows.Forms.CheckBox() CType(Me.pic, System.ComponentModel.ISupportInitialize).BeginInit() Me.SuspendLayout() ' @@ -140,7 +144,7 @@ Partial Class usrcntlVollmacht_DE_indirekt ' 'btn ' - Me.btn.BackgroundImage = Global.SDL.My.Resources.search + Me.btn.BackgroundImage = Global.SDL.My.Resources.Resources.search Me.btn.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom Me.btn.FlatStyle = System.Windows.Forms.FlatStyle.Flat Me.btn.Location = New System.Drawing.Point(937, 34) @@ -163,12 +167,15 @@ Partial Class usrcntlVollmacht_DE_indirekt Me.txtAnsprechpartner._DateTimeOnly = False Me.txtAnsprechpartner._numbersOnly = False Me.txtAnsprechpartner._numbersOnlyKommastellen = "" + Me.txtAnsprechpartner._numbersOnlyTrennzeichen = True Me.txtAnsprechpartner._Prozent = False Me.txtAnsprechpartner._ShortDateNew = False Me.txtAnsprechpartner._ShortDateOnly = False Me.txtAnsprechpartner._TimeOnly = False + Me.txtAnsprechpartner._TimeOnly_Seconds = False Me.txtAnsprechpartner._value = Nothing Me.txtAnsprechpartner._Waehrung = False + Me.txtAnsprechpartner._WaehrungZeichen = True Me.txtAnsprechpartner.ForeColor = System.Drawing.Color.Black Me.txtAnsprechpartner.Location = New System.Drawing.Point(653, 9) Me.txtAnsprechpartner.MaxLineLength = -1 @@ -183,12 +190,15 @@ Partial Class usrcntlVollmacht_DE_indirekt Me.txtEinmalig_RgDat._DateTimeOnly = False Me.txtEinmalig_RgDat._numbersOnly = False Me.txtEinmalig_RgDat._numbersOnlyKommastellen = "" + Me.txtEinmalig_RgDat._numbersOnlyTrennzeichen = True Me.txtEinmalig_RgDat._Prozent = False Me.txtEinmalig_RgDat._ShortDateNew = False Me.txtEinmalig_RgDat._ShortDateOnly = False Me.txtEinmalig_RgDat._TimeOnly = False + Me.txtEinmalig_RgDat._TimeOnly_Seconds = False Me.txtEinmalig_RgDat._value = Nothing Me.txtEinmalig_RgDat._Waehrung = False + Me.txtEinmalig_RgDat._WaehrungZeichen = True Me.txtEinmalig_RgDat.Enabled = False Me.txtEinmalig_RgDat.ForeColor = System.Drawing.Color.Black Me.txtEinmalig_RgDat.Location = New System.Drawing.Point(653, 162) @@ -204,12 +214,15 @@ Partial Class usrcntlVollmacht_DE_indirekt Me.txtEinmalig_RgNr._DateTimeOnly = False Me.txtEinmalig_RgNr._numbersOnly = False Me.txtEinmalig_RgNr._numbersOnlyKommastellen = "" + Me.txtEinmalig_RgNr._numbersOnlyTrennzeichen = True Me.txtEinmalig_RgNr._Prozent = False Me.txtEinmalig_RgNr._ShortDateNew = False Me.txtEinmalig_RgNr._ShortDateOnly = False Me.txtEinmalig_RgNr._TimeOnly = False + Me.txtEinmalig_RgNr._TimeOnly_Seconds = False Me.txtEinmalig_RgNr._value = Nothing Me.txtEinmalig_RgNr._Waehrung = False + Me.txtEinmalig_RgNr._WaehrungZeichen = True Me.txtEinmalig_RgNr.Enabled = False Me.txtEinmalig_RgNr.ForeColor = System.Drawing.Color.Black Me.txtEinmalig_RgNr.Location = New System.Drawing.Point(363, 162) @@ -225,12 +238,15 @@ Partial Class usrcntlVollmacht_DE_indirekt Me.txtEmail._DateTimeOnly = False Me.txtEmail._numbersOnly = False Me.txtEmail._numbersOnlyKommastellen = "" + Me.txtEmail._numbersOnlyTrennzeichen = True Me.txtEmail._Prozent = False Me.txtEmail._ShortDateNew = False Me.txtEmail._ShortDateOnly = False Me.txtEmail._TimeOnly = False + Me.txtEmail._TimeOnly_Seconds = False Me.txtEmail._value = Nothing Me.txtEmail._Waehrung = False + Me.txtEmail._WaehrungZeichen = True Me.txtEmail.ForeColor = System.Drawing.Color.Black Me.txtEmail.Location = New System.Drawing.Point(254, 136) Me.txtEmail.MaxLineLength = -1 @@ -245,12 +261,15 @@ Partial Class usrcntlVollmacht_DE_indirekt Me.txtFax._DateTimeOnly = False Me.txtFax._numbersOnly = False Me.txtFax._numbersOnlyKommastellen = "" + Me.txtFax._numbersOnlyTrennzeichen = True Me.txtFax._Prozent = False Me.txtFax._ShortDateNew = False Me.txtFax._ShortDateOnly = False Me.txtFax._TimeOnly = False + Me.txtFax._TimeOnly_Seconds = False Me.txtFax._value = Nothing Me.txtFax._Waehrung = False + Me.txtFax._WaehrungZeichen = True Me.txtFax.ForeColor = System.Drawing.Color.Black Me.txtFax.Location = New System.Drawing.Point(653, 117) Me.txtFax.MaxLineLength = -1 @@ -265,12 +284,15 @@ Partial Class usrcntlVollmacht_DE_indirekt Me.txtTel._DateTimeOnly = False Me.txtTel._numbersOnly = False Me.txtTel._numbersOnlyKommastellen = "" + Me.txtTel._numbersOnlyTrennzeichen = True Me.txtTel._Prozent = False Me.txtTel._ShortDateNew = False Me.txtTel._ShortDateOnly = False Me.txtTel._TimeOnly = False + Me.txtTel._TimeOnly_Seconds = False Me.txtTel._value = Nothing Me.txtTel._Waehrung = False + Me.txtTel._WaehrungZeichen = True Me.txtTel.ForeColor = System.Drawing.Color.Black Me.txtTel.Location = New System.Drawing.Point(254, 117) Me.txtTel.MaxLineLength = -1 @@ -285,12 +307,15 @@ Partial Class usrcntlVollmacht_DE_indirekt Me.txtEori._DateTimeOnly = False Me.txtEori._numbersOnly = False Me.txtEori._numbersOnlyKommastellen = "" + Me.txtEori._numbersOnlyTrennzeichen = True Me.txtEori._Prozent = False Me.txtEori._ShortDateNew = False Me.txtEori._ShortDateOnly = False Me.txtEori._TimeOnly = False + Me.txtEori._TimeOnly_Seconds = False Me.txtEori._value = Nothing Me.txtEori._Waehrung = False + Me.txtEori._WaehrungZeichen = True Me.txtEori.ForeColor = System.Drawing.Color.Black Me.txtEori.Location = New System.Drawing.Point(653, 98) Me.txtEori.MaxLineLength = -1 @@ -305,12 +330,15 @@ Partial Class usrcntlVollmacht_DE_indirekt Me.txtUid._DateTimeOnly = False Me.txtUid._numbersOnly = False Me.txtUid._numbersOnlyKommastellen = "" + Me.txtUid._numbersOnlyTrennzeichen = True Me.txtUid._Prozent = False Me.txtUid._ShortDateNew = False Me.txtUid._ShortDateOnly = False Me.txtUid._TimeOnly = False + Me.txtUid._TimeOnly_Seconds = False Me.txtUid._value = Nothing Me.txtUid._Waehrung = False + Me.txtUid._WaehrungZeichen = True Me.txtUid.ForeColor = System.Drawing.Color.Black Me.txtUid.Location = New System.Drawing.Point(254, 98) Me.txtUid.MaxLineLength = -1 @@ -325,12 +353,15 @@ Partial Class usrcntlVollmacht_DE_indirekt Me.txtAdresse2._DateTimeOnly = False Me.txtAdresse2._numbersOnly = False Me.txtAdresse2._numbersOnlyKommastellen = "" + Me.txtAdresse2._numbersOnlyTrennzeichen = True Me.txtAdresse2._Prozent = False Me.txtAdresse2._ShortDateNew = False Me.txtAdresse2._ShortDateOnly = False Me.txtAdresse2._TimeOnly = False + Me.txtAdresse2._TimeOnly_Seconds = False Me.txtAdresse2._value = Nothing Me.txtAdresse2._Waehrung = False + Me.txtAdresse2._WaehrungZeichen = True Me.txtAdresse2.ForeColor = System.Drawing.Color.Black Me.txtAdresse2.Location = New System.Drawing.Point(254, 72) Me.txtAdresse2.MaxLineLength = -1 @@ -345,12 +376,15 @@ Partial Class usrcntlVollmacht_DE_indirekt Me.txtAdresse1._DateTimeOnly = False Me.txtAdresse1._numbersOnly = False Me.txtAdresse1._numbersOnlyKommastellen = "" + Me.txtAdresse1._numbersOnlyTrennzeichen = True Me.txtAdresse1._Prozent = False Me.txtAdresse1._ShortDateNew = False Me.txtAdresse1._ShortDateOnly = False Me.txtAdresse1._TimeOnly = False + Me.txtAdresse1._TimeOnly_Seconds = False Me.txtAdresse1._value = Nothing Me.txtAdresse1._Waehrung = False + Me.txtAdresse1._WaehrungZeichen = True Me.txtAdresse1.ForeColor = System.Drawing.Color.Black Me.txtAdresse1.Location = New System.Drawing.Point(254, 53) Me.txtAdresse1.MaxLineLength = -1 @@ -365,12 +399,15 @@ Partial Class usrcntlVollmacht_DE_indirekt Me.txtFirma._DateTimeOnly = False Me.txtFirma._numbersOnly = False Me.txtFirma._numbersOnlyKommastellen = "" + Me.txtFirma._numbersOnlyTrennzeichen = True Me.txtFirma._Prozent = False Me.txtFirma._ShortDateNew = False Me.txtFirma._ShortDateOnly = False Me.txtFirma._TimeOnly = False + Me.txtFirma._TimeOnly_Seconds = False Me.txtFirma._value = Nothing Me.txtFirma._Waehrung = False + Me.txtFirma._WaehrungZeichen = True Me.txtFirma.ForeColor = System.Drawing.Color.Black Me.txtFirma.Location = New System.Drawing.Point(254, 34) Me.txtFirma.MaxLineLength = -1 @@ -382,7 +419,7 @@ Partial Class usrcntlVollmacht_DE_indirekt ' 'pic ' - Me.pic.BackgroundImage = Global.SDL.My.Resources.pdf + Me.pic.BackgroundImage = Global.SDL.My.Resources.Resources.pdf Me.pic.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch Me.pic.Cursor = System.Windows.Forms.Cursors.Hand Me.pic.Location = New System.Drawing.Point(5, 5) @@ -404,7 +441,7 @@ Partial Class usrcntlVollmacht_DE_indirekt 'btnDown ' Me.btnDown.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles) - Me.btnDown.BackgroundImage = Global.SDL.My.Resources.pfeil_unten + Me.btnDown.BackgroundImage = Global.SDL.My.Resources.Resources.pfeil_unten Me.btnDown.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom Me.btnDown.FlatStyle = System.Windows.Forms.FlatStyle.Flat Me.btnDown.Location = New System.Drawing.Point(976, 42) @@ -416,7 +453,7 @@ Partial Class usrcntlVollmacht_DE_indirekt 'btnUp ' Me.btnUp.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles) - Me.btnUp.BackgroundImage = Global.SDL.My.Resources.pfeil_oben + Me.btnUp.BackgroundImage = Global.SDL.My.Resources.Resources.pfeil_oben Me.btnUp.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom Me.btnUp.FlatStyle = System.Windows.Forms.FlatStyle.Flat Me.btnUp.Location = New System.Drawing.Point(976, 22) @@ -428,7 +465,7 @@ Partial Class usrcntlVollmacht_DE_indirekt 'btnDel ' Me.btnDel.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles) - Me.btnDel.BackgroundImage = Global.SDL.My.Resources.del + Me.btnDel.BackgroundImage = Global.SDL.My.Resources.Resources.del Me.btnDel.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom Me.btnDel.FlatStyle = System.Windows.Forms.FlatStyle.Flat Me.btnDel.Location = New System.Drawing.Point(976, -1) @@ -472,12 +509,15 @@ Partial Class usrcntlVollmacht_DE_indirekt Me.txtEinmalig_CarnetATA._DateTimeOnly = False Me.txtEinmalig_CarnetATA._numbersOnly = False Me.txtEinmalig_CarnetATA._numbersOnlyKommastellen = "" + Me.txtEinmalig_CarnetATA._numbersOnlyTrennzeichen = True Me.txtEinmalig_CarnetATA._Prozent = False Me.txtEinmalig_CarnetATA._ShortDateNew = False Me.txtEinmalig_CarnetATA._ShortDateOnly = False Me.txtEinmalig_CarnetATA._TimeOnly = False + Me.txtEinmalig_CarnetATA._TimeOnly_Seconds = False Me.txtEinmalig_CarnetATA._value = Nothing Me.txtEinmalig_CarnetATA._Waehrung = False + Me.txtEinmalig_CarnetATA._WaehrungZeichen = True Me.txtEinmalig_CarnetATA.Enabled = False Me.txtEinmalig_CarnetATA.ForeColor = System.Drawing.Color.Black Me.txtEinmalig_CarnetATA.Location = New System.Drawing.Point(390, 181) @@ -488,12 +528,68 @@ Partial Class usrcntlVollmacht_DE_indirekt Me.txtEinmalig_CarnetATA.Size = New System.Drawing.Size(174, 20) Me.txtEinmalig_CarnetATA.TabIndex = 34 ' - 'usrcntlVollmacht_DE + 'datDatum + ' + Me.datDatum.Format = System.Windows.Forms.DateTimePickerFormat.[Short] + Me.datDatum.Location = New System.Drawing.Point(868, 206) + Me.datDatum.Name = "datDatum" + Me.datDatum.Size = New System.Drawing.Size(95, 20) + Me.datDatum.TabIndex = 69 + ' + 'txtOrt + ' + Me.txtOrt._DateTimeOnly = False + Me.txtOrt._numbersOnly = False + Me.txtOrt._numbersOnlyKommastellen = "" + Me.txtOrt._numbersOnlyTrennzeichen = True + Me.txtOrt._Prozent = False + Me.txtOrt._ShortDateNew = False + Me.txtOrt._ShortDateOnly = False + Me.txtOrt._TimeOnly = False + Me.txtOrt._TimeOnly_Seconds = False + Me.txtOrt._value = Nothing + Me.txtOrt._Waehrung = False + Me.txtOrt._WaehrungZeichen = True + Me.txtOrt.ForeColor = System.Drawing.Color.Black + Me.txtOrt.Location = New System.Drawing.Point(687, 205) + Me.txtOrt.MaxLineLength = -1 + Me.txtOrt.MaxLines_Warning = "" + Me.txtOrt.MaxLines_Warning_Label = Nothing + Me.txtOrt.Name = "txtOrt" + Me.txtOrt.Size = New System.Drawing.Size(109, 20) + Me.txtOrt.TabIndex = 67 + ' + 'Label9 + ' + Me.Label9.AutoSize = True + Me.Label9.Location = New System.Drawing.Point(650, 212) + Me.Label9.Name = "Label9" + Me.Label9.Size = New System.Drawing.Size(24, 13) + Me.Label9.TabIndex = 66 + Me.Label9.Text = "Ort:" + ' + 'cbxDatum + ' + Me.cbxDatum.AutoSize = True + Me.cbxDatum.Checked = True + Me.cbxDatum.CheckState = System.Windows.Forms.CheckState.Checked + Me.cbxDatum.Location = New System.Drawing.Point(808, 208) + Me.cbxDatum.Name = "cbxDatum" + Me.cbxDatum.Size = New System.Drawing.Size(60, 17) + Me.cbxDatum.TabIndex = 120 + Me.cbxDatum.Text = "Datum:" + Me.cbxDatum.UseVisualStyleBackColor = True + ' + 'usrcntlVollmacht_DE_indirekt ' Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font Me.BackColor = System.Drawing.Color.WhiteSmoke Me.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.Controls.Add(Me.cbxDatum) + Me.Controls.Add(Me.datDatum) + Me.Controls.Add(Me.txtOrt) + Me.Controls.Add(Me.Label9) Me.Controls.Add(Me.txtEinmalig_CarnetATA) Me.Controls.Add(Me.cbxEinmaligeVollmachtCarnetATA) Me.Controls.Add(Me.Label12) @@ -525,8 +621,8 @@ Partial Class usrcntlVollmacht_DE_indirekt Me.Controls.Add(Me.Label1) Me.Controls.Add(Me.txtFirma) Me.Controls.Add(Me.lbl) - Me.Name = "usrcntlVollmacht_DE" - Me.Size = New System.Drawing.Size(1000, 202) + Me.Name = "usrcntlVollmacht_DE_indirekt" + Me.Size = New System.Drawing.Size(1000, 229) CType(Me.pic, System.ComponentModel.ISupportInitialize).EndInit() Me.ResumeLayout(False) Me.PerformLayout() @@ -563,5 +659,8 @@ Partial Class usrcntlVollmacht_DE_indirekt Friend WithEvents cboSprache As VERAG_PROG_ALLGEMEIN.MyComboBox Friend WithEvents cbxEinmaligeVollmachtCarnetATA As System.Windows.Forms.CheckBox Friend WithEvents txtEinmalig_CarnetATA As VERAG_PROG_ALLGEMEIN.MyTextBox - + Friend WithEvents datDatum As DateTimePicker + Friend WithEvents txtOrt As VERAG_PROG_ALLGEMEIN.MyTextBox + Friend WithEvents Label9 As Label + Friend WithEvents cbxDatum As CheckBox End Class diff --git a/SDL/Formulare/KDFormulare/frmFormulare.vb b/SDL/Formulare/KDFormulare/frmFormulare.vb index 1e6f0c0e..1d499121 100644 --- a/SDL/Formulare/KDFormulare/frmFormulare.vb +++ b/SDL/Formulare/KDFormulare/frmFormulare.vb @@ -1961,6 +1961,24 @@ Public Class FormularManagerNEU listTowrite.Add(New VERAG_PROG_ALLGEMEIN.cPDFWriteValues(usrCntl.txtFax.Text, 119, 74, 70, 6, "bold", 10, , itextsharp.text.Element.ALIGN_LEFT)) listTowrite.Add(New VERAG_PROG_ALLGEMEIN.cPDFWriteValues(usrCntl.txtEmail.Text, 40, 80, 90, 6, "bold", 8, , itextsharp.text.Element.ALIGN_LEFT)) + + If usrCntl.txtOrt.Text <> "" Then + If (IsDate(usrCntl.datDatum.Text)) AndAlso usrCntl.cbxDatum.Checked Then + listTowrite.Add(New VERAG_PROG_ALLGEMEIN.cPDFWriteValues(usrCntl.txtOrt.Text & ", " & usrCntl.datDatum.Text, 20, 269, 90, 6, "bold", 8, , itextsharp.text.Element.ALIGN_LEFT)) + End If + + Else + If (IsDate(usrCntl.datDatum.Text)) AndAlso usrCntl.cbxDatum.Checked Then + listTowrite.Add(New VERAG_PROG_ALLGEMEIN.cPDFWriteValues(usrCntl.datDatum.Text, 50, 269, 90, 6, "bold", 8, , itextsharp.text.Element.ALIGN_LEFT)) + End If + End If + + + + + + + Dim top = 0 If VERAG_PROG_ALLGEMEIN.cAllgemein.FIRMA = "IMEX" Or VERAG_PROG_ALLGEMEIN.cAllgemein.FIRMA = "AMBAR" Then top = 25 diff --git a/SDL/SDL.vbproj b/SDL/SDL.vbproj index 8b6c1fdd..3a2340d8 100644 --- a/SDL/SDL.vbproj +++ b/SDL/SDL.vbproj @@ -1275,6 +1275,7 @@ Component + usrCntlUSTV.vb @@ -1335,6 +1336,7 @@ UserControl + True True diff --git a/SDL/USTV/VATRefund.vb b/SDL/USTV/VATRefund.vb new file mode 100644 index 00000000..5d5371fc --- /dev/null +++ b/SDL/USTV/VATRefund.vb @@ -0,0 +1,218 @@ +Imports System.Xml.Serialization +Imports java.util.function +Imports javax.print.attribute.standard + + +Public Class VATRefundApplication + + + Public Property CodF1 As CodF1 + + + Public Property RefundPeriod As RefundPeriod + + + Public Property ApplicationReference As ApplicationReference + + + Public Property ProrateAdjustment As ProrateAdjustment + + + Public Property Applicant As Applicant + + + Public Property BusinessDescription As BusinessDescription + + + Public Property Representative As Representative + + + Public Property DetailedBankAccount As DetailedBankAccount + + + Public Property PurchaseInformation As PurchaseInformation + + + Public Property ImportInformation As ImportInformation + + + Public Property DocumentCopy1 As DocumentCopy1 + + + Public Property NumberOfDocuments As NumberOfDocuments + + + Public Property ApplicantSignature As ApplicantSignature + + + +End Class + +Public Class BusinessDescription + Public Property d_caen As String + Public Property CAEN As String + Public Property BusinessActivity As String +End Class + +Public Class ImportInformation + + Public Property ListOfImports As List(Of Import) +End Class + + +Public Class DocumentCopy1 + Public Property Bifa_atasament As Integer + + + Public Property Document As Document +End Class + +Public Class ApplicantSignature + Public Property NameFree As String + Public Property Position As String +End Class + + +Public Class Document + Public Property FileName As String + Public Property FileType As String + Public Property FileDescription As String + + Friend Class Drawing + End Class +End Class + +Public Class Import + Public Property SequenceNumber As Integer + Public Property ReferenceNumber As String + Public Property IssuingDate As String + Public Property ReferenceInformation As String + Public Property GoodsDescription As GoodsDescription + Public Property TransactionDescription As TransactionDescription + Public Property Deduction As Deduction + Public Property Supplier As Supplier +End Class + +Public Class Supplier + Public Property NameFree As String + Public Property AddressFree As String + Public Property CountryCode As String + Public Property Phone As String +End Class + + + + +Public Class ProrateAdjustment + Public Property Year As String + Public Property FinalProrate As String +End Class + +Public Class CodF1 + Public Property formType As String + Public Property formId As String + Public Property universalCode As String +End Class + +Public Class RefundPeriod + Public Property StartDate As String + Public Property EndDate As String +End Class + +Public Class ApplicationReference + Public Property Year As Integer + Public Property RefundingCountryCode As String + Public Property Language As String + Public Property Currency As String + Public Property ApplicationType As Integer + Public Property ReferenceNumber As String + Public Property Annual As Integer + Public Property an_r As Integer + Public Property d_rec As Integer + Public Property luna_r As Integer + Public Property cif As String + Public Property totalPlata_A As Decimal +End Class + +Public Class Applicant + Public Property NameFree As String + Public Property VATIdentificationNumber As String + Public Property AddressFree As String + Public Property PostCode As String + Public Property Phone As String + Public Property EmailAddress As String +End Class + +Public Class Representative + Public Property NameFree As String + Public Property RepresentativeID As String + Public Property AddressFree As String + Public Property PostCode As String + Public Property Phone As String + Public Property EmailAddress As String + Public Property CountryCode As String + Public Property identificationType As String +End Class + + +Public Class DetailedBankAccount + Public Property Total As Decimal + Public Property Currency As String + Public Property OwnerType As Integer + Public Property OwnerName As String + Public Property IBAN As String + Public Property BIC As String +End Class + +Public Class PurchaseInformation + + Public Property Invoices As List(Of Invoice) +End Class + +Public Class Invoice + Public Property SequenceNumber As Integer + Public Property simplifiedInvoice As Integer + Public Property ReferenceNumber As String + Public Property IssuingDate As String + Public Property GoodsDescription As GoodsDescription + Public Property TransactionDescription As TransactionDescription + Public Property Deduction As Deduction + Public Property EUSupplier As EUSupplier +End Class + + +Public Class GoodsDescription + Public Property GoodsItem As GoodsItem +End Class + +Public Class GoodsItem + Public Property Code As String + Public Property SubCode As String + Public Property FreeText As String +End Class + +Public Class TransactionDescription + Public Property TaxableAmount As Decimal + Public Property VATAmount As Decimal +End Class + +Public Class Deduction + Public Property ProRataRate As String + Public Property DeductibleVATAmount As Decimal +End Class + +Public Class EUSupplier + Public Property NameFree As String + Public Property AddressFree As String + Public Property CountryCode As String + Public Property Phone As String + Public Property EUTraderID As EUTraderID +End Class + +Public Class EUTraderID + Public Property VATIdentificationNumber As String +End Class + + + + diff --git a/SDL/USTV/VATRefundMapper.vb b/SDL/USTV/VATRefundMapper.vb new file mode 100644 index 00000000..1f9af57f --- /dev/null +++ b/SDL/USTV/VATRefundMapper.vb @@ -0,0 +1,143 @@ +Imports javax.print.attribute.standard +Imports VERAG_PROG_ALLGEMEIN + +Public Class VATRefundMapper + + Public Shared Function BuildApplication(year As Integer, startMonth As Integer, endMonth As Integer, invoices As DataTable, company As cFirmen, ANTRAG As cUSTVAntrag) As VATRefundApplication + + Dim app As New VATRefundApplication() + + ' ================= HEADER ================= + app.CodF1 = New CodF1 With { + .formType = "D318", + .formId = "318", + .universalCode = "D318_A1.0.0" + } + + app.RefundPeriod = New RefundPeriod With { + .StartDate = startMonth.ToString("00"), + .EndDate = endMonth.ToString("00") + } + + ' ================= APPLICATION REF ================= + app.ApplicationReference = New ApplicationReference With { + .Year = year, + .RefundingCountryCode = ANTRAG.UStVAn_LandKz, + .Language = "DE", + .Currency = ANTRAG.UStVAn_Währungscode, + .ApplicationType = 1, + .Annual = 0, + .an_r = year, + .d_rec = 0, + .luna_r = endMonth, + .cif = "", + .totalPlata_A = invoices.AsEnumerable(). + Sum(Function(r) CDec(r!VatAmount)) + } + + ' ================= PRORATE ================= + app.ProrateAdjustment = New ProrateAdjustment() + + ' ================= APPLICANT ================= + app.Applicant = New Applicant With { + .NameFree = company.Firma_Bez, + .VATIdentificationNumber = company.Firma_UID, + .AddressFree = company.Firma_Straße + " " + company.Firma_PLZ + " " + company.Firma_Ort, + .EmailAddress = company.Firma_E_Mail + } + + ' ================= BUSINESS ================= + app.BusinessDescription = New BusinessDescription With { + .d_caen = "2", + .CAEN = "4941--Transp.rutiere de marfuri", + .BusinessActivity = "4941" + } + + ' ================= BANK ================= + app.DetailedBankAccount = New DetailedBankAccount With { + .Total = invoices.AsEnumerable(). + Sum(Function(r) CDec(r!VatAmount)), + .Currency = "EUR", + .OwnerType = 1, + .OwnerName = company.Firma_Bankverbindung1, + .IBAN = company.Firma_IBAN1, + .BIC = company.Firma_BIC1 + } + + ' ================= PURCHASES ================= + app.PurchaseInformation = BuildPurchaseInformation(invoices) + + ' ================= IMPORTS (leer) ================= + app.ImportInformation = New ImportInformation With { + .ListOfImports = New List(Of Import)() + } + + ' ================= ATTACHMENTS ================= + 'app.DocumentCopy1 = New DocumentCopy1 With { + ' .Bifa_atasament = 1, + ' .Document = New Document With { + ' .FileName = "INVOICES.zip", + ' .FileType = "application/zip", + ' .FileDescription = "INVOICES" + ' } + '} + + 'app.NumberOfDocuments = New NumberOfDocuments With { + ' .AtachatedFiles = 0, + ' .PurchaseOrders = invoices.Rows.Count, + ' .ImportOrders = 0 + '} + + app.ApplicantSignature = New ApplicantSignature() + + Return app + End Function + + Private Shared Function BuildPurchaseInformation( + invoices As DataTable +) As PurchaseInformation + + Dim result As New PurchaseInformation With { + .Invoices = New List(Of Invoice)() + } + + Dim seq As Integer = 1 + + For Each r As DataRow In invoices.Rows + + Dim inv As New Invoice With { + .SequenceNumber = seq, + .simplifiedInvoice = 0, + .ReferenceNumber = r!InvoiceNo.ToString(), + .IssuingDate = CDate(r!InvoiceDate).ToString("yyyy-MM-dd"), + .GoodsDescription = New GoodsDescription With { + .GoodsItem = New GoodsItem With { + .Code = r!GoodsCode.ToString(), + .SubCode = r!GoodsSubCode.ToString() + } + }, + .TransactionDescription = New TransactionDescription With { + .TaxableAmount = CDec(r!NetAmount), + .VATAmount = CDec(r!VatAmount) + }, + .Deduction = New Deduction With { + .DeductibleVATAmount = CDec(r!VatAmount) + }, + .EUSupplier = New EUSupplier With { + .NameFree = r!SupplierName.ToString(), + .AddressFree = r!SupplierAddress.ToString(), + .CountryCode = "AT", + .EUTraderID = New EUTraderID With { + .VATIdentificationNumber = r!SupplierVatId.ToString() + } + } + } + + result.Invoices.Add(inv) + seq += 1 + Next + + Return result + End Function + +End Class diff --git a/SDL/USTV/frmMDM_USTVAntrag.Designer.vb b/SDL/USTV/frmMDM_USTVAntrag.Designer.vb index bdb90c5f..3a67ac4e 100644 --- a/SDL/USTV/frmMDM_USTVAntrag.Designer.vb +++ b/SDL/USTV/frmMDM_USTVAntrag.Designer.vb @@ -27,6 +27,8 @@ Partial Class frmMDM_USTVAntrag Dim DataGridViewCellStyle1 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() Dim DataGridViewCellStyle2 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() Me.pnlBottom = New System.Windows.Forms.Panel() + Me.PictureBox1 = New System.Windows.Forms.PictureBox() + Me.btnRMCQuartal = New System.Windows.Forms.Button() Me.Label18 = New System.Windows.Forms.Label() Me.txtSumme = New VERAG_PROG_ALLGEMEIN.MyTextBox() Me.pbMail = New System.Windows.Forms.PictureBox() @@ -144,8 +146,8 @@ Partial Class frmMDM_USTVAntrag Me.ToolStripMenuItem2 = New System.Windows.Forms.ToolStripMenuItem() Me.ToolStripMenuItem3 = New System.Windows.Forms.ToolStripMenuItem() Me.FakturiertToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() - Me.btnRMCQuartal = New System.Windows.Forms.Button() Me.pnlBottom.SuspendLayout() + CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).BeginInit() CType(Me.pbMail, System.ComponentModel.ISupportInitialize).BeginInit() CType(Me.pb_Beleg, System.ComponentModel.ISupportInitialize).BeginInit() CType(Me.picExcel, System.ComponentModel.ISupportInitialize).BeginInit() @@ -176,6 +178,7 @@ Partial Class frmMDM_USTVAntrag ' Me.pnlBottom.BackColor = System.Drawing.Color.FromArgb(CType(CType(224, Byte), Integer), CType(CType(224, Byte), Integer), CType(CType(224, Byte), Integer)) Me.pnlBottom.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle + Me.pnlBottom.Controls.Add(Me.PictureBox1) Me.pnlBottom.Controls.Add(Me.btnRMCQuartal) Me.pnlBottom.Controls.Add(Me.Label18) Me.pnlBottom.Controls.Add(Me.txtSumme) @@ -198,6 +201,29 @@ Partial Class frmMDM_USTVAntrag Me.pnlBottom.Size = New System.Drawing.Size(1444, 100) Me.pnlBottom.TabIndex = 3 ' + 'PictureBox1 + ' + Me.PictureBox1.Image = Global.SDL.My.Resources.Resources.xml + Me.PictureBox1.Location = New System.Drawing.Point(1203, 10) + Me.PictureBox1.Name = "PictureBox1" + Me.PictureBox1.Size = New System.Drawing.Size(35, 35) + Me.PictureBox1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom + Me.PictureBox1.TabIndex = 56 + Me.PictureBox1.TabStop = False + ' + 'btnRMCQuartal + ' + Me.btnRMCQuartal.FlatStyle = System.Windows.Forms.FlatStyle.Flat + Me.btnRMCQuartal.ForeColor = System.Drawing.Color.Black + Me.btnRMCQuartal.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft + Me.btnRMCQuartal.Location = New System.Drawing.Point(752, 17) + Me.btnRMCQuartal.Name = "btnRMCQuartal" + Me.btnRMCQuartal.Size = New System.Drawing.Size(103, 39) + Me.btnRMCQuartal.TabIndex = 55 + Me.btnRMCQuartal.Text = "RMC Quartal" + Me.btnRMCQuartal.UseVisualStyleBackColor = True + Me.btnRMCQuartal.Visible = False + ' 'Label18 ' Me.Label18.AutoSize = True @@ -236,7 +262,7 @@ Partial Class frmMDM_USTVAntrag 'pbMail ' Me.pbMail.Image = CType(resources.GetObject("pbMail.Image"), System.Drawing.Image) - Me.pbMail.Location = New System.Drawing.Point(1097, 8) + Me.pbMail.Location = New System.Drawing.Point(1080, 8) Me.pbMail.Name = "pbMail" Me.pbMail.Size = New System.Drawing.Size(35, 35) Me.pbMail.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom @@ -305,7 +331,7 @@ Partial Class frmMDM_USTVAntrag 'picExcel ' Me.picExcel.Image = CType(resources.GetObject("picExcel.Image"), System.Drawing.Image) - Me.picExcel.Location = New System.Drawing.Point(1145, 8) + Me.picExcel.Location = New System.Drawing.Point(1121, 8) Me.picExcel.Name = "picExcel" Me.picExcel.Size = New System.Drawing.Size(35, 35) Me.picExcel.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom @@ -327,7 +353,7 @@ Partial Class frmMDM_USTVAntrag 'picPDF ' Me.picPDF.Image = CType(resources.GetObject("picPDF.Image"), System.Drawing.Image) - Me.picPDF.Location = New System.Drawing.Point(1198, 8) + Me.picPDF.Location = New System.Drawing.Point(1162, 10) Me.picPDF.Name = "picPDF" Me.picPDF.Size = New System.Drawing.Size(35, 35) Me.picPDF.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom @@ -1850,19 +1876,6 @@ Partial Class frmMDM_USTVAntrag Me.FakturiertToolStripMenuItem.Text = "Fakturiert zurücksetzen" Me.FakturiertToolStripMenuItem.Visible = False ' - 'btnRMCQuartal - ' - Me.btnRMCQuartal.FlatStyle = System.Windows.Forms.FlatStyle.Flat - Me.btnRMCQuartal.ForeColor = System.Drawing.Color.Black - Me.btnRMCQuartal.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft - Me.btnRMCQuartal.Location = New System.Drawing.Point(752, 17) - Me.btnRMCQuartal.Name = "btnRMCQuartal" - Me.btnRMCQuartal.Size = New System.Drawing.Size(103, 39) - Me.btnRMCQuartal.TabIndex = 55 - Me.btnRMCQuartal.Text = "RMC Quartal" - Me.btnRMCQuartal.UseVisualStyleBackColor = True - Me.btnRMCQuartal.Visible = False - ' 'frmMDM_USTVAntrag ' Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) @@ -1878,6 +1891,7 @@ Partial Class frmMDM_USTVAntrag Me.Text = "USTV Antrag" Me.pnlBottom.ResumeLayout(False) Me.pnlBottom.PerformLayout() + CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).EndInit() CType(Me.pbMail, System.ComponentModel.ISupportInitialize).EndInit() CType(Me.pb_Beleg, System.ComponentModel.ISupportInitialize).EndInit() CType(Me.picExcel, System.ComponentModel.ISupportInitialize).EndInit() @@ -2031,4 +2045,5 @@ Partial Class frmMDM_USTVAntrag Friend WithEvents Label18 As Label Friend WithEvents txtSumme As VERAG_PROG_ALLGEMEIN.MyTextBox Friend WithEvents btnRMCQuartal As Button + Friend WithEvents PictureBox1 As PictureBox End Class diff --git a/SDL/USTV/frmMDM_USTVAntrag.vb b/SDL/USTV/frmMDM_USTVAntrag.vb index f7193375..2c671e23 100644 --- a/SDL/USTV/frmMDM_USTVAntrag.vb +++ b/SDL/USTV/frmMDM_USTVAntrag.vb @@ -1,6 +1,8 @@ Imports System.IO Imports System.Reflection +Imports System.Text Imports System.Windows.Documents +Imports System.Xml.Serialization Imports com.sun.crypto.provider Imports GrapeCity.SpreadBuilder Imports itextsharp.text.pdf @@ -542,7 +544,7 @@ Public Class frmMDM_USTVAntrag End If Else - Dim sqlWhere As String = "" + Dim sqlWhere As String = "" 'neuer USTVA-Antrag KdSearchBox1.Visible = True cbxWahrung.Enabled = True @@ -1161,8 +1163,8 @@ Public Class frmMDM_USTVAntrag USTV_POS.UStVPo_Leistungsbezeichnung = r.Item("specification_page_name") Dim leistender As New cUStVLeistender("MS Europe BV" & " " & Antrag_LandKz, Antrag_LandKz) - If leistender.UStV_LeistenderId <1 Then - leistender= New cUStVLeistender("MS Europe BV") + If leistender.UStV_LeistenderId < 1 Then + leistender = New cUStVLeistender("MS Europe BV") End If USTV_POS.UStVPo_Leistender = leistender.UStV_Leistender.ToString @@ -1339,65 +1341,65 @@ Public Class frmMDM_USTVAntrag Select Case Antrag_LandKz - Case "RO" - leistenderName = "Kuwait Petroleum Romania S.R.L" - Case "SE" - leistenderName = "OK-Q8 AB" - Case "DK" - leistenderName = "Q8 Danmark A/S" - Case "PL" - leistenderName = "Kuwait Petroleum Sp. Z.o.o" - Case "DE" - leistenderName = "Kuwait Petroleum Gmbh" - Case "IT" - leistenderName = "Kuwait Petroleum Italie Spa" - Case "ES" - leistenderName = "Fuel Iberia S.L.U" - Case Else + Case "RO" + leistenderName = "Kuwait Petroleum Romania S.R.L" + Case "SE" + leistenderName = "OK-Q8 AB" + Case "DK" + leistenderName = "Q8 Danmark A/S" + Case "PL" + leistenderName = "Kuwait Petroleum Sp. Z.o.o" + Case "DE" + leistenderName = "Kuwait Petroleum Gmbh" + Case "IT" + leistenderName = "Kuwait Petroleum Italie Spa" + Case "ES" + leistenderName = "Fuel Iberia S.L.U" + Case Else leistenderName = IIf(Not useNewAdress, "IDS EUROPE B.V.", "Q8Truck International B.V.") End Select Dim leistender As New cUStVLeistender(leistenderName & " " & Antrag_LandKz, Antrag_LandKz) - If leistender.UStV_LeistenderId < 1 Then - leistender = New cUStVLeistender(leistenderName) - End If - - USTV_POS.UStVPo_Leistender = leistender.UStV_Leistender.ToString - - USTV_POS.UStVPo_Sachbearbeiter = VERAG_PROG_ALLGEMEIN.cAllgemein.USRKURZNAME - USTV_POS.UStVPo_Zeitstempel = Now() - - - Dim umrechKurs As Double = 1 - - 'TODO: IDS liefert Beträge immer in EUR, wir müssen allerdings die Beträge in FREMDW umrechnen, ev. bei IDS nachfragen, ob wir den Fremdwährungsbetrag bekommen können (würde uns einige manuelle Arbeit ersparen oder zumindest den Umrechnungskurs, das IDS einen Mischsatz verwendet und nicht den Umrechnungskurs vom Rechnungsdatum)!! - - Dim UST_EUR = CDbl(r.Item("Steuerbetrag")) 'ist immer EUR - Dim UST_org = CDbl(r.Item("Steuerbetrag")) - - If USTV_ANTRAG.UStVAn_Währungscode <> "EUR" Then - Dim kurs As New cEZB_Waehrungskurse(USTV_ANTRAG.UStVAn_Währungscode) - UST_org = Math.Round(kurs.EXCHANGE_EURTOCUR(UST_EUR, USTV_ANTRAG.UStVAn_Währungscode, CDate(USTV_POS.UStVPo_ReDat)), 2) - End If - - If (UST_org <> 0 AndAlso UST_org <> UST_EUR) Then - umrechKurs = Math.Floor((UST_org / UST_EUR * 100 + 0.5)) / 100 - End If - - - If UST_org <> 0 Then - USTV_POS.UStVPo_USteuerbetragEUR = UST_EUR - USTV_POS.UStVPo_Umrechnungskurs = umrechKurs - USTV_POS.UStVPo_USteuerbetrag = UST_org - End If - - If USTV_POS.INSERT() Then - cIDS.UPDATE_ARCHIV(USTV_POS.UStVPo_ReDat, USTV_POS.UStVPo_ReNr, kdnr, Antrag_LandKz, USTV_POS.UStVAn_ID) - End If - 'tblUStVPositionen + If leistender.UStV_LeistenderId < 1 Then + leistender = New cUStVLeistender(leistenderName) End If + USTV_POS.UStVPo_Leistender = leistender.UStV_Leistender.ToString + + USTV_POS.UStVPo_Sachbearbeiter = VERAG_PROG_ALLGEMEIN.cAllgemein.USRKURZNAME + USTV_POS.UStVPo_Zeitstempel = Now() + + + Dim umrechKurs As Double = 1 + + 'TODO: IDS liefert Beträge immer in EUR, wir müssen allerdings die Beträge in FREMDW umrechnen, ev. bei IDS nachfragen, ob wir den Fremdwährungsbetrag bekommen können (würde uns einige manuelle Arbeit ersparen oder zumindest den Umrechnungskurs, das IDS einen Mischsatz verwendet und nicht den Umrechnungskurs vom Rechnungsdatum)!! + + Dim UST_EUR = CDbl(r.Item("Steuerbetrag")) 'ist immer EUR + Dim UST_org = CDbl(r.Item("Steuerbetrag")) + + If USTV_ANTRAG.UStVAn_Währungscode <> "EUR" Then + Dim kurs As New cEZB_Waehrungskurse(USTV_ANTRAG.UStVAn_Währungscode) + UST_org = Math.Round(kurs.EXCHANGE_EURTOCUR(UST_EUR, USTV_ANTRAG.UStVAn_Währungscode, CDate(USTV_POS.UStVPo_ReDat)), 2) + End If + + If (UST_org <> 0 AndAlso UST_org <> UST_EUR) Then + umrechKurs = Math.Floor((UST_org / UST_EUR * 100 + 0.5)) / 100 + End If + + + If UST_org <> 0 Then + USTV_POS.UStVPo_USteuerbetragEUR = UST_EUR + USTV_POS.UStVPo_Umrechnungskurs = umrechKurs + USTV_POS.UStVPo_USteuerbetrag = UST_org + End If + + If USTV_POS.INSERT() Then + cIDS.UPDATE_ARCHIV(USTV_POS.UStVPo_ReDat, USTV_POS.UStVPo_ReNr, kdnr, Antrag_LandKz, USTV_POS.UStVAn_ID) + End If + 'tblUStVPositionen + End If + Next End If @@ -3764,19 +3766,19 @@ Public Class frmMDM_USTVAntrag If listOfTextconserven.LIST.Any(Function(c) c.txt_sprache = spracheRechnung) Then - Dim r As cTextkonserve = listOfTextconserven.LIST.Find(Function(c) c.txt_sprache = spracheRechnung) - If r IsNot Nothing Then - - Mail.Subject = r.txt_betreff - Mail.Subject = Mail.Subject.Replace("%KdNr%", USTV_ANTRAG.UStVAn_KuNr) - Mail.Subject = Mail.Subject.Replace("%KdName%", USTV_ANTRAG.UStVAn_Name) - mailText = r.txt_text - End If - + Dim r As cTextkonserve = listOfTextconserven.LIST.Find(Function(c) c.txt_sprache = spracheRechnung) + If r IsNot Nothing Then + Mail.Subject = r.txt_betreff + Mail.Subject = Mail.Subject.Replace("%KdNr%", USTV_ANTRAG.UStVAn_KuNr) + Mail.Subject = Mail.Subject.Replace("%KdName%", USTV_ANTRAG.UStVAn_Name) + mailText = r.txt_text End If - Select Case spracheRechnung + + End If + + Select Case spracheRechnung Case "DE" : Attachmens_Bez = "Lief.-Rechn" : Attachmens_Bez_POS = "POS-Liste" Case "EN", "TR" : Attachmens_Bez = "Supplier-Invoice(s)" : Attachmens_Bez_POS = "Item-List" Case "RO" : Attachmens_Bez = "Factura-furnizorului" : Attachmens_Bez_POS = "Lista-articolelor" @@ -3805,7 +3807,7 @@ Public Class frmMDM_USTVAntrag End If - End If + End If Dim TextHTML = "" @@ -3919,7 +3921,7 @@ Public Class frmMDM_USTVAntrag End If -Return "" + Return "" End Function @@ -3944,6 +3946,60 @@ Return "" + End Sub + + Private Sub PictureBox1_Click(sender As Object, e As EventArgs) Handles PictureBox1.Click + + + Me.Cursor = Cursors.WaitCursor + + If dgvUSTVPositionen.SelectedRows.Count = 0 Then Exit Sub + + + + Try + + Dim dtInvoices As New DataTable + + Dim FIRMA As New cFirmen(VERAG_PROG_ALLGEMEIN.cAllgemein.FIRMA_ID) + + + + For Each row As DataGridViewRow In dgvUSTVPositionen.SelectedRows.Cast(Of DataGridViewRow)().OrderBy(Function(dgvr) dgvr.Index) + + + + Next + + Dim sPath As String = Environment.GetFolderPath(Environment.SpecialFolder.Personal) & "\VERAG\MDM\tmp\" + + + + ' sicherstellen, dass das Verzeichnis existiert + If Not Directory.Exists(sPath) Then + Directory.CreateDirectory(sPath) + End If + + Dim fn As String = Path.Combine(sPath, "D318.xml") + + Dim app = VATRefundMapper.BuildApplication(CDate(USTV_ANTRAG.UStVAn_ReDatVon).Year, CDate(USTV_ANTRAG.UStVAn_ReDatVon).Month, CDate(USTV_ANTRAG.UStVAn_ReDatBis).Month, dtInvoices, FIRMA, USTV_ANTRAG) + + Dim ser As New XmlSerializer(GetType(VATRefundApplication)) + + Using sw As New StreamWriter("VATRefund.xml", False, Encoding.UTF8) + ser.Serialize(sw, app) + End Using + + + + + 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 PDFInvoicesPath(ByRef posId As String) As String diff --git a/SDL/kunden/frmKundenUebersichtZOLL.Designer.vb b/SDL/kunden/frmKundenUebersichtZOLL.Designer.vb index 07186471..06298b5d 100644 --- a/SDL/kunden/frmKundenUebersichtZOLL.Designer.vb +++ b/SDL/kunden/frmKundenUebersichtZOLL.Designer.vb @@ -22,7 +22,6 @@ Partial Class frmKundenUebersichtZOLL 'Das Bearbeiten mit dem Code-Editor ist nicht möglich. Private Sub InitializeComponent() - Me.components = New System.ComponentModel.Container() Dim DataGridViewCellStyle1 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() Dim DataGridViewCellStyle2 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() Dim DataGridViewCellStyle3 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() @@ -30,19 +29,17 @@ Partial Class frmKundenUebersichtZOLL Dim DataGridViewCellStyle5 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() Dim DataGridViewCellStyle6 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() Dim resources As System.ComponentModel.ComponentResourceManager = New System.ComponentModel.ComponentResourceManager(GetType(frmKundenUebersichtZOLL)) - Me.ContextMenuStrip1 = New System.Windows.Forms.ContextMenuStrip(Me.components) + Me.ContextMenuStrip1 = New System.Windows.Forms.ContextMenuStrip() Me.KopierenToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.tabZolltarife = New System.Windows.Forms.TabPage() Me.pnlZollTarife = New System.Windows.Forms.Panel() Me.tabKundendaten = New System.Windows.Forms.TabPage() Me.rtbInfo = New System.Windows.Forms.RichTextBox() Me.lblAbfertigungsverbot = New System.Windows.Forms.Label() - Me.usrcntlKundenuebersicht = New SDL.usrCntlKundenuebersicht() - Me.ContextMenuStrip2 = New System.Windows.Forms.ContextMenuStrip(Me.components) + Me.ContextMenuStrip2 = New System.Windows.Forms.ContextMenuStrip() Me.ToolStripMenuItem2 = New System.Windows.Forms.ToolStripMenuItem() Me.tbcntrKundenDaten = New System.Windows.Forms.TabControl() Me.TabPage1 = New System.Windows.Forms.TabPage() - Me.UsrCntlOfferte1 = New SDL.usrCntlOfferte() Me.tbStatistik = New System.Windows.Forms.TabPage() Me.cboKundenblattFirma = New VERAG_PROG_ALLGEMEIN.MyComboBox() Me.Button1 = New System.Windows.Forms.Button() @@ -89,10 +86,10 @@ Partial Class frmKundenUebersichtZOLL Me.btnSpeichern = New System.Windows.Forms.Button() Me.Label35 = New System.Windows.Forms.Label() Me.tbRechnungen = New System.Windows.Forms.TabPage() - Me.dgvRg = New VERAG_PROG_ALLGEMEIN.MyDatagridview(Me.components) - Me.MyPanel1 = New VERAG_PROG_ALLGEMEIN.MyPanel(Me.components) + Me.dgvRg = New VERAG_PROG_ALLGEMEIN.MyDatagridview() + Me.MyPanel1 = New VERAG_PROG_ALLGEMEIN.MyPanel() Me.btnRgPdf = New System.Windows.Forms.Button() - Me.ctxtRg = New System.Windows.Forms.ContextMenuStrip(Me.components) + Me.ctxtRg = New System.Windows.Forms.ContextMenuStrip() Me.DateiHochladenToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.btnMonat = New System.Windows.Forms.Button() Me.Button10 = New System.Windows.Forms.Button() @@ -100,9 +97,8 @@ Partial Class frmKundenUebersichtZOLL Me.Label40 = New System.Windows.Forms.Label() Me.tbSpeditionsbuch = New System.Windows.Forms.TabPage() Me.tbFiskaluebersicht = New System.Windows.Forms.TabPage() - Me.UsrcntlFiskaluebersicht1 = New SDL.usrcntlFiskaluebersicht() Me.tbCBAM = New System.Windows.Forms.TabPage() - Me.NotifyIcon1 = New System.Windows.Forms.NotifyIcon(Me.components) + Me.NotifyIcon1 = New System.Windows.Forms.NotifyIcon() Me.Panel1 = New System.Windows.Forms.Panel() Me.MenuStripKunden = New System.Windows.Forms.MenuStrip() Me.mnueKunden = New System.Windows.Forms.ToolStripMenuItem() @@ -149,8 +145,8 @@ Partial Class frmKundenUebersichtZOLL Me.lblTESTSystem = New System.Windows.Forms.Label() Me.pic = New System.Windows.Forms.PictureBox() Me.KdSearchBox1 = New VERAG_PROG_ALLGEMEIN.KdSearchBox() - Me.tmrFiskal = New System.Windows.Forms.Timer(Me.components) - Me.ContextMenuStrip3 = New System.Windows.Forms.ContextMenuStrip(Me.components) + Me.tmrFiskal = New System.Windows.Forms.Timer() + Me.ContextMenuStrip3 = New System.Windows.Forms.ContextMenuStrip() Me.ToolStripMenuItem3 = New System.Windows.Forms.ToolStripMenuItem() Me.ÄndernToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.HochladenToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() @@ -158,6 +154,10 @@ Partial Class frmKundenUebersichtZOLL Me.PDFLöschenToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.DataGridViewTextBoxColumn1 = New System.Windows.Forms.DataGridViewTextBoxColumn() Me.DataGridViewTextBoxColumn2 = New System.Windows.Forms.DataGridViewTextBoxColumn() + Me.usrcntlKundenuebersicht = New SDL.usrCntlKundenuebersicht() + Me.UsrCntlOfferte1 = New SDL.usrCntlOfferte() + Me.UsrcntlFiskaluebersicht1 = New SDL.usrcntlFiskaluebersicht() + Me.ZollvollmachtDEIndirektToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.ContextMenuStrip1.SuspendLayout() Me.tabZolltarife.SuspendLayout() Me.tabKundendaten.SuspendLayout() @@ -205,7 +205,7 @@ Partial Class frmKundenUebersichtZOLL Me.tabZolltarife.Location = New System.Drawing.Point(4, 25) Me.tabZolltarife.Name = "tabZolltarife" Me.tabZolltarife.Padding = New System.Windows.Forms.Padding(3) - Me.tabZolltarife.Size = New System.Drawing.Size(1182, 697) + Me.tabZolltarife.Size = New System.Drawing.Size(1182, 750) Me.tabZolltarife.TabIndex = 1 Me.tabZolltarife.Text = "Kunden - Zolltarife" Me.tabZolltarife.UseVisualStyleBackColor = True @@ -216,7 +216,7 @@ Partial Class frmKundenUebersichtZOLL Me.pnlZollTarife.Dock = System.Windows.Forms.DockStyle.Fill Me.pnlZollTarife.Location = New System.Drawing.Point(3, 3) Me.pnlZollTarife.Name = "pnlZollTarife" - Me.pnlZollTarife.Size = New System.Drawing.Size(1176, 691) + Me.pnlZollTarife.Size = New System.Drawing.Size(1176, 744) Me.pnlZollTarife.TabIndex = 0 ' 'tabKundendaten @@ -260,17 +260,6 @@ Partial Class frmKundenUebersichtZOLL Me.lblAbfertigungsverbot.TextAlign = System.Drawing.ContentAlignment.MiddleCenter Me.lblAbfertigungsverbot.Visible = False ' - 'usrcntlKundenuebersicht - ' - Me.usrcntlKundenuebersicht.BackColor = System.Drawing.Color.White - Me.usrcntlKundenuebersicht.BER_STUFE = 0 - Me.usrcntlKundenuebersicht.Dock = System.Windows.Forms.DockStyle.Fill - Me.usrcntlKundenuebersicht.Location = New System.Drawing.Point(3, 3) - Me.usrcntlKundenuebersicht.Margin = New System.Windows.Forms.Padding(2) - Me.usrcntlKundenuebersicht.Name = "usrcntlKundenuebersicht" - Me.usrcntlKundenuebersicht.Size = New System.Drawing.Size(1176, 744) - Me.usrcntlKundenuebersicht.TabIndex = 0 - ' 'ContextMenuStrip2 ' Me.ContextMenuStrip2.ImageScalingSize = New System.Drawing.Size(24, 24) @@ -312,20 +301,10 @@ Partial Class frmKundenUebersichtZOLL Me.TabPage1.Location = New System.Drawing.Point(4, 25) Me.TabPage1.Name = "TabPage1" Me.TabPage1.Padding = New System.Windows.Forms.Padding(3) - Me.TabPage1.Size = New System.Drawing.Size(1182, 697) + Me.TabPage1.Size = New System.Drawing.Size(1182, 750) Me.TabPage1.TabIndex = 2 Me.TabPage1.Text = "Offerte" ' - 'UsrCntlOfferte1 - ' - Me.UsrCntlOfferte1.BackColor = System.Drawing.Color.White - Me.UsrCntlOfferte1.Dock = System.Windows.Forms.DockStyle.Fill - Me.UsrCntlOfferte1.Location = New System.Drawing.Point(3, 3) - Me.UsrCntlOfferte1.Margin = New System.Windows.Forms.Padding(2) - Me.UsrCntlOfferte1.Name = "UsrCntlOfferte1" - Me.UsrCntlOfferte1.Size = New System.Drawing.Size(1176, 691) - Me.UsrCntlOfferte1.TabIndex = 0 - ' 'tbStatistik ' Me.tbStatistik.BackColor = System.Drawing.Color.White @@ -359,7 +338,7 @@ Partial Class frmKundenUebersichtZOLL Me.tbStatistik.Location = New System.Drawing.Point(4, 25) Me.tbStatistik.Name = "tbStatistik" Me.tbStatistik.Padding = New System.Windows.Forms.Padding(3) - Me.tbStatistik.Size = New System.Drawing.Size(1182, 697) + Me.tbStatistik.Size = New System.Drawing.Size(1182, 750) Me.tbStatistik.TabIndex = 3 Me.tbStatistik.Text = "Statikstik" ' @@ -850,7 +829,7 @@ Partial Class frmKundenUebersichtZOLL Me.tbFiskal.Controls.Add(Me.pnlFiskTop) Me.tbFiskal.Location = New System.Drawing.Point(4, 25) Me.tbFiskal.Name = "tbFiskal" - Me.tbFiskal.Size = New System.Drawing.Size(1182, 697) + Me.tbFiskal.Size = New System.Drawing.Size(1182, 750) Me.tbFiskal.TabIndex = 4 Me.tbFiskal.Text = "Fiskal" ' @@ -859,7 +838,7 @@ Partial Class frmKundenUebersichtZOLL Me.pnlFiskal.Dock = System.Windows.Forms.DockStyle.Fill Me.pnlFiskal.Location = New System.Drawing.Point(0, 55) Me.pnlFiskal.Name = "pnlFiskal" - Me.pnlFiskal.Size = New System.Drawing.Size(1182, 642) + Me.pnlFiskal.Size = New System.Drawing.Size(1182, 695) Me.pnlFiskal.TabIndex = 40 ' 'pnlFiskTop @@ -912,7 +891,7 @@ Partial Class frmKundenUebersichtZOLL Me.tbRechnungen.Controls.Add(Me.MyPanel1) Me.tbRechnungen.Location = New System.Drawing.Point(4, 25) Me.tbRechnungen.Name = "tbRechnungen" - Me.tbRechnungen.Size = New System.Drawing.Size(1182, 697) + Me.tbRechnungen.Size = New System.Drawing.Size(1182, 750) Me.tbRechnungen.TabIndex = 5 Me.tbRechnungen.Text = "Rechnungen" ' @@ -930,7 +909,7 @@ Partial Class frmKundenUebersichtZOLL Me.dgvRg.ReadOnly = True Me.dgvRg.RowHeadersVisible = False Me.dgvRg.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect - Me.dgvRg.Size = New System.Drawing.Size(1182, 637) + Me.dgvRg.Size = New System.Drawing.Size(1182, 690) Me.dgvRg.TabIndex = 1 ' 'MyPanel1 @@ -1033,7 +1012,7 @@ Partial Class frmKundenUebersichtZOLL ' Me.tbSpeditionsbuch.Location = New System.Drawing.Point(4, 25) Me.tbSpeditionsbuch.Name = "tbSpeditionsbuch" - Me.tbSpeditionsbuch.Size = New System.Drawing.Size(1182, 697) + Me.tbSpeditionsbuch.Size = New System.Drawing.Size(1182, 750) Me.tbSpeditionsbuch.TabIndex = 6 Me.tbSpeditionsbuch.Text = "Speditionsbuch" Me.tbSpeditionsbuch.UseVisualStyleBackColor = True @@ -1043,26 +1022,17 @@ Partial Class frmKundenUebersichtZOLL Me.tbFiskaluebersicht.Controls.Add(Me.UsrcntlFiskaluebersicht1) Me.tbFiskaluebersicht.Location = New System.Drawing.Point(4, 25) Me.tbFiskaluebersicht.Name = "tbFiskaluebersicht" - Me.tbFiskaluebersicht.Size = New System.Drawing.Size(1182, 697) + Me.tbFiskaluebersicht.Size = New System.Drawing.Size(1182, 750) Me.tbFiskaluebersicht.TabIndex = 7 Me.tbFiskaluebersicht.Text = "Fiskal-Analyse" Me.tbFiskaluebersicht.UseVisualStyleBackColor = True ' - 'UsrcntlFiskaluebersicht1 - ' - Me.UsrcntlFiskaluebersicht1.BackColor = System.Drawing.Color.White - Me.UsrcntlFiskaluebersicht1.Dock = System.Windows.Forms.DockStyle.Fill - Me.UsrcntlFiskaluebersicht1.Location = New System.Drawing.Point(0, 0) - Me.UsrcntlFiskaluebersicht1.Name = "UsrcntlFiskaluebersicht1" - Me.UsrcntlFiskaluebersicht1.Size = New System.Drawing.Size(1182, 697) - Me.UsrcntlFiskaluebersicht1.TabIndex = 0 - ' 'tbCBAM ' Me.tbCBAM.Location = New System.Drawing.Point(4, 25) Me.tbCBAM.Name = "tbCBAM" Me.tbCBAM.Padding = New System.Windows.Forms.Padding(3) - Me.tbCBAM.Size = New System.Drawing.Size(1182, 697) + Me.tbCBAM.Size = New System.Drawing.Size(1182, 750) Me.tbCBAM.TabIndex = 8 Me.tbCBAM.Text = "CBAM" Me.tbCBAM.UseVisualStyleBackColor = True @@ -1214,7 +1184,7 @@ Partial Class frmKundenUebersichtZOLL ' 'ToolStripMenuItem4 ' - Me.ToolStripMenuItem4.DropDownItems.AddRange(New System.Windows.Forms.ToolStripItem() {Me.toolStrVM_de, Me.ZollvollmachtDEFiskalToolStripMenuItem, Me.ToolStripMenuItem6, Me.ToolStripMenuItem8, Me.ZollvollmachtATEVToolStripMenuItem, Me.VollmachtFinanzamtToolStripMenuItem}) + Me.ToolStripMenuItem4.DropDownItems.AddRange(New System.Windows.Forms.ToolStripItem() {Me.toolStrVM_de, Me.ZollvollmachtDEFiskalToolStripMenuItem, Me.ToolStripMenuItem6, Me.ToolStripMenuItem8, Me.ZollvollmachtATEVToolStripMenuItem, Me.VollmachtFinanzamtToolStripMenuItem, Me.ZollvollmachtDEIndirektToolStripMenuItem}) Me.ToolStripMenuItem4.Name = "ToolStripMenuItem4" Me.ToolStripMenuItem4.Size = New System.Drawing.Size(242, 22) Me.ToolStripMenuItem4.Text = "Vollmachten" @@ -1222,37 +1192,37 @@ Partial Class frmKundenUebersichtZOLL 'toolStrVM_de ' Me.toolStrVM_de.Name = "toolStrVM_de" - Me.toolStrVM_de.Size = New System.Drawing.Size(204, 22) + Me.toolStrVM_de.Size = New System.Drawing.Size(215, 22) Me.toolStrVM_de.Text = "Zollvollmacht DE" ' 'ZollvollmachtDEFiskalToolStripMenuItem ' Me.ZollvollmachtDEFiskalToolStripMenuItem.Name = "ZollvollmachtDEFiskalToolStripMenuItem" - Me.ZollvollmachtDEFiskalToolStripMenuItem.Size = New System.Drawing.Size(204, 22) + Me.ZollvollmachtDEFiskalToolStripMenuItem.Size = New System.Drawing.Size(215, 22) Me.ZollvollmachtDEFiskalToolStripMenuItem.Text = "Zollvollmacht DE - Fiskal" ' 'ToolStripMenuItem6 ' Me.ToolStripMenuItem6.Name = "ToolStripMenuItem6" - Me.ToolStripMenuItem6.Size = New System.Drawing.Size(204, 22) + Me.ToolStripMenuItem6.Size = New System.Drawing.Size(215, 22) Me.ToolStripMenuItem6.Text = "Zollvollmacht AT" ' 'ToolStripMenuItem8 ' Me.ToolStripMenuItem8.Name = "ToolStripMenuItem8" - Me.ToolStripMenuItem8.Size = New System.Drawing.Size(204, 22) + Me.ToolStripMenuItem8.Size = New System.Drawing.Size(215, 22) Me.ToolStripMenuItem8.Text = "Zollvollmacht AT - Fiskal" ' 'ZollvollmachtATEVToolStripMenuItem ' Me.ZollvollmachtATEVToolStripMenuItem.Name = "ZollvollmachtATEVToolStripMenuItem" - Me.ZollvollmachtATEVToolStripMenuItem.Size = New System.Drawing.Size(204, 22) + Me.ZollvollmachtATEVToolStripMenuItem.Size = New System.Drawing.Size(215, 22) Me.ZollvollmachtATEVToolStripMenuItem.Text = "Zollvollmacht AT - EV" ' 'VollmachtFinanzamtToolStripMenuItem ' Me.VollmachtFinanzamtToolStripMenuItem.Name = "VollmachtFinanzamtToolStripMenuItem" - Me.VollmachtFinanzamtToolStripMenuItem.Size = New System.Drawing.Size(204, 22) + Me.VollmachtFinanzamtToolStripMenuItem.Size = New System.Drawing.Size(215, 22) Me.VollmachtFinanzamtToolStripMenuItem.Text = "Vollmacht Finanzamt" ' 'ToolStripMenuItem9 @@ -1577,6 +1547,42 @@ Partial Class frmKundenUebersichtZOLL Me.DataGridViewTextBoxColumn2.HeaderText = "KundenNr" Me.DataGridViewTextBoxColumn2.Name = "DataGridViewTextBoxColumn2" ' + 'usrcntlKundenuebersicht + ' + Me.usrcntlKundenuebersicht.BackColor = System.Drawing.Color.White + Me.usrcntlKundenuebersicht.BER_STUFE = 0 + Me.usrcntlKundenuebersicht.Dock = System.Windows.Forms.DockStyle.Fill + Me.usrcntlKundenuebersicht.Location = New System.Drawing.Point(3, 3) + Me.usrcntlKundenuebersicht.Margin = New System.Windows.Forms.Padding(2) + Me.usrcntlKundenuebersicht.Name = "usrcntlKundenuebersicht" + Me.usrcntlKundenuebersicht.Size = New System.Drawing.Size(1176, 744) + Me.usrcntlKundenuebersicht.TabIndex = 0 + ' + 'UsrCntlOfferte1 + ' + Me.UsrCntlOfferte1.BackColor = System.Drawing.Color.White + Me.UsrCntlOfferte1.Dock = System.Windows.Forms.DockStyle.Fill + Me.UsrCntlOfferte1.Location = New System.Drawing.Point(3, 3) + Me.UsrCntlOfferte1.Margin = New System.Windows.Forms.Padding(2) + Me.UsrCntlOfferte1.Name = "UsrCntlOfferte1" + Me.UsrCntlOfferte1.Size = New System.Drawing.Size(1176, 744) + Me.UsrCntlOfferte1.TabIndex = 0 + ' + 'UsrcntlFiskaluebersicht1 + ' + Me.UsrcntlFiskaluebersicht1.BackColor = System.Drawing.Color.White + Me.UsrcntlFiskaluebersicht1.Dock = System.Windows.Forms.DockStyle.Fill + Me.UsrcntlFiskaluebersicht1.Location = New System.Drawing.Point(0, 0) + Me.UsrcntlFiskaluebersicht1.Name = "UsrcntlFiskaluebersicht1" + Me.UsrcntlFiskaluebersicht1.Size = New System.Drawing.Size(1182, 750) + Me.UsrcntlFiskaluebersicht1.TabIndex = 0 + ' + 'ZollvollmachtDEIndirektToolStripMenuItem + ' + Me.ZollvollmachtDEIndirektToolStripMenuItem.Name = "ZollvollmachtDEIndirektToolStripMenuItem" + Me.ZollvollmachtDEIndirektToolStripMenuItem.Size = New System.Drawing.Size(215, 22) + Me.ZollvollmachtDEIndirektToolStripMenuItem.Text = "Zollvollmacht DE - indirekt" + ' 'frmKundenUebersichtZOLL ' Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) @@ -1754,4 +1760,5 @@ Partial Class frmKundenUebersichtZOLL Friend WithEvents lblAvgTnr As Label Friend WithEvents Button4 As Button Friend WithEvents lbAvgTnrGesPos As Label + Friend WithEvents ZollvollmachtDEIndirektToolStripMenuItem As ToolStripMenuItem End Class diff --git a/SDL/kunden/frmKundenUebersichtZOLL.vb b/SDL/kunden/frmKundenUebersichtZOLL.vb index 077d42c1..96b85cd1 100644 --- a/SDL/kunden/frmKundenUebersichtZOLL.vb +++ b/SDL/kunden/frmKundenUebersichtZOLL.vb @@ -164,7 +164,7 @@ Public Class frmKundenUebersichtZOLL ' toolOptionen.Visible = False mneBearbeiten.Visible = False mnueOfferte.Visible = False - mneFormulare.Visible = False + ' mneFormulare.Visible = False -> temoprär deaktiviert wegen einholung von Zoll-VM!!!!!!!!!!! mnueFiskal.Visible = False toolNeuerKunde.Visible = False mnueFiskaluebersicht.Visible = False @@ -365,6 +365,10 @@ Public Class frmKundenUebersichtZOLL toolOptionen.Enabled = False + Else + + mneFormulare.Enabled = True 'ebenfalls nach Erledigung deaktivieren!!!!!!!!!!!!!!!!!!! + End If mnueFiskaluebersicht.Enabled = False @@ -1522,7 +1526,9 @@ Public Class frmKundenUebersichtZOLL End Sub - + Private Sub ZollvollmachtDEIndirektToolStripMenuItem_Click(sender As Object, e As EventArgs) Handles ZollvollmachtDEIndirektToolStripMenuItem.Click + SDL.FormularManagerNEU.OPEN_FORM(SDL.FormularManagerArten.DE_Vollmacht_indirekt, kdNr, {}) + End Sub End Class diff --git a/SDL/kunden/frmSDLDetails.vb b/SDL/kunden/frmSDLDetails.vb index 4b90d02b..c22143c5 100644 --- a/SDL/kunden/frmSDLDetails.vb +++ b/SDL/kunden/frmSDLDetails.vb @@ -21,6 +21,7 @@ ComboBox1.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("0 - Sperre aufgehoben", "0")) 'Sperre aufgehoben ComboBox1.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("1 - Sperre gesetzt", "1")) 'Sperre gesetzt ComboBox1.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("3 - Stopped for Post-Pay", "3")) 'Stopped for Post-Pay + ComboBox1.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("4 - temporär gesperrt", "4")) ComboBox1.SelectedIndex = 0 bindingSDL.binddata(CheckBox1, "CheckState", bindingSDL.bindingSource, "Vertretungsvollmacht") diff --git a/VERAG_PROG_ALLGEMEIN/Classes/cRMC.vb b/VERAG_PROG_ALLGEMEIN/Classes/cRMC.vb index 6f4165cb..c1d03df2 100644 --- a/VERAG_PROG_ALLGEMEIN/Classes/cRMC.vb +++ b/VERAG_PROG_ALLGEMEIN/Classes/cRMC.vb @@ -341,7 +341,7 @@ Public Class cRMC Dim SQLFirst As String = "" If getInvoiceData Then - SQLFirst = "SELECT [rmc_kdNr], [rmc_kdName], [rmc_landKZ], [rmc_reDatum], [rmc_reNr], [rmc_waehrung], case WHEN rmc_daid IS NULL THEN 0 else 1 end as PDF_Rechnung, case WHEN rmc_daId_InvAtt IS NULL THEN 0 else 1 end as PDF_Anhang " + SQLFirst = "SELECT [rmc_kdNr], [rmc_kdName], [rmc_landKZ], [rmc_reDatum], [rmc_reNr], [rmc_waehrung],[rmc_betragNetto],([rmc_betragBrutto] - [rmc_betragNetto]) as MWST,[rmc_betragBrutto], case WHEN rmc_daid IS NULL THEN 0 else 1 end as PDF_Rechnung, case WHEN rmc_daId_InvAtt IS NULL THEN 0 else 1 end as PDF_Anhang " Else SQLFirst = "SELECT DISTINCT r.rmc_kdNr,r.rmc_kdName " End If