From fa49bf13f32effd485b9e8520c4c7eff1d341904 Mon Sep 17 00:00:00 2001 From: shish Date: Fri, 6 Jul 2007 17:21:17 +0000 Subject: [PATCH] add status messages during bulk_add git-svn-id: file:///home/shish/svn/shimmie2/trunk@238 7f39781d-f577-437e-ae19-be835c7a54ca --- ext/bulk_add/main.php | 2 +- ext/bulk_add/theme.php | 7 ++++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/ext/bulk_add/main.php b/ext/bulk_add/main.php index afff4aae..1a077481 100644 --- a/ext/bulk_add/main.php +++ b/ext/bulk_add/main.php @@ -11,8 +11,8 @@ class BulkAdd extends Extension { if($user->is_admin() && isset($_POST['dir'])) { set_time_limit(0); - $this->theme->display_upload_results($event->page_object); $this->add_dir($_POST['dir']); + $this->theme->display_upload_results($event->page_object); } } diff --git a/ext/bulk_add/theme.php b/ext/bulk_add/theme.php index a140558f..2081f416 100644 --- a/ext/bulk_add/theme.php +++ b/ext/bulk_add/theme.php @@ -1,10 +1,15 @@ set_title("Adding folder"); $page->set_heading("Adding folder"); $page->add_block(new NavBlock()); + foreach($this->messages as $block) { + $page->add_block($block); + } } public function display_admin_block($page) { @@ -23,7 +28,7 @@ class BulkAddTheme extends Themelet { } public function add_status($title, $body) { - $page->add_block(new Block($title, $body)); + $this->messages[] = new Block($title, $body); } } ?>