mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-31 05:50:42 +02:00
[ticket/11366] Extension's version's check
Add a feature to check automatically the version of the installed extensions. The informations are cached for 24 hours (like for the global update check on the main page of the acp). The informations about the versions are display both on the global list and on the detailled page. To do this the developper has to to let the composer.json of the latest version available and add some informations into it : "extra": { "version-check": { "host": "<the host>", "directory": "<the directory containing the file>", "filename": "<the composer.json of the latest version>" } } He can also add two extra informations which will be displayed if a new version is available : "extra": { "download": "<download link>", "annoucement": "<announcement link>", } Currently a notice is displayed when the "extra.version-check" informations are missing. Ticket: https://tracker.phpbb.com/browse/PHPBB3-11366 Signed-off-by: Nicofuma <github@nicofuma.fr> PHPBB3-11366
This commit is contained in:
committed by
Tristan Darricau
parent
47b240660b
commit
e0b2ceef83
@@ -6,6 +6,19 @@
|
||||
|
||||
<h1>{L_EXTENSIONS_ADMIN}</h1>
|
||||
|
||||
<!-- IF S_VERSIONCHECK_FAIL -->
|
||||
<div class="errorbox notice">
|
||||
<p>{L_VERSIONCHECK_FAIL}</p>
|
||||
<p>{VERSIONCHECK_FAIL_REASON}</p>
|
||||
<p><a href="{U_VERSIONCHECK_FORCE}">{L_VERSIONCHECK_FORCE_UPDATE}</a></p>
|
||||
</div>
|
||||
<!-- ENDIF -->
|
||||
<!-- IF S_VERSIONCHECK -->
|
||||
<div class="<!-- IF S_UP_TO_DATE -->successbox<!-- ELSE -->errorbox<!-- ENDIF -->">
|
||||
<p>{UP_TO_DATE_MSG} - <a href="{U_VERSIONCHECK_FORCE}">{L_VERSIONCHECK_FORCE_UPDATE}</a></p>
|
||||
</div>
|
||||
<!-- ENDIF -->
|
||||
|
||||
<fieldset>
|
||||
<legend>{L_EXT_DETAILS}</legend>
|
||||
<!-- IF META_DISPLAY_NAME -->
|
||||
@@ -46,6 +59,28 @@
|
||||
</dl>
|
||||
</fieldset>
|
||||
|
||||
<!-- IF S_VERSIONCHECK && not S_UP_TO_DATE -->
|
||||
<fieldset>
|
||||
<legend>{L_LATEST_VERSION}</legend>
|
||||
<dl>
|
||||
<dt><label>{L_VERSION}{L_COLON}</label></dt>
|
||||
<dd><span id="latest_version">{LATEST_VERSION}</span></dd>
|
||||
</dl>
|
||||
<!-- IF LATEST_DOWNLOAD -->
|
||||
<dl>
|
||||
<dt><label>{L_DOWNLOAD_LATEST}</label></dt>
|
||||
<dd><strong id="latest_download"><a href="{LATEST_DOWNLOAD}">{L_DOWNLOAD} {META_NAME} {LATEST_VERSION}</a></strong></dd>
|
||||
</dl>
|
||||
<!-- ENDIF -->
|
||||
<!-- IF LATEST_ANNOUNCEMENT -->
|
||||
<dl>
|
||||
<dt><label>{L_ANNOUNCEMENT_TOPIC}</label></dt>
|
||||
<dd><strong id="latest_announcement"><a href="{LATEST_ANNOUNCEMENT}">{L_RELEASE_ANNOUNCEMENT}</a></strong></dd>
|
||||
</dl>
|
||||
<!-- ENDIF -->
|
||||
</fieldset>
|
||||
<!-- ENDIF -->
|
||||
|
||||
<!-- IF META_REQUIRE_PHPBB || META_REQUIRE_PHP -->
|
||||
<fieldset>
|
||||
<legend>{L_REQUIREMENTS}</legend>
|
||||
|
@@ -7,22 +7,30 @@
|
||||
<p>{L_EXTENSIONS_EXPLAIN}</p>
|
||||
|
||||
<table class="table1">
|
||||
<col class="row1" ><col class="row2" ><col class="row2" >
|
||||
<col class="row1" ><col class="row1" ><col class="row1" ><col class="row2" ><col class="row2" >
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{L_EXTENSION_NAME}</th>
|
||||
<th>{L_EXTENSION_OPTIONS}</th>
|
||||
<th>{L_EXTENSION_ACTIONS}</th>
|
||||
<th width="10%">{L_CURRENT_VERSION}</th>
|
||||
<th width="10%">{L_LATEST_VERSION}</th>
|
||||
<th width="10%">{L_EXTENSION_OPTIONS}</th>
|
||||
<th width="10%">{L_EXTENSION_ACTIONS}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<!-- IF .enabled -->
|
||||
<tr>
|
||||
<td class="row3" colspan="3"><strong>{L_EXTENSIONS_ENABLED}</strong></td>
|
||||
<td class="row3" colspan="5"><strong>{L_EXTENSIONS_ENABLED}</strong></td>
|
||||
</tr>
|
||||
<!-- BEGIN enabled -->
|
||||
<tr class="ext_enabled">
|
||||
<td><strong>{enabled.META_DISPLAY_NAME}</strong></td>
|
||||
<td style="text-align: center;">{enabled.META_VERSION}</td>
|
||||
<td style="text-align: center;">
|
||||
<!-- IF enabled.S_VERSIONCHECK -->
|
||||
<strong <!-- IF enabled.S_UP_TO_DATE -->style="color: #228822;"<!-- ELSE -->style="color: #BC2A4D;"<!-- ENDIF -->>{enabled.LATEST_VERSION}</strong> [ <a href="{enabled.U_VERSIONCHECK_FORCE}">{L_VERSIONCHECK_FORCE_UPDATE}</a> ]
|
||||
<!-- ENDIF -->
|
||||
</td>
|
||||
<td style="text-align: center;"><a href="{enabled.U_DETAILS}">{L_DETAILS}</a></td>
|
||||
<td style="text-align: center;">
|
||||
<!-- BEGIN actions -->
|
||||
@@ -36,11 +44,17 @@
|
||||
|
||||
<!-- IF .disabled -->
|
||||
<tr>
|
||||
<td class="row3" colspan="3"><strong>{L_EXTENSIONS_DISABLED}</strong></td>
|
||||
<td class="row3" colspan="5"><strong>{L_EXTENSIONS_DISABLED}</strong></td>
|
||||
</tr>
|
||||
<!-- BEGIN disabled -->
|
||||
<tr class="ext_disabled">
|
||||
<td><strong>{disabled.META_DISPLAY_NAME}</strong></td>
|
||||
<td style="text-align: center;">{disabled.META_VERSION}</td>
|
||||
<td style="text-align: center;">
|
||||
<!-- IF disabled.S_VERSIONCHECK -->
|
||||
<strong <!-- IF disabled.S_UP_TO_DATE -->style="color: #228822;"<!-- ELSE -->style="color: #BC2A4D;"<!-- ENDIF -->>{disabled.LATEST_VERSION}</strong> [ <a href="{U_VERSIONCHECK_FORCE}">{L_VERSIONCHECK_FORCE_UPDATE}</a> ]
|
||||
<!-- ENDIF -->
|
||||
</td>
|
||||
<td style="text-align: center;">
|
||||
<!-- IF disabled.U_DETAILS --><a href="{disabled.U_DETAILS}">{L_DETAILS}</a><!-- ENDIF -->
|
||||
</td>
|
||||
|
Reference in New Issue
Block a user