Updates: Show the Authentication key settings after selecting the SSH transport in both the modal, and also on the plugin/theme updates screen.

Props afercia.
Fixes #39057 for trunk.

Built from https://develop.svn.wordpress.org/trunk@39657


git-svn-id: http://core.svn.wordpress.org/trunk@39597 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Dion Hulse 2016-12-30 07:44:41 +00:00
parent 6066654967
commit 05f07e13d9
3 changed files with 6 additions and 7 deletions

View File

@ -1516,11 +1516,9 @@
* @param {string} message Error message. * @param {string} message Error message.
*/ */
wp.updates.showErrorInCredentialsForm = function( message ) { wp.updates.showErrorInCredentialsForm = function( message ) {
var $modal = $( '#request-filesystem-credentials-form' );
// Remove any existing error. // Remove any existing error.
$modal.find( '.notice' ).remove(); $filesystemForm.find( '.notice' ).remove();
$modal.find( '#request-filesystem-credentials-title' ).after( '<div class="notice notice-alt notice-error"><p>' + message + '</p></div>' ); $filesystemForm.find( '#request-filesystem-credentials-title' ).after( '<div class="notice notice-alt notice-error"><p>' + message + '</p></div>' );
}; };
/** /**
@ -1670,6 +1668,7 @@
$( function() { $( function() {
var $pluginFilter = $( '#plugin-filter' ), var $pluginFilter = $( '#plugin-filter' ),
$bulkActionForm = $( '#bulk-action-form' ), $bulkActionForm = $( '#bulk-action-form' ),
$filesystemForm = $( '#request-filesystem-credentials-form' ),
$filesystemModal = $( '#request-filesystem-credentials-dialog' ), $filesystemModal = $( '#request-filesystem-credentials-dialog' ),
$pluginSearch = $( '.plugins-php .wp-filter-search' ), $pluginSearch = $( '.plugins-php .wp-filter-search' ),
$pluginInstallSearch = $( '.plugin-install-php .wp-filter-search' ); $pluginInstallSearch = $( '.plugin-install-php .wp-filter-search' );
@ -1725,7 +1724,7 @@
* *
* @since 4.2.0 * @since 4.2.0
*/ */
$filesystemModal.on( 'change', 'input[name="connection_type"]', function() { $filesystemForm.on( 'change', 'input[name="connection_type"]', function() {
$( '#ssh-keys' ).toggleClass( 'hidden', ( 'ssh' !== $( this ).val() ) ); $( '#ssh-keys' ).toggleClass( 'hidden', ( 'ssh' !== $( this ).val() ) );
} ).change(); } ).change();

File diff suppressed because one or more lines are too long

View File

@ -4,7 +4,7 @@
* *
* @global string $wp_version * @global string $wp_version
*/ */
$wp_version = '4.8-alpha-39656'; $wp_version = '4.8-alpha-39657';
/** /**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema. * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.