]> git.mxchange.org Git - friendica.git/blobdiff - include/conversation.php
Merge pull request #3819 from annando/photo-rework
[friendica.git] / include / conversation.php
index 8d3ee98a262aecaaa3a6cbb860cf3fd979f6ab9d..bc227d97729fb0ac1a2251f2bab3ce48e310f3eb 100644 (file)
@@ -463,7 +463,14 @@ These Fields are not added below (yet). They are here to for bug search.
                `author`.`thumb` AS `author-thumb`, `owner`.`thumb` AS `owner-thumb`,
 
                `contact`.`network`, `contact`.`url`, `contact`.`name`, `contact`.`writable`,
-               `contact`.`self`, `contact`.`id` AS `cid`, `contact`.`alias`";
+               `contact`.`self`, `contact`.`id` AS `cid`, `contact`.`alias`,
+
+               `event`.`created` AS `event-created`, `event`.`edited` AS `event-edited`,
+               `event`.`start` AS `event-start`,`event`.`finish` AS `event-finish`,
+               `event`.`summary` AS `event-summary`,`event`.`desc` AS `event-desc`,
+               `event`.`location` AS `event-location`, `event`.`type` AS `event-type`,
+               `event`.`nofinish` AS `event-nofinish`,`event`.`adjust` AS `event-adjust`,
+               `event`.`ignore` AS `event-ignore`, `event`.`id` AS `event-id`";
 }
 
 /**
@@ -473,7 +480,8 @@ function item_joins() {
        return "STRAIGHT_JOIN `contact` ON `contact`.`id` = `item`.`contact-id` AND
                (NOT `contact`.`blocked` OR `contact`.`pending`)
                LEFT JOIN `contact` AS `author` ON `author`.`id`=`item`.`author-id`
-               LEFT JOIN `contact` AS `owner` ON `owner`.`id`=`item`.`owner-id`";
+               LEFT JOIN `contact` AS `owner` ON `owner`.`id`=`item`.`owner-id`
+               LEFT JOIN `event` ON `event-id` = `event`.`id`";
 }
 
 /**
@@ -792,6 +800,7 @@ function conversation(App $a, $items, $mode, $update, $preview = false) {
                                $tmp_item = array(
                                        'template' => $tpl,
                                        'id' => (($preview) ? 'P0' : $item['item_id']),
+                                       'guid' => (($preview) ? 'Q0' : $item['guid']),
                                        'network' => $item['item_network'],
                                        'network_name' => network_to_name($item['item_network'], $profile_link),
                                        'linktitle' => sprintf( t('View %s\'s profile @ %s'), $profile_name, ((strlen($item['author-link'])) ? $item['author-link'] : $item['url'])),