← Back to team overview

dhis2-devs-core team mailing list archive

Re: Default view of idObjects in field filter

 

Hi guys

Just reminding everyone about this. Remember now that something like option
sets will -not- have the codes from options available by default, so you
will need to more clearly define what you need
?fields=id,displayName,options[displayName,code] for example

This affects all metadata requests, so this should be the first place to
start if you are seeing metadata related issues suddenly popping up

--
Morten

On Tue, Dec 22, 2015 at 5:49 PM, Lars Helge Øverland <larshelge@xxxxxxxxx>
wrote:

> Nice.
>
> On Tue, Dec 22, 2015 at 11:32 AM, Morten Olav Hansen <mortenoh@xxxxxxxxx>
> wrote:
>
>> This is now implemented. I tested most of the apps, and they seem to
>> function as they should. If you see any issues in your apps, either select
>> fields explicitly or just use the :identifiable preset.
>>
>> --
>> Morten
>>
>> On Fri, Dec 18, 2015 at 3:10 PM, Morten Olav Hansen <mortenoh@xxxxxxxxx>
>> wrote:
>>
>>> Internally displayName falls back to name if not displayName is set (no
>>> translation), so displayName should always be used, its part of id-object.
>>>
>>> --
>>> Morten
>>>
>>> On Fri, Dec 18, 2015 at 2:40 PM, Abyot Gizaw <abyota@xxxxxxxxx> wrote:
>>>
>>>> I also use displayName. But if no displayName, I use name.
>>>>
>>>>
>>>> ---
>>>> Thank you,
>>>> Abyot.
>>>>
>>>> On Fri, Dec 18, 2015 at 10:31 AM, Morten Olav Hansen <
>>>> mortenoh@xxxxxxxxx> wrote:
>>>>
>>>>> Hi everyone
>>>>>
>>>>> As you probably, if you do something like
>>>>> /api/organisationUnits.json?fields=*
>>>>>
>>>>> All the objects are expanded, and by default the idObjects /
>>>>> collection of idObjects are expanded to include
>>>>> id,code,name,href,created,lastUpdated.
>>>>>
>>>>> This adds a lot of space to default payloads, and I don't think we
>>>>> actually need all this properties.
>>>>>
>>>>> 1) Export use-case: We only want the id, nothing else is important, we
>>>>> just need something to link to
>>>>>
>>>>> 2) App use-case: You just want the id and displayName (you should
>>>>> never use name anymore anyways)
>>>>>
>>>>> I think all our apps probably already are requesting displayName
>>>>> (Jan?), so I don't think a change here would affect anyone.
>>>>>
>>>>> I suggest we change the default to just include the id, and then the
>>>>> user can expand more if he needs to (I'm also open to having id,
>>>>> displayName as default.. although I think in many cases you don't need
>>>>> displayName)
>>>>>
>>>>> --
>>>>> Morten
>>>>>
>>>>> --
>>>>> Mailing list: https://launchpad.net/~dhis2-devs-core
>>>>> Post to     : dhis2-devs-core@xxxxxxxxxxxxxxxxxxx
>>>>> Unsubscribe : https://launchpad.net/~dhis2-devs-core
>>>>> More help   : https://help.launchpad.net/ListHelp
>>>>>
>>>>>
>>>>
>>>
>>
>> --
>> Mailing list: https://launchpad.net/~dhis2-devs-core
>> Post to     : dhis2-devs-core@xxxxxxxxxxxxxxxxxxx
>> Unsubscribe : https://launchpad.net/~dhis2-devs-core
>> More help   : https://help.launchpad.net/ListHelp
>>
>>
>
>
> --
> Lars Helge Øverland
> Lead developer, DHIS 2
> University of Oslo
> Skype: larshelgeoverland
> http://www.dhis2.org <https://www.dhis2.org>
>
>

References