aboutsummaryrefslogtreecommitdiffstats
path: root/view
diff options
context:
space:
mode:
authorzotlabs <mike@macgirvin.com>2017-01-27 13:27:36 +1100
committerGitHub <noreply@github.com>2017-01-27 13:27:36 +1100
commit80e1130bb5d7dcbfeb0fa2af7038237f65a3a0db (patch)
tree5d5bc2efa544586bfa7a9df6e35f09592d842398 /view
parent22839e48d013abdc46b609cd50b45b3bce6626f9 (diff)
parentd9a5b11c9a1b5e400e83130306bd375b22887201 (diff)
downloadvolse-hubzilla-80e1130bb5d7dcbfeb0fa2af7038237f65a3a0db.tar.gz
volse-hubzilla-80e1130bb5d7dcbfeb0fa2af7038237f65a3a0db.tar.bz2
volse-hubzilla-80e1130bb5d7dcbfeb0fa2af7038237f65a3a0db.zip
Merge pull request #655 from anaqreon/addon-repo-gui
Addon repo management GUI
Diffstat (limited to 'view')
-rwxr-xr-xview/tpl/admin_plugins.tpl18
1 files changed, 15 insertions, 3 deletions
diff --git a/view/tpl/admin_plugins.tpl b/view/tpl/admin_plugins.tpl
index 993a4dea2..4360aa30c 100755
--- a/view/tpl/admin_plugins.tpl
+++ b/view/tpl/admin_plugins.tpl
@@ -1,8 +1,10 @@
<div class="generic-content-wrapper">
<div class="section-title-wrapper">
+ {{if $allowManageRepos}}
<div class="pull-right">
<button class="btn btn-success btn-xs" onclick="openClose('form');">{{$managerepos}}</button>
</div>
+ {{/if}}
<h2 id="title">{{$title}} - {{$page}}</h2>
<div class="clear"></div>
</div>
@@ -18,7 +20,7 @@
{{foreach $addonrepos as $repo}}
<tr>
<td style="width: 70%;">
- <span class="pull-left">{{$repo.name}}</span>
+ <span class="pull-left">{{$repo.name}}</span><span id="update-message-{{$repo.name}}" style="margin-left: 20px;"></span>
</td>
<td style="width: 15%;">
<button class="btn btn-xs btn-primary pull-right" style="margin-left: 10px; margin-right: 10px;" onclick="updateAddonRepo('{{$repo.name}}'); return false;"><i class='fa fa-download'></i>&nbsp;{{$repoUpdateButton}}</button>
@@ -139,10 +141,20 @@
function(response) {
if (response.success) {
window.console.log('Addon repo '+repoName+' successfully updated :' + response['message']);
- alert('Addon repo updated.');
+ //alert('Addon repo updated.');
+ $('#update-message-' + repoName).css('background-color', 'yellow');
+ $('#update-message-' + repoName).html('Repo updated!');
+ setTimeout(function () {
+ $('#update-message-' + repoName).html('');
+ }, 60000);
} else {
window.console.log('Error updating repo :' + response['message']);
- alert('Error updating addon repo!');
+ //alert('Error updating addon repo!');
+ $('#update-message-' + repoName).css('background-color', 'red');
+ $('#update-message-' + repoName).html('Error updating repo!');
+ setTimeout(function () {
+ $('#update-message-' + repoName).html('');
+ }, 60000);
}
return false;
},