Keyword

K2 custom ordering not working

  • Dion Eng
  • Dion Eng's Avatar Topic Author
  • Offline
  • Junior Member
More
9 years 9 months ago - 9 years 9 months ago #145695 by Dion Eng
K2 custom ordering not working was created by Dion Eng
The drag-and-drop ordering is a hit and miss. Sometimes it works and sometimes it doesn't. I'm running Joomla v3.3.6 and K2 v2.6.9. My setup is multiple 1-level categories and many items within each. If I try dragging an item far down the list and bring it to first the change in the order becomes sporadic on the front-end. Then I refresh the back-end and the list changes as if my ordering was not saved.

I filter the category, publish state on, feature on, and click on the up/down arrow ordering column and set it at an ascending order.

I inspected the code and get 2 errors showing: "TypeError: undefined is not an object (evaluating 'a.length')"

Any ideas on a fix? Someone please help.
Last edit: 9 years 9 months ago by Dion Eng.

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

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
9 years 9 months ago #145716 by Krikor Boghossian
Replied by Krikor Boghossian on topic K2 custom ordering not working
Hello, Have you tried it under 3.4.3?
Also I would suggest backing up and installing the dev version.
You can get it from here: getk2.org/assets/get/

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

  • Dion Eng
  • Dion Eng's Avatar Topic Author
  • Offline
  • Junior Member
More
9 years 9 months ago #145727 by Dion Eng
Replied by Dion Eng on topic K2 custom ordering not working
Hi Krikor,

Thanks for the response. I made a local development server and loaded the K2 dev 3.4.3. It's a little better but still behaves the same way. When I reorder the items it may show the first 2 or 3 in correct order but then the rest is wrong. Then, if I refresh the back-end the list reflects the incorrect order of the front-end.

Here's a quick video demonstrating my issue - www.dropbox.com/s/9ajtb79d02uwcwy/k2_ordering_issue.mp4?dl=0

Thanks,

Dion

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

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
9 years 9 months ago #145786 by Krikor Boghossian
Replied by Krikor Boghossian on topic K2 custom ordering not working
Dion, I am looking into it and I will let you know.

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

More
9 years 9 months ago #145792 by sj
Replied by sj on topic K2 custom ordering not working
Hi Krikor, i have this problem too, i have updated joomla to 3.4.3 and installed k2 dev version but problem not solved.

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

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
9 years 9 months ago - 9 years 9 months ago #145884 by Krikor Boghossian
Replied by Krikor Boghossian on topic K2 custom ordering not working
I will need some more info from your side.
It is working as intended on my end so something is causing this issue.

Which other extensions are you using, which caching method are you using?
Last edit: 9 years 9 months ago by Krikor Boghossian.

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

  • Dion Eng
  • Dion Eng's Avatar Topic Author
  • Offline
  • Junior Member
More
9 years 9 months ago #145910 by Dion Eng
Replied by Dion Eng on topic K2 custom ordering not working
Hi Krikor,

Thanks for looking into it. I have many extensions but I have just tested a FRESH install of Joomla v3.4.3 and K2 3.4.3 dev using only the default Beez3 template and no additional extensions installed. Then I just exported my k2 content in CSV and imported into the new install.

I made another quick video demonstrating the same problem:
www.dropbox.com/s/9ajtb79d02uwcwy/k2_ordering_issue.mp4?dl=0

-Dion

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

  • Dion Eng
  • Dion Eng's Avatar Topic Author
  • Offline
  • Junior Member
More
9 years 9 months ago #145912 by Dion Eng
Replied by Dion Eng on topic K2 custom ordering not working
I just had a thought... I am looking at the database of the k2_items table and specifically under the featured_ordering column, my items span several 100s apart from each other. This has happened because over the years the editors have been removing and creating new items so the items are not consecutively in sequence apart from each other. I'm wondering if this great stagger in numbers is causing the problem?

Your thoughts?

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

  • Dion Eng
  • Dion Eng's Avatar Topic Author
  • Offline
  • Junior Member
More
9 years 9 months ago #145916 by Dion Eng
Replied by Dion Eng on topic K2 custom ordering not working
....Nevermind... I didn't filter out the columns, but the featured order seems to be a few apart not by 100s like previously stated.

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

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
9 years 9 months ago #145958 by Krikor Boghossian
Replied by Krikor Boghossian on topic K2 custom ordering not working
Is caching enabled in that demo site?

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

  • Dion Eng
  • Dion Eng's Avatar Topic Author
  • Offline
  • Junior Member
More
9 years 9 months ago #145969 by Dion Eng
Replied by Dion Eng on topic K2 custom ordering not working
Caching is disabled. Under Global Configuration->System->Cache Settings?

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

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
9 years 9 months ago #145973 by Krikor Boghossian
Replied by Krikor Boghossian on topic K2 custom ordering not working
Check your browser's console for the AJAX request and the response being made. If the response is not made and you navigate to another page or refresh the page, the order is not being saved.

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

  • Dion Eng
  • Dion Eng's Avatar Topic Author
  • Offline
  • Junior Member
More
9 years 9 months ago #145976 by Dion Eng

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

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
9 years 9 months ago #145985 by Krikor Boghossian
Replied by Krikor Boghossian on topic K2 custom ordering not working
You should actually look under the network tab.
EG: imgur.com/a/nyHkj

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

  • Dion Eng
  • Dion Eng's Avatar Topic Author
  • Offline
  • Junior Member
More
9 years 9 months ago #145986 by Dion Eng
Replied by Dion Eng on topic K2 custom ordering not working
Ok. The blue lines are when I have changed the order of an item.

www.dropbox.com/s/gb5da5ia1wx8chp/Screen%20Shot%202015-07-21%20at%2010.59.46%20AM.jpg?dl=0

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

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
9 years 9 months ago #145987 by Krikor Boghossian
Replied by Krikor Boghossian on topic K2 custom ordering not working
I don't think that Safari gives us the whole picture.
It is impossible to tell from these two lines, plus the actual response is not shown. Is is possible to use Chrome as the example?

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

  • Dion Eng
  • Dion Eng's Avatar Topic Author
  • Offline
  • Junior Member
More
9 years 9 months ago #145988 by Dion Eng

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

More
9 years 9 months ago #146012 by sj
Replied by sj on topic K2 custom ordering not working
My cache is disabled
http://imgur.com/Ti0l9Fl

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

More
9 years 9 months ago #146016 by sj
Replied by sj on topic K2 custom ordering not working
my network response
imgur.com/59K3ka1

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

  • Dion Eng
  • Dion Eng's Avatar Topic Author
  • Offline
  • Junior Member
More
9 years 9 months ago #146057 by Dion Eng
Replied by Dion Eng on topic K2 custom ordering not working
Here's some screen some more captures of the same area you showed. I seem to be getting a couple errors in my console.

www.dropbox.com/s/qm748y12d4s9uhp/Screen%20Shot%202015-07-22%20at%203.29.36%20PM.jpg?dl=0
www.dropbox.com/s/i381qf0tcvndot8/Screen%20Shot%202015-07-22%20at%203.31.57%20PM.jpg?dl=0

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


Powered by Kunena Forum