Hi Folks,
I am still trying to implement drag and drop manual ordering. I just want simple, non-nested ability to manually sort a list.
I have gotten the drag and drop to work and the task to lead me to the task->controller-> model->rebuild() method, and in the limited examples I can see that seems to call the table class rebuild method which does not exist.
So it seems to me there is a built-in method that I cannot seem to find either in what I extend or in a use statement. I cannot seem to find an example or post that answers the question. The examples I have to work with are killing me. As noted in my earlier forum post (not this list), Articles does not seem to let you save the reordering. Neither does guided tours. Both category and menu are somewhat customized due to their role in the whole framework and both more complicated because of nesting, which I do not need.
Does anyone have an example or know of a post, or can otherwise guide me to getting a simple, non-nested, manual ordering of records using my singular, integer `ordering` database field?
I don’t want to write my own if I should be able to use something built in.
Steven
So I have figured out that I have been on the wrong track, but it appears the issue I am having is the same issue that makes articles (com_content) not work.
Just dragging and dropping activates saveOrderAjax which then activates AdminModel saveOrder.
It goes through and correctly adjusts all the ordering values and then it executes the code:
// Execute reorder for each category.
foreach
($conditions
as
$cond) {
$this->table->load($cond[0]);
$this->table->reorder($cond[1]);
}
And that puts all the values back to where they were. WTF?
I’m not using categories for the list I am trying to sort, but com_content uses categories. Neither sorts with the drag and drop feature.
Any help would be appreciated.
--
You received this message because you are subscribed to the Google Groups "Joomla! General Development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
joomla-dev-gene...@googlegroups.com.
To view this discussion on the web, visit
https://groups.google.com/d/msgid/joomla-dev-general/SJ2PR22MB4167AA8E2DEE4163FDF98584CB442%40SJ2PR22MB4167.namprd22.prod.outlook.com.
In this case, yes. A list of options which have been entered in the correct order, but if I add one, it would probably need to be manually reordered.
I did this with J4.4, but I am using J5.0.3 now and I have not checked to see if the problem still exists. I am guessing it does.
To view this discussion on the web, visit https://groups.google.com/d/msgid/joomla-dev-general/56a86d01-faca-43e2-9cab-cb9a21c9f96fn%40googlegroups.com.