diff options
Diffstat (limited to 'mod/blog/views')
-rw-r--r-- | mod/blog/views/default/blog/group_module.php | 2 | ||||
-rw-r--r-- | mod/blog/views/default/forms/blog/save.php | 33 | ||||
-rw-r--r-- | mod/blog/views/default/object/blog.php | 4 |
3 files changed, 28 insertions, 11 deletions
diff --git a/mod/blog/views/default/blog/group_module.php b/mod/blog/views/default/blog/group_module.php index 9a1515585..6cfe6c98e 100644 --- a/mod/blog/views/default/blog/group_module.php +++ b/mod/blog/views/default/blog/group_module.php @@ -10,7 +10,7 @@ if ($group->blog_enable == "no") { } $all_link = elgg_view('output/url', array( - 'href' => "blog/group/$group->guid/owner", + 'href' => "blog/group/$group->guid/all", 'text' => elgg_echo('link:view:all'), )); diff --git a/mod/blog/views/default/forms/blog/save.php b/mod/blog/views/default/forms/blog/save.php index b2d20579f..d99f45f01 100644 --- a/mod/blog/views/default/forms/blog/save.php +++ b/mod/blog/views/default/forms/blog/save.php @@ -5,6 +5,8 @@ * @package Blog */ +$blog = get_entity($vars['guid']); + $draft_warning = $vars['draft_warning']; if ($draft_warning) { $draft_warning = '<span class="message warning">' . $draft_warning . '</span>'; @@ -12,6 +14,7 @@ if ($draft_warning) { $action_buttons = ''; $delete_link = ''; +$preview_button = ''; if ($vars['guid']) { // add a delete button if editing @@ -19,12 +22,24 @@ if ($vars['guid']) { $delete_link = elgg_view('output/confirmlink', array( 'href' => $delete_url, 'text' => elgg_echo('delete'), - 'class' => 'elgg-button elgg-button-delete elgg-state-disabled' + 'class' => 'elgg-button elgg-button-delete elgg-state-disabled float-alt' )); } -$save_button = elgg_view('input/submit', array('value' => elgg_echo('save'))); -$action_buttons = $save_button . $delete_link; +// published blogs do not get the preview button +if (!$vars['guid'] || ($blog && $blog->status != 'published')) { + $preview_button = elgg_view('input/submit', array( + 'value' => elgg_echo('preview'), + 'name' => 'preview', + 'class' => 'mls', + )); +} + +$save_button = elgg_view('input/submit', array( + 'value' => elgg_echo('save'), + 'name' => 'save', +)); +$action_buttons = $save_button . $preview_button . $delete_link; $title_label = elgg_echo('title'); $title_input = elgg_view('input/text', array( @@ -135,13 +150,15 @@ $body_input $categories_input -<div class="elgg-subtext pvm mbn elgg-divide-top"> +<div class="elgg-form-footer-alt"> + <div class="elgg-subtext mbm"> $save_status <span class="blog-save-status-time">$saved</span> -</div> + </div> -$guid_input -$container_guid_input + $guid_input + $container_guid_input -$action_buttons + $action_buttons +</div> ___HTML; diff --git a/mod/blog/views/default/object/blog.php b/mod/blog/views/default/object/blog.php index 048a68a1a..8456829fe 100644 --- a/mod/blog/views/default/object/blog.php +++ b/mod/blog/views/default/object/blog.php @@ -74,7 +74,7 @@ if ($full) { 'subtitle' => $subtitle, 'tags' => $tags, ); - $list_body = elgg_view('page/components/summary', $params); + $list_body = elgg_view('object/elements/summary', $params); $blog_info = elgg_view_image_block($owner_icon, $list_body); @@ -94,7 +94,7 @@ HTML; 'tags' => $tags, 'content' => $excerpt, ); - $list_body = elgg_view('page/components/summary', $params); + $list_body = elgg_view('object/elements/summary', $params); echo elgg_view_image_block($owner_icon, $list_body); } |