From 754ac2cff72b0d9d5d9b389740cc8946ed1e40b2 Mon Sep 17 00:00:00 2001 From: Klaus Weidenbach Date: Mon, 6 Apr 2015 23:51:30 +0200 Subject: Fix Design Tool navigation for sys channel. Fix creating menu for sys channel. --- mod/layouts.php | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'mod/layouts.php') diff --git a/mod/layouts.php b/mod/layouts.php index 74a713cf1..2616513f8 100644 --- a/mod/layouts.php +++ b/mod/layouts.php @@ -98,7 +98,6 @@ function layouts_content(&$a) { header('Content-disposition: attachment; filename="' . $r[0]['sid'] . '.pdl"'); echo json_encode($r); killme(); - } } @@ -156,7 +155,7 @@ function layouts_content(&$a) { 'title' => $rr['sid'], 'mid' => $rr['mid'] ); - } + } } //Build the base URL for edit links @@ -172,7 +171,6 @@ function layouts_content(&$a) { '$preview' => '1', )); - - return $o; + return $o; } -- cgit v1.2.3 From 2619b60721c328aacbf7bd30d47476a68ce9b203 Mon Sep 17 00:00:00 2001 From: friendica Date: Thu, 9 Apr 2015 15:45:08 -0700 Subject: make sure we redirect to a sane place after deleting a webpage element --- mod/layouts.php | 2 ++ 1 file changed, 2 insertions(+) (limited to 'mod/layouts.php') diff --git a/mod/layouts.php b/mod/layouts.php index 2616513f8..4640c6690 100644 --- a/mod/layouts.php +++ b/mod/layouts.php @@ -33,6 +33,8 @@ function layouts_content(&$a) { $which = argv(1); + $_SESSION['return_url'] = $a->query_string; + $uid = local_channel(); $owner = 0; $channel = null; -- cgit v1.2.3 From b4dff3a9ff16811ea0310f5dbf4d7559c97835b0 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Wed, 22 Apr 2015 10:31:36 +0200 Subject: provide headings for blocks and layouts --- mod/layouts.php | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'mod/layouts.php') diff --git a/mod/layouts.php b/mod/layouts.php index 4640c6690..04d81f91e 100644 --- a/mod/layouts.php +++ b/mod/layouts.php @@ -112,7 +112,7 @@ function layouts_content(&$a) { 'id' => 'layout-help-tab', )); - $o .= replace_macros(get_markup_template('common_tabs.tpl'),array('$tabs' => $tabs)); + //$o .= replace_macros(get_markup_template('common_tabs.tpl'),array('$tabs' => $tabs)); // Create a status editor (for now - we'll need a WYSIWYG eventually) to create pages @@ -123,13 +123,15 @@ function layouts_content(&$a) { 'webpage' => ITEM_PDL, 'is_owner' => true, 'nickname' => $a->profile['channel_address'], - 'lockstate' => (($channel['channel_allow_cid'] || $channel['channel_allow_gid'] || $channel['channel_deny_cid'] || $channel['channel_deny_gid']) ? 'lock' : 'unlock'), + //do we need that at this place? + //'lockstate' => (($channel['channel_allow_cid'] || $channel['channel_allow_gid'] || $channel['channel_deny_cid'] || $channel['channel_deny_gid']) ? 'lock' : 'unlock'), 'bang' => '', 'showacl' => false, 'visitor' => false, 'nopreview' => 1, 'ptlabel' => t('Layout Name'), 'profile_uid' => intval($owner), + 'expanded' => true ); if($_REQUEST['title']) @@ -140,7 +142,7 @@ function layouts_content(&$a) { $x['pagetitle'] = $_REQUEST['pagetitle']; - $o .= status_editor($a,$x); + $editor = status_editor($a,$x); $r = q("select iid, sid, mid from item_id left join item on item.id = item_id.iid where item_id.uid = %d and service = 'PDL' order by sid asc", @@ -164,14 +166,16 @@ function layouts_content(&$a) { $url = z_root() . '/editlayout/' . $which; $o .= replace_macros(get_markup_template('layoutlist.tpl'), array( + '$title' => t('Layouts'), + '$create' => t('Create'), + '$help' => array('text' => t('Help'), 'url' => 'help/Comanche', 'title' => t('Comanche page description language help')), + '$editor' => $editor, '$baseurl' => $url, '$edit' => t('Edit'), '$share' => t('Share'), '$pages' => $pages, '$channel' => $which, '$view' => t('View'), - '$preview' => '1', - )); return $o; -- cgit v1.2.3