Ticket #951 (closed Defect: worksforme)

Opened 8 years ago

Last modified 8 years ago

a composite label value is not updated when the child topic involved in it is

Reported by: Malte Owned by: jri
Priority: Major Milestone:
Component: DeepaMehta Standard Distribution Version: 4.7
Keywords: Cc: jri
Complexity: 5 Area: Application Framework / API
Module: deepamehta-core

Description

What i justhave observed is, when updating the "ka2.geo_object.name" value via a PUT to the "core/topic" REST API, the label of the "Geo Object" does not change.

I could not find a related ticket dealing with this.

My first guess is, may be the following has a role in this issue:
Some type defs do not include an explicit label configuration, such as "ka2.geo_object" for example. In this case, some default applies to calculate the label value used in the composite topic (the rule is something like, "first text child" or so but i am not 100% sure).

Change History

comment:1 Changed 8 years ago by jri

When updating a child topic directly the parent's label is not recalculated. You have to update the parent instead.

Instead

PUT /core/topic/<childId>

{
    value: "new value"
}

do this:

PUT /core/topic/<parentId>

{
    childs: {
        ka2.geo_object.name: "new value"
    }
}

comment:2 Changed 8 years ago by jri

Regarding the label config you're almost right. If there is no explicit label config for a composite the label of its first child is used, regardless of its data type (Text, Number, ...). This rule applies recursively.

comment:3 Changed 8 years ago by jri

  • Status changed from new to closed
  • Resolution set to worksforme
Note: See TracTickets for help on using tickets.