categorize.phtml 2.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. <?php $this->partial ('aside_feed'); ?>
  2. <div class="post">
  3. <a href="<?php echo _url ('index', 'index'); ?>"><?php echo Minz_Translate::t ('back_to_rss_feeds'); ?></a>
  4. <form method="post" action="<?php echo _url ('configure', 'categorize'); ?>">
  5. <legend><?php echo Minz_Translate::t ('categories_management'); ?></legend>
  6. <p class="alert alert-warn"><?php echo Minz_Translate::t ('feeds_moved_category_deleted', $this->defaultCategory->name ()); ?></p>
  7. <?php $i = 0; foreach ($this->categories as $cat) { $i++; ?>
  8. <div class="form-group">
  9. <label class="group-name" for="cat_<?php echo $cat->id (); ?>">
  10. <?php echo Minz_Translate::t ('category_number', $i); ?>
  11. </label>
  12. <div class="group-controls">
  13. <div class="stick">
  14. <input type="text" id="cat_<?php echo $cat->id (); ?>" name="categories[]" value="<?php echo $cat->name (); ?>" />
  15. <?php if ($cat->nbFeed () > 0) { ?>
  16. <button type="submit" class="btn btn-attention confirm" formaction="<?php echo _url ('feed', 'delete', 'id', $cat->id (), 'type', 'category'); ?>"><?php echo Minz_Translate::t ('ask_empty'); ?></button>
  17. <?php } ?>
  18. </div>
  19. (<?php echo Minz_Translate::t ('number_feeds', $cat->nbFeed ()); ?>)
  20. <?php if ($cat->id () === $this->defaultCategory->id ()) { ?>
  21. <?php echo FreshRSS_Themes::icon('help'); ?> <?php echo Minz_Translate::t ('can_not_be_deleted'); ?>
  22. <?php } ?>
  23. <input type="hidden" name="ids[]" value="<?php echo $cat->id (); ?>" />
  24. </div>
  25. </div>
  26. <?php } ?>
  27. <div class="form-group">
  28. <label class="group-name" for="new_category"><?php echo Minz_Translate::t ('add_category'); ?></label>
  29. <div class="group-controls">
  30. <input type="text" id="new_category" name="new_category" placeholder="<?php echo Minz_Translate::t ('new_category'); ?>" />
  31. </div>
  32. </div>
  33. <div class="form-group form-actions">
  34. <div class="group-controls">
  35. <button type="submit" class="btn btn-important"><?php echo Minz_Translate::t ('save'); ?></button>
  36. <button type="reset" class="btn"><?php echo Minz_Translate::t ('cancel'); ?></button>
  37. </div>
  38. </div>
  39. </form>
  40. </div>