ZUGFeRDService: Add Options AllowZugferd10, AllowZugferd2x
This commit is contained in:
parent
debd07256c
commit
d4a4e842fa
@ -35,9 +35,10 @@
|
|||||||
Public Property RejectionTransferTimeUnit As String = "HOUR"
|
Public Property RejectionTransferTimeUnit As String = "HOUR"
|
||||||
Public Property RejectionTransferTimeValue As Integer = 12
|
Public Property RejectionTransferTimeValue As Integer = 12
|
||||||
|
|
||||||
Public Property AllowFacturX As Boolean = True
|
Public Property AllowFacturX As Boolean = False
|
||||||
Public Property AllowXRechnung As Boolean = True
|
Public Property AllowXRechnung As Boolean = False
|
||||||
|
Public Property AllowZugferd10 As Boolean = True
|
||||||
|
Public Property AllowZugferd2x As Boolean = True
|
||||||
End Class
|
End Class
|
||||||
|
|
||||||
Public Class FirebirdConfig
|
Public Class FirebirdConfig
|
||||||
|
|||||||
@ -53,11 +53,13 @@ Public Class ThreadRunner
|
|||||||
.NamePortal = _config.Config.PORTAL_NAME,
|
.NamePortal = _config.Config.PORTAL_NAME,
|
||||||
.EmailOutProfileId = _config.Config.MSSQLEmailOutAccountID,
|
.EmailOutProfileId = _config.Config.MSSQLEmailOutAccountID,
|
||||||
.AllowFacturX = _config.Config.Custom.AllowFacturX,
|
.AllowFacturX = _config.Config.Custom.AllowFacturX,
|
||||||
.AllowXRechnung = _config.Config.Custom.AllowXRechnung
|
.AllowXRechnung = _config.Config.Custom.AllowXRechnung,
|
||||||
|
.AllowZugferd10 = _config.Config.Custom.AllowZugferd10,
|
||||||
|
.AllowZugferd2x = _config.Config.Custom.AllowZugferd2x
|
||||||
}
|
}
|
||||||
|
|
||||||
oArgs = LoadFolderConfig(oArgs)
|
oArgs = LoadFolderConfig(oArgs)
|
||||||
oArgs = LoadPropertyMapFor(oArgs, "DEFAULT")
|
oArgs = LoadPropertyMap(oArgs)
|
||||||
|
|
||||||
' Use MSSQL Server if available
|
' Use MSSQL Server if available
|
||||||
If Not IsNothing(_mssql) Then
|
If Not IsNothing(_mssql) Then
|
||||||
@ -243,18 +245,19 @@ Public Class ThreadRunner
|
|||||||
Return pArgs
|
Return pArgs
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
Private Function LoadPropertyMapFor(pArgs As WorkerArgs, pSpecification As String) As WorkerArgs
|
Private Function LoadPropertyMap(pArgs As WorkerArgs) As WorkerArgs
|
||||||
Dim oSQL As String = $"SELECT * FROM TBEDM_XML_ITEMS WHERE SPECIFICATION = '{pSpecification}' AND ACTIVE = True ORDER BY XML_PATH"
|
Dim oSQL As String = $"SELECT * FROM TBEDM_XML_ITEMS WHERE ACTIVE = True ORDER BY XML_PATH"
|
||||||
Dim oResult As DataTable = _firebird.GetDatatable(oSQL)
|
Dim oResult As DataTable = _firebird.GetDatatable(oSQL)
|
||||||
|
|
||||||
For Each row As DataRow In oResult.Rows
|
For Each oRow As DataRow In oResult.Rows
|
||||||
Dim oXmlPath = row.Item("XML_PATH")
|
Dim oXmlPath = oRow.Item("XML_PATH")
|
||||||
Dim oTableName = row.Item("TABLE_NAME")
|
Dim oTableName = oRow.Item("TABLE_NAME")
|
||||||
Dim oTableColumn = row.Item("TABLE_COLUMN")
|
Dim oTableColumn = oRow.Item("TABLE_COLUMN")
|
||||||
Dim oDescription = row.Item("DESCRIPTION")
|
Dim oDescription = oRow.Item("DESCRIPTION")
|
||||||
Dim oIsRequired = row.Item("IS_REQUIRED")
|
Dim oIsRequired = oRow.Item("IS_REQUIRED")
|
||||||
Dim oIsGrouped = row.Item("IS_GROUPED")
|
Dim oIsGrouped = oRow.Item("IS_GROUPED")
|
||||||
Dim oGroupScope = row.Item("GROUP_SCOPE")
|
Dim oGroupScope = oRow.Item("GROUP_SCOPE")
|
||||||
|
Dim oSpecification = oRow.Item("SPECIFICATION")
|
||||||
|
|
||||||
pArgs.PropertyMap.Add(oXmlPath, New XmlItemProperty() With {
|
pArgs.PropertyMap.Add(oXmlPath, New XmlItemProperty() With {
|
||||||
.Description = oDescription,
|
.Description = oDescription,
|
||||||
@ -262,7 +265,8 @@ Public Class ThreadRunner
|
|||||||
.TableColumn = oTableColumn,
|
.TableColumn = oTableColumn,
|
||||||
.IsRequired = oIsRequired,
|
.IsRequired = oIsRequired,
|
||||||
.IsGrouped = oIsGrouped,
|
.IsGrouped = oIsGrouped,
|
||||||
.GroupScope = oGroupScope
|
.GroupScope = oGroupScope,
|
||||||
|
.Specification = oSpecification
|
||||||
})
|
})
|
||||||
Next
|
Next
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user