mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-26 12:08:47 +02:00
N°6934 - Symfony 6.4 - upgrade Symfony bundles to 6.4 (#580)
* Update Symfony lib to version ~6.4.0 * Update code missing return type * Add an iTop general configuration entry to store application secret (Symfony mandatory parameter) * Use dependency injection in ExceptionListener & UserProvider classes
This commit is contained in:
@@ -1,5 +1,51 @@
|
||||
{% extends '@WebProfiler/Profiler/layout.html.twig' %}
|
||||
|
||||
{% block head %}
|
||||
{{ parent() }}
|
||||
|
||||
<style>
|
||||
.config-symfony-version-lts {
|
||||
border: 0;
|
||||
color: var(--color-muted);
|
||||
font-size: 21px;
|
||||
line-height: 33px;
|
||||
}
|
||||
.config-symfony-version-lts[title] {
|
||||
text-decoration: none;
|
||||
}
|
||||
.config-symfony-version-status-badge {
|
||||
background-color: var(--badge-background);
|
||||
border-radius: 4px;
|
||||
color: var(--badge-color);
|
||||
display: inline-block;
|
||||
font-size: 15px;
|
||||
font-weight: bold;
|
||||
margin: 10px 0 5px;
|
||||
padding: 3px 7px;
|
||||
white-space: nowrap;
|
||||
}
|
||||
.config-symfony-version-status-badge.status-success {
|
||||
background-color: var(--badge-success-background);
|
||||
color: var(--badge-success-color);
|
||||
}
|
||||
.config-symfony-version-status-badge.status-warning {
|
||||
background-color: var(--badge-warning-background);
|
||||
color: var(--badge-warning-color);
|
||||
}
|
||||
.config-symfony-version-status-badge.status-error {
|
||||
background-color: var(--badge-danger-background);
|
||||
color: var(--badge-danger-color);
|
||||
}
|
||||
.config-symfony-version-roadmap-link {
|
||||
display: inline-block;
|
||||
margin: 10px 5px 5px;
|
||||
}
|
||||
.config-symfony-eol {
|
||||
margin-top: 5px;
|
||||
}
|
||||
</style>
|
||||
{% endblock %}
|
||||
|
||||
{% block toolbar %}
|
||||
{% if 'unknown' == collector.symfonyState %}
|
||||
{% set block_status = '' %}
|
||||
@@ -20,7 +66,7 @@
|
||||
|
||||
{% set icon %}
|
||||
<span class="sf-toolbar-label">
|
||||
{{ include('@WebProfiler/Icon/symfony.svg') }}
|
||||
{{ source('@WebProfiler/Icon/symfony.svg') }}
|
||||
</span>
|
||||
<span class="sf-toolbar-value">{{ collector.symfonyState is defined ? collector.symfonyversion : 'n/a' }}</span>
|
||||
{% endset %}
|
||||
@@ -64,7 +110,13 @@
|
||||
|
||||
<div class="sf-toolbar-info-piece sf-toolbar-info-php-ext">
|
||||
<b>PHP Extensions</b>
|
||||
<span class="sf-toolbar-status sf-toolbar-status-{{ collector.hasxdebug ? 'green' : 'gray' }}">xdebug {{ collector.hasxdebug ? '✓' : '✗' }}</span>
|
||||
{% if collector.hasXdebugInfo %}
|
||||
<a href="{{ path('_profiler_xdebug') }}" title="View xdebug_info()">
|
||||
{% endif %}
|
||||
<span class="sf-toolbar-status sf-toolbar-status-{{ collector.hasXdebug ? 'green' : 'gray' }}">Xdebug {{ collector.hasXdebug ? '✓' : '✗' }}</span>
|
||||
{% if collector.hasXdebugInfo %}
|
||||
</a>
|
||||
{% endif %}
|
||||
<span class="sf-toolbar-status sf-toolbar-status-{{ collector.hasapcu ? 'green' : 'gray' }}">APCu {{ collector.hasapcu ? '✓' : '✗' }}</span>
|
||||
<span class="sf-toolbar-status sf-toolbar-status-{{ collector.haszendopcache ? 'green' : 'red' }}">OPcache {{ collector.haszendopcache ? '✓' : '✗' }}</span>
|
||||
</div>
|
||||
@@ -102,7 +154,7 @@
|
||||
|
||||
{% block menu %}
|
||||
<span class="label label-status-{{ collector.symfonyState == 'eol' ? 'red' : collector.symfonyState in ['eom', 'dev'] ? 'yellow' }}">
|
||||
<span class="icon">{{ include('@WebProfiler/Icon/config.svg') }}</span>
|
||||
<span class="icon">{{ source('@WebProfiler/Icon/config.svg') }}</span>
|
||||
<strong>Configuration</strong>
|
||||
</span>
|
||||
{% endblock %}
|
||||
@@ -112,7 +164,13 @@
|
||||
|
||||
<div class="metrics">
|
||||
<div class="metric">
|
||||
<span class="value">{{ collector.symfonyversion }}</span>
|
||||
<span class="value">
|
||||
{{ collector.symfonyversion }}
|
||||
|
||||
{% if collector.symfonylts %}
|
||||
<abbr class="config-symfony-version-lts" title="This is a Long-Term Support version">(LTS)</abbr>
|
||||
{% endif %}
|
||||
</span>
|
||||
<span class="label">Symfony version</span>
|
||||
</div>
|
||||
|
||||
@@ -131,33 +189,39 @@
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
{% set symfony_status = { dev: 'Unstable Version', stable: 'Stable Version', eom: 'Maintenance Ended', eol: 'Version Expired' } %}
|
||||
{% set symfony_status = { dev: 'In Development', stable: 'Maintained', eom: 'Security Fixes Only', eol: 'Unmaintained' } %}
|
||||
{% set symfony_status_class = { dev: 'warning', stable: 'success', eom: 'warning', eol: 'error' } %}
|
||||
<table>
|
||||
<thead class="small">
|
||||
<tr>
|
||||
<th>Symfony Status</th>
|
||||
<th>Bugs {{ collector.symfonystate in ['eom', 'eol'] ? 'were' : 'are' }} fixed until</th>
|
||||
<th>Security issues {{ collector.symfonystate == 'eol' ? 'were' : 'are' }} fixed until</th>
|
||||
<th></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td class="font-normal">
|
||||
<span class="label status-{{ symfony_status_class[collector.symfonystate] }}">{{ symfony_status[collector.symfonystate]|upper }}</span>
|
||||
{% if collector.symfonylts %}
|
||||
<span class="label status-success">Long-Term Support</span>
|
||||
{% endif %}
|
||||
</td>
|
||||
<td class="font-normal">{{ collector.symfonyeom }}</td>
|
||||
<td class="font-normal">{{ collector.symfonyeol }}</td>
|
||||
<td class="font-normal">
|
||||
<a href="https://symfony.com/releases/{{ collector.symfonyminorversion }}#release-checker">View roadmap</a>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<div class="metrics">
|
||||
<div class="metric-group">
|
||||
<div class="metric">
|
||||
<span class="value">
|
||||
<span class="config-symfony-version-status-badge status-{{ symfony_status_class[collector.symfonystate] }}">{{ symfony_status[collector.symfonystate]|upper }}</span>
|
||||
</span>
|
||||
<span class="label">Your Symfony version status</span>
|
||||
</div>
|
||||
|
||||
{% if collector.symfonylts %}
|
||||
<div class="metric">
|
||||
<span class="value config-symfony-eol">
|
||||
{{ collector.symfonyeom }}
|
||||
</span>
|
||||
<span class="label">Bug fixes {{ collector.symfonystate in ['eom', 'eol'] ? 'ended on' : 'until' }}</span>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
<div class="metric">
|
||||
<span class="value config-symfony-eol">
|
||||
{{ collector.symfonyeol }}
|
||||
</span>
|
||||
<span class="label">
|
||||
{{ collector.symfonylts ? 'Security fixes' : 'Bug fixes and security fixes' }}
|
||||
{{ 'eol' == collector.symfonystate ? 'ended on' : 'until' }}</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<a class="config-symfony-version-roadmap-link" href="https://symfony.com/releases/{{ collector.symfonyminorversion }}">View Symfony {{ collector.symfonyversion }} release details</a>
|
||||
|
||||
<h2>PHP Configuration</h2>
|
||||
|
||||
@@ -184,19 +248,21 @@
|
||||
</div>
|
||||
|
||||
<div class="metrics">
|
||||
<div class="metric">
|
||||
<span class="value">{{ include('@WebProfiler/Icon/' ~ (collector.haszendopcache ? 'yes' : 'no') ~ '.svg') }}</span>
|
||||
<span class="label">OPcache</span>
|
||||
</div>
|
||||
<div class="metric-group">
|
||||
<div class="metric">
|
||||
<span class="value value-is-icon {{ not collector.haszendopcache ? 'value-shows-no-color' }}">{{ source('@WebProfiler/Icon/' ~ (collector.haszendopcache ? 'yes' : 'no') ~ '.svg') }}</span>
|
||||
<span class="label">OPcache</span>
|
||||
</div>
|
||||
|
||||
<div class="metric">
|
||||
<span class="value">{{ include('@WebProfiler/Icon/' ~ (collector.hasapcu ? 'yes' : 'no-gray') ~ '.svg') }}</span>
|
||||
<span class="label">APCu</span>
|
||||
</div>
|
||||
<div class="metric">
|
||||
<span class="value value-is-icon {{ not collector.hasapcu ? 'value-shows-no-color' }}">{{ source('@WebProfiler/Icon/' ~ (collector.hasapcu ? 'yes' : 'no') ~ '.svg') }}</span>
|
||||
<span class="label">APCu</span>
|
||||
</div>
|
||||
|
||||
<div class="metric">
|
||||
<span class="value">{{ include('@WebProfiler/Icon/' ~ (collector.hasxdebug ? 'yes' : 'no-gray') ~ '.svg') }}</span>
|
||||
<span class="label">Xdebug</span>
|
||||
<div class="metric">
|
||||
<span class="value value-is-icon {{ not collector.hasxdebug ? 'value-shows-no-color' }}">{{ source('@WebProfiler/Icon/' ~ (collector.hasxdebug ? 'yes' : 'no') ~ '.svg') }}</span>
|
||||
<span class="label">Xdebug</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user