Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1

TOPIC:

How to Disable Sorting? 09 Apr 2012 07:34 #1942

I've built a simple module for work, very much like the one in the (enjoyable) tutorials but how do I turn OFF sorting?

I want the records to stay in the order they were entered.

Ideally, it would be helpful for the most recent record to always be at the top of the list with the older records being pushed down. This would save a bunch of scrolling down since we'll only be using the most recent 2 or 3 records.

Thank you!

Please Log in or Create an account to join the conversation.

Re: How to Disable Sorting? 09 Apr 2012 10:43 #1943

  • admin
  • admin's Avatar
  • Offline
  • Administrator
  • Administrator
  • Chef
  • Posts: 3711
  • Thank you received: 986
Uncheck it in the properties box.
Coding is now a piece of cake

Please Log in or Create an account to join the conversation.

Re: How to Disable Sorting? 09 Apr 2012 18:18 #1954

Thank you for the help.

The front end and the back end are automatically sorting on the field "My Name". I checked the property for "My Name" in the front and back Collections and the option "Sortable" is NOT ticked. Nor is it ticked for the other 7 fields.

I deleted my project and re-made it. The new project also automatically sorts on "My Name".

As a test, I ticked "Sortable" for "My Name" and the column name "My Name" becomes a clickable to sort ascending or descending.

Any ideas on how to stop each new record from being sorted? The front end and back end tables should have the records listed in the order they were entered.

For example, if I enter in this order: Peter, Andy, Wilhelm as records, the table should be (and the way I need it to be):
Wilhelm
Andy
Peter

But it shows up sorted as:
Andy
Peter
Wilhelm

Any suggestions?

Please Log in or Create an account to join the conversation.

Re: How to Disable Sorting? 09 Apr 2012 18:48 #1955

If I edit the persons name, they are sorted to a different position in the table. A BIG No-go.
Trying different users in the sandbox doesn't change this behavior.

Please Log in or Create an account to join the conversation.

Re: How to Disable Sorting? 10 Apr 2012 08:32 #1958

You have to set a default sort order. Solution is here:

www.j-cook.pro/forum/9-coding-inside-you...g-default-sort-order

Please Log in or Create an account to join the conversation.

Re: How to Disable Sorting? 11 Apr 2012 03:55 #1967

Thank you Giori for the suggestion. I read through it but I don't see how to apply it to my really simple module.

All I want is to turn off automatic sorting. The last record added is either at the top or bottom of the list.

If automatic sorting can not be turned off, then it will have to sort on a web server date & time stamp.

It would actually be useful to have a field that is automatically filled in with the record's creation date & time.

BUT there is no "Date & Time" data type in Builder so how do I add an automatic D&T field?
Thanks!

Please Log in or Create an account to join the conversation.

Re: How to Disable Sorting? 11 Apr 2012 05:09 #1968

I just saw this current post about the lack of a Date & Time data type:

www.j-cook.pro/forum/12-new-functionalities/149-date-a-time

So maybe it is impossible to have an unsorted (or get the same end result by using sorted-by-date-&-time) table?

Please Log in or Create an account to join the conversation.

Re: How to Disable Sorting? 11 Apr 2012 06:48 #1970

You need to use the "Creation Date Wizard" in your table. Then you get the creation date (or Modfication date if you use the "Modification Date Wizard"). With this and the "Order By" change recommended in the link mentioned above you can create what you want.
Unfortunately the Creation Date Wizard does not support date & time, which is quite a drawback. I do not understand why Jocelyn does not put more importance in adding this as it is a vital element of database management and has been requested many times. And it is standard in Joomla to have date and time in the same field.

In my case I created an intranet application where users have to write weekly reports, so it was enough to simply sort by creation date having the newest report record on top. So the time here was not relevant. But in most cases it is.
The following user(s) said Thank You: admin

Please Log in or Create an account to join the conversation.

Last edit: by giori.

Re: How to Disable Sorting? 11 Apr 2012 06:59 #1973

  • admin
  • admin's Avatar
  • Offline
  • Administrator
  • Administrator
  • Chef
  • Posts: 3711
  • Thank you received: 986
Yes, you are right, I am sooo late on this.

I promise you to give move importance on this for next month.
Coding is now a piece of cake

Please Log in or Create an account to join the conversation.

Re: How to Disable Sorting? 11 Apr 2012 08:51 #1974

Jocelyn,

great, and I also sympathize with you. In software development it always takes longer than one would expect to get something done. I see it in my own work. It is so difficult be be on time, as there are always minute details to care about.
The following user(s) said Thank You: admin

Please Log in or Create an account to join the conversation.

Re: How to Disable Sorting? 11 Apr 2012 17:11 #1977

Thank you giori, I'll implement your recommendation later today. I'm curious how the sorting will work with several records with the same date. Hopefully it defaults to sorting in the order they were added and not something unexpected like "Name"!

Can't wait to test...

Please Log in or Create an account to join the conversation.

  • Page:
  • 1
Time to create page: 0.113 seconds

  I want to save the world...... let's cook a solution about it.
VeCrea (Forum)

Get Started