tractorcow-farm / silverstripe-fluent

Multi-language translate module for Silverstripe, without having to manage separate site trees.
BSD 3-Clause "New" or "Revised" License
91 stars 109 forks source link

ENH: Localisation manager links available for CMS edit link capable models. #838

Closed mfendeksilverstripe closed 5 months ago

mfendeksilverstripe commented 5 months ago

Description

Allow all CMS edit link capable models to use a Title link in the Locale manager. This link is quite handy as you can switch between locales easily. Previously this was available only for models extending SiteTree (pages).

Screenshot 2024-04-05 at 11 35 15 AM

Pull request checklist

GuySartorelli commented 5 months ago

Please change the commit prefix to FIX as per the commit message guidelines - I've unticked that box in the checklist, feel free to tick it again when you've made this change.

As this is a bug fix that doesn't introduce new API, please also retarget this to the 7.0 branch so it can be released as a patch. I've unticked the relevant checkbox for this in the checklist as well.

Note you may need to reset your commits after retargetting the PR.

mfendeksilverstripe commented 5 months ago

I've pushed up the requested changes @GuySartorelli , please review.

GuySartorelli commented 5 months ago

There are failing unit tests to address. It looks like you changed the base after pushing the commit, so you may need to force push your changes to get CI to rerun against the correct parent branch.

mfendeksilverstripe commented 5 months ago

Tests passing now @GuySartorelli , please review 🙏 .

GuySartorelli commented 5 months ago

re: https://github.com/tractorcow-farm/silverstripe-fluent/pull/838#discussion_r1555045471

I'll mark this as a draft in the meantime to avoid it being merged in its current state.

mfendeksilverstripe commented 5 months ago

This is now ready to be reviewed as a standalone enhancement @GuySartorelli

GuySartorelli commented 5 months ago

Please retarget this to the 7 branch since this is no longer fixing a bug

mfendeksilverstripe commented 5 months ago

Created https://github.com/silverstripe/silverstripe-framework/issues/11191 to cover the malformed HTML

mfendeksilverstripe commented 5 months ago

@GuySartorelli Updated base branch to 7 as requested. Please review.

GuySartorelli commented 5 months ago

Works well locally, just one suggested change above.

mfendeksilverstripe commented 5 months ago

I've added the requested change @GuySartorelli , please review.