Closed (fixed)
Project:
Entityqueue
Version:
8.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
4 Apr 2014 at 01:53 UTC
Updated:
15 Apr 2020 at 12:59 UTC
Jump to comment: Most recent
Any plans for a D8 version on the horizon?
Comments
Comment #1
jojonaloha commentedYes this is something I discussed with amateescu awhile back. Good to have an issue for it now though :)
Comment #2
jojonaloha commentedComment #3
gnugetI want try to migrate this module to D8, i will create a sandbox project and start to porting the most common and straightforward things to D8. And if all going well, continue working on it until leave a usable version of the project.
I will assign this issue to myself for now.
EDIT: The project: https://www.drupal.org/sandbox/gnuget/2291539
Comment #4
scotwith1tJust curious how this is going. We use nodequeue/entityqueue all the time and would love to see this ported for D8 when it comes out. We have a couple clients that want to live on the edge and go ahead and be one of the first to D8 and this module would be a majorly important component. Thanks for any update! If nothing else, I'll just try out the sandbox project at some point and see what we can do to help out if we get to that point soon.
Comment #5
gnugetI haven't had free time the last months and this has been stopped since then.
I still have in my plans continue working on this and I hope at least have a usable version when the first version of D8 be released it but this will be still on pause a couple weeks more.
If you want to check my work so far (which is not too much either) you can check it here:
https://github.com/gnuget/entityqueue-drupal8
Comment #6
jojonaloha commentedI talked with amateescu a few weeks ago and the current plan is:
Comment #7
amateescu commentedHere's my thoughts on what we should aim to accomplish in the 8.x version of Entityqueue.
The main problem with the 7.x version is that it relies too much on the entity reference field and doesn't provide a nice/fluent API to work with a (sub)queue, like Nodequeue did. Also, if we just rely on the ER (entity reference) field provided by core, we'll have a huge performance problem on large queues (e.g. > 100 items), because accessing the ER field of the subqueue will cause all the referenced entities to be loaded, even if we just want to work with the first 10 items, for example.
In bullet points, this big picture would be something like this:
Drupal\Core\Field\EntityReferenceFieldItemListand which will allow us to take over the loading of referenced entities (e.g. we can have a dedicated method on our custom list class that provides the "give me the first 10 items in the queue" functionality)Drupal\Core\Field\Plugin\Field\FieldWidget\EntityReferenceAutocompleteWidget), which lacks *a lot* in usability compared to the nodequeue/entityqueue widgetNote that the second and third bullet points are based on a discussion with @yched, author of CKK and maintainer of Field API in core, and are mostly his ideas that I happen to fully agree with :)
Comment #8
larowlanAny reason to limit it to ER field - have you considered DER? Multiple entity-types in the one queue?
Comment #9
amateescu commentedThat would be a very simple change to make at any time and doesn't affect the "big picture" above, but yes, I agree that we should consider it after we have some initial prototype code written.
Comment #10
gnugetComment #11
yched commentedJust adding to @amateescu's notes from what I recollect from our discussion :
Basically the idea was that you get queue items by manually loading "slices" of the (sub)queue in a runtime structure (a computed field) that you can then use with all the tools available for a regular ER field (loading of entities, rendering, formatters, widgets...). Something like (names made up) :
The subqueue entity could probably come with a default slice pre-populated (e.g 10 items, offset 0, from the end), with default $length, $offset, $reversed params configured in the queue config entity.
Then you can use $subQueueContentEntity->items as a regular ER field item list : load entities, display with ER formatters, edit with ER widgets, add/remove entities and save data back to the queue table...
Comment #12
darol100 commentedComment #13
twang commentedI just downloaded entityqueue for our drupal 8 project. I have been playing with it, and find it provides a lot of features we need. Thanks for the great work!
Just wondering if there is a plan to make subqueue behave similar to the parent entityqueue? We are looking for some subqueue level features, including sorting/reordering subqueue list, displaying subqueue attributes like size, allowing setting min and max on size, and also allowing users to extend subqueue by adding fields as needed.
Comment #14
amateescu commentedI can see how some of those features could be useful in the main module, but not all of them :)
- sorting/reordering subqueue list
This can easily accomplished on a per-project basis either with something like Draggable Views or, why not, a subqueue of subqueues :)
- displaying subqueue attributes like size
This would be a nice thing to provide by default. For your use case, is it needed as an entity field (it can be either a computed field or an "extra field" on the subqueue entity)? Or maybe just as a views field?
- allowing setting min and max on size
I think we can facilitate this by allowing queue handler plugins to act on subqueue entity events (e.g. onSubqueuePreSave(), etc.), because they can only act on queue events at the moment. This will allow a custom queue handler to enforce a min/max size on individual subqueues, but I'm not sure if such a handler would be very useful in the main module. Also, I can't really see how we could put this setting the UI, since subqueues do not have a "configuration" form, but we can definitely discuss this in a dedicated issue.
- allowing users to extend subqueue by adding fields as needed
This one is not really possible because it means that subqueues would be bundles themselves, but bundles of what exactly? :)
Comment #15
andypostJust checked the module - it works fine!
Suppose #7 and #8 is a separate issue and this one could be closed.
PS: looks there's no way to filter/sort by subqueue in views
Comment #16
twang commentedHi amateescu, Thanks a lot for your great response. Among the features I mentioned, sorting subqueue list is very important for us. Looks like the list is currently sorted by their title in alphabet order, isn't it? As you suggested, It would be great if the subqueue list view is draggable or it allows to change order index for each subqueue.
Regarding subqueue's size, I think it would be nice to have it as an entity field (computed makes sense to me).
One observation: I tried to use inline_entity_form for the items field, and it works well, except that the Reverse and Shuffle buttons don't work without manually changing the order index.
Comment #17
amateescu commentedWhat I suggested was that you could use Draggable Views and replace the current subqueue listing page with a view in your project, sorry if that wasn't clear enough :)
Can you please open a separate issue for this? Sounds like something that should be easy to fix.
Comment #18
sagesolutions commentedThere is now an 8.x-1.0-alpha8 version available for Drupal 8. Can we close this ticket now, or wait until a full 8.0 version is out?
Comment #19
amateescu commentedLet's wait until we have a beta at least :)
Comment #20
amateescu commentedEntityqueue 8.x-1.0-rc1 is out, so we can close this issue :)