kAssenbuch, etc.
This commit is contained in:
7
SDL/kassenbuch/frmBelegNeu.Designer.vb
generated
7
SDL/kassenbuch/frmBelegNeu.Designer.vb
generated
@@ -146,6 +146,7 @@ Partial Class frmBelegNeu
|
||||
Me.DataGridViewTextBoxColumn9 = New System.Windows.Forms.DataGridViewTextBoxColumn()
|
||||
Me.FlowLayoutPanel2 = New System.Windows.Forms.FlowLayoutPanel()
|
||||
Me.ContextMenuStrip1 = New System.Windows.Forms.ContextMenuStrip(Me.components)
|
||||
Me.cm_FT = New System.Windows.Forms.ContextMenuStrip(Me.components)
|
||||
CType(Me.dgvBelegPos, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
Me.pnl.SuspendLayout()
|
||||
Me.pnlData.SuspendLayout()
|
||||
@@ -1778,6 +1779,11 @@ Partial Class frmBelegNeu
|
||||
Me.ContextMenuStrip1.Name = "ContextMenuStrip1"
|
||||
Me.ContextMenuStrip1.Size = New System.Drawing.Size(61, 4)
|
||||
'
|
||||
'cm_FT
|
||||
'
|
||||
Me.cm_FT.Name = "ContextMenuStrip1"
|
||||
Me.cm_FT.Size = New System.Drawing.Size(61, 4)
|
||||
'
|
||||
'frmBelegNeu
|
||||
'
|
||||
Me.AutoScaleDimensions = New System.Drawing.SizeF(96.0!, 96.0!)
|
||||
@@ -1928,4 +1934,5 @@ Partial Class frmBelegNeu
|
||||
Friend WithEvents LinkLabel1 As LinkLabel
|
||||
Friend WithEvents cboBuchungsoforterzeugen As CheckBox
|
||||
Friend WithEvents Button4 As Button
|
||||
Friend WithEvents cm_FT As ContextMenuStrip
|
||||
End Class
|
||||
|
||||
@@ -159,6 +159,9 @@
|
||||
<metadata name="ContextMenuStrip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>17, 17</value>
|
||||
</metadata>
|
||||
<metadata name="cm_FT.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>173, 17</value>
|
||||
</metadata>
|
||||
<metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>86</value>
|
||||
</metadata>
|
||||
|
||||
@@ -1712,8 +1712,10 @@ Public Class frmBelegNeu
|
||||
|
||||
If Not verarbeitet Then
|
||||
If Not TESTBUCHUNG Then
|
||||
|
||||
KASSE.DECREASE_BELEG_UMSATZ(oldBelegZaehler, If(EA = "E", summeBRUTTO * -1, summeBRUTTO))
|
||||
cRKSV.DELETE(BELEG, KASSE.rksv_firma)
|
||||
|
||||
End If
|
||||
Dim Errmsg = "Programmfehler bei der digitalen Signatur." & vbNewLine & vbNewLine & answer
|
||||
MsgBox(Errmsg, MsgBoxStyle.Critical)
|
||||
@@ -1887,40 +1889,136 @@ Public Class frmBelegNeu
|
||||
Process.Start("https://wiki.verag.ag/de/software/aviso/howtos/Bankomat")
|
||||
End Sub
|
||||
|
||||
Private Async Function Button4_ClickAsync(sender As Object, e As EventArgs) As Task Handles Button4.Click
|
||||
Try
|
||||
Dim QR_CodeString As String = ""
|
||||
Dim LastJWS As String = ""
|
||||
|
||||
|
||||
KASSE.LOAD(cboKassen._value)
|
||||
If KASSE.rksv_FT_RestServiceURL <> "" Then
|
||||
Dim client As New cFiskaltrustClient(KASSE.rksv_FT_RestServiceURL, KASSE.rksv_FT_CashboxID, KASSE.rksv_FT_AccessToken, KASSE.rksv_FT_Country)
|
||||
Dim result_verbindungstest As String = Await client.Echo()
|
||||
Dim result_zahlung As String = Await client.SignReceiptAsync_test()
|
||||
|
||||
client.saveRKSV_FT(result_zahlung, QR_CodeString)
|
||||
|
||||
MsgBox(result_verbindungstest)
|
||||
|
||||
Else
|
||||
MsgBox("keine Rest-Service URL hinterlegt!")
|
||||
|
||||
End If
|
||||
|
||||
Catch ex As Exception
|
||||
|
||||
End Try
|
||||
|
||||
|
||||
End Function
|
||||
|
||||
Private Sub cboKassen_SelectedIndexChanged(sender As Object, e As EventArgs) Handles cboKassen.SelectedIndexChanged
|
||||
|
||||
KASSE.LOAD(cboKassen._value)
|
||||
Button4.Visible = KASSE.rksv_FT_RestServiceURL <> ""
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub Button4_ClickAsync(sender As Object, e As EventArgs) Handles Button4.Click
|
||||
|
||||
If Not cm_FT.Items.ContainsKey("null") Then
|
||||
Dim plose = New ToolStripMenuItem() With {.Text = "Nullbeleg", .Name = "null", .Font = New Font(Me.Font.FontFamily, Me.Font.Size)}
|
||||
cm_FT.Items.Add(plose)
|
||||
AddHandler plose.Click, AddressOf mnuItemAuftrauege_Clicked
|
||||
End If
|
||||
|
||||
If Not cm_FT.Items.ContainsKey("monthly") Then
|
||||
Dim rmc = New ToolStripMenuItem() With {.Text = "Monatabschluss", .Name = "monthly", .Font = New Font(Me.Font.FontFamily, Me.Font.Size)}
|
||||
AddHandler rmc.Click, AddressOf mnuItemAuftrauege_Clicked
|
||||
cm_FT.Items.Add(rmc)
|
||||
End If
|
||||
|
||||
If Not cm_FT.Items.ContainsKey("daily") Then
|
||||
Dim rmc = New ToolStripMenuItem() With {.Text = "Tagesabschluss", .Name = "daily", .Font = New Font(Me.Font.FontFamily, Me.Font.Size)}
|
||||
AddHandler rmc.Click, AddressOf mnuItemAuftrauege_Clicked
|
||||
cm_FT.Items.Add(rmc)
|
||||
End If
|
||||
|
||||
If Not cm_FT.Items.ContainsKey("yearly") Then
|
||||
Dim uta = New ToolStripMenuItem() With {.Text = "Jahresabschluss", .Name = "yearly", .Font = New Font(Me.Font.FontFamily, Me.Font.Size)}
|
||||
AddHandler uta.Click, AddressOf mnuItemAuftrauege_Clicked
|
||||
cm_FT.Items.Add(uta)
|
||||
End If
|
||||
|
||||
If Not cm_FT.Items.ContainsKey("bar") Then
|
||||
Dim ids = New ToolStripMenuItem() With {.Text = "Barverkauf", .Name = "bar", .Font = New Font(Me.Font.FontFamily, Me.Font.Size)}
|
||||
AddHandler ids.Click, AddressOf mnuItemAuftrauege_Clicked
|
||||
cm_FT.Items.Add(ids)
|
||||
End If
|
||||
|
||||
If Not cm_FT.Items.ContainsKey("storno") Then
|
||||
Dim ids = New ToolStripMenuItem() With {.Text = "Storno", .Name = "storno", .Font = New Font(Me.Font.FontFamily, Me.Font.Size)}
|
||||
AddHandler ids.Click, AddressOf mnuItemAuftrauege_Clicked
|
||||
cm_FT.Items.Add(ids)
|
||||
End If
|
||||
|
||||
If Not cm_FT.Items.ContainsKey("test") Then
|
||||
Dim ids = New ToolStripMenuItem() With {.Text = "Verbindungstest", .Name = "test", .Font = New Font(Me.Font.FontFamily, Me.Font.Size)}
|
||||
AddHandler ids.Click, AddressOf mnuItemAuftrauege_Clicked
|
||||
cm_FT.Items.Add(ids)
|
||||
End If
|
||||
|
||||
If Not cm_FT.Items.ContainsKey("journal") Then
|
||||
Dim ids = New ToolStripMenuItem() With {.Text = "Journal", .Name = "journal", .Font = New Font(Me.Font.FontFamily, Me.Font.Size)}
|
||||
AddHandler ids.Click, AddressOf mnuItemAuftrauege_Clicked
|
||||
cm_FT.Items.Add(ids)
|
||||
End If
|
||||
|
||||
cm_FT.Show(Cursor.Position)
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
Private Async Function mnuItemAuftrauege_Clicked(sender As Object, e As EventArgs) As Task(Of Object)
|
||||
|
||||
cm_FT.Hide()
|
||||
Dim item As ToolStripMenuItem = TryCast(sender, ToolStripMenuItem)
|
||||
|
||||
If item IsNot Nothing Then
|
||||
|
||||
KASSE.LOAD(cboKassen._value)
|
||||
|
||||
Dim client As New cFiskaltrustClient(KASSE.rksv_FT_RestServiceURL, KASSE.rksv_FT_CashboxID, KASSE.rksv_FT_AccessToken, KASSE.rksv_FT_Country)
|
||||
|
||||
If item.Name = "null" Then
|
||||
'beide
|
||||
Dim result As String = Await client.SignNullReceiptAsync(KASSE.rksv_id)
|
||||
MsgBox(result)
|
||||
|
||||
|
||||
ElseIf item.Name = "test" Then
|
||||
'beide
|
||||
Dim result As String = Await client.Echo(KASSE.rksv_bez & " " & KASSE.rksv_FT_Country & " - ")
|
||||
MsgBox(result)
|
||||
|
||||
|
||||
ElseIf item.Name = "storno" Then
|
||||
'beide
|
||||
Dim result As String = Await client.CancelReceiptAsync_test("-1", 100, "Cash")
|
||||
MsgBox(result)
|
||||
|
||||
ElseIf item.Name = "bar" Then
|
||||
'beide
|
||||
Dim result As String = Await client.SignReceiptAsync_test(KASSE.rksv_id)
|
||||
MsgBox(result)
|
||||
|
||||
ElseIf item.Name = "monthly" Then
|
||||
'beide
|
||||
Dim result As String = Await client.SignClosinglReceiptAsync(item.Name, KASSE.rksv_id)
|
||||
MsgBox(result)
|
||||
|
||||
ElseIf item.Name = "daily" Then
|
||||
'Nur DE
|
||||
If KASSE.rksv_FT_Country = "DE" Then
|
||||
Dim result As String = Await client.SignClosinglReceiptAsync(item.Name, KASSE.rksv_id)
|
||||
MsgBox(result)
|
||||
Else
|
||||
MsgBox("nicht für AT-Kassen möglich!")
|
||||
End If
|
||||
|
||||
|
||||
ElseIf item.Name = "yearly" Then
|
||||
|
||||
Dim result As String = Await client.SignClosinglReceiptAsync(item.Name, KASSE.rksv_id)
|
||||
MsgBox(result)
|
||||
|
||||
ElseIf item.Name = "journal" Then
|
||||
|
||||
Dim result As String = Await client.Journal(2)
|
||||
MsgBox(result)
|
||||
|
||||
|
||||
|
||||
End If
|
||||
|
||||
|
||||
End If
|
||||
|
||||
|
||||
|
||||
End Function
|
||||
End Class
|
||||
|
||||
Class TestRKSVW
|
||||
|
||||
@@ -1150,7 +1150,7 @@ Public Class frmKassenbuch
|
||||
|
||||
If KASSE.rksv_FT_RestServiceURL <> "" Then
|
||||
Dim client As New cFiskaltrustClient(KASSE.rksv_FT_RestServiceURL, KASSE.rksv_FT_CashboxID, KASSE.rksv_FT_AccessToken, KASSE.rksv_FT_Country)
|
||||
Dim result = Await client.SignNullReceiptAsync()
|
||||
Dim result = Await client.SignNullReceiptAsync(RKSV.rksv_id)
|
||||
Dim QR_CodeString As String = ""
|
||||
client.saveRKSV_FT(result, QR_CodeString)
|
||||
Else
|
||||
|
||||
Reference in New Issue
Block a user