Skip to content

Commit 91e2199

Browse files
committed
Merge remote-tracking branch 'ogresCE/MAGETWO-44043-Wording-In-Readiness-Check' into PR_Branch
2 parents b20558d + ecf5d27 commit 91e2199

File tree

8 files changed

+57
-27
lines changed

8 files changed

+57
-27
lines changed

setup/config/states.installer.config.php renamed to setup/config/states.install.config.php

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
return [
1010
'navInstallerTitles' => [
11-
'installer' => 'Magento Installer',
11+
'install' => 'Magento Installer',
1212
],
1313
'navInstaller' => [
1414
[
@@ -24,39 +24,39 @@
2424
'main' => true,
2525
'nav' => false,
2626
'order' => -1,
27-
'type' => 'installer'
27+
'type' => 'install'
2828
],
2929
[
30-
'id' => 'root.landing-installer',
31-
'url' => 'landing-installer',
30+
'id' => 'root.landing-install',
31+
'url' => 'landing-install',
3232
'templateUrl' => "$base/landing-installer",
3333
'title' => 'Landing',
3434
'controller' => 'landingController',
3535
'main' => true,
3636
'default' => true,
3737
'order' => 0,
38-
'type' => 'installer'
38+
'type' => 'install'
3939
],
4040
[
41-
'id' => 'root.readiness-check-installer',
42-
'url' => 'readiness-check-installer',
41+
'id' => 'root.readiness-check-install',
42+
'url' => 'readiness-check-install',
4343
'templateUrl' => "{$base}/readiness-check-installer",
4444
'title' => "Readiness \n Check",
4545
'header' => 'Step 1: Readiness Check',
4646
'nav' => true,
4747
'order' => 1,
48-
'type' => 'installer'
48+
'type' => 'install'
4949
],
5050
[
51-
'id' => 'root.readiness-check-installer.progress',
52-
'url' => 'readiness-check-installer/progress',
51+
'id' => 'root.readiness-check-install.progress',
52+
'url' => 'readiness-check-install/progress',
5353
'templateUrl' => "{$base}/readiness-check-installer/progress",
5454
'title' => 'Readiness Check',
5555
'header' => 'Step 1: Readiness Check',
5656
'controller' => 'readinessCheckController',
5757
'nav' => false,
5858
'order' => 2,
59-
'type' => 'installer'
59+
'type' => 'install'
6060
],
6161
[
6262
'id' => 'root.add-database',
@@ -68,7 +68,7 @@
6868
'nav' => true,
6969
'validate' => true,
7070
'order' => 3,
71-
'type' => 'installer'
71+
'type' => 'install'
7272
],
7373
[
7474
'id' => 'root.web-configuration',
@@ -80,7 +80,7 @@
8080
'nav' => true,
8181
'validate' => true,
8282
'order' => 4,
83-
'type' => 'installer'
83+
'type' => 'install'
8484
],
8585
[
8686
'id' => 'root.customize-your-store',
@@ -91,7 +91,7 @@
9191
'controller' => 'customizeYourStoreController',
9292
'nav' => true,
9393
'order' => 5,
94-
'type' => 'installer'
94+
'type' => 'install'
9595
],
9696
[
9797
'id' => 'root.create-admin-account',
@@ -103,7 +103,7 @@
103103
'nav' => true,
104104
'validate' => true,
105105
'order' => 6,
106-
'type' => 'installer'
106+
'type' => 'install'
107107
],
108108
[
109109
'id' => 'root.install',
@@ -114,7 +114,7 @@
114114
'controller' => 'installController',
115115
'nav' => true,
116116
'order' => 7,
117-
'type' => 'installer'
117+
'type' => 'install'
118118
],
119119
[
120120
'id' => 'root.success',
@@ -123,7 +123,7 @@
123123
'controller' => 'successController',
124124
'main' => true,
125125
'order' => 8,
126-
'type' => 'installer'
126+
'type' => 'install'
127127
],
128128
],
129129
];

setup/pub/magento/setup/component-grid.js

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,12 @@ angular.module('component-grid', ['ngStorage'])
117117
if ($localStorage.titles['update'].indexOf(component.moduleName) < 0 ) {
118118
$localStorage.titles['update'] = 'Update ' + component.moduleName;
119119
}
120-
$localStorage.moduleName = component.moduleName;
120+
if (component.moduleName) {
121+
$localStorage.moduleName = component.moduleName;
122+
} else {
123+
$localStorage.moduleName = component.name;
124+
}
125+
121126
$scope.nextState();
122127
};
123128

