Platal::page()->kill("Visibility invalide: " . $visibility);
}
$this->visibility = self::$v_values[$visibility];
+ if ($this->mobile && !in_array($this->modbile_pub, $this->visibility)) {
+ unset($this->data['mobile']);
+ }
}
pn_f.name AS firstname, pn_l.name AS lastname, pn_n.name AS nickname,
IF(pn_uf.name IS NULL, pn_f.name, pn_uf.name) AS firstname_usual,
IF(pn_ul.name IS NULL, pn_l.name, pn_ul.name) AS lastname_usual,
- pd.promo AS promo, pd.short_name, pd.directory_name AS full_name
+ pd.promo AS promo, pd.short_name, pd.directory_name AS full_name,
+ pp.display_tel AS mobile, pp.pub AS mobile_pub
FROM profiles AS p
INNER JOIN profile_display AS pd ON (pd.pid = p.pid)
INNER JOIN profile_education AS pe ON (pe.uid = p.pid AND FIND_IN_SET(\'primary\', pe.flags))
AND pn_uf.typeid = ' . self::getNameTypeId('lastname_ordinary', true) . ')
LEFT JOIN profile_name AS pn_ul ON (pn_ul.pid = p.pid
AND pn_ul.typeid = ' . self::getNameTypeId('firstname_ordinary', true) . ')
- LEFT JOIN profile_name aS pn_n ON (pn_n.pid = p.pid
+ LEFT JOIN profile_name AS pn_n ON (pn_n.pid = p.pid
AND pn_n.typeid = ' . self::getNameTypeId('nickname', true) . ')
+ LEFT JOIN profile_phones AS pp ON (pp.uid = p.pid AND pp.link_type = \'user\' AND tel_type = \'mobile\')
WHERE p.pid IN ' . XDB::formatArray($pids) . '
GROUP BY p.pid');
}
<div class="long">
{if !$dead}
{assign var=address value=$profile->getMainAddress()}
- {if $c.web || $c.mobile || $address.country || $c.entreprise || (!$dead && !$registered)}
+ {if $c.web || $profile->mobile || $address.country || $c.entreprise || (!$dead && !$registered)}
<table cellspacing="0" cellpadding="0">
{if $c.web}
<tr>
<td class="rt">{if $address.locality}{$address.locality}, {/if}{$address.country}</td>
</tr>
{/if}
- {if $c.mobile && !$dead}
+ {if $profile->mobile && !$dead}
<tr>
<td class="lt">Mobile :</td>
- <td class="rt">{$c.mobile}</td>
+ <td class="rt">{$profile->mobile}</td>
</tr>
{/if}
{if $c.entreprise}