AlexHill
Posts: 0
Joined: Sat Nov 02, 2013 1:12 pm

Retain mapping when updating REST service

When I want to add an element to a page that has elements populated by a REST service, I also update the REST response (I create my own responses). The problem is that the mapping disappears when the service is updated. Perhaps if the REST response names are unchanged their mapping should also remain? That way we can add additional elements to the REST response, and only have to map the new elements.

Kateryna Grynko
Posts: 0
Joined: Thu Nov 15, 2012 9:13 am

Retain mapping when updating REST service

Hi Alex,

Element created by service have another names because they should be unique for a page. You can work with them using other selectors, for example:
code.Screen_component/code
where 'Screen' is a page name,
'component' is a component name.

AlexHill
Posts: 0
Joined: Sat Nov 02, 2013 1:12 pm

Retain mapping when updating REST service

Sorry, the element isnt created by the service, let me try and explain with an example.

Current Mapping:
REST -- Element on page
[Name] -- [Label_Name]
[PhoneNumber] -- [Label_PhoneNumber]

Now as the app develops I decide I want to add in a user's mail address too, so I add another label, and update the REST response to include their email address:

REST -- Element on Page
[Name] -- [Label_Name]
[PhoneNumber] -- [Label_PhoneNumber]
[EmailAddress] -- [Label_EmailAddress]

However when I update the service response to include the email address, the current mapping of name and phone number disappear and I need to re-map them. It isnt a huge issue, but it does take a bit of time to re-map things.

Illya Stepanov
Posts: 0
Joined: Mon Mar 18, 2013 8:48 am

Retain mapping when updating REST service

Hi Alex, can you share your app with a href="mailto:support@appery.io" rel="nofollow"support@appery.io/a? We'll test it.
:: http://docs.appery.io/documentation/s...

Return to “Issues”