ENH: Allow adding link(s) to unsaved DataObjects (closes #387)#388
ENH: Allow adding link(s) to unsaved DataObjects (closes #387)#388lozcalver wants to merge 1 commit intosilverstripe:5from
Conversation
|
Marked as draft because I still need to look at PHP/Behat coverage Edit: actually it’s not working properly for |
|
I’ve pushed up a working solution and test coverage, but I’m struggling to get Behat running at the moment |
GuySartorelli
left a comment
There was a problem hiding this comment.
We aren't releasing any new minor releases for the CMS 5 compatible branches. Please retarget this to the 5 branch (you may need to reset your commits).
This also needs a behat test - if you're using DDEV my solution lately has been to install chromedriver and chromium into the web container since the various DDEV selenium addons stopped working for me a few months ago.
here is my docker file and here is my behat command
Alternatively if you're still having trouble let me know and I can make a behat feature for this separately.
Please also update docs and make this new behaviour configurable per #387 (comment)
52d9722 to
5a9b788
Compare
|
I’ve rebased onto the |
|
Even after re-running all the CI actions, the base ref is still wrong (it says |
|
Replaced by #425 |
Description
This seems surprisingly trivial in terms of code changes! There’s some minor refactoring in that the
jsonError()calls are moved out of most of the getters, but these are all private methods anyway so there aren’t any BC concerns.Manual testing steps
Add a DataObject class which
has_oneand/orhas_manylinks. Create a new, unsaved DataObject (basically anything that isn’t a page or elemental block) and you should now be able to add links instead of seeing the old “Cannot create links” message.Issues
Pull request checklist