| @@ 241-253 (lines=13) @@ | ||
| 238 | * |
|
| 239 | * @return void |
|
| 240 | */ |
|
| 241 | public function activeAction() |
|
| 242 | {
|
|
| 243 | $all = $this->page->query() |
|
| 244 | ->where('inactivated IS NULL')
|
|
| 245 | ->andWhere('deleted is NULL')
|
|
| 246 | ->execute(); |
|
| 247 | ||
| 248 | $this->theme->setTitle("Pages that are active");
|
|
| 249 | $this->views->add('page/active', [
|
|
| 250 | 'pages' => $all, |
|
| 251 | 'title' => "Pages that are active", |
|
| 252 | ]); |
|
| 253 | } |
|
| 254 | ||
| 255 | /** |
|
| 256 | * List all inactive pages. |
|
| @@ 260-271 (lines=12) @@ | ||
| 257 | * |
|
| 258 | * @return void |
|
| 259 | */ |
|
| 260 | public function inactiveAction() |
|
| 261 | {
|
|
| 262 | $all = $this->page->query() |
|
| 263 | ->where('inactivated IS NOT NULL')
|
|
| 264 | ->execute(); |
|
| 265 | ||
| 266 | $this->theme->setTitle("Pages that are inactive");
|
|
| 267 | $this->views->add('page/inactive', [
|
|
| 268 | 'pages' => $all, |
|
| 269 | 'title' => "Pages that are inactive", |
|
| 270 | ]); |
|
| 271 | } |
|
| 272 | ||
| 273 | /** |
|
| 274 | * List all deleted pages. |
|
| @@ 278-289 (lines=12) @@ | ||
| 275 | * |
|
| 276 | * @return void |
|
| 277 | */ |
|
| 278 | public function trashAction() |
|
| 279 | {
|
|
| 280 | $all = $this->page->query() |
|
| 281 | ->where('deleted IS NOT NULL')
|
|
| 282 | ->execute(); |
|
| 283 | ||
| 284 | $this->theme->setTitle("Pages that are deleted");
|
|
| 285 | $this->views->add('page/deleted', [
|
|
| 286 | 'pages' => $all, |
|
| 287 | 'title' => "Pages that are deleted", |
|
| 288 | ]); |
|
| 289 | } |
|
| 290 | ||
| 291 | } |
|
| @@ 246-258 (lines=13) @@ | ||
| 243 | * |
|
| 244 | * @return void |
|
| 245 | */ |
|
| 246 | public function activeAction() |
|
| 247 | {
|
|
| 248 | $all = $this->blog->query() |
|
| 249 | ->where('inactivated IS NULL')
|
|
| 250 | ->andWhere('deleted is NULL')
|
|
| 251 | ->execute(); |
|
| 252 | ||
| 253 | $this->theme->setTitle("Posts that are active");
|
|
| 254 | $this->views->add('blog/active', [
|
|
| 255 | 'posts' => $all, |
|
| 256 | 'title' => "Blogposts that are active", |
|
| 257 | ]); |
|
| 258 | } |
|
| 259 | ||
| 260 | /** |
|
| 261 | * List all inactive blogposts. |
|
| @@ 265-276 (lines=12) @@ | ||
| 262 | * |
|
| 263 | * @return void |
|
| 264 | */ |
|
| 265 | public function inactiveAction() |
|
| 266 | {
|
|
| 267 | $all = $this->blog->query() |
|
| 268 | ->where('inactivated IS NOT NULL')
|
|
| 269 | ->execute(); |
|
| 270 | ||
| 271 | $this->theme->setTitle("Posts that are inactive");
|
|
| 272 | $this->views->add('blog/inactive', [
|
|
| 273 | 'posts' => $all, |
|
| 274 | 'title' => "Blogposts that are inactive", |
|
| 275 | ]); |
|
| 276 | } |
|
| 277 | ||
| 278 | /** |
|
| 279 | * List all deleted blogposts. |
|
| @@ 283-294 (lines=12) @@ | ||
| 280 | * |
|
| 281 | * @return void |
|
| 282 | */ |
|
| 283 | public function trashAction() |
|
| 284 | {
|
|
| 285 | $all = $this->blog->query() |
|
| 286 | ->where('deleted IS NOT NULL')
|
|
| 287 | ->execute(); |
|
| 288 | ||
| 289 | $this->theme->setTitle("Posts that are deleted");
|
|
| 290 | $this->views->add('blog/deleted', [
|
|
| 291 | 'posts' => $all, |
|
| 292 | 'title' => "Blogposts that are deleted", |
|
| 293 | ]); |
|
| 294 | } |
|
| 295 | ||
| 296 | } |
|