← Back to team overview

dhis2-devs team mailing list archive

Re: [Bug 567080] [NEW] dataset-section-no-sorting

 

Hi

Jason, I think your problem is that the "available data elements" list is
not sorted, right? I have fixed this, someone simply forgot to put in the
sorting code in the action.

Bob, I agree that "dataset" should have been "dataelementset". Changing it
will take a lot of work. Also agree that view-related attributes of a
data(element)set should be in a different object. This will as Ola says be
worked on for 2.0.5.

Lars


On Tue, Apr 20, 2010 at 2:30 PM, Ola Hodne Titlestad <olatitle@xxxxxxxxx>wrote:

> On 20 April 2010 13:04, Jason Pickering <jason.p.pickering@xxxxxxxxx>wrote:
>
>> Hi Ola,
>>
>> Here is what i am trying to do. I have a paper data collection form
>> that i am implementing as a custom data entry screen. Pretty simple in
>> practice, but is laborious to implement because 1) We do not have
>> multidimensional/category combo type data elements here and 2) The
>> sort order of the data elements is all jumbled up.
>>
>>
>>  I want to break up the dataset, which is rather large, into sections
>> that correspond to two separate pages of the paper aggregation form.
>> Why? Well, it is not entirely necessary I guess, since I am using a
>> custom data entry form, but some users actually prefer to use the
>> "default" form instead of the custom form. I want to be sure that the
>> data elements are ordered properly and they have appropriate sections.
>> Thus, I figured that the data set sections would do this for me.
>>
>
> Sound reasonable to use the data set sections for this yes. If you imported
> the custom sort order for the full list of data elements from 1.4 to 2 then
> you can turn on custom system wide sort order and that sort order should(!)
> then be respected by all modules and lists, including the data set section
> edit lists and the data entry form. That is how it is supposed to be at
> least.
>
>
>
>> Perhaps this is totally unnecessary, but it still does not mean that
>> this bug is not valid. The list remains totally unordered, so if
>> people want to have a data set section for whatever reason, it should
>> be presented in some form that makes sense. Seems Bob may have already
>> figured it out.
>>
>
> Yes, as I said these lists in data set section edit should also respect the
> system wide sort order, so this seems like a bug.
>
>
>>
>> >Why would that be important if it has nothing to do with the order in the
>> >form?
>> >And again, why use the section at all?
>>
>> Well, maybe you can enlighten us then as to the use of data set
>> sections? I assumed that it was for the purpose I am trying to
>> achieve, but perhaps not.
>>
>
> My point was that it is the sort order in the default form that matters the
> most, right?
> But of course I agree that the lists in the data set edit should also be
> sorted and easy to browse.
> Was just confused by the statement that it was not the ordering in the form
> that was important.
>
>
>> If you take a look at the datasetmembers table, there is no sortorder
>> field, unlike DHIS1.4. DHIS 1.4 has both a sort order in the data
>> elements table, as well as the equivalent of the datasetmembers table.
>>
>
> Yes, I am aware of this difference, and I guess I can understand that is
> sometimes is useful to have a different sort order among data elements in a
> dataset than when they appear in a full list. Although I am not sure how
> often that is actually the case. A few years back we had a quite different
> data set model in DHIS2 and then we had an object called datasetelement.
> To this object we could attach other properties such as sortorder. This
> object no longer exists and as such the model does not support any other
> properties on the individual data elements belonging to a specific dataset.
> If I remember correctly this new rationale behind the change of model was to
> simplify what had become a very comlicated data set model and removing the
> datasetelement sort order thing was traded for simplicity. After all in most
> cases the sort order for a full list of data elements would still be valid
> when looking at a subset of those data elements. I think sort order in forms
> will be a major part of the new form model , and as Bob writes, should be
> part of the form (e.g. form elements with various properties) and not the
> data model. The new form model will most likely not be ready for 2.0.5,at
> least per the discussion we had in Oslo some weeks back, but some interim
> fixes will be there as stated in the blueprint.
>
>
>> It would just be very useful to be able to resort the data elements
>> (and all objects for that matter) in the browser itself. Sort by name
>> (Ascending, descending), sort by code, sort by sort order, etc. When I
>> was in Tajikistan, I thought that Murod has sent some code for server
>> side filtering and ordering. Not sure what happened to it, but that is
>> exactly what would be useful to have in these situations.
>>
>
> In maintenance->data elements there is a sort button in the top right
> corner and there you can sort all the data elements.
> Note that this ordering only takes effect after you have set your user
> setting Sort Order to "custom".
> After this you will see data elements sorted by this custom sort order in
> all lists in all modules, at least if the code follows the design.
>
> The other sort options found in user settings are name, short name,
> alternative name and code.
>
> What you are asking for is a way to more quickly swap between different
> sorting schemes inside each module and not only through system-wide user
> settings, or something else?
>
> Ola
> ------------
>
>
>>
>> Regards,
>> Jason
>>
>>
>> On Tue, Apr 20, 2010 at 11:29 AM, Ola Hodne Titlestad
>> <olatitle@xxxxxxxxx> wrote:
>> > Jason,
>> >
>> > What are you trying to achieve using the dataset sections?
>> >
>> >
>> > Ola Hodne Titlestad |Technical Officer|
>> > Health Metrics Network (HMN) | World Health Organization
>> > Avenue Appia 20 |1211 Geneva 27, Switzerland | Email:
>> > titlestado@xxxxxxx|Tel: +41 788216897
>> > Website: www.healthmetricsnetwork.org
>> >
>> > Better Information. Better Decisions. Better Health.
>> >
>> >
>> > On 20 April 2010 11:19, Jason Pickering <jason.p.pickering@xxxxxxxxx>
>> wrote:
>> >>
>> >> Sounds good, but I need to fix this now. Will have a look myself and
>> >> see what can be done in the interim. Creating a dataset section is
>> >> nigh impossible with several hundred elements unsorted.
>> >>
>> >> On 4/20/10, Ola Hodne Titlestad <olatitle@xxxxxxxxx> wrote:
>> >> > Hi,
>> >> >
>> >> > Note that there is a planned revamp of the whole forms/dataset model
>> >> > quite
>> >> > soon and this blueprint for 2.0.5 covers at least improved
>> functionality
>> >> > in
>> >> > terms of defining the layout of default forms, incl. sort order:
>> >> > https://blueprints.launchpad.net/dhis2/+spec/improved-forms
>> >> >
>> >> > The goal is to be able to use the default tabular forms as much as
>> >> > possible,
>> >> > since that will save us all a lot of time.
>> >> > These default tabular forms should be (as it they are today)
>> generated
>> >> > off a
>> >> > data set with data elements and one or more category combos,  but we
>> >> > need to
>> >> > provide the form designers with more options in terms of disabling
>> >> > certain
>> >> > fields, sort order of data elements, pivoting of the table (option to
>> >> > have
>> >> > data elements on columns and categories on rows).
>> >> >
>> >> > The idea is to use custom forms (which take a lot more time to
>> design)
>> >> > only
>> >> > when its not possible to generate the form off the data set and some
>> >> > additional (and not too complicated) layout choices.
>> >> > Most tabular forms should be possible to auto generate.
>> >> >
>> >> > Feel free to add to the blueprint.
>> >> >
>> >> > Ola Hodne Titlestad |Technical Officer|
>> >> > Health Metrics Network (HMN) | World Health Organization
>> >> > Avenue Appia 20 |1211 Geneva 27, Switzerland | Email:
>> >> > titlestado@xxxxxxx|Tel:
>> >> > +41 788216897
>> >> > Website: www.healthmetricsnetwork.org
>> >> >
>> >> > Better Information. Better Decisions. Better Health.
>> >> >
>> >> >
>> >> > On 20 April 2010 10:31, Jason Pickering <jason.p.pickering@xxxxxxxxx
>> >
>> >> > wrote:
>> >> >
>> >> >> This may actually be a problem due to the way that the data elements
>> >> >> were sorted in DHIS 1.4. 1.4 allows you to specify both a sorting
>> >> >> order in the dataelement table, as well as the equivalent of the
>> >> >> datasetmembers table. A global (system) setting allows one to chose
>> >> >> how they should be displayed in lists. Our data elements were sorted
>> >> >> correctly according to the dataset,  but as far as I can tell,
>>  DHIS2
>> >> >> does not support sorting of data elements by data set (at least
>> there
>> >> >> is no field in datasetmembers that would support this)
>> >> >>
>> >> >> On  the datasetsection page, the ordering that is presented to me,
>> is
>> >> >> not in alphabetical order the SECOND time I enter the page. The
>> first
>> >> >> time, everything is ordered alphabetically (user setting), the
>> second
>> >> >> time around, the ordering is completely mixed up. I would expect it
>> to
>> >> >> follow the user setting (alphabetical) but this does not seem to be
>> >> >> the case.
>> >> >>
>> >> >> I agree that it should probably be a system setting, similar to
>> >> >> DHIS1.4.
>> >> >>
>> >> >>
>> >> >>
>> >> >> On Tue, Apr 20, 2010 at 10:16 AM, Ola Hodne Titlestad
>> >> >> <olatitle@xxxxxxxxx> wrote:
>> >> >> > Hi,
>> >> >> >
>> >> >> > My understanding of this is that you can apply the system wide
>> custom
>> >> >> sort
>> >> >> > order to data elements in a data set section.
>> >> >> >
>> >> >> > In user settings you can set the sort order to be custom and then
>> go
>> >> >> > to
>> >> >> > Maintenance>Data Elements and sort the elements in the full list
>> >> >> > there.
>> >> >> >
>> >> >> > Then the data elements in the data set section (or data set) will
>> be
>> >> >> sorted
>> >> >> > according to their global sort order when listed in a default data
>> >> >> > entry
>> >> >> > form.
>> >> >> >
>> >> >> > My only concern with this is that the sort order is a user setting
>> >> >> > and
>> >> >> not a
>> >> >> > system setting so different users doing data entry might
>> experience
>> >> >> > different sort order, which may not be desired in data entry
>> forms.
>> >> >> >
>> >> >> >
>> >> >> > Ola Hodne Titlestad |Technical Officer|
>> >> >> > Health Metrics Network (HMN) | World Health Organization
>> >> >> > Avenue Appia 20 |1211 Geneva 27, Switzerland | Email:
>> >> >> > titlestado@xxxxxxx|Tel: +41 788216897
>> >> >> > Website: www.healthmetricsnetwork.org
>> >> >> >
>> >> >> > Better Information. Better Decisions. Better Health.
>> >> >> >
>> >> >> >
>> >> >> > On 20 April 2010 10:08, Hieu Dang Duy <hieu.hispvietnam@xxxxxxxxx
>> >
>> >> >> wrote:
>> >> >> >>
>> >> >> >> Dear Jason,
>> >> >> >>
>> >> >> >> Actually, this ordering is completely belongs to your action
>> during
>> >> >> >> on
>> >> >> >> sorting data elements in the selected list.
>> >> >> >> For example;
>> >> >> >>
>> >> >> >> Assuming that, there are five data elements such as: A, B, C, D
>> and
>> >> >> >> E
>> >> >> >> in
>> >> >> >> the available list. Then, if select each element following the
>> >> >> >> ordering
>> >> >> >> likes B, D, A, C in the selected list. So after coming back to
>> edit
>> >> >> >> that
>> >> >> >> data section you will see the selected list of this one, which is
>> >> >> >> not
>> >> >> >> ordered alphabetically in expecting on.
>> >> >> >>
>> >> >> >> On Tue, Apr 20, 2010 at 2:12 PM, jason.p.pickering
>> >> >> >> <jason.p.pickering@xxxxxxxxx> wrote:
>> >> >> >>>
>> >> >> >>> Public bug reported:
>> >> >> >>>
>> >> >> >>> When creating a data set section, there is no logical ordering
>> >> >> >>> applied
>> >> >> >>> to the data elements. The first time I created the dataset
>> section,
>> >> >> they
>> >> >> >>> appeared to be ordered alphabetically. When I saved and edited
>> the
>> >> >> >>> dataset again, the ordering is completely jumbled up.
>> >> >> >>>
>> >> >> >>> ** Affects: dhis2
>> >> >> >>>     Importance: Undecided
>> >> >> >>>         Status: New
>> >> >> >>>
>> >> >> >>> --
>> >> >> >>> dataset-section-no-sorting
>> >> >> >>> https://bugs.launchpad.net/bugs/567080
>> >> >> >>> You received this bug notification because you are a member of
>> DHIS
>> >> >> >>> 2
>> >> >> >>> developers, which is subscribed to DHIS.
>> >> >> >>>
>> >> >> >>> Status in DHIS 2 - District Health Information Software: New
>> >> >> >>>
>> >> >> >>> Bug description:
>> >> >> >>> When creating a data set section, there is no logical ordering
>> >> >> >>> applied
>> >> >> to
>> >> >> >>> the data elements. The first time I created the dataset section,
>> >> >> >>> they
>> >> >> >>> appeared to be ordered alphabetically. When I saved and edited
>> the
>> >> >> dataset
>> >> >> >>> again, the ordering is completely jumbled up.
>> >> >> >>>
>> >> >> >>>
>> >> >> >>>
>> >> >> >>> _______________________________________________
>> >> >> >>> Mailing list:
>> >> >> >>>
>> >> >> >>> https://launchpad.net/~dhis2-devs<https://launchpad.net/%7Edhis2-devs>
>> <https://launchpad.net/%7Edhis2-devs>
>> >> >> >>> Post to     : dhis2-devs@xxxxxxxxxxxxxxxxxxx
>> >> >> >>> Unsubscribe :
>> >> >> >>>
>> >> >> >>> https://launchpad.net/~dhis2-devs<https://launchpad.net/%7Edhis2-devs>
>> <https://launchpad.net/%7Edhis2-devs>
>> >> >> >>> More help   : https://help.launchpad.net/ListHelp
>> >> >> >>
>> >> >> >>
>> >> >> >>
>> >> >> >> --
>> >> >> >> Hieu.HISPVietnam
>> >> >> >> Good Health !
>> >> >> >>
>> >> >> >> _______________________________________________
>> >> >> >> Mailing list:
>> >> >> >>
>> >> >> >> https://launchpad.net/~dhis2-devs<https://launchpad.net/%7Edhis2-devs>
>> <https://launchpad.net/%7Edhis2-devs>
>> >> >> >> Post to     : dhis2-devs@xxxxxxxxxxxxxxxxxxx
>> >> >> >> Unsubscribe :
>> >> >> >>
>> >> >> >> https://launchpad.net/~dhis2-devs<https://launchpad.net/%7Edhis2-devs>
>> <https://launchpad.net/%7Edhis2-devs>
>> >> >> >> More help   : https://help.launchpad.net/ListHelp
>> >> >> >>
>> >> >> >
>> >> >> >
>> >> >>
>> >> >>
>> >> >>
>> >> >> --
>> >> >> --
>> >> >> Jason P. Pickering
>> >> >> email: jason.p.pickering@xxxxxxxxx
>> >> >> tel:+260968395190
>> >> >>
>> >> >
>> >>
>> >>
>> >> --
>> >> --
>> >> Jason P. Pickering
>> >> email: jason.p.pickering@xxxxxxxxx
>> >> tel:+260968395190
>> >
>> >
>>
>>
>>
>> --
>> --
>> Jason P. Pickering
>> email: jason.p.pickering@xxxxxxxxx
>> tel:+260968395190
>>
>
>
> _______________________________________________
> Mailing list: https://launchpad.net/~dhis2-devs
> Post to     : dhis2-devs@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~dhis2-devs
> More help   : https://help.launchpad.net/ListHelp
>
>

Follow ups

References