File: _systemCheckSection.twig

package info (click to toggle)
matomo 5.8.0-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 95,068 kB
  • sloc: php: 289,425; xml: 127,249; javascript: 112,130; python: 202; sh: 178; makefile: 20; sql: 10
file content (29 lines) | stat: -rw-r--r-- 1,486 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
{%- import _self as local -%}
{% macro diagnosticInfo(results) -%}
{% set error = constant('Piwik\\Plugins\\Diagnostics\\Diagnostic\\DiagnosticResult::STATUS_ERROR') %}
{% set warning = constant('Piwik\\Plugins\\Diagnostics\\Diagnostic\\DiagnosticResult::STATUS_WARNING') %}
{% set informational = constant('Piwik\\Plugins\\Diagnostics\\Diagnostic\\DiagnosticResult::STATUS_INFORMATIONAL') %}
{%- for result in results %}

#### {{ result.label|rawSafeDecoded }}:
{% for item in result.items -%}
{%- if item.status == error -%} &#9888; Error: {{ item.comment|anonymiseSystemInfo|striptags('<br><p><strong><code>') }}{% elseif item.status == warning %} &#9888; Warning: {{ item.comment|anonymiseSystemInfo|striptags('<br><p><strong><code>') }}{% elseif item.status == informational %} {{ item.comment|anonymiseSystemInfo|striptags('<br><p><strong><code>') }}{% else %} &#10004; {{ item.comment|anonymiseSystemInfo|striptags('<br><p><strong><code>') }}{% endif -%}
{%- endfor %}

{% if result.longErrorMessage -%}
{{ result.longErrorMessage|striptags('<br><p><strong><code>') }}
{%- endif -%}
    {%- endfor -%}
{%- endmacro -%}
<details>
<summary>Click to view System Check</summary>

### Mandatory checks
{{ local.diagnosticInfo(diagnosticReport.getMandatoryDiagnosticResults()) }}

### Optional checks
{{ local.diagnosticInfo(diagnosticReport.getOptionalDiagnosticResults()) }}

### Informational results
{{ local.diagnosticInfo(diagnosticReport.getInformationalResults()) }}
</details>