From 7e055a94044100c17ffa103c56e2d238f9b4e6ac Mon Sep 17 00:00:00 2001 From: Vincent Petry Date: Wed, 28 May 2014 11:29:22 +0200 Subject: [PATCH] Fixed DOM elements, styling and code style issues - Reduced number of DOM elements - Also added mention of "config" backup. --- core/css/styles.css | 2 +- core/js/update.js | 16 +++++++++------- core/templates/update.admin.php | 33 ++++++++++++++------------------- 3 files changed, 24 insertions(+), 27 deletions(-) diff --git a/core/css/styles.css b/core/css/styles.css index fdfe282198d..c493941fed8 100644 --- a/core/css/styles.css +++ b/core/css/styles.css @@ -370,7 +370,7 @@ input[type="submit"].enabled { opacity: .6; } -#body-login .update .title { +#body-login .update h2 { font-weight: bold; font-size: 18px; margin-bottom: 30px; diff --git a/core/js/update.js b/core/js/update.js index abf2d6ae6db..cc0f541bd79 100644 --- a/core/js/update.js +++ b/core/js/update.js @@ -18,7 +18,6 @@ * @param $el progress list element */ start: function($el) { - var self = this; if (this._started) { return; } @@ -51,12 +50,16 @@ .addClass('error bold') .append('
') .append(t('core', 'The update was unsuccessful.' + - 'Please report this issue to the ownCloud community.')) + 'Please report this issue to the ' + + 'ownCloud community.')) .appendTo($el); }); - updateEventSource.listen('done', function(message) { + updateEventSource.listen('done', function() { // FIXME: use product name - $('').addClass('bold').append('
').append(t('core', 'The update was successful. Redirecting you to ownCloud now.')).appendTo($el); + $('').addClass('bold') + .append('
') + .append(t('core', 'The update was successful. Redirecting you to ownCloud now.')) + .appendTo($el); setTimeout(function () { OC.redirect(OC.webroot); }, 3000); @@ -73,11 +76,10 @@ })(); $(document).ready(function() { - $('.updateForm').on('submit', function(ev) { - ev.preventDefault(); + $('.updateButton').on('click', function() { var $progressEl = $('.updateProgress'); $progressEl.removeClass('hidden'); - $('.updateForm').addClass('hidden'); + $('.updateOverview').addClass('hidden'); OC.Update.start($progressEl); return false; }); diff --git a/core/templates/update.admin.php b/core/templates/update.admin.php index acc9c26c662..a09e2d07bf4 100644 --- a/core/templates/update.admin.php +++ b/core/templates/update.admin.php @@ -1,32 +1,27 @@
-
-

- t('%s will be updated to version %s.', - array($_['productName'], $_['version']))); ?> -

+
+

t('%s will be updated to version %s.', + array($_['productName'], $_['version']))); ?>

-

t('The following apps will be disabled during the upgrade:')) ?>

+ t('The following apps will be disabled:')) ?>
    - -
  • ()
  • - + +
  • ()
  • +
-
-

t('The theme %s has been disabled.', array($_['oldTheme']))) ?>

+
+ t('The theme %s has been disabled.', array($_['oldTheme']))) ?>
-
-

t('Please make sure that the database and the data folder have been backed up before proceeding.')) ?>

-
-
- +
+ t('Please make sure that the database, the config folder and the data folder have been backed up before proceeding.')) ?>
- - - + +
-- 2.39.5