Filesystem EDMI

This commit is contained in:
Developer01
2025-12-23 13:02:14 +01:00
parent 1d17afb400
commit 0ef5a3b339
3 changed files with 91 additions and 131 deletions

View File

@@ -86,14 +86,7 @@ Namespace Methods.GlobalIndexer.ImportFile
oAutoAttributes = oAutomaticIndexing.ApplyAutomaticeAttributes(oUserAttributes, pData.File.FileInfoRaw, User)
' Import the file
Dim oNewFile As New NewFile.NewFileMethod(LogConfig, DatabaseIDB, DatabaseECM, GlobalState)
Dim oResponse = oNewFile.Run(New NewFile.NewFileRequest With {
.File = pData.File,
.IDBDoctypeId = pData.IDBDoctypeId,
.KindType = pData.KindType,
.StoreName = pData.StoreName,
.User = User
})
Dim oResponse = ImportFile(pData)
If oResponse.OK Then
Logger.Info("Import of file [{0}] under ObjectId [{1}] successful!", pData.File.FileName, oResponse.ObjectId)
@@ -147,7 +140,16 @@ Namespace Methods.GlobalIndexer.ImportFile
Return New Globix_ImportFileResponse(ex)
End Try
End Function
Private Function ImportFile(pData As Globix_ImportFileRequest) As NewFile.NewFileResponse
Dim oNewFile As New NewFile.NewFileMethod(LogConfig, DatabaseIDB, DatabaseECM, GlobalState)
Return oNewFile.Run(New NewFile.NewFileRequest With {
.File = pData.File,
.IDBDoctypeId = pData.IDBDoctypeId,
.KindType = pData.KindType,
.StoreName = pData.StoreName,
.User = User
})
End Function
Private Function GetVirtualPath(pFileInfo As FileInfo, pPathConvention As String, pUser As UserState, pUserAttributes As List(Of UserAttributeValue), pAutoAttributes As List(Of UserAttributeValue))
Logger.Info("Generating virtual path for file [{0}]", pFileInfo.Name)