dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #10002
Re: [Bug 705340] Re: User list paging sort order problem
I think this patch creates the desired behaviour.
Regards,
Jason
=== modified file
'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/user/hibernate/HibernateUserStore.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/user/hibernate/HibernateUserStore.java 2010-12-30
09:13:41 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/user/hibernate/HibernateUserStore.java 2011-01-23
07:52:12 +0000
@@ -135,6 +135,7 @@
Session session = sessionFactory.getCurrentSession();
return session.createQuery( "from User" ).list();
+
}
public Collection<User> getUsersByOrganisationUnit(
OrganisationUnit organisationUnit )
@@ -394,7 +395,7 @@
{
Session session = sessionFactory.getCurrentSession();
- return session.createQuery( "from UserCredentials"
).setFirstResult( first ).setMaxResults( max ).list();
+ return session.createQuery( "from UserCredentials order by
username" ).setFirstResult( first ).setMaxResults( max ).list();
}
@SuppressWarnings("unchecked")
On Sun, Jan 23, 2011 at 8:30 AM, Shinichi Suzuki
<705340@xxxxxxxxxxxxxxxxxx> wrote:
> Hi Lars,
>
> Sorry, I did not clear my browser cash. (Tested 206 Build 2724)
> It is nice for me. I can see many improvements.
>
> But it is still remain my point out problem, sorry.
> You could test to reduce no. of rows in page setting.
>
> Best regards,
> Shinichi
>
> From: Shinichi Suzuki [mailto:shin461@xxxxxxxxx]
> Sent: Sunday, January 23, 2011 8:32 AM
> To: 'Bug 705340'
> Subject: RE: [Bug 705340] Re: User list paging sort order problem
>
> Hi Lars
> Thank you very much for your helping.
> But my description may wrong. Still the same. Please look at hiskenya.
>
> Example of my intention:
> When over 50 user definition, current user list in "User management" in "User" from menu;
> I guess as following sequence.
> For first page,
> 1. take first 50 from database
> 2. sort of this 50 user by name.
> 3. list out.
> For net page,
> 1. take next 50 from database
> 2. sort of this 50 user by name.
> 3. list out.
> Correct sequence should be as follow.
> For first page,
> 1. take out all users name from the database.
> 2. sort of all the user by name.
> 3. list first 50 users from sorted users name.
> For net page,
> 1. take next 50 from sorted users name.
> 2. list out it
>
> Best regards,
> Shinichi
>
> -----Original Message-----
> From: bounces@xxxxxxxxxxxxx [mailto:bounces@xxxxxxxxxxxxx] On Behalf Of Lars Helge Overland
> Sent: Sunday, January 23, 2011 1:56 AM
> To: shin461@xxxxxxxxx
> Subject: Re: [Bug 705340] Re: User list paging sort order problem
>
> Hi Suzuki, can you please test this again? It seems this has been fixed by
> another related bugix.
>
> On Thu, Jan 20, 2011 at 2:09 PM, Shinichi Suzuki
> <705340@xxxxxxxxxxxxxxxxxx>wrote:
>
>> This was happened on DHIS 206
>>
>> --
>> You received this bug notification because you are a member of DHIS 2
>> coordinators, which is the registrant for DHIS.
>> https://bugs.launchpad.net/bugs/705340
>>
>> Title:
>> User list paging sort order problem
>>
>> Status in DHIS 2 - District Health Information Software:
>> New
>>
>> Bug description:
>> User list paging sort order only sorted in a page. When you have multiple
>> pages of users, next page are not sorted.
>> Need sort first and then start list by page size.
>>
>>
>>
>
> --
> You received this bug notification because you are a direct subscriber
> of the bug.
> https://bugs.launchpad.net/bugs/705340
>
> Title:
> User list paging sort order problem
>
> Status in DHIS 2 - District Health Information Software:
> New
>
> Bug description:
> User list paging sort order only sorted in a page. When you have multiple pages of users, next page are not sorted.
> Need sort first and then start list by page size.
>
> To unsubscribe from this bug, go to:
> https://bugs.launchpad.net/dhis2/+bug/705340/+subscribe
>
> --
> You received this bug notification because you are a member of DHIS 2
> India Developers, which is subscribed to DHIS.
> https://bugs.launchpad.net/bugs/705340
>
> Title:
> User list paging sort order problem
>
> Status in DHIS 2 - District Health Information Software:
> New
>
> Bug description:
> User list paging sort order only sorted in a page. When you have multiple pages of users, next page are not sorted.
> Need sort first and then start list by page size.
>
>
>
--
Jason P. Pickering
email: jason.p.pickering@xxxxxxxxx
tel:+260968395190
--
You received this bug notification because you are a member of DHIS 2
developers, which is subscribed to DHIS.
https://bugs.launchpad.net/bugs/705340
Title:
User list paging sort order problem
Status in DHIS 2 - District Health Information Software:
New
Bug description:
User list paging sort order only sorted in a page. When you have multiple pages of users, next page are not sorted.
Need sort first and then start list by page size.
References