@@ -131,7 +136,11 @@ angular.module('component-grid', ['ngStorage'])
131136
$localStorage.titles['uninstall'] = 'Uninstall ' + component.moduleName;
132137
}
133138
$localStorage.componentType = component.type;
134-
$localStorage.moduleName = component.moduleName;
139+
if (component.moduleName) {
140+
$localStorage.moduleName = component.moduleName;
141+
} else {
142+
$localStorage.moduleName = component.name;
143+
}
135144
$state.go('root.readiness-check-uninstall');
136145
};
137146

setup/pub/magento/setup/landing.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ angular.module('landing', ['ngStorage'])
1010
'$location',
1111
'$localStorage',
1212
function ($scope, $location, $localStorage) {
13-
$localStorage.$reset();
1413
$scope.selectLanguage = function () {
1514
$localStorage.lang = $scope.modelLanguage;
1615
window.location = 'index.php/' + $scope.modelLanguage + '/index';

setup/pub/magento/setup/main.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,8 +83,8 @@ main.controller('navigationController',
8383
}
8484

8585
$scope.goToStart = function() {
86-
if ($state.current.type === 'installer') {
87-
$state.go('root.landing-installer');
86+
if ($state.current.type === 'install') {
87+
$state.go('root.landing-install');
8888
} else if ($state.current.type === 'upgrade') {
8989
$state.go('root.upgrade');
9090
} else {
@@ -103,6 +103,7 @@ main.controller('navigationController',
103103
mainState: {},
104104
states: [],
105105
load: function () {
106+
$localStorage.$reset();
106107
var self = this;
107108
return $http.get('index.php/navigation').success(function (data) {
108109
var currentState = $location.path().replace('/', '');

setup/pub/magento/setup/readiness-check.js

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -334,4 +334,27 @@ angular.module('readiness-check', [])
334334
$scope.progress();
335335
}
336336
});
337+
338+
$scope.wordingOfReadinessCheckAction = function() {
339+
var $actionString = 'We\'re making sure your server environment is ready for ';
340+
if ($localStorage.moduleName) {
341+
$actionString += $localStorage.moduleName;
342+
} else {
343+
if($state.current.type === 'install' || $state.current.type === 'upgrade') {
344+
$actionString += 'Magento';
345+
if ($state.current.type === 'upgrade' && $localStorage.packages.length > 1 ) {
346+
$actionString += ' and selected components';
347+
}
348+
} else {
349+
$actionString += 'package';
350+
}
351+
}
352+
$actionString += " to be " + $state.current.type;
353+
if ($scope.endsWith($state.current.type, 'e')) {
354+
$actionString += 'd';
355+
} else {
356+
$actionString +='ed';
357+
}
358+
return $actionString;
359+
}
337360
}]);

setup/src/Magento/Setup/Module.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ public function getConfig()
6363
include __DIR__ . '/../../../config/module.config.php',
6464
include __DIR__ . '/../../../config/router.config.php',
6565
include __DIR__ . '/../../../config/di.config.php',
66-
include __DIR__ . '/../../../config/states.installer.config.php',
66+
include __DIR__ . '/../../../config/states.install.config.php',
6767
include __DIR__ . '/../../../config/states.update.config.php',
6868
include __DIR__ . '/../../../config/states.home.config.php',
6969
include __DIR__ . '/../../../config/states.extensionManager.config.php',

setup/view/magento/setup/index.phtml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
*/
66
?>
77
<div ng-include="'index.php/navigation/side-menu'" style="display: inline-block"></div>
8-
<div class="{{$state.current.type == 'installer' ? 'container' : 'page-wrapper'}}">
8+
<div class="{{$state.current.type == 'install' ? 'container' : 'page-wrapper'}}">
99
<div ng-include="'index.php/navigation/header-bar'"></div>
1010
<main id="anchor-content" class="page-content">
1111
<?php echo $this->render('navigation/menu.phtml');?>

setup/view/magento/setup/readiness-check/progress.phtml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,7 @@
3030
<span></span><span></span><span></span><span></span>
3131
<span></span><span></span><span></span><span></span>
3232
</span>
33-
<span class="message-text">We're making sure your server environment is ready for
34-
{{typeOf(moduleName) !== 'undefined' ? moduleName : title[$state.current.type]}}
35-
to be {{$state.current.type}}{{endsWith($state.current.type, 'e') ? 'd' : 'ed'}}.</span>
33+
<span class="message-text">{{wordingOfReadinessCheckAction()}}.</span>
3634
</div>
3735

3836
</div>

0 commit comments

Comments
 (0)