The server list no longer renders a bogus server entry in case no
monotone server has been configured yet in the connected usher instance. Also display a short info text if the server or connection list for a running monotone server is empty.
This commit is contained in:
parent
8693418d39
commit
1b1b00a10c
@ -17,6 +17,9 @@
|
||||
- Fix SSH public key parsing issues and improve the check for existing, uploaded keys (issue 679)
|
||||
- Diff views now show empty context lines for git and hg again (issue 688)
|
||||
- Let the SVN command line client not store the login credentials we give him as arguments
|
||||
- The usher section in the forge administration no longer displays a bogus
|
||||
server enty in case no monotone server is configured in the connected
|
||||
usher instance
|
||||
|
||||
## Documentation
|
||||
|
||||
|
@ -48,7 +48,7 @@ class IDF_Scm_Monotone_Usher
|
||||
if ($conn == 'none')
|
||||
return array();
|
||||
|
||||
return preg_split('/[ ]/', $conn);
|
||||
return preg_split('/[ ]/', $conn, -1, PREG_SPLIT_NO_EMPTY);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -73,7 +73,7 @@ class IDF_Scm_Monotone_Usher
|
||||
if ($conn == 'none')
|
||||
return array();
|
||||
|
||||
$single_conns = preg_split('/[ ]/', $conn);
|
||||
$single_conns = preg_split('/[ ]/', $conn, -1, PREG_SPLIT_NO_EMPTY);
|
||||
$ret = array();
|
||||
foreach ($single_conns as $conn) {
|
||||
preg_match('/\((\w+)\)([^:]+):(\d+)/', $conn, $matches);
|
||||
|
@ -8,12 +8,18 @@
|
||||
<th>{trans "address"}</th>
|
||||
<th>{trans "port"}</th>
|
||||
</tr>
|
||||
{if count($connections) == 0}
|
||||
<tr>
|
||||
<td colspan="2" align="center">{trans 'No connections found.'}</td>
|
||||
</tr>
|
||||
{else}
|
||||
{foreach $connections as $connection}
|
||||
<tr>
|
||||
<td>{$connection.address}</td>
|
||||
<td>{$connection.port}</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
{/if}
|
||||
</table>
|
||||
{/block}
|
||||
|
||||
|
@ -9,6 +9,11 @@
|
||||
<th>{trans "status"}</th>
|
||||
<th>{trans "action"}</th>
|
||||
</tr>
|
||||
{if count($servers) == 0}
|
||||
<tr>
|
||||
<td colspan="3" align="center">{trans 'No monotone servers configured.'}</td>
|
||||
</tr>
|
||||
{else}
|
||||
{foreach $servers as $server}
|
||||
<tr>
|
||||
<td>{$server.name}</td>
|
||||
@ -31,6 +36,7 @@
|
||||
{/if}
|
||||
</tr>
|
||||
{/foreach}
|
||||
{/if}
|
||||
</table>
|
||||
{/block}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user