creditsafe-bugfix, fiskalübersicht
This commit is contained in:
@@ -139,7 +139,7 @@ Public Class frmMain
|
||||
btnMitarbeiterKonto.Text = VERAG_PROG_ALLGEMEIN.cAllgemein.USRNAME
|
||||
setProfileImage()
|
||||
|
||||
If False Then 'Bei Produktivstart löschen!!!!!
|
||||
If False Then 'Bei Produktivstart Bedingung auf True!!!!!
|
||||
|
||||
If VERAG_PROG_ALLGEMEIN.cAllgemein.MITARBEITER.mit_timasId IsNot Nothing Then
|
||||
Dim timas As New cTimasAPI
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
|
||||
Imports System.Globalization
|
||||
Imports System.Linq.Expressions
|
||||
Imports System.Net
|
||||
Imports System.Text.RegularExpressions
|
||||
Imports com.sun.tools.doclets.internal.toolkit.util
|
||||
@@ -247,6 +248,7 @@ Public Class usrcntlFiskaluebersicht
|
||||
|
||||
Private Sub btnPDFReport_Click(sender As Object, e As EventArgs) Handles btnPDFReport.Click
|
||||
Try
|
||||
Me.Cursor = Cursors.WaitCursor
|
||||
Dim listeUnterlagen As New List(Of String)
|
||||
If dgvUnterlagen.Rows.Count > 0 Then
|
||||
|
||||
@@ -322,11 +324,12 @@ Public Class usrcntlFiskaluebersicht
|
||||
VERAG_PROG_ALLGEMEIN.cFormularManager.mergePDFs(files, outputFile)
|
||||
|
||||
Process.Start(outputFile)
|
||||
|
||||
Me.Cursor = Cursors.Default
|
||||
Catch ex As Exception
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
||||
End Try
|
||||
Me.Cursor = Cursors.Default
|
||||
End Try
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub btnOK_Click(sender As Object, e As EventArgs) Handles btnOK.Click
|
||||
@@ -359,6 +362,9 @@ Public Class usrcntlFiskaluebersicht
|
||||
|
||||
|
||||
Private Sub dgvFiskaluebersicht_SelectionChanged(sender As Object, e As EventArgs) Handles dgvFiskaluebersicht.SelectionChanged
|
||||
|
||||
|
||||
|
||||
If dgvFiskaluebersicht.SelectedRows.Count > 0 Then
|
||||
|
||||
fk = New cFiskalkunden(dgvFiskaluebersicht.SelectedRows(0).Cells("FK_Id").Value)
|
||||
@@ -375,14 +381,17 @@ Public Class usrcntlFiskaluebersicht
|
||||
Button4.Enabled = True
|
||||
setAbschlusstxt(locked)
|
||||
|
||||
BA = VERAG_PROG_ALLGEMEIN.cBonitaetsauskunft.LOADByKdNrWithingDate(kdNr)
|
||||
setControlButtons()
|
||||
|
||||
Else
|
||||
|
||||
Button4.Enabled = False
|
||||
clearTXT()
|
||||
End If
|
||||
|
||||
BA = VERAG_PROG_ALLGEMEIN.cBonitaetsauskunft.LOADByKdNrWithingDate(kdNr)
|
||||
setControlButtons()
|
||||
'BA = VERAG_PROG_ALLGEMEIN.cBonitaetsauskunft.LOADByKdNrWithingDate(kdNr)
|
||||
'setControlButtons()
|
||||
|
||||
|
||||
End Sub
|
||||
@@ -868,6 +877,7 @@ Public Class usrcntlFiskaluebersicht
|
||||
|
||||
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
|
||||
|
||||
Me.Cursor = Cursors.WaitCursor
|
||||
Dim url As String = ""
|
||||
lblWarning.Text = ""
|
||||
txtHomepage.ForeColor = Color.Black
|
||||
@@ -878,6 +888,7 @@ Public Class usrcntlFiskaluebersicht
|
||||
If anh_list.Count > 0 Then
|
||||
DS = New VERAG_PROG_ALLGEMEIN.cDATENSERVER(anh_list.ElementAt(0).fka_docId)
|
||||
DS.OPEN_SINGLE()
|
||||
Me.Cursor = Cursors.Default
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
@@ -885,26 +896,13 @@ Public Class usrcntlFiskaluebersicht
|
||||
|
||||
If txtHomepage.Text = "" Then
|
||||
picOK.Visible = False
|
||||
Me.Cursor = Cursors.Default
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
If Not IsValidURL(txtHomepage.Text) Then Exit Sub
|
||||
|
||||
Dim req As System.Net.WebRequest
|
||||
Dim res As System.Net.WebResponse
|
||||
|
||||
Try
|
||||
url = txtHomepage.Text
|
||||
req = System.Net.WebRequest.Create(url)
|
||||
|
||||
res = req.GetResponse()
|
||||
Catch ex As WebException
|
||||
lblWarning.Text = ex.Message
|
||||
txtHomepage.ForeColor = Color.Red
|
||||
picOK.Visible = False
|
||||
Exit Sub
|
||||
End Try
|
||||
|
||||
If Not checkWebsite(url) Then Exit Sub
|
||||
|
||||
Dim pdf = VERAG_PROG_ALLGEMEIN.cFormularManager.getPDFViaSpirePDF_FromURL(url) 'UU langsam....
|
||||
|
||||
@@ -931,6 +929,7 @@ Public Class usrcntlFiskaluebersicht
|
||||
If Not cbxHomepage.Checked Then cbxHomepage.Checked = True
|
||||
|
||||
initDGVUnterlagen()
|
||||
Me.Cursor = Cursors.Default
|
||||
|
||||
End Sub
|
||||
|
||||
@@ -1035,11 +1034,15 @@ Public Class usrcntlFiskaluebersicht
|
||||
|
||||
Private Sub setControlButtons()
|
||||
|
||||
If fk IsNot Nothing Then
|
||||
|
||||
If fk.FK_locked Then
|
||||
btnSave.Enabled = False
|
||||
btnOK.Enabled = False
|
||||
Exit Sub
|
||||
End If
|
||||
End If
|
||||
|
||||
|
||||
For Each c As Control In MyPanel1.Controls
|
||||
|
||||
@@ -1089,21 +1092,7 @@ Public Class usrcntlFiskaluebersicht
|
||||
|
||||
If Not IsValidURL(txtWebsiteSt.Text) Then Exit Sub
|
||||
|
||||
Dim req As System.Net.WebRequest
|
||||
Dim res As System.Net.WebResponse
|
||||
|
||||
Try
|
||||
url = txtWebsiteSt.Text
|
||||
req = System.Net.WebRequest.Create(url)
|
||||
|
||||
res = req.GetResponse()
|
||||
Catch ex As WebException
|
||||
lblWarning.Text = ex.Message
|
||||
txtWebsiteSt.ForeColor = Color.Red
|
||||
picOKSt.Visible = False
|
||||
Exit Sub
|
||||
End Try
|
||||
|
||||
If Not checkWebsite(url) Then Exit Sub
|
||||
|
||||
Dim pdf = VERAG_PROG_ALLGEMEIN.cFormularManager.getPDFViaSpirePDF_FromURL(url) 'UU langsam....
|
||||
|
||||
@@ -1127,4 +1116,27 @@ Public Class usrcntlFiskaluebersicht
|
||||
initDGVUnterlagen()
|
||||
|
||||
End Sub
|
||||
|
||||
Private Function checkWebsite(url As String) As Boolean
|
||||
|
||||
Dim req As System.Net.HttpWebRequest
|
||||
Dim res As System.Net.HttpWebResponse
|
||||
|
||||
Try
|
||||
url = txtHomepage.Text
|
||||
req = System.Net.HttpWebRequest.Create(url)
|
||||
req.Timeout = 5000
|
||||
req.UserAgent = "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/65.0.3325.181 Safari/537.36"
|
||||
res = req.GetResponse()
|
||||
Catch ex As WebException
|
||||
lblWarning.Text = ex.Message
|
||||
txtHomepage.ForeColor = Color.Red
|
||||
picOK.Visible = False
|
||||
Me.Cursor = Cursors.Default
|
||||
Return False
|
||||
End Try
|
||||
|
||||
Return True
|
||||
|
||||
End Function
|
||||
End Class
|
||||
|
||||
@@ -3,6 +3,7 @@ Imports System.Net
|
||||
Imports System.Reflection
|
||||
Imports System.Threading
|
||||
Imports System.Web.Routing
|
||||
Imports System.Windows.Forms
|
||||
Imports VERAG_PROG_ALLGEMEIN.cCreditSafeAPI
|
||||
|
||||
Public Class cATEZ_NCTS_DATA
|
||||
@@ -323,6 +324,50 @@ Public Class cATEZ_NCTS_IN
|
||||
End Try
|
||||
End Function
|
||||
|
||||
Shared Function setJson(ncts As cATEZ_NCTS_DATA, dgv As DataGridView)
|
||||
|
||||
|
||||
Dim success As Boolean
|
||||
Dim json As New Chilkat.JsonObject
|
||||
success = json.UpdateString("VERAG_LRN", ncts.VERAG_LRN)
|
||||
success = json.UpdateString("LicensePlateContainerNo", ncts.LicensePlateContainerNo)
|
||||
success = json.UpdateString("DAKOSY.TemplateCode", ncts.DAKOSY_TemplateCode)
|
||||
success = json.UpdateString("DAKOSY.IOPartner", ncts.DAKOSY_IOPartner)
|
||||
success = json.UpdateString("DAKOSY.Division1", ncts.DAKOSY_Division1)
|
||||
success = json.UpdateString("DAKOSY.Division2", ncts.DAKOSY_Division2)
|
||||
success = json.UpdateString("DAKOSY.Division3", ncts.DAKOSY_Division3)
|
||||
success = json.UpdateString("DepartureCustomsOffice", ncts.DepartureCustomsOffice)
|
||||
success = json.UpdateString("DestinationCustomsOffice", ncts.DestinationCustomsOffice)
|
||||
success = json.UpdateString("DatDeterminationLimit", ncts.DatDeterminationLimit)
|
||||
success = json.UpdateString("CoolingTemperature", ncts.CoolingTemperature)
|
||||
success = json.UpdateString("Carrier.Name", ncts.Carrier_Name)
|
||||
success = json.UpdateString("Carrier.Adress.Country", ncts.Carrier_Adress_Country)
|
||||
success = json.UpdateString("Carrier.Adress.Postcode", ncts.Carrier_Adress_Postcode)
|
||||
success = json.UpdateString("Carrier.Adress.City", ncts.Carrier_Adress_City)
|
||||
success = json.UpdateString("Carrier.Adress.Street", ncts.Carrier_Adress_Street)
|
||||
success = json.UpdateString("Guarantee.GRN", ncts.Guarantee_GRN)
|
||||
success = json.UpdateString("Route[0].Country", ncts.Route_Country)
|
||||
success = json.UpdateString("TransitCustomsOffices[0].TransitCustomsOffice", "text")
|
||||
success = json.UpdateString("TransitCustomsOffices[1].TransitCustomsOffice", "text")
|
||||
success = json.UpdateString("TransitCustomsOffices[2].TransitCustomsOffice", "text")
|
||||
|
||||
|
||||
For Each r As DataGridViewRow In dgv.SelectedRows
|
||||
Dim i As Integer = 0
|
||||
Dim bd As New Chilkat.BinData
|
||||
Dim json1 As New Chilkat.JsonObject
|
||||
success = bd.LoadFile(VERAG_PROG_ALLGEMEIN.cDATENSERVER.GET_PDFPath_BY_DocID(r.Cells("anh_docId").Value))
|
||||
'json1.UpdateBd("", "base64", bd)
|
||||
success = json.UpdateString("Attachments.Attachment[" & i & "].FileType", "text")
|
||||
success = json.UpdateString("Attachments.Attachment[" & i & "].DocumentType", "INVOICE")
|
||||
success = json.UpdateString("Attachments.Attachment[" & i & "].base64BinaryStream", bd.GetEncoded("base64"))
|
||||
i = +1
|
||||
Next
|
||||
|
||||
Return success
|
||||
|
||||
End Function
|
||||
|
||||
|
||||
|
||||
End Class
|
||||
|
||||
@@ -460,7 +460,7 @@ Public Class cCreditSafeAPI
|
||||
myUrl &= "?customData=de_reason_code::3"
|
||||
myUrl &= "&?language=DE"
|
||||
Else
|
||||
myUrl &= "?language=DE"
|
||||
myUrl &= "?language=EN"
|
||||
End If
|
||||
|
||||
Dim acceptContentType = "application/pdf"
|
||||
|
||||
Reference in New Issue
Block a user