summaryrefslogtreecommitdiffstats
path: root/web/template
diff options
context:
space:
mode:
Diffstat (limited to 'web/template')
-rw-r--r--web/template/comaintainers_form.php20
-rw-r--r--web/template/pkg_details.php3
-rw-r--r--web/template/pkgbase_details.php3
3 files changed, 26 insertions, 0 deletions
diff --git a/web/template/comaintainers_form.php b/web/template/comaintainers_form.php
new file mode 100644
index 00000000..050f2550
--- /dev/null
+++ b/web/template/comaintainers_form.php
@@ -0,0 +1,20 @@
+<div class="box">
+ <h2><?= __('Manage Co-maintainers: %s', htmlspecialchars($pkgbase_name)) ?></h2>
+ <p>
+ <?= __('Use this form to add co-maintainers for %s%s%s (one user name per line):',
+ '<strong>', htmlspecialchars($pkgbase_name), '</strong>'); ?>
+ </p>
+ <form action="<?= get_pkgbase_uri($pkgbase_name); ?>" method="post">
+ <fieldset>
+ <input type="hidden" name="token" value="<?= htmlspecialchars($_COOKIE['AURSID']) ?>" />
+ <p>
+ <label for="id_users"><?= __("Users") ?>:</label>
+ <textarea name="users" id="id_users" rows="5" cols="50"><?= htmlspecialchars(implode("\n", $users)) ?></textarea>
+ </p>
+ <p>
+ <input type="submit" class="button" name="do_EditComaintainers" value="<?= __("Save") ?>" />
+ </p>
+ </fieldset>
+ </form>
+</div>
+
diff --git a/web/template/pkg_details.php b/web/template/pkg_details.php
index ecb081c1..359ea3c7 100644
--- a/web/template/pkg_details.php
+++ b/web/template/pkg_details.php
@@ -131,6 +131,9 @@ $sources = pkg_sources($row["ID"]);
</form>
</li>
<?php endif; ?>
+ <?php if (has_credential(CRED_PKGBASE_EDIT_COMAINTAINERS, array($row["MaintainerUID"]))): ?>
+ <li><a href="<?= get_pkgbase_uri($row['BaseName']) . 'comaintainers/'; ?>"><?= __('Manage Co-Maintainers'); ?></a></li>
+ <?php endif; ?>
<li><span class="flagged"><?php if ($row["RequestCount"] > 0) { echo _n('%d pending request', '%d pending requests', $row["RequestCount"]); } ?></span></li>
<li><a href="<?= get_pkgbase_uri($row['BaseName']) . 'request/'; ?>"><?= __('File Request'); ?></a></li>
<?php if (has_credential(CRED_PKGBASE_DELETE)): ?>
diff --git a/web/template/pkgbase_details.php b/web/template/pkgbase_details.php
index e698fb0a..ae363fd3 100644
--- a/web/template/pkgbase_details.php
+++ b/web/template/pkgbase_details.php
@@ -82,6 +82,9 @@ $pkgs = pkgbase_get_pkgnames($base_id);
</form>
</li>
<?php endif; ?>
+ <?php if (has_credential(CRED_PKGBASE_EDIT_COMAINTAINERS, array($row["MaintainerUID"]))): ?>
+ <li><a href="<?= get_pkgbase_uri($row['Name']) . 'comaintainers/'; ?>"><?= __('Manage Co-Maintainers'); ?></a></li>
+ <?php endif; ?>
<li><span class="flagged"><?php if ($row["RequestCount"] > 0) { echo _n('%d pending request', '%d pending requests', $row["RequestCount"]); } ?></span></li>
<li><a href="<?= get_pkgbase_uri($row['Name']) . 'request/'; ?>"><?= __('File Request'); ?></a></li>
<?php if (has_credential(CRED_PKGBASE_DELETE)): ?>