aboutsummaryrefslogtreecommitdiff
path: root/app/views/configure/system.phtml
diff options
context:
space:
mode:
authorGravatar Alexis Degrugillier <github@ainw.org> 2015-08-22 09:33:58 -0400
committerGravatar Alexis Degrugillier <github@ainw.org> 2015-08-22 09:33:58 -0400
commit269c6b88c4486a0ae1a92df65578ee6ab6f0bbca (patch)
treed8771ef8e7c2c128b81a4187cb6d8b728421e7f9 /app/views/configure/system.phtml
parenta63dadd91bcb23f2b9d2ecac9bef76265b8d9f48 (diff)
Add a system configuration page
It allows to modify system configuration from the interface. At the moment, only limits are modifiable. The user limit was removed from the user page and added here along with categories and feeds limits.
Diffstat (limited to 'app/views/configure/system.phtml')
-rw-r--r--app/views/configure/system.phtml47
1 files changed, 47 insertions, 0 deletions
diff --git a/app/views/configure/system.phtml b/app/views/configure/system.phtml
new file mode 100644
index 000000000..cbedc511b
--- /dev/null
+++ b/app/views/configure/system.phtml
@@ -0,0 +1,47 @@
+<?php $this->partial('aside_configure'); ?>
+
+<div class="post">
+ <a href="<?php echo _url('index', 'index'); ?>"><?php echo _t('gen.action.back_to_rss_feeds'); ?></a>
+
+ <form method="post" action="<?php echo _url('configure', 'system'); ?>">
+ <legend><?php echo _t('admin.system'); ?></legend>
+
+ <div class="form-group">
+ <label class="group-name" for="max-registrations"><?php echo _t('admin.system.registration.number'); ?></label>
+ <div class="group-controls">
+ <input type="number" id="max-registrations" name="max-registrations" value="<?php echo FreshRSS_Context::$system_conf->limits['max_registrations']; ?>" min="0" data-leave-validation="<?php echo FreshRSS_Context::$system_conf->limits['max_registrations']; ?>"/>
+ <?php echo _i('help'); ?> <?php echo _t('admin.system.registration.help'); ?>
+ </div>
+ </div>
+
+ <div class="form-group">
+ <div class="group-controls">
+ <?php
+ $number = count(listUsers());
+ echo _t($number > 1 ? 'admin.user.numbers' : 'admin.user.number', $number);
+ ?>
+ </div>
+ </div>
+
+ <div class="form-group">
+ <label class="group-name" for="max-feeds"><?php echo _t('admin.system.max-feeds'); ?></label>
+ <div class="group-controls">
+ <input type="number" id="max-feeds" name="max-feeds" value="<?php echo FreshRSS_Context::$system_conf->limits['max_feeds']; ?>" min="1" data-leave-validation="<?php echo FreshRSS_Context::$system_conf->limits['max_feeds']; ?>"/>
+ </div>
+ </div>
+
+ <div class="form-group">
+ <label class="group-name" for="max-categories"><?php echo _t('admin.system.max-categories'); ?></label>
+ <div class="group-controls">
+ <input type="number" id="max-categories" name="max-categories" value="<?php echo FreshRSS_Context::$system_conf->limits['max_categories']; ?>" min="1" data-leave-validation="<?php echo FreshRSS_Context::$system_conf->limits['max_categories']; ?>"/>
+ </div>
+ </div>
+
+ <div class="form-group form-actions">
+ <div class="group-controls">
+ <button type="submit" class="btn btn-important"><?php echo _t('gen.action.submit'); ?></button>
+ <button type="reset" class="btn"><?php echo _t('gen.action.cancel'); ?></button>
+ </div>
+ </div>
+ </form>
+</div> \ No newline at end of file