jj firebird
This commit is contained in:
@@ -9,26 +9,16 @@ Imports DigitalData.Modules.Jobs.ImportZUGFeRDFiles
|
||||
Imports DigitalData.Modules.Logging
|
||||
|
||||
Public Class Form1
|
||||
|
||||
Public Const ZUGFERD_IN = "ZUGFeRD in"
|
||||
Public Const ZUGFERD_ERROR = "ZUGFeRD Error"
|
||||
Public Const ZUGFERD_SUCCESS = "ZUGFeRD Success"
|
||||
|
||||
Private _logConfig As LogConfig
|
||||
Private _firebird As Firebird
|
||||
|
||||
Private PropertyMap As New Dictionary(Of String, String)
|
||||
Private PropertyMap As New Dictionary(Of String, XmlItemProperty)
|
||||
|
||||
|
||||
Private Sub Form1_Load(sender As Object, e As EventArgs) Handles Me.Load
|
||||
_logConfig = New LogConfig(LogConfig.PathType.CurrentDirectory)
|
||||
_logConfig.Debug = True
|
||||
_firebird = New Firebird(_logConfig, My.Settings.FB_DATASOURCE, My.Settings.FB_DATABASE, My.Settings.FB_USER, My.Settings.FB_PASS)
|
||||
|
||||
PropertyMap.Add("TBEDM_INVOICE_HEAD.INVOICE_NR", "HeaderExchangedDocument.ID.Value")
|
||||
PropertyMap.Add("TBEDM_INVOICE_HEAD.DOC_TYPE", "HeaderExchangedDocument.Name(0).Value")
|
||||
PropertyMap.Add("TBEDM_INVOICE_HEAD.INVOICE_DATE", "HeaderExchangedDocument.IssueDateTime.Item.Value")
|
||||
PropertyMap.Add("TBEDM_INVOICE_HEAD.INVOICE_DATE_FORMAT", "HeaderExchangedDocument.IssueDateTime.Item.format")
|
||||
PropertyMap.Add("TBEDM_INVOICE_HEAD.NOTE", "HeaderExchangedDocument.IncludedNote(0).Content(0).Value")
|
||||
End Sub
|
||||
|
||||
Private Function LoadFolderConfig(args As WorkerArgs)
|
||||
@@ -61,9 +51,14 @@ Public Class Form1
|
||||
For Each row As DataRow In oResult.Rows
|
||||
Dim xmlPath = row.Item("XML_PATH")
|
||||
Dim tableName = row.Item("TABLE_NAME")
|
||||
Dim tableColumn = row.Item("TABLE_COLUMN")
|
||||
Dim description = row.Item("DESCRIPTION")
|
||||
Dim isRequired = row.Item("IS_REQUIRED")
|
||||
|
||||
args.PropertyMap.Add($"{tableName}.{tableColumn}", xmlPath)
|
||||
args.PropertyMap.Add(xmlPath, New XmlItemProperty() With {
|
||||
.Description = description,
|
||||
.TableName = tableName,
|
||||
.IsRequired = isRequired
|
||||
})
|
||||
Next
|
||||
|
||||
Return args
|
||||
|
||||
Reference in New Issue
Block a user