]> git.mxchange.org Git - friendica.git/blob - view/templates/group_side.tpl
Improve contactgroupChangeMember() javascript function
[friendica.git] / view / templates / group_side.tpl
1 <div class="widget" id="group-sidebar">
2         <h3>{{$title}}</h3>
3
4         <div id="sidebar-group-list">
5                 <ul role="menu" id="sidebar-group-ul">
6                         {{foreach $groups as $group}}
7                                 <li role="menuitem" class="sidebar-group-li group-{{$group.id}}">
8                                         {{if ! $newgroup}}<span class="notify badge pull-right"></span>{{/if}}
9                                         {{if $group.cid}}
10                                                 <input type="checkbox"
11                                                         class="{{if $group.selected}}ticked{{else}}unticked {{/if}} action"
12                                                         onclick="return contactgroupChangeMember(this, '{{$group.id}}','{{$group.cid}}');"
13                                                         {{if $group.ismember}}checked="checked"{{/if}}
14                                                 />
15                                         {{/if}}
16                                         {{if $group.edit}}
17                                                 <a class="groupsideedit" href="{{$group.edit.href}}" title="{{$edittext}}">
18                                                         <span id="edit-sidebar-group-element-{{$group.id}}" class="group-edit-icon iconspacer small-pencil"><span class="sr-only">{{$edittext}}</span></span>
19                                                 </a>
20                                         {{/if}}
21                                         <a id="sidebar-group-element-{{$group.id}}" class="sidebar-group-element {{if $group.selected}}group-selected{{/if}}" href="{{$group.href}}">{{$group.text}}</a>
22                                 </li>
23                         {{/foreach}}
24                 </ul>
25         </div>
26
27         {{if $newgroup}}
28         <div id="sidebar-new-group">
29                 <a onclick="javascript:$('#group-new-form').fadeIn('fast');return false;">{{$createtext}}</a>
30                 <form id="group-new-form" action="group/new" method="post" style="display:none;">
31                         <input type="hidden" name="form_security_token" value="{{$form_security_token}}">
32                         <input name="groupname" id="id_groupname" placeholder="{{$creategroup}}">
33                 </form>
34         </div>
35         {{else}}
36         <div id="sidebar-edit-groups"><a href="{{$grouppage}}">{{$editgroupstext}}</a></div>
37         {{/if}}
38
39         {{if $ungrouped}}<div id="sidebar-ungrouped"><a class="{{if $ungrouped_selected}}group-selected{{/if}}" href="nogroup">{{$ungrouped}}</a></div>{{/if}}
40 </div>
41
42