Active
Project:
Devel Entity Updates
Version:
3.0.0
Component:
Base system
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
10 Nov 2020 at 15:56 UTC
Updated:
10 Nov 2020 at 17:51 UTC
Jump to comment: Most recent
Comments
Comment #2
plachPatches welcome :)
Comment #3
djg_tram commentedComment #4
djg_tram commentedI knew it. :-) The problem is that my site I want to try it own doesn't run now, because of that problem that the module is supposed to fix, and I don't have Drush because I couldn't yet set it up in Docker. :-)
I can't immediately see how the actual operation could be called without Drush being present. Is it possible at all? Because the outer shell would be relatively simple:
devel_entity_updates.routing.yml
devel_entity_updates.links.menu.yml
src/Form/EntityUpdateConfirmForm.php
With the
//...being the interesting part...Comment #5
plachThe interesting part should just be
DevelEntityDefinitionUpdateManager::applyUpdates():)Comment #6
plachSee also https://git.drupalcode.org/project/devel_entity_updates/-/blob/3.0.x/src...
Comment #7
djg_tram commentedCertainly, but that's not static to call easily, we would need to round up the injections normally provided by Drush, I suppose, to construct that command and then be able to call its member function.
Comment #8
plachThis should do the trick:
Of course we should inject the class resolver.
Comment #9
djg_tram commentedYes, I arrived at that just at the same time. My only problem is that while it runs, it doesn't cure my site. :-)) Much ado about nothing, but only in my particular case, of course...
Comment #10
djg_tram commentedBut I changed the source above, anyway, to be functional. :-)
Comment #11
djg_tram commentedOK, I cured the site with some manual editing of the
key_valuetable. Of course, I didn't have just the right backup right now. :-))So, what I'm stuck with is adding the item to the Devel menu in the toolbar. It seems this depends on Devel itself and additional modules can't have a say in it. So while it works by manually typing the route, the last step is still missing.
Comment #12
djg_tram commentedSorry, found the culprit. The Admin Toolbar Tools module ignores what Devel sets up and provides its own hardwired menu in the toolbar. It's their fault, I'll go there to complain.
So, if you can use the small code above, please, do.