Add translation to required labels for install checks
- Remove unused checks loop in install_base template
This commit is contained in:
parent
65f74da45b
commit
a991f3dfcf
|
@ -186,6 +186,10 @@ class Install extends BaseModule
|
||||||
$output .= Renderer::replaceMacros($tpl, [
|
$output .= Renderer::replaceMacros($tpl, [
|
||||||
'$title' => $install_title,
|
'$title' => $install_title,
|
||||||
'$pass' => DI::l10n()->t('System check'),
|
'$pass' => DI::l10n()->t('System check'),
|
||||||
|
'$required' => DI::l10n()->t('Required'),
|
||||||
|
'$requirement_not_satisfied' => DI::l10n()->t('Requirement not satisfied'),
|
||||||
|
'$optional_requirement_not_satisfied' => DI::l10n()->t('Optional requirement not satisfied'),
|
||||||
|
'$ok' => DI::l10n()->t('OK'),
|
||||||
'$checks' => self::$installer->getChecks(),
|
'$checks' => self::$installer->getChecks(),
|
||||||
'$passed' => $status,
|
'$passed' => $status,
|
||||||
'$see_install' => DI::l10n()->t('Please see the file "doc/INSTALL.md".'),
|
'$see_install' => DI::l10n()->t('Please see the file "doc/INSTALL.md".'),
|
||||||
|
@ -215,12 +219,12 @@ class Install extends BaseModule
|
||||||
DI::l10n()->t('Host name'),
|
DI::l10n()->t('Host name'),
|
||||||
$configCache->get('config', 'hostname'),
|
$configCache->get('config', 'hostname'),
|
||||||
DI::l10n()->t('Overwrite this field in case the determinated hostname isn\'t right, otherweise leave it as is.'),
|
DI::l10n()->t('Overwrite this field in case the determinated hostname isn\'t right, otherweise leave it as is.'),
|
||||||
'required'],
|
DI::l10n()->t('Required')],
|
||||||
'$basepath' => ['system-basepath',
|
'$basepath' => ['system-basepath',
|
||||||
DI::l10n()->t("Base path to installation"),
|
DI::l10n()->t("Base path to installation"),
|
||||||
$configCache->get('system', 'basepath'),
|
$configCache->get('system', 'basepath'),
|
||||||
DI::l10n()->t("If the system cannot detect the correct path to your installation, enter the correct path here. This setting should only be set if you are using a restricted system and symbolic links to your webroot."),
|
DI::l10n()->t("If the system cannot detect the correct path to your installation, enter the correct path here. This setting should only be set if you are using a restricted system and symbolic links to your webroot."),
|
||||||
'required'],
|
DI::l10n()->t('Required')],
|
||||||
'$urlpath' => ['system-urlpath',
|
'$urlpath' => ['system-urlpath',
|
||||||
DI::l10n()->t('Sub path of the URL'),
|
DI::l10n()->t('Sub path of the URL'),
|
||||||
$configCache->get('system', 'urlpath'),
|
$configCache->get('system', 'urlpath'),
|
||||||
|
@ -239,7 +243,9 @@ class Install extends BaseModule
|
||||||
'$info_01' => DI::l10n()->t('In order to install Friendica we need to know how to connect to your database.'),
|
'$info_01' => DI::l10n()->t('In order to install Friendica we need to know how to connect to your database.'),
|
||||||
'$info_02' => DI::l10n()->t('Please contact your hosting provider or site administrator if you have questions about these settings.'),
|
'$info_02' => DI::l10n()->t('Please contact your hosting provider or site administrator if you have questions about these settings.'),
|
||||||
'$info_03' => DI::l10n()->t('The database you specify below should already exist. If it does not, please create it before continuing.'),
|
'$info_03' => DI::l10n()->t('The database you specify below should already exist. If it does not, please create it before continuing.'),
|
||||||
'checks' => self::$installer->getChecks(),
|
'$required' => DI::l10n()->t('Required'),
|
||||||
|
'$requirement_not_satisfied' => DI::l10n()->t('Requirement not satisfied'),
|
||||||
|
'$checks' => self::$installer->getChecks(),
|
||||||
'$hostname' => $configCache->get('config', 'hostname'),
|
'$hostname' => $configCache->get('config', 'hostname'),
|
||||||
'$ssl_policy' => $configCache->get('system', 'ssl_policy'),
|
'$ssl_policy' => $configCache->get('system', 'ssl_policy'),
|
||||||
'$basepath' => $configCache->get('system', 'basepath'),
|
'$basepath' => $configCache->get('system', 'basepath'),
|
||||||
|
@ -248,23 +254,23 @@ class Install extends BaseModule
|
||||||
DI::l10n()->t('Database Server Name'),
|
DI::l10n()->t('Database Server Name'),
|
||||||
$configCache->get('database', 'hostname'),
|
$configCache->get('database', 'hostname'),
|
||||||
'',
|
'',
|
||||||
'required'],
|
DI::l10n()->t('Required')],
|
||||||
'$dbuser' => ['database-username',
|
'$dbuser' => ['database-username',
|
||||||
DI::l10n()->t('Database Login Name'),
|
DI::l10n()->t('Database Login Name'),
|
||||||
$configCache->get('database', 'username'),
|
$configCache->get('database', 'username'),
|
||||||
'',
|
'',
|
||||||
'required',
|
DI::l10n()->t('Required'),
|
||||||
'autofocus'],
|
'autofocus'],
|
||||||
'$dbpass' => ['database-password',
|
'$dbpass' => ['database-password',
|
||||||
DI::l10n()->t('Database Login Password'),
|
DI::l10n()->t('Database Login Password'),
|
||||||
$configCache->get('database', 'password'),
|
$configCache->get('database', 'password'),
|
||||||
DI::l10n()->t("For security reasons the password must not be empty"),
|
DI::l10n()->t("For security reasons the password must not be empty"),
|
||||||
'required'],
|
DI::l10n()->t('Required')],
|
||||||
'$dbdata' => ['database-database',
|
'$dbdata' => ['database-database',
|
||||||
DI::l10n()->t('Database Name'),
|
DI::l10n()->t('Database Name'),
|
||||||
$configCache->get('database', 'database'),
|
$configCache->get('database', 'database'),
|
||||||
'',
|
'',
|
||||||
'required'],
|
DI::l10n()->t('Required')],
|
||||||
'$lbl_10' => DI::l10n()->t('Please select a default timezone for your website'),
|
'$lbl_10' => DI::l10n()->t('Please select a default timezone for your website'),
|
||||||
'$php_path' => $configCache->get('config', 'php_path'),
|
'$php_path' => $configCache->get('config', 'php_path'),
|
||||||
'$submit' => DI::l10n()->t('Submit')
|
'$submit' => DI::l10n()->t('Submit')
|
||||||
|
@ -278,6 +284,7 @@ class Install extends BaseModule
|
||||||
$tpl = Renderer::getMarkupTemplate('install_settings.tpl');
|
$tpl = Renderer::getMarkupTemplate('install_settings.tpl');
|
||||||
$output .= Renderer::replaceMacros($tpl, [
|
$output .= Renderer::replaceMacros($tpl, [
|
||||||
'$title' => $install_title,
|
'$title' => $install_title,
|
||||||
|
'$required' => DI::l10n()->t('Required'),
|
||||||
'$checks' => self::$installer->getChecks(),
|
'$checks' => self::$installer->getChecks(),
|
||||||
'$pass' => DI::l10n()->t('Site settings'),
|
'$pass' => DI::l10n()->t('Site settings'),
|
||||||
'$hostname' => $configCache->get('config', 'hostname'),
|
'$hostname' => $configCache->get('config', 'hostname'),
|
||||||
|
@ -292,7 +299,7 @@ class Install extends BaseModule
|
||||||
DI::l10n()->t('Site administrator email address'),
|
DI::l10n()->t('Site administrator email address'),
|
||||||
$configCache->get('config', 'admin_email'),
|
$configCache->get('config', 'admin_email'),
|
||||||
DI::l10n()->t('Your account email address must match this in order to use the web admin panel.'),
|
DI::l10n()->t('Your account email address must match this in order to use the web admin panel.'),
|
||||||
'required', 'autofocus', 'email'],
|
DI::l10n()->t('Required'), 'autofocus', 'email'],
|
||||||
'$timezone' => Temporal::getTimezoneField('system-default_timezone',
|
'$timezone' => Temporal::getTimezoneField('system-default_timezone',
|
||||||
DI::l10n()->t('Please select a default timezone for your website'),
|
DI::l10n()->t('Please select a default timezone for your website'),
|
||||||
$configCache->get('system', 'default_timezone'),
|
$configCache->get('system', 'default_timezone'),
|
||||||
|
@ -319,6 +326,8 @@ class Install extends BaseModule
|
||||||
$tpl = Renderer::getMarkupTemplate('install_finished.tpl');
|
$tpl = Renderer::getMarkupTemplate('install_finished.tpl');
|
||||||
$output .= Renderer::replaceMacros($tpl, [
|
$output .= Renderer::replaceMacros($tpl, [
|
||||||
'$title' => $install_title,
|
'$title' => $install_title,
|
||||||
|
'$required' => DI::l10n()->t('Required'),
|
||||||
|
'$requirement_not_satisfied' => DI::l10n()->t('Requirement not satisfied'),
|
||||||
'$checks' => self::$installer->getChecks(),
|
'$checks' => self::$installer->getChecks(),
|
||||||
'$pass' => DI::l10n()->t('Installation finished'),
|
'$pass' => DI::l10n()->t('Installation finished'),
|
||||||
'$text' => $db_return_text . self::whatNext(),
|
'$text' => $db_return_text . self::whatNext(),
|
||||||
|
|
|
@ -7,15 +7,6 @@
|
||||||
{{$info_03}}
|
{{$info_03}}
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<table>
|
|
||||||
{{foreach $checks as $check}}
|
|
||||||
<tr><td>{{$check.title}} </td><td>
|
|
||||||
{{if ! $check.status}}
|
|
||||||
<img src="{{$baseurl}}/view/install/red.png" alt="Requirement not satisfied">
|
|
||||||
{{/if}}
|
|
||||||
{{/foreach}}
|
|
||||||
</table>
|
|
||||||
|
|
||||||
<form id="install-form" action="{{$baseurl}}/install" method="post">
|
<form id="install-form" action="{{$baseurl}}/install" method="post">
|
||||||
|
|
||||||
<input type="hidden" name="config-php_path" value="{{$php_path}}" />
|
<input type="hidden" name="config-php_path" value="{{$php_path}}" />
|
||||||
|
|
|
@ -6,20 +6,20 @@
|
||||||
{{foreach $checks as $check}}
|
{{foreach $checks as $check}}
|
||||||
<tr><td>{{$check.title nofilter}} </td><td>
|
<tr><td>{{$check.title nofilter}} </td><td>
|
||||||
{{if $check.status}}
|
{{if $check.status}}
|
||||||
<img src="{{$baseurl}}/view/install/green.png" alt="Ok">
|
<img src="{{$baseurl}}/view/install/green.png" alt="{{$ok}}">
|
||||||
{{else}}
|
{{else}}
|
||||||
{{if $check.required}}
|
{{if $check.required}}
|
||||||
<img src="{{$baseurl}}/view/install/red.png" alt="Requirement not satisfied">
|
<img src="{{$baseurl}}/view/install/red.png" alt="{{$requirement_not_satisfied}}">
|
||||||
{{else}}
|
{{else}}
|
||||||
<img src="{{$baseurl}}/view/install/yellow.png" alt="Optional requirement not satisfied">
|
<img src="{{$baseurl}}/view/install/yellow.png" alt="{{$optional_requirement_not_satisfied}}">
|
||||||
{{/if}}
|
{{/if}}
|
||||||
{{/if}}
|
{{/if}}
|
||||||
</td><td>{{if $check.required}}(required){{/if}}</td></tr>
|
</td><td>{{if $check.required}}{{$required}}{{/if}}</td></tr>
|
||||||
{{if $check.help}}
|
{{if $check.help}}
|
||||||
<tr><td class="help" colspan="3">
|
<tr><td class="help" colspan="3">
|
||||||
<blockquote>{{$check.help nofilter}}</blockquote>
|
<blockquote>{{$check.help nofilter}}</blockquote>
|
||||||
{{if $check.error_msg}}
|
{{if $check.error_msg}}
|
||||||
<div class="error_header"><b>{{$check.error_msg.head}}</br><a href="{{$check.error_msg.url}}">{{$check.error_msg.url}}</a></b></div>
|
<div class="error_header"><b>{{$check.error_msg.head}}<br><a href="{{$check.error_msg.url}}">{{$check.error_msg.url}}</a></b></div>
|
||||||
<blockquote>{{$check.error_msg.msg}}</blockquote>
|
<blockquote>{{$check.error_msg.msg}}</blockquote>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
</td></tr>
|
</td></tr>
|
||||||
|
|
|
@ -9,10 +9,13 @@
|
||||||
|
|
||||||
<table>
|
<table>
|
||||||
{{foreach $checks as $check}}
|
{{foreach $checks as $check}}
|
||||||
<tr><td>{{$check.title}} </td><td>
|
<tr>
|
||||||
|
<td>{{$check.title}} </td>
|
||||||
|
<td>
|
||||||
{{if ! $check.status}}
|
{{if ! $check.status}}
|
||||||
<img src="{{$baseurl}}/view/install/red.png" alt="Requirement not satisfied">
|
<img src="{{$baseurl}}/view/install/red.png" alt="{{$requirement_not_satisfied}}">
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
</td>
|
||||||
{{/foreach}}
|
{{/foreach}}
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
<h2>{{$pass}}</h2>
|
<h2>{{$pass}}</h2>
|
||||||
|
|
||||||
{{foreach $checks as $check}}
|
{{foreach $checks as $check}}
|
||||||
<img src="{{$baseurl}}/view/install/red.png" alt="Requirement not satisfied">
|
<img src="{{$baseurl}}/view/install/red.png" alt="{{$requirement_not_satisfied}}">
|
||||||
{{$check.title nofilter}}
|
{{$check.title nofilter}}
|
||||||
<textarea rows="24" cols="80">{{$check.help nofilter}}</textarea>
|
<textarea rows="24" cols="80">{{$check.help nofilter}}</textarea>
|
||||||
{{/foreach}}
|
{{/foreach}}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user