jj
This commit is contained in:
@@ -1,12 +1,13 @@
|
||||
Imports DigitalData.Modules.Logging
|
||||
Imports DigitalData.Modules.EDMIFileOps.EDMIServiceReference
|
||||
Imports System.ServiceModel
|
||||
Imports System.IO
|
||||
|
||||
Public Class FileOp
|
||||
Private _logger As DigitalData.Modules.Logging.Logger
|
||||
Private _logger As Logger
|
||||
Private _logConfig As LogConfig
|
||||
Private _channelFactory As ChannelFactory(Of EDMIServiceReference.IEDMServiceChannel)
|
||||
Private _channel As EDMIServiceReference.IEDMServiceChannel
|
||||
Private _channelFactory As ChannelFactory(Of IEDMServiceChannel)
|
||||
Private _channel As IEDMServiceChannel
|
||||
Public Sub New(LogConfig As LogConfig, EDMI_ServiceAdress As String)
|
||||
_logger = LogConfig.GetLogger()
|
||||
_logConfig = LogConfig
|
||||
@@ -22,7 +23,7 @@ Public Class FileOp
|
||||
binding.ReaderQuotas.MaxArrayLength = 2147483647
|
||||
binding.ReaderQuotas.MaxStringContentLength = 2147483647
|
||||
Dim endpointAddress = New EndpointAddress(EDMI_ServiceAdress)
|
||||
_channelFactory = New ChannelFactory(Of EDMIServiceReference.IEDMServiceChannel)(binding, endpointAddress)
|
||||
_channelFactory = New ChannelFactory(Of IEDMServiceChannel)(binding, endpointAddress)
|
||||
Connect2NetService()
|
||||
Catch ex As Exception
|
||||
_logger.Error(ex)
|
||||
@@ -52,8 +53,8 @@ Public Class FileOp
|
||||
Dim oFileGUID = Await New_EDMIFile_CreateContainer(oFILENAME)
|
||||
Dim oFileRecordID = Nothing
|
||||
If Not IsNothing(oFileGUID) Then
|
||||
Dim oSQL = $"Select Case FNEDMI_SET_RECORD('TBEDMI_ADRESSE','{oUserName}',FALSE,NULL,'','{oFileGUID}') From rdb$database;"
|
||||
oFileRecordID = New_EDMIFile_CreateDB_Record(oSQL)
|
||||
Dim oSQL = $"SELECT FNEDMI_SET_RECORD('TBEDMI_ADRESSE','{oUserName}',FALSE,NULL,'','{oFileGUID}') FROM rdb$database;"
|
||||
oFileRecordID = Await New_EDMIFile_CreateDB_Record(oSQL)
|
||||
End If
|
||||
Return oFileRecordID
|
||||
Catch ex As Exception
|
||||
|
||||
Reference in New Issue
Block a user