aboutsummaryrefslogtreecommitdiff
path: root/app/views/subscription
diff options
context:
space:
mode:
authorGravatar Alexandre Alapetite <alexandre@alapetite.fr> 2019-07-25 16:51:48 +0200
committerGravatar GitHub <noreply@github.com> 2019-07-25 16:51:48 +0200
commit82611c9622ed23b0e9fcf5f9f651ddffa1fd7706 (patch)
treefc2c97fd8dd84ec30473cb85b889d8326c9a831a /app/views/subscription
parent744a9e8cf00aef7dec0acfa5f90f0dcfa2ef8837 (diff)
parent042b40eeeea77db854daab1bec96fce5c2cdd4b2 (diff)
Merge pull request #2451 from FreshRSS/dev1.14.3
FreshRSS 1.14.3
Diffstat (limited to 'app/views/subscription')
-rw-r--r--app/views/subscription/category.phtml5
-rw-r--r--app/views/subscription/index.phtml49
2 files changed, 10 insertions, 44 deletions
diff --git a/app/views/subscription/category.phtml b/app/views/subscription/category.phtml
new file mode 100644
index 000000000..38746f23c
--- /dev/null
+++ b/app/views/subscription/category.phtml
@@ -0,0 +1,5 @@
+<?php
+
+if ($this->category) {
+ $this->renderHelper('category/update');
+}
diff --git a/app/views/subscription/index.phtml b/app/views/subscription/index.phtml
index 8b196cb00..20f72ad66 100644
--- a/app/views/subscription/index.phtml
+++ b/app/views/subscription/index.phtml
@@ -80,50 +80,9 @@
?>
<div class="box">
<div class="box-title">
- <form action="<?php echo _url('category', 'update', 'id', $cat->id()); ?>" method="post">
- <input type="hidden" name="_csrf" value="<?php echo FreshRSS_Auth::csrfToken(); ?>" />
- <input type="text" name="name" value="<?php echo $cat->name(); ?>" />
-
- <div class="dropdown">
- <div id="dropdown-cat-<?php echo $cat->id(); ?>" class="dropdown-target"></div>
-
- <a class="dropdown-toggle btn" href="#dropdown-cat-<?php echo $cat->id(); ?>"><?php echo _i('down'); ?></a>
- <ul class="dropdown-menu">
- <li class="dropdown-close"><a href="#close">❌</a></li>
-
- <li class="item"><a href="<?php echo _url('index', 'index', 'get', 'c_' . $cat->id()); ?>"><?php echo _t('gen.action.filter'); ?></a></li>
-
- <?php
- $no_feed = empty($feeds);
- $is_default = ($cat->id() === $this->default_category->id());
-
- if (!$no_feed || !$is_default) {
- ?>
- <li class="separator"></li>
- <?php } if (!$no_feed) { ?>
- <li class="item">
- <button class="as-link confirm"
- data-str-confirm="<?php echo _t('gen.js.confirm_action_feed_cat'); ?>"
- type="submit"
- form="controller-category"
- formaction="<?php echo _url('category', 'empty', 'id', $cat->id()); ?>">
- <?php echo _t('gen.action.empty'); ?></button>
- </li>
- <?php } if (!$is_default) { ?>
- <li class="item">
- <button class="as-link confirm"
- data-str-confirm="<?php echo _t('gen.js.confirm_action_feed_cat'); ?>"
- type="submit"
- form="controller-category"
- formaction="<?php echo _url('category', 'delete', 'id', $cat->id()); ?>">
- <?php echo _t('gen.action.remove'); ?></button>
- </li>
- <?php } ?>
- </ul>
- </div>
- </form>
+ <a class="configure open-slider" href="<?php echo _url('subscription', 'category', 'id', $cat->id()); ?>"><?php echo _i('configure'); ?></a>
+ <?php echo $cat->name(); ?>
</div>
-
<ul class="box-content" data-cat-id="<?php echo $cat->id(); ?>">
<?php if (!empty($feeds)) { ?>
<?php
@@ -159,12 +118,14 @@
</ul>
</div>
-<?php $class = isset($this->feed) ? ' class="active"' : ''; ?>
+<?php $class = $this->displaySlider ? ' class="active"' : ''; ?>
<a href="#" id="close-slider"<?php echo $class; ?>></a>
<div id="slider"<?php echo $class; ?>>
<?php
if (isset($this->feed)) {
$this->renderHelper('feed/update');
+ } elseif (isset($this->category)) {
+ $this->renderHelper('category/update');
}
?>
</div>