Common: ObjectPropertyDialog

This commit is contained in:
Jonathan Jenne
2022-03-11 15:46:59 +01:00
parent a6de7e0af2
commit 7f9fd6ee58
36 changed files with 785 additions and 326 deletions

View File

@@ -224,6 +224,18 @@ Public Class Client
End Try
End Function
Public Async Function SetAttributeValueAsync(pObjectId As Long, pName As String, pValue As Object, Optional pOptions As Options.SetAttributeValueOptions = Nothing) As Task(Of Boolean)
Try
Dim oSetAttributeValue As New Modules.IDB.SetAttributeValue(LogConfig, Channel)
Return Await oSetAttributeValue.RunAsync(pObjectId, pName, pValue, pOptions)
Catch ex As Exception
Logger.Error(ex)
Return False
End Try
End Function
Public Async Function Globix_ImportFileAsync(
pFilePath As String,
pProfileId As Integer,
@@ -273,115 +285,115 @@ Public Class Client
''' <param name="pValue"></param>
''' <param name="pOptions"></param>
''' <returns></returns>
Public Function SetVariableValue(pObjectId As Long, pAttributeName As String, pValue As Object, Optional pOptions As Options.SetVariableValueOptions = Nothing) As Boolean
Try
' Set default options
If pOptions Is Nothing Then
pOptions = New Options.SetVariableValueOptions()
End If
'Public Function SetVariableValue(pObjectId As Long, pAttributeName As String, pValue As Object, Optional pOptions As Options.SetVariableValueOptions = Nothing) As Boolean
' Try
' ' Set default options
' If pOptions Is Nothing Then
' pOptions = New Options.SetVariableValueOptions()
' End If
Dim oOptions As New Options.GetVariableValueOptions With {
.Language = pOptions.Language,
.Username = pOptions.Username
}
' Dim oOptions As New Options.GetVariableValueOptions With {
' .Language = pOptions.Language,
' .Username = pOptions.Username
' }
Try
Dim oResponse = Channel.TestObjectIdExists(New TestObjectIdExistsRequest With {.ObjectId = pObjectId})
If oResponse.Exists = False Then
Return False
End If
' Try
' Dim oResponse = Channel.TestObjectIdExists(New TestObjectIdExistsRequest With {.ObjectId = pObjectId})
' If oResponse.Exists = False Then
' Return False
' End If
Catch ex As Exception
Logger.Error(ex)
Return False
End Try
' Catch ex As Exception
' Logger.Error(ex)
' Return False
' End Try
Dim oType = pValue.GetType.Name
' Dim oType = pValue.GetType.Name
If oType = GetType(DataTable).Name Then
Dim oValueTable As DataTable = pValue
Dim oCurrentValue As VariableValue
' If oType = GetType(DataTable).Name Then
' Dim oValueTable As DataTable = pValue
' Dim oCurrentValue As VariableValue
' Get current value
oCurrentValue = GetVariableValue(pObjectId, pAttributeName, oOptions)
' ' Get current value
' oCurrentValue = GetVariableValue(pObjectId, pAttributeName, oOptions)
' If current value is datatable
If oCurrentValue.Type = GetType(DataTable) Then
' ' If current value is datatable
' If oCurrentValue.Type = GetType(DataTable) Then
' Convert value to Datatable
Dim oTable As DataTable = oCurrentValue.Value
' ' Convert value to Datatable
' Dim oTable As DataTable = oCurrentValue.Value
If oTable.Rows.Count > 1 Then
' If oTable.Rows.Count > 1 Then
'now Checking whether the old row still remains in Vector? If not it will be deleted as it cannot be replaced in multivalues
For Each oRow As DataRow In oTable.Rows
Dim oExists As Boolean = False
For Each oNewValueRow As DataRow In oValueTable.Rows
Logger.Debug($"Checking oldValue[{oCurrentValue}] vs NewValue [{oNewValueRow.Item(1)}]")
' 'now Checking whether the old row still remains in Vector? If not it will be deleted as it cannot be replaced in multivalues
' For Each oRow As DataRow In oTable.Rows
' Dim oExists As Boolean = False
' For Each oNewValueRow As DataRow In oValueTable.Rows
' Logger.Debug($"Checking oldValue[{oCurrentValue}] vs NewValue [{oNewValueRow.Item(1)}]")
If oNewValueRow.Item(1).ToString.ToUpper = oRow.Item(0).ToString.ToUpper Then
oExists = True
Exit For
End If
Next
' If oNewValueRow.Item(1).ToString.ToUpper = oRow.Item(0).ToString.ToUpper Then
' oExists = True
' Exit For
' End If
' Next
If oExists = False Then
Logger.Debug($"Value [{oRow.Item(0)}] no longer existing in Vector-Attribute [{pAttributeName}] - will be deleted!")
DeleteTermObjectFromMetadata(pObjectId, pAttributeName, oRow.Item(0))
End If
' If oExists = False Then
' Logger.Debug($"Value [{oRow.Item(0)}] no longer existing in Vector-Attribute [{pAttributeName}] - will be deleted!")
' DeleteTermObjectFromMetadata(pObjectId, pAttributeName, oRow.Item(0))
' End If
Next
End If
Else
If oValueTable.Rows.Count > 1 Then
' Next
' End If
' Else
' If oValueTable.Rows.Count > 1 Then
'now Checking whether the old row still remains in Vector? If not it will be deleted as it cannot be replaced in multivalues
Dim oExists As Boolean = False
For Each oNewValueRow As DataRow In oValueTable.Rows
Logger.Debug($"Checking oldValue[{oCurrentValue}] vs NewValue [{oNewValueRow.Item(1)}]")
' 'now Checking whether the old row still remains in Vector? If not it will be deleted as it cannot be replaced in multivalues
' Dim oExists As Boolean = False
' For Each oNewValueRow As DataRow In oValueTable.Rows
' Logger.Debug($"Checking oldValue[{oCurrentValue}] vs NewValue [{oNewValueRow.Item(1)}]")
If oNewValueRow.Item(1).ToString.ToUpper = oCurrentValue.ToString.ToUpper Then
oExists = True
Exit For
End If
' If oNewValueRow.Item(1).ToString.ToUpper = oCurrentValue.ToString.ToUpper Then
' oExists = True
' Exit For
' End If
Next
If oExists = False Then
Logger.Debug($"Value [{oCurrentValue}] no longer existing in Vector-Attribute [{pAttributeName}] - will be deleted!")
DeleteTermObjectFromMetadata(pObjectId, pAttributeName, oCurrentValue.Value)
End If
' Next
' If oExists = False Then
' Logger.Debug($"Value [{oCurrentValue}] no longer existing in Vector-Attribute [{pAttributeName}] - will be deleted!")
' DeleteTermObjectFromMetadata(pObjectId, pAttributeName, oCurrentValue.Value)
' End If
Else
Logger.Debug($"Value [{oCurrentValue}] of Attribute [{pAttributeName}] obviously was updated during runtime - will be deleted!")
DeleteTermObjectFromMetadata(pObjectId, pAttributeName, oCurrentValue.Value)
' Else
' Logger.Debug($"Value [{oCurrentValue}] of Attribute [{pAttributeName}] obviously was updated during runtime - will be deleted!")
' DeleteTermObjectFromMetadata(pObjectId, pAttributeName, oCurrentValue.Value)
End If
' End If
End If
' End If
For Each oNewValueRow As DataRow In oValueTable.Rows
Dim oResult As Boolean = NewObjectData(pObjectId, pAttributeName, pValue, New Options.NewObjectOptions With {
.Language = pOptions.Language,
.Username = pOptions.Username
})
' For Each oNewValueRow As DataRow In oValueTable.Rows
' Dim oResult As Boolean = NewObjectData(pObjectId, pAttributeName, pValue, New Options.NewObjectOptions With {
' .Language = pOptions.Language,
' .Username = pOptions.Username
' })
If oResult = False Then
Return False
End If
Next
Return True
Else
Return NewObjectData(pObjectId, pAttributeName, pValue, New Options.NewObjectOptions With {
.Language = pOptions.Language,
.Username = pOptions.Username
})
End If
' If oResult = False Then
' Return False
' End If
' Next
' Return True
' Else
' Return NewObjectData(pObjectId, pAttributeName, pValue, New Options.NewObjectOptions With {
' .Language = pOptions.Language,
' .Username = pOptions.Username
' })
' End If
Catch ex As Exception
Logger.Error(ex)
Return False
End Try
End Function
' Catch ex As Exception
' Logger.Error(ex)
' Return False
' End Try
'End Function
''' <summary>
'''

View File

@@ -52,6 +52,10 @@
Public Property DateImported As Date = Date.Now
End Class
Public Class SetAttributeValueOptions
Inherits BaseOptions
End Class
Public Class GetVariableValueOptions
Inherits BaseOptions

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
This file is automatically generated by Visual Studio .Net. It is
used to store generic object data source configuration information.
Renaming the file extension or editing the content of this file may
cause the file to be unrecognizable by the program.
-->
<GenericObjectDataSource DisplayName="DocumentInfoResponse" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
<TypeInfo>DigitalData.Modules.EDMI.API.EDMIServiceReference.DocumentInfoResponse, Connected Services.EDMIServiceReference.Reference.vb.dll, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</TypeInfo>
</GenericObjectDataSource>

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
This file is automatically generated by Visual Studio .Net. It is
used to store generic object data source configuration information.
Renaming the file extension or editing the content of this file may
cause the file to be unrecognizable by the program.
-->
<GenericObjectDataSource DisplayName="DocumentListResponse" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
<TypeInfo>DigitalData.Modules.EDMI.API.EDMIServiceReference.DocumentListResponse, Connected Services.EDMIServiceReference.Reference.vb.dll, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</TypeInfo>
</GenericObjectDataSource>

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
This file is automatically generated by Visual Studio .Net. It is
used to store generic object data source configuration information.
Renaming the file extension or editing the content of this file may
cause the file to be unrecognizable by the program.
-->
<GenericObjectDataSource DisplayName="DocumentStreamResponse" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
<TypeInfo>DigitalData.Modules.EDMI.API.EDMIServiceReference.DocumentStreamResponse, Connected Services.EDMIServiceReference.Reference.vb.dll, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</TypeInfo>
</GenericObjectDataSource>

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
This file is automatically generated by Visual Studio .Net. It is
used to store generic object data source configuration information.
Renaming the file extension or editing the content of this file may
cause the file to be unrecognizable by the program.
-->
<GenericObjectDataSource DisplayName="ExecuteNonQueryResponse" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
<TypeInfo>DigitalData.Modules.EDMI.API.EDMIServiceReference.ExecuteNonQueryResponse, Connected Services.EDMIServiceReference.Reference.vb.dll, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</TypeInfo>
</GenericObjectDataSource>

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
This file is automatically generated by Visual Studio .Net. It is
used to store generic object data source configuration information.
Renaming the file extension or editing the content of this file may
cause the file to be unrecognizable by the program.
-->
<GenericObjectDataSource DisplayName="GetAttributeValueResponse" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
<TypeInfo>DigitalData.Modules.EDMI.API.EDMIServiceReference.GetAttributeValueResponse, Connected Services.EDMIServiceReference.Reference.vb.dll, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</TypeInfo>
</GenericObjectDataSource>

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
This file is automatically generated by Visual Studio .Net. It is
used to store generic object data source configuration information.
Renaming the file extension or editing the content of this file may
cause the file to be unrecognizable by the program.
-->
<GenericObjectDataSource DisplayName="GetClientConfigResponse" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
<TypeInfo>DigitalData.Modules.EDMI.API.EDMIServiceReference.GetClientConfigResponse, Connected Services.EDMIServiceReference.Reference.vb.dll, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</TypeInfo>
</GenericObjectDataSource>

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
This file is automatically generated by Visual Studio .Net. It is
used to store generic object data source configuration information.
Renaming the file extension or editing the content of this file may
cause the file to be unrecognizable by the program.
-->
<GenericObjectDataSource DisplayName="GetDatatableResponse" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
<TypeInfo>DigitalData.Modules.EDMI.API.EDMIServiceReference.GetDatatableResponse, Connected Services.EDMIServiceReference.Reference.vb.dll, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</TypeInfo>
</GenericObjectDataSource>

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
This file is automatically generated by Visual Studio .Net. It is
used to store generic object data source configuration information.
Renaming the file extension or editing the content of this file may
cause the file to be unrecognizable by the program.
-->
<GenericObjectDataSource DisplayName="GetFileObjectResponse" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
<TypeInfo>DigitalData.Modules.EDMI.API.EDMIServiceReference.GetFileObjectResponse, Connected Services.EDMIServiceReference.Reference.vb.dll, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</TypeInfo>
</GenericObjectDataSource>

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
This file is automatically generated by Visual Studio .Net. It is
used to store generic object data source configuration information.
Renaming the file extension or editing the content of this file may
cause the file to be unrecognizable by the program.
-->
<GenericObjectDataSource DisplayName="GetScalarValueResponse" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
<TypeInfo>DigitalData.Modules.EDMI.API.EDMIServiceReference.GetScalarValueResponse, Connected Services.EDMIServiceReference.Reference.vb.dll, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</TypeInfo>
</GenericObjectDataSource>

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
This file is automatically generated by Visual Studio .Net. It is
used to store generic object data source configuration information.
Renaming the file extension or editing the content of this file may
cause the file to be unrecognizable by the program.
-->
<GenericObjectDataSource DisplayName="ImportFileResponse" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
<TypeInfo>DigitalData.Modules.EDMI.API.EDMIServiceReference.ImportFileResponse, Connected Services.EDMIServiceReference.Reference.vb.dll, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</TypeInfo>
</GenericObjectDataSource>

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
This file is automatically generated by Visual Studio .Net. It is
used to store generic object data source configuration information.
Renaming the file extension or editing the content of this file may
cause the file to be unrecognizable by the program.
-->
<GenericObjectDataSource DisplayName="NewFileResponse" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
<TypeInfo>DigitalData.Modules.EDMI.API.EDMIServiceReference.NewFileResponse, Connected Services.EDMIServiceReference.Reference.vb.dll, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</TypeInfo>
</GenericObjectDataSource>

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
This file is automatically generated by Visual Studio .Net. It is
used to store generic object data source configuration information.
Renaming the file extension or editing the content of this file may
cause the file to be unrecognizable by the program.
-->
<GenericObjectDataSource DisplayName="NonQueryResult" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
<TypeInfo>DigitalData.Modules.EDMI.API.EDMIServiceReference.NonQueryResult, Connected Services.EDMIServiceReference.Reference.vb.dll, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</TypeInfo>
</GenericObjectDataSource>

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
This file is automatically generated by Visual Studio .Net. It is
used to store generic object data source configuration information.
Renaming the file extension or editing the content of this file may
cause the file to be unrecognizable by the program.
-->
<GenericObjectDataSource DisplayName="RightsAccessRight" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
<TypeInfo>DigitalData.Modules.EDMI.API.EDMIServiceReference.RightsAccessRight, Connected Services.EDMIServiceReference.Reference.vb.dll, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</TypeInfo>
</GenericObjectDataSource>

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
This file is automatically generated by Visual Studio .Net. It is
used to store generic object data source configuration information.
Renaming the file extension or editing the content of this file may
cause the file to be unrecognizable by the program.
-->
<GenericObjectDataSource DisplayName="ScalarResult" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
<TypeInfo>DigitalData.Modules.EDMI.API.EDMIServiceReference.ScalarResult, Connected Services.EDMIServiceReference.Reference.vb.dll, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</TypeInfo>
</GenericObjectDataSource>

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
This file is automatically generated by Visual Studio .Net. It is
used to store generic object data source configuration information.
Renaming the file extension or editing the content of this file may
cause the file to be unrecognizable by the program.
-->
<GenericObjectDataSource DisplayName="SetAttributeValueResponse" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
<TypeInfo>DigitalData.Modules.EDMI.API.EDMIServiceReference.SetAttributeValueResponse, Connected Services.EDMIServiceReference.Reference.vb.dll, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</TypeInfo>
</GenericObjectDataSource>

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
This file is automatically generated by Visual Studio .Net. It is
used to store generic object data source configuration information.
Renaming the file extension or editing the content of this file may
cause the file to be unrecognizable by the program.
-->
<GenericObjectDataSource DisplayName="TableResult" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
<TypeInfo>DigitalData.Modules.EDMI.API.EDMIServiceReference.TableResult, Connected Services.EDMIServiceReference.Reference.vb.dll, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</TypeInfo>
</GenericObjectDataSource>

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
This file is automatically generated by Visual Studio .Net. It is
used to store generic object data source configuration information.
Renaming the file extension or editing the content of this file may
cause the file to be unrecognizable by the program.
-->
<GenericObjectDataSource DisplayName="TestObjectIdExistsResponse" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
<TypeInfo>DigitalData.Modules.EDMI.API.EDMIServiceReference.TestObjectIdExistsResponse, Connected Services.EDMIServiceReference.Reference.vb.dll, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</TypeInfo>
</GenericObjectDataSource>

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
This file is automatically generated by Visual Studio .Net. It is
used to store generic object data source configuration information.
Renaming the file extension or editing the content of this file may
cause the file to be unrecognizable by the program.
-->
<GenericObjectDataSource DisplayName="UpdateFileResponse" Version="1.0" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
<TypeInfo>DigitalData.Modules.EDMI.API.EDMIServiceReference.UpdateFileResponse, Connected Services.EDMIServiceReference.Reference.vb.dll, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</TypeInfo>
</GenericObjectDataSource>

View File

@@ -7,7 +7,7 @@
<xs:element minOccurs="0" name="AttributeValue" nillable="true" type="xs:string" />
<xs:element minOccurs="0" name="Language" nillable="true" type="xs:string" />
<xs:element minOccurs="0" name="ObjectId" type="xs:long" />
<xs:element minOccurs="0" name="Who" type="xs:long" />
<xs:element minOccurs="0" name="Who" nillable="true" type="xs:string" />
</xs:sequence>
</xs:complexType>
<xs:element name="SetAttributeValueRequest" nillable="true" type="tns:SetAttributeValueRequest" />

View File

@@ -1810,7 +1810,7 @@ Namespace EDMIServiceReference
Private ObjectIdField As Long
<System.Runtime.Serialization.OptionalFieldAttribute()> _
Private WhoField As Long
Private WhoField As String
<Global.System.ComponentModel.BrowsableAttribute(false)> _
Public Property ExtensionData() As System.Runtime.Serialization.ExtensionDataObject Implements System.Runtime.Serialization.IExtensibleDataObject.ExtensionData
@@ -1875,12 +1875,12 @@ Namespace EDMIServiceReference
End Property
<System.Runtime.Serialization.DataMemberAttribute()> _
Public Property Who() As Long
Public Property Who() As String
Get
Return Me.WhoField
End Get
Set
If (Me.WhoField.Equals(value) <> true) Then
If (Object.ReferenceEquals(Me.WhoField, value) <> true) Then
Me.WhoField = value
Me.RaisePropertyChanged("Who")
End If

View File

@@ -80,6 +80,7 @@
<Compile Include="Modules\Globix\ImportFile.vb" />
<Compile Include="Helpers.vb" />
<Compile Include="Modules\IDB\NewFile.vb" />
<Compile Include="Modules\IDB\SetAttributeValue.vb" />
<Compile Include="Modules\IDB\SetObjectState.vb" />
<Compile Include="Modules\IDB\UpdateFile.vb" />
<Compile Include="Modules\ZooFlow\GetFileObject.vb" />
@@ -120,58 +121,58 @@
<None Include="Connected Services\EDMIServiceReference\Arrays.xsd">
<SubType>Designer</SubType>
</None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.DocumentInfoResponse.datasource">
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.DocumentInfoResponse1.datasource">
<DependentUpon>Reference.svcmap</DependentUpon>
</None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.DocumentListResponse.datasource">
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.DocumentListResponse1.datasource">
<DependentUpon>Reference.svcmap</DependentUpon>
</None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.DocumentStreamResponse.datasource">
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.DocumentStreamResponse1.datasource">
<DependentUpon>Reference.svcmap</DependentUpon>
</None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.ExecuteNonQueryResponse.datasource">
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.ExecuteNonQueryResponse1.datasource">
<DependentUpon>Reference.svcmap</DependentUpon>
</None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.GetAttributeValueResponse.datasource">
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.GetAttributeValueResponse1.datasource">
<DependentUpon>Reference.svcmap</DependentUpon>
</None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.GetClientConfigResponse.datasource">
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.GetClientConfigResponse1.datasource">
<DependentUpon>Reference.svcmap</DependentUpon>
</None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.GetDatatableResponse.datasource">
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.GetDatatableResponse1.datasource">
<DependentUpon>Reference.svcmap</DependentUpon>
</None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.GetFileObjectResponse.datasource">
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.GetFileObjectResponse1.datasource">
<DependentUpon>Reference.svcmap</DependentUpon>
</None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.GetScalarValueResponse.datasource">
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.GetScalarValueResponse1.datasource">
<DependentUpon>Reference.svcmap</DependentUpon>
</None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.ImportFileResponse.datasource">
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.ImportFileResponse1.datasource">
<DependentUpon>Reference.svcmap</DependentUpon>
</None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.NewFileResponse.datasource">
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.NewFileResponse1.datasource">
<DependentUpon>Reference.svcmap</DependentUpon>
</None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.NonQueryResult.datasource">
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.NonQueryResult1.datasource">
<DependentUpon>Reference.svcmap</DependentUpon>
</None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.RightsAccessRight.datasource">
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.RightsAccessRight1.datasource">
<DependentUpon>Reference.svcmap</DependentUpon>
</None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.ScalarResult.datasource">
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.ScalarResult1.datasource">
<DependentUpon>Reference.svcmap</DependentUpon>
</None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.SetAttributeValueResponse.datasource">
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.SetAttributeValueResponse1.datasource">
<DependentUpon>Reference.svcmap</DependentUpon>
</None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.TableResult.datasource">
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.TableResult1.datasource">
<DependentUpon>Reference.svcmap</DependentUpon>
</None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.TestObjectIdExistsResponse.datasource">
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.TestObjectIdExistsResponse1.datasource">
<DependentUpon>Reference.svcmap</DependentUpon>
</None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.UpdateFileResponse.datasource">
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.EDMIServiceReference.UpdateFileResponse1.datasource">
<DependentUpon>Reference.svcmap</DependentUpon>
</None>
<None Include="Connected Services\EDMIServiceReference\DigitalData.Modules.EDMI.API.xsd">

View File

@@ -0,0 +1,38 @@
Imports DigitalData.Modules.EDMI.API.EDMIServiceReference
Imports DigitalData.Modules.EDMI.API.Options
Imports DigitalData.Modules.Logging
Namespace Modules.IDB
Public Class SetAttributeValue
Inherits BaseMethod
Public Sub New(pLogConfig As LogConfig, pChannel As IEDMIServiceChannel)
MyBase.New(pLogConfig, pChannel)
End Sub
Public Async Function RunAsync(pObjectId As String, pAttributeName As String, pAttributeValue As Object, Optional pOptions As SetAttributeValueOptions = Nothing) As Task(Of Boolean)
Try
Dim oParams As New SetAttributeValueRequest With {
.ObjectId = pObjectId,
.Language = pOptions.Language,
.Who = pOptions.Username,
.AttributeName = pAttributeName,
.AttributeValue = pAttributeValue
}
Dim oResponse As SetAttributeValueResponse = Await Channel.SetAttributeValueAsync(oParams)
If oResponse.OK Then
Return True
End If
Logger.Warn("Error while setting Attribute Value: [{0}]", oResponse.ErrorMessage)
Return False
Catch ex As Exception
Logger.Error(ex)
Return False
End Try
End Function
End Class
End Namespace