1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-05-03 06:08:05 +02:00

Merge pull request #6743 from marc1706/ticket/17421

[ticket/17421] Rename extensions section to "not installed"
This commit is contained in:
Marc Alexander 2024-11-10 10:31:53 +01:00 committed by GitHub
commit bf83c73a60
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 29 additions and 27 deletions

View File

@ -42,7 +42,7 @@
</tr>
</thead>
<tbody>
{% for list in ['enabled', 'disabled', 'available'] %}
{% for list in ['enabled', 'disabled', 'not_installed'] %}
{% set blockname = attribute(loops, list) %}
{% if blockname|length %}
<tr>
@ -51,8 +51,8 @@
{% EVENT acp_ext_list_enabled_title_after %}
{% elseif list == 'disabled' %}
{% EVENT acp_ext_list_disabled_title_after %}
{% elseif list == 'available' %}
{% EVENT acp_ext_list_available_title_after %}
{% elseif list == 'not_installed' %}
{% EVENT acp_ext_list_not_installed_title_after %}
{% endif %}
</td>
</tr>
@ -63,8 +63,8 @@
{% EVENT acp_ext_list_enabled_name_after %}
{% elseif list == 'disabled' %}
{% EVENT acp_ext_list_disabled_name_after %}
{% elseif list == 'available' %}
{% EVENT acp_ext_list_available_name_after %}
{% elseif list == 'not_installed' %}
{% EVENT acp_ext_list_not_installed_name_after %}
{% endif %}
</td>
<td style="text-align: center;">

View File

@ -70,18 +70,6 @@ acp_ext_details_notice
* Since: 3.1.11-RC1
* Purpose: Add extension detail notices after version check information.
acp_ext_list_available_name_after
===
* Location: adm/style/acp_ext_list.html
* Since: 3.3.14-RC1
* Purpose: Add content after the name of available extensions in the list
acp_ext_list_available_title_after
===
* Location: adm/style/acp_ext_list.html
* Since: 3.3.14-RC1
* Purpose: Add text after available extensions section title.
acp_ext_list_disabled_name_after
===
* Location: adm/style/acp_ext_list.html
@ -106,6 +94,20 @@ acp_ext_list_enabled_title_after
* Since: 3.1.11-RC1
* Purpose: Add text after enabled extensions section title.
acp_ext_list_not_installed_name_after
===
* Location: adm/style/acp_ext_list.html
* Since: 3.3.14-RC1
* Changed: 3.3.14 Renamed from acp_ext_list_available_name_after
* Purpose: Add content after the name of not installed extensions in the list
acp_ext_list_not_installed_title_after
===
* Location: adm/style/acp_ext_list.html
* Since: 3.3.14-RC1
* Changed: 3.3.14 Renamed from acp_ext_list_available_title_after
* Purpose: Add text after not installed extensions section title.
acp_forums_custom_settings
===
* Location: adm/style/acp_forums.html

View File

@ -575,7 +575,7 @@ class acp_extensions
catch (exception_interface $e)
{
$message = call_user_func_array(array($this->user, 'lang'), array_merge(array($e->getMessage()), $e->get_parameters()));
$this->template->assign_block_vars('available', array(
$this->template->assign_block_vars('not_installed', array(
'META_DISPLAY_NAME' => $this->user->lang('EXTENSION_INVALID_LIST', $name, $message),
'S_VERSIONCHECK' => false,
));
@ -589,9 +589,9 @@ class acp_extensions
$block_vars['NAME'] = $name;
$block_vars['U_DETAILS'] = $this->u_action . '&amp;action=details&amp;ext_name=' . urlencode($name);
$this->template->assign_block_vars('available', $block_vars);
$this->template->assign_block_vars('not_installed', $block_vars);
$this->output_actions('available', array(
$this->output_actions('not_installed', array(
'ENABLE' => $this->u_action . '&amp;action=enable_pre&amp;ext_name=' . urlencode($name),
));
}

View File

@ -47,9 +47,9 @@ $lang = array_merge($lang, array(
'DETAILS' => 'Details',
'EXTENSIONS_AVAILABLE' => 'Available Extensions',
'EXTENSIONS_DISABLED' => 'Disabled Extensions',
'EXTENSIONS_ENABLED' => 'Enabled Extensions',
'EXTENSIONS_NOT_INSTALLED' => 'Not installed Extensions',
'EXTENSIONS_DISABLED' => 'Disabled Extensions',
'EXTENSIONS_ENABLED' => 'Enabled Extensions',
'EXTENSION_DELETE_DATA' => 'Delete data',
'EXTENSION_DISABLE' => 'Disable',

View File

@ -85,7 +85,7 @@ class phpbb_functional_extension_acp_test extends phpbb_functional_test_case
$this->assertCount(1, $crawler->filter('.ext_enabled'));
$this->assertCount(3, $crawler->filter('.ext_disabled'));
$this->assertCount(4, $crawler->filter('.ext_available'));
$this->assertCount(4, $crawler->filter('.ext_not_installed'));
$this->assertStringContainsString('phpBB Foo Extension', $crawler->filter('.ext_enabled')->eq(0)->text());
$this->assertContainsLang('EXTENSION_DISABLE', $crawler->filter('.ext_enabled')->eq(0)->text());
@ -99,9 +99,9 @@ class phpbb_functional_extension_acp_test extends phpbb_functional_test_case
$this->assertStringContainsString('The “vendor/test3” extension is not valid.', $crawler->filter('.ext_disabled')->eq(1)->text());
$this->assertStringContainsString('phpBB Bar Extension', $crawler->filter('.ext_available')->eq(0)->text());
$this->assertContainsLang('DETAILS', $crawler->filter('.ext_available')->eq(0)->text());
$this->assertContainsLang('EXTENSION_ENABLE', $crawler->filter('.ext_available')->eq(0)->text());
$this->assertStringContainsString('phpBB Bar Extension', $crawler->filter('.ext_not_installed')->eq(0)->text());
$this->assertContainsLang('DETAILS', $crawler->filter('.ext_not_installed')->eq(0)->text());
$this->assertContainsLang('EXTENSION_ENABLE', $crawler->filter('.ext_not_installed')->eq(0)->text());
// Check that invalid extensions are not listed.
$this->assertStringNotContainsString('phpBB BarFoo Extension', $crawler->filter('.table1')->text());