mirror of
https://github.com/friendica/friendica
synced 2024-11-10 02:22:55 +00:00
Issue 1871: Show an information if a group is empty
This commit is contained in:
parent
a8ab1bc947
commit
01c9d13927
2 changed files with 7 additions and 2 deletions
|
@ -190,6 +190,7 @@ function group_content(&$a) {
|
|||
'label_members' => t('Members'),
|
||||
'members' => array(),
|
||||
'label_contacts' => t('All Contacts'),
|
||||
'group_is_empty' => t('Group is empty'),
|
||||
'contacts' => array(),
|
||||
);
|
||||
|
||||
|
@ -204,7 +205,7 @@ function group_content(&$a) {
|
|||
group_rmv_member(local_user(),$group['name'],$member['id']);
|
||||
}
|
||||
|
||||
$r = q("SELECT * FROM `contact` WHERE `uid` = %d AND `blocked` = 0 and `pending` = 0 and `self` = 0 ORDER BY `name` ASC",
|
||||
$r = q("SELECT * FROM `contact` WHERE `uid` = %d AND NOT `blocked` AND NOT `pending` AND NOT `self` ORDER BY `name` ASC",
|
||||
intval(local_user())
|
||||
);
|
||||
|
||||
|
|
|
@ -2,7 +2,11 @@
|
|||
<div id="group">
|
||||
<h3>{{$groupeditor.label_members}}</h3>
|
||||
<div id="group-members" class="contact_list">
|
||||
{{foreach $groupeditor.members as $c}} {{$c}} {{/foreach}}
|
||||
{{if $groupeditor.members }}
|
||||
{{foreach $groupeditor.members as $c}} {{$c}} {{/foreach}}
|
||||
{{else}}
|
||||
{{$groupeditor.group_is_empty}}
|
||||
{{/if}}
|
||||
</div>
|
||||
<div id="group-members-end"></div>
|
||||
<hr id="group-separator" />
|
||||
|
|
Loading…
Reference in a new issue