Describe the bug
I have service with open type entity:
public class ResultObject
{
public string Id { get; set; } = string.Empty;
public IDictionary<string, object> DynamicProperties { get; set; } = new Dictionary<string, object>();
}
Metadata:
<EntityType Name="ResultObject" OpenType="true">
<Key>
<PropertyRef Name="Id" />
</Key>
<Property Name="Id" Type="Edm.String" Nullable="false" />
</EntityType>
ODataConnectedService generated class:
[global::Microsoft.OData.Client.Key("Id")]
[global::Microsoft.OData.Client.OriginalNameAttribute("ResultObject")]
public partial class ResultObject : global::Microsoft.OData.Client.BaseEntityType
{
/// <summary>
/// Create a new ResultObject object.
/// </summary>
/// <param name="ID">Initial value of Id.</param>
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.OData.Client.Design.T4", "#VersionNumber#")]
public static ResultObject CreateResultObject(string ID)
{
ResultObject resultObject = new ResultObject();
resultObject.Id = ID;
return resultObject;
}
/// <summary>
/// There are no comments for Property Id in the schema.
/// </summary>
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.OData.Client.Design.T4", "#VersionNumber#")]
[global::Microsoft.OData.Client.OriginalNameAttribute("Id")]
[global::System.ComponentModel.DataAnnotations.RequiredAttribute(ErrorMessage = "Id is required.")]
public virtual string Id
{
get
{
return this._Id;
}
set
{
this.OnIdChanging(value);
this._Id = value;
this.OnIdChanged();
}
}
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.OData.Client.Design.T4", "#VersionNumber#")]
private string _Id;
partial void OnIdChanging(string value);
partial void OnIdChanged();
/// <summary>
/// There are no comments for Property DynamicProperties in the schema.
/// </summary>
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.OData.Client.Design.T4", "#VersionNumber#")]
[global::Microsoft.OData.Client.OriginalNameAttribute("DynamicProperties")]
public virtual global::System.Collections.Generic.IDictionary<string, object> DynamicProperties
{
get
{
return this._DynamicProperties;
}
set
{
this.OnDynamicPropertiesChanging(value);
this._DynamicProperties = value;
this.OnDynamicPropertiesChanged();
}
}
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.OData.Client.Design.T4", "#VersionNumber#")]
private global::System.Collections.Generic.IDictionary<string, object> _DynamicProperties = new global::System.Collections.Generic.Dictionary<string, object>();
partial void OnDynamicPropertiesChanging(global::System.Collections.Generic.IDictionary<string, object> value);
partial void OnDynamicPropertiesChanged();
}
DynamicProperties property on generated class missing [ContainerProperty] attribute.
Version of the Project affected
ODataConnectedService v1.0.2.0
VisualStudio Version v17.8.7
Microsoft.Odata.Client v7.20.0
To Reproduce
Create or update connected service
Expected behavior
DynamicProperties property should have [ContainerPropertyAttribute] attribute
Actual behavior
DynamicProperties property does not have [ContainerPropertyAttribute] attribute
Describe the bug
I have service with open type entity:
Metadata:
ODataConnectedService generated class:
DynamicPropertiesproperty on generated class missing[ContainerProperty]attribute.Version of the Project affected
ODataConnectedService v1.0.2.0
VisualStudio Version v17.8.7
Microsoft.Odata.Client v7.20.0
To Reproduce
Create or update connected service
Expected behavior
DynamicPropertiesproperty should have[ContainerPropertyAttribute]attributeActual behavior
DynamicPropertiesproperty does not have[ContainerPropertyAttribute]attribute