diff options
| author | 2014-02-11 23:17:44 +0100 | |
|---|---|---|
| committer | 2014-02-11 23:17:44 +0100 | |
| commit | 6f693afe99fdd236484e157ee491c0a6c92a8219 (patch) | |
| tree | 4f8fe5b99d1266211b7a67be6808443e381a5dce /app/views | |
| parent | 4419df1da4f5b7199ece4f51f2e4da66f976616e (diff) | |
Add an information message when a feed is empty
Diffstat (limited to 'app/views')
| -rw-r--r-- | app/views/configure/feed.phtml | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/app/views/configure/feed.phtml b/app/views/configure/feed.phtml index 138808a9f..2da04ac2d 100644 --- a/app/views/configure/feed.phtml +++ b/app/views/configure/feed.phtml @@ -7,8 +7,12 @@ <h1><?php echo $this->flux->name (); ?></h1> <?php echo $this->flux->description (); ?> + <?php $nbEntries = $this->flux->nbEntries (); ?> + <?php if ($this->flux->inError ()) { ?> <p class="alert alert-error"><span class="alert-head"><?php echo Minz_Translate::t ('damn'); ?></span> <?php echo Minz_Translate::t ('feed_in_error'); ?></p> + <?php } elseif ($nbEntries === 0) { ?> + <p class="alert alert-warn"><?php echo Minz_Translate::t ('feed_empty'); ?></p> <?php } ?> <form method="post" action="<?php echo _url ('configure', 'feed', 'id', $this->flux->id ()); ?>" autocomplete="off"> @@ -81,7 +85,7 @@ <div class="form-group"> <label class="group-name"><?php echo Minz_Translate::t ('number_articles'); ?></label> <div class="group-controls"> - <span class="control"><?php echo $this->flux->nbEntries (); ?></span> + <span class="control"><?php echo $nbEntries; ?></span> </div> </div> <div class="form-group"> |
