EDMI: Add VersionFileMethod WIP
This commit is contained in:
@@ -19,12 +19,12 @@ Namespace Methods.IDB.NewFile
|
||||
Transaction = Connection.BeginTransaction()
|
||||
End Sub
|
||||
|
||||
Public Function Run(pData As NewFile.NewFileRequest) As Methods.IDB.NewFile.NewFileResponse
|
||||
Public Function Run(pData As NewFile.VersionFileRequest) As Methods.IDB.NewFile.VersionFileResponse
|
||||
Dim oFilePath As String = Nothing
|
||||
|
||||
Dim oExistingObjectId = TestFileChecksumExists(pData.File.FileChecksum)
|
||||
If oExistingObjectId > 0 Then
|
||||
Return New NewFile.NewFileResponse(oExistingObjectId)
|
||||
Return New NewFile.VersionFileResponse(oExistingObjectId)
|
||||
End If
|
||||
|
||||
Try
|
||||
@@ -157,7 +157,7 @@ Namespace Methods.IDB.NewFile
|
||||
' Finally, commit the transaction
|
||||
Transaction?.Commit()
|
||||
|
||||
Return New NewFile.NewFileResponse(oObjectId)
|
||||
Return New NewFile.VersionFileResponse(oObjectId)
|
||||
Catch ex As Exception
|
||||
Logger.Warn("Error occurred while creating file!")
|
||||
Logger.Error(ex)
|
||||
@@ -175,7 +175,7 @@ Namespace Methods.IDB.NewFile
|
||||
Logger.Info("Rolling back transaction.")
|
||||
Transaction?.Rollback()
|
||||
|
||||
Return New NewFile.NewFileResponse(ex)
|
||||
Return New NewFile.VersionFileResponse(ex)
|
||||
|
||||
End Try
|
||||
End Function
|
||||
|
||||
Reference in New Issue
Block a user