]> git.mxchange.org Git - friendica.git/commitdiff
Contact requests now contain more information.
authorMichael Vogel <icarus@dabo.de>
Wed, 12 Aug 2015 06:07:21 +0000 (08:07 +0200)
committerMichael Vogel <icarus@dabo.de>
Wed, 12 Aug 2015 06:07:21 +0000 (08:07 +0200)
mod/notifications.php
view/templates/intros.tpl

index 09666d08c2e5ace79f952fe208173392a947f136..82e13b1be5c2a08219a20bde99744f2eed96ec82 100644 (file)
@@ -135,8 +135,13 @@ function notifications_content(&$a) {
                        $a->set_pager_itemspage(20);
                }
 
-               $r = q("SELECT `intro`.`id` AS `intro_id`, `intro`.*, `contact`.*, `fcontact`.`name` AS `fname`,`fcontact`.`url` AS `furl`,`fcontact`.`photo` AS `fphoto`,`fcontact`.`request` AS `frequest`
-                       FROM `intro` LEFT JOIN `contact` ON `contact`.`id` = `intro`.`contact-id` LEFT JOIN `fcontact` ON `intro`.`fid` = `fcontact`.`id`
+               $r = q("SELECT `intro`.`id` AS `intro_id`, `intro`.*, `contact`.*, `fcontact`.`name` AS `fname`,`fcontact`.`url` AS `furl`,`fcontact`.`photo` AS `fphoto`,`fcontact`.`request` AS `frequest`,
+                               `gcontact`.`location` AS `glocation`, `gcontact`.`about` AS `gabout`,
+                               `gcontact`.`keywords` AS `gkeywords`, `gcontact`.`gender` AS `ggender`
+                       FROM `intro`
+                               LEFT JOIN `contact` ON `contact`.`id` = `intro`.`contact-id`
+                               LEFT JOIN `gcontact` ON `gcontact`.`nurl` = `contact`.`nurl`
+                               LEFT JOIN `fcontact` ON `intro`.`fid` = `fcontact`.`id`
                        WHERE `intro`.`uid` = %d $sql_extra AND `intro`.`blocked` = 0 ",
                                intval($_SESSION['uid']));
 
@@ -210,6 +215,15 @@ function notifications_content(&$a) {
                                        '$contact_id' => $rr['contact-id'],
                                        '$photo' => ((x($rr,'photo')) ? $rr['photo'] : "images/person-175.jpg"),
                                        '$fullname' => $rr['name'],
+                                       '$location_label' => t('Location:'),
+                                       '$location' => $rr['glocation'],
+                                       '$location_label' => t('Location:'),
+                                       '$about' => $rr['gabout'],
+                                       '$about_label' => t('About:'),
+                                       '$keywords' => $rr['gkeywords'],
+                                       '$keywords_label' => t('Tags:'),
+                                       '$gender' => $rr['ggender'],
+                                       '$gender_label' => t('Gender:'),
                                        '$hidden' => array('hidden', t('Hide this contact from others'), ($rr['hidden'] == 1), ''),
                                        '$activity' => array('activity', t('Post a new friend activity'), (intval(get_pconfig(local_user(),'system','post_newfriend')) ? '1' : 0), t('if applicable')),
                                        '$url' => zrl($rr['url']),
index 74fb53b589f5a91c127857225fd5796eb0218ea6..aa10cde48fea4fb2cb7bb255a6baab29836d37f5 100644 (file)
@@ -3,8 +3,12 @@
 <div class="intro-wrapper" id="intro-{{$contact_id}}" >
 
 <p class="intro-desc">{{$str_notifytype}} {{$notify_type}}</p>
-<div class="intro-fullname" id="intro-fullname-{{$contact_id}}" >{{$fullname}}</div>
-<a class="intro-url-link" id="intro-url-link-{{$contact_id}}" href="{{$url}}" ><img id="photo-{{$contact_id}}" class="intro-photo" src="{{$photo}}" width="175" height=175" title="{{$fullname|escape:'html'}}" alt="{{$fullname|escape:'html'}}" /></a>
+<a class="intro-url-link" id="intro-url-link-{{$contact_id}}" href="{{$url}}" ><div class="intro-fullname" id="intro-fullname-{{$contact_id}}" >{{$fullname}}</div></a>
+<img id="photo-{{$contact_id}}" class="intro-photo" src="{{$photo}}" width="175" height=175" title="{{$fullname|escape:'html'}}" alt="{{$fullname|escape:'html'}}" />
+{{if $location}}<dl><dt>{{$location_label}}</dt><dd>{{$location}}</dd></dl>{{/if}}
+{{if $gender}}<dl><dt>{{$gender_label}}</dt><dd>{{$gender}}</dd></dl>{{/if}}
+{{if $keywords}}<dl><dt>{{$keywords_label}}</dt><dd>{{$keywords}}</dd></dl>{{/if}}
+{{if $about}}<dl><dt>{{$about_label}}</dt><dd>{{$about}}</dd></dl>{{/if}}
 <div class="intro-knowyou">{{$knowyou}}</div>
 <div class="intro-note" id="intro-note-{{$contact_id}}">{{$note}}</div>
 <div class="intro-wrapper-end" id="intro-wrapper-end-{{$contact_id}}"></div>