API: 3rd-party: Add tools for getting module overrides; Add to API#8836
Merged
API: 3rd-party: Add tools for getting module overrides; Add to API#8836
Conversation
e645a6b to
fa47b00
Compare
ae54490 to
d0c2cfb
Compare
oskosk
approved these changes
Feb 15, 2018
Contributor
oskosk
left a comment
There was a problem hiding this comment.
LGTM! Sorry, forgot to approve yesterday
matticbot
pushed a commit
that referenced
this pull request
Feb 16, 2018
…se format to add override Currently, it is possible to override the active modules in Jetpack and force some to be active or inactive. The issue with this is that our UI does not respond to that. So, while a module may be forced on, a user is shown UI that allows them to attempt to disable the module, except, when the page is refreshed, the module is still enabled. See: #8836 See: #8800 Differential Revision: D10224-code This commit syncs r170223-wpcom.
dereksmart
pushed a commit
that referenced
this pull request
Feb 21, 2018
…se format to add override (#8863) Currently, it is possible to override the active modules in Jetpack and force some to be active or inactive. The issue with this is that our UI does not respond to that. So, while a module may be forced on, a user is shown UI that allows them to attempt to disable the module, except, when the page is refreshed, the module is still enabled. See: #8836 See: #8800 Differential Revision: D10224-code This commit syncs r170223-wpcom.
oskosk
added a commit
that referenced
this pull request
Feb 27, 2018
oskosk
added a commit
that referenced
this pull request
Feb 27, 2018
* update changelog.txt * Update readme.txt with scaffolding for 5.9 changelog and release draft shortlink * Add changelog entry for #8243 * Add changelog entry for #8296 * Add changelog entry for #8367 * Add changelog entry for #8686 * Add changelog entry for #8707 * Add changelog entry for #8709 and #8714 * Add changelog entry for #8729 * Add changelog entry for #8777 * Add changelog entry for #8780 * Add changelog entry for #8786 * Add changelog entry for #8787 * Add changelog entry for #8801 #8805 #8832 #8865 and #8804 * Add changelog entry for #8817 * Add changelog entry for #8822 * Add changelog entry for #8823 * Add changelog entry for #8829 * Add changelog entry for #8834 * move some items to major enhancements * Add changelog entry for #8836 * Add changelog entry for #8839 * Add changelog entry for #8861 * Add changelog entry for #8862 * Add changelog entry for #8863 * Add changelog entry for #8866 * Add changelog entry for #8870 * Add changelog entry for #8874 * Add changelog entry for #8875 * Add changelog entry for #8881 * Add changelog entry for #8890 * Add changelog entry for #8911 * Add changelog entry for #8927 * Add changelog entry for #8931 * Add changelog entry for #8933 * Add changelog entry for #8930 * fix wording * typo * minor fixes * replace partner scripts for Jetpack Start in changelog entry * Update to-test.md * Update to-test.md * minor style fixes to to-test.md * minor style fixes to to-test.md * minor fixes on to-test.md * Add changelog entry for #8868 * Add changelog entry for #8844 * Add changelog entry for #8664 * Add changelog entry for #8935 * Add changelog entry for #8425 * Add changelog entry for #8625
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
As part of my work on #8800, I need to know which modules are being forced on and which are being forced off. With that information, it should be relatively easy to modify the UI to let a user know that an option can not be modified.
Updating the UI to reflect whether an option can be updated is especially important in the context of a hosting partner forcing modules on/off.
This PR also adds the
overridekey to each module result returned in the API. This will allow us to support module overrides on both WPCOM and in the Jetpack UI.To test:
phpunit --filter=Jetpack_Modules_Overrideswp shellGET /sites/$site/jetpack/modulesGET /sites/$site/jetpack/modules/$module_slugoverridekey for modulesGET /sites/$site/jetpack/modulesand ensure that the override forphotonandlazy-imagesisactive, the override forsitemapsisinactive, and all others have an empty value.cc @oskosk since you mentioned you looked at this before in #8800.
Changelog entry