Zooflow: Update

This commit is contained in:
Jonathan Jenne 2022-03-09 14:55:58 +01:00
parent e9662a9835
commit f48912b996
3 changed files with 10 additions and 12 deletions

View File

@ -761,9 +761,8 @@ INNER JOIN IDB.dbo.VWIDB_DOCTYPE_LANGUAGE DL ON DT.IDB_DOCTYPE_ID = DL.Doctype_I
Dim oFilePath As String = My.Application.Globix.CurrentWorkfile.FilePath Dim oFilePath As String = My.Application.Globix.CurrentWorkfile.FilePath
Dim oObjectStore As String = SelectedDocType.ObjectStore Dim oObjectStore As String = SelectedDocType.ObjectStore
Dim oIDBDoctypeId As Long = SelectedDocType.IDB_DoctypeID
Dim oObjectKind As String = "DOC" Dim oObjectKind As String = "DOC"
Dim oBusinessEntity As String = "DEFAULT"
' sd
Dim oProfileId As Integer = SelectedDocType.Guid Dim oProfileId As Integer = SelectedDocType.Guid
Dim oAttributes As List(Of UserAttributeValue) = oValues Dim oAttributes As List(Of UserAttributeValue) = oValues
Dim oOptions As New Options.ImportFileOptions Dim oOptions As New Options.ImportFileOptions
@ -771,14 +770,13 @@ INNER JOIN IDB.dbo.VWIDB_DOCTYPE_LANGUAGE DL ON DT.IDB_DOCTYPE_ID = DL.Doctype_I
Logger.Debug("FilePath: [{0}]", oFilePath) Logger.Debug("FilePath: [{0}]", oFilePath)
Logger.Debug("ObjectStore: [{0}]", oObjectStore) Logger.Debug("ObjectStore: [{0}]", oObjectStore)
Logger.Debug("ObjectKind: [{0}]", oObjectKind) Logger.Debug("ObjectKind: [{0}]", oObjectKind)
Logger.Debug("BusinessEntity: [{0}]", oBusinessEntity)
Logger.Debug("ProfileId: [{0}]", oProfileId) Logger.Debug("ProfileId: [{0}]", oProfileId)
Logger.Debug("BusinessEntity: [{0}]", oBusinessEntity) Logger.Debug("IDB DoctypeId: [{0}]", oIDBDoctypeId)
Logger.Info("Running Import") Logger.Info("Running Import")
Dim oResult = Await My.Application.Service.Client.Globix_ImportFileAsync( Dim oResult = Await My.Application.Service.Client.Globix_ImportFileAsync(
oFilePath, oProfileId, oAttributes, oObjectStore, oObjectKind, oBusinessEntity, oOptions) oFilePath, oProfileId, oAttributes, oObjectStore, oObjectKind, oIDBDoctypeId, oOptions)
Logger.Info("Import result: [{0}]", oResult.OK) Logger.Info("Import result: [{0}]", oResult.OK)
Logger.Info("Imported file got ObjectId [{0}]", oResult.ObjectId) Logger.Info("Imported file got ObjectId [{0}]", oResult.ObjectId)

View File

@ -230,11 +230,11 @@ Public Class Client
pAttributeValues As List(Of UserAttributeValue), pAttributeValues As List(Of UserAttributeValue),
pObjectStoreName As String, pObjectStoreName As String,
pObjectKind As String, pObjectKind As String,
pBusinessEntity As String, pIDBDoctypeId As String,
Optional pImportOptions As Options.ImportFileOptions = Nothing) As Task(Of ImportFileResponse) Optional pImportOptions As Options.ImportFileOptions = Nothing) As Task(Of ImportFileResponse)
Try Try
Dim oImportFile As New Modules.Globix.ImportFile(LogConfig, Channel) Dim oImportFile As New Modules.Globix.ImportFile(LogConfig, Channel)
Return Await oImportFile.RunAsync(pFilePath, pProfileId, pAttributeValues, pObjectStoreName, pObjectKind, pBusinessEntity, pImportOptions) Return Await oImportFile.RunAsync(pFilePath, pProfileId, pAttributeValues, pObjectStoreName, pObjectKind, pIDBDoctypeId, pImportOptions)
Catch ex As Exception Catch ex As Exception
Logger.Error(ex) Logger.Error(ex)

View File

@ -96,7 +96,7 @@ Public Class GlobalState
Public Sub LoadObjectStores() Public Sub LoadObjectStores()
_Logger.Info("Loading Object Stores") _Logger.Info("Loading Object Stores")
Try Try
Dim oSQL As String = "SELECT * FROM VWIDB_OBJECTSTORE" Dim oSQL As String = "SELECT * FROM VWIDB_OBJECT_STORE"
Dim oTable As DataTable = _MSSQL_IDB.GetDatatable(oSQL) Dim oTable As DataTable = _MSSQL_IDB.GetDatatable(oSQL)
_Logger.Info("Found [{0}] Object Stores", oTable.Rows.Count) _Logger.Info("Found [{0}] Object Stores", oTable.Rows.Count)
@ -105,10 +105,10 @@ Public Class GlobalState
For Each oRow As DataRow In oTable.Rows For Each oRow As DataRow In oTable.Rows
Dim oStore As New ObjectStore() With { Dim oStore As New ObjectStore() With {
.Id = oRow.Item("OST_ID"), .Id = oRow.Item("GUID"),
.IsArchive = oRow.Item("OS_IS_ARCHIVE"), .IsArchive = oRow.Item("Archive"),
.Path = oRow.Item("IDB_PRAEFIX"), .Path = oRow.Item("REL_PATH"),
.Title = oRow.Item("OS_TITLE") .Title = oRow.Item("Objectstore")
} }
_Logger.Info("New Object Store [{0}]", oStore.Title) _Logger.Info("New Object Store [{0}]", oStore.Title)
oObjectStores.Add(oStore) oObjectStores.Add(oStore)