Hi,

The name breakdown is follows:

1st level: Represents the name field
2nd level : Represents the name element which appears within the field
definition
3rd level : Represents the value of the name

As an example,the Category field is defined as follows in the RXT
definition:

 <field type="options">
                <name label="Category">Category</name>

If we match the above definition to the JSON configuration:

1st level: Category field definition
2nd level: Name element which occurs within the Category field
3rd level: The value of the name element

As Manu mentioned we can make it less confusing by calling the 3rd level as
"Value".

Thank You,
Sameera

On Thu, Jul 16, 2015 at 7:24 AM, Manuranga Perera <[email protected]> wrote:

> AFAIK,
> the inner most 'name' is an implementation detail it is not necessary to
> be mentioned in asset.configure
>
>
> asset.configure = function() {
>     return {
>         table: {
>             overview: {
>                 fields: {
>                     provider: {
>                         auto: true
>                     },
>                     name: {
>                         name: {
>                             label: 'Name'
>                         },
>                         updatable: false,
>                         validation: function() {}
>                     },
>                     version: {
>                         name: {
>                             label: 'Version'
>                         }
>                     },
>                     createdtime: {
>                         hidden: true
>                     }
>                 }
>             },
>
>
>
> On Thu, Jul 16, 2015 at 4:07 PM, Ruchira Wageesha <[email protected]>
> wrote:
>
>> SameeraM,
>>
>> Do we have any reason to design following section to have 3 nested "name"
>> properties?
>>
>> /Ruchira
>>
>> [1]
>> name: {
>>     name: {
>>         name: 'name',
>>         label: 'Name'
>>     },
>>     updatable: false,
>>     validation: function() {}
>> }
>>
>> On Wed, Jul 15, 2015 at 2:22 PM, Mariangela Hills <[email protected]>
>> wrote:
>>
>>> Hi team,
>>>
>>> Can you please clarify the following doubts:
>>>
>>> 1) How come the field "name" appears in three consecutive nested levels
>>> in the default
>>> <ES_HOME>/repository/deployment/server/jaggeryapps/publisher/extensions/assets/default/asset.js
>>> [1] file?
>>>
>>> 2) In an offline chat, you mentioned that the properties returned by the
>>> asset.configure callback function were as follows: name, label, type,
>>> readonly, hidden, updatable. As the field "label" appears at a different
>>> level when compared to the other fields, is it correct to have "label" too
>>> as a property that is returned by the asset.configure callback method? If
>>> 'label' is actually a property that is returned, shouldn't it be defined at
>>> the same level as the other properties that are returned?
>>>
>>>
>>> [1]
>>> asset.configure = function() {
>>>     return {
>>>         table: {
>>>             overview: {
>>>                 fields: {
>>>                     provider: {
>>>                         auto: true
>>>                     },
>>>                     name: {
>>>                         name: {
>>>                             name: 'name',
>>>                             label: 'Name'
>>>                         },
>>>                         updatable: false,
>>>                         validation: function() {}
>>>                     },
>>>                     version: {
>>>                         name: {
>>>                             label: 'Version'
>>>                         }
>>>                     },
>>>                     createdtime: {
>>>                         hidden: true
>>>                     }
>>>                 }
>>>             },
>>>
>>>
>>>
>>>
>>>
>>> Regards,
>>> Mariangela
>>>
>>>
>>> *Mariangela Hills*
>>> Senior Technical Writer - WSO2, Inc. http://wso2.com
>>> Committer and PMC member - Apache Stratos
>>> email:[email protected] | mobile: +94 773 500185
>>>
>>
>>
>>
>> --
>>
>> *Ruchira Wageesha**Technical Lead*
>> *WSO2 Inc. - lean . enterprise . middleware |  wso2.com <http://wso2.com>*
>>
>> *email: [email protected] <[email protected]>,   blog:
>> ruchirawageesha.blogspot.com <http://ruchirawageesha.blogspot.com>,
>> mobile: +94 77 5493444 <%2B94%2077%205493444>*
>>
>
>
>
> --
> With regards,
> *Manu*ranga Perera.
>
> phone : 071 7 70 20 50
> mail : [email protected]
>



-- 
Sameera Medagammaddegedara
Software Engineer

Contact:
Email: [email protected]
Mobile: + 94 077 255 3005
_______________________________________________
Dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to