root / snf-astakos-app / astakos / im / templates / im / astakosgroup_list.html @ df67421c
History | View | Annotate | Download (7.3 kB)
1 |
{% extends "im/account_base.html" %} |
---|---|
2 |
|
3 |
{% load filters %} |
4 |
|
5 |
{% block page.body %} |
6 |
<div class="maincol {% block innerpage.class %}{% endblock %}"> |
7 |
<h2>GROUPS</h2> |
8 |
{% if form %} |
9 |
<p>You can search for a group by name</p> |
10 |
<form action="{% url group_search %}" method="post" class="withlabels signup">{% csrf_token %} |
11 |
{% include "im/form_render.html" %} |
12 |
<div class="form-row submit"> |
13 |
<input type="submit" class="submit altcol" value="SEARCH" /> |
14 |
</div>
|
15 |
</form>
|
16 |
|
17 |
<!-- <p><a href="">Show all groups</a></p> -->
|
18 |
<form action="{% url group_all %}" method="post" class="withlabels signup">{% csrf_token %} |
19 |
<div class="form-row submit"> |
20 |
<input type="submit" class="submit altcol" value="Show all groups" /> |
21 |
</div>
|
22 |
</form>
|
23 |
{% else %} |
24 |
<div class="projects"> |
25 |
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. <br />You can <a href="{% url group_create_list %}">create a new group</a> or <a href="{% url group_search %}">join</a> to an existing one.</p> |
26 |
|
27 |
<ul class="widjets clearfix"> |
28 |
<li>
|
29 |
<div>
|
30 |
<p>WELCOME!<br />Connect with a world of people who share your passions.<br />With millions of groups at your fingertips, it's easy to find the group that's best for you -- no matter your interest.</p> |
31 |
<p class="btn"><a href="{% url group_create_list %}" class="submit">CREATE</a></p> |
32 |
</div>
|
33 |
</li>
|
34 |
<li>
|
35 |
<div>
|
36 |
<p>LOOKING FOR A GROUP?</p><p>Well, this is the place to start!</br>sdofuisd ofuaofi usdiof uiofu osifuaoi ufisdfiousf oiusd<br /><img alt="THINK ABOUT IT" src="/static/medialibrary/2012/06/behind_okeanos.png"></p> |
37 |
<p class="btn"><a href="{% url group_search %}" class="submit">JOIN</a></p> |
38 |
</div>
|
39 |
</li>
|
40 |
</ul>
|
41 |
|
42 |
{% endif %} |
43 |
{% with object_list|enabled:is_search as object_list %} |
44 |
{% if object_list %} |
45 |
{% with object_list|split:user as d %} |
46 |
{% with d|lookup:'own' as mine %} |
47 |
{% if mine %} |
48 |
<div class="full-dotted"> |
49 |
<table class="alt-style complex" id=""> |
50 |
<caption>MY GROUPS</caption> |
51 |
<thead>
|
52 |
<tr>
|
53 |
<th>Name</th> |
54 |
<th>Type</th> |
55 |
<th>Issued</th> |
56 |
<th>Expires</th> |
57 |
<th>Enrolled</th> |
58 |
<th>Status</th> |
59 |
<th>Moderated</th> |
60 |
<th> </th> |
61 |
|
62 |
</tr>
|
63 |
</thead>
|
64 |
<tbody>
|
65 |
{% for o in mine %} |
66 |
<tr class="{% cycle 'tr1' 'tr2' %}"> |
67 |
<td><a href="{% url group_detail o.id %}" title="visit group page">{{o.name|cut:"http://"|cut:"/" }}</a></td> |
68 |
<td>{{o.kind|capfirst}}</td> |
69 |
<td>{{o.issue_date|date:"d/m/Y"}}</td> |
70 |
<td>{{o.expiration_date|date:"d/m/Y"}}</td> |
71 |
<td>{{ o.approved_members|length }}</td> |
72 |
<td>{% if o.is_enabled %}Active{% else %}Pending{% endif %}</td> |
73 |
<td>{% if o.moderation_enabled%}Yes{% else %}No{% endif %}</td> |
74 |
<td><a href="#" class="more-info" title="more info"> </a></td> |
75 |
</tr>
|
76 |
<tr class="{% cycle 'tmore1' 'tmore2' %}" style="display:none"> |
77 |
<td colspan="8" class="info-td"> |
78 |
<div>
|
79 |
<p>{{o.desc}}</p> |
80 |
<p>{% if o.homepage%}
|
81 |
Vistit group's home page: <a href="{{ o.homepage }}">{{ o.homepage }}</a> |
82 |
{% else %} |
83 |
There is no homepage for this group yet. |
84 |
{% endif %} |
85 |
</p>
|
86 |
</div>
|
87 |
</td>
|
88 |
</tr>
|
89 |
{% endfor %} |
90 |
</tbody>
|
91 |
</table>
|
92 |
|
93 |
</div>
|
94 |
{% endif %} |
95 |
{% endwith %} |
96 |
{% with d|lookup:'other' as other %} |
97 |
{% if other %} |
98 |
<div class="full-dotted"> |
99 |
<table class="alt-style complex"> |
100 |
<caption>
|
101 |
{% if is_search %} |
102 |
SEARCH RESULTS |
103 |
{% else %} |
104 |
I PARTICIPATE IN |
105 |
{% endif %} |
106 |
</caption>
|
107 |
<thead>
|
108 |
<tr>
|
109 |
<th>Name</th> |
110 |
<th>Type</th> |
111 |
<th>Issued</th> |
112 |
<th>Expires</th> |
113 |
|
114 |
<th>Enrolled</th> |
115 |
|
116 |
|
117 |
<th>Enrollment status</th> |
118 |
<th> </th> |
119 |
|
120 |
</tr>
|
121 |
</thead>
|
122 |
<tbody>
|
123 |
{% for o in other %} |
124 |
<tr class="{% cycle 'tr1' 'tr2' %}"> |
125 |
<td><a href="{% url group_detail o.id %}" title="visit group page">{{o.name|cut:"http://"|cut:"/" }}</a></td> |
126 |
<td>{{o.kind|capfirst}}</td> |
127 |
<td>{{o.issue_date|date:"d/m/Y"}}</td> |
128 |
<td>{{o.expiration_date|date:"d/m/Y"}}</td> |
129 |
|
130 |
<td>{{ o.approved_members|length }}</td> |
131 |
|
132 |
<td>
|
133 |
{% if user in o.approved_members %} |
134 |
|
135 |
Registered |
136 |
<form action="{% url group_leave o.id %}" method="post" class="link-like">{% csrf_token %} |
137 |
<input type="submit" value="LEAVE GROUP" /> |
138 |
</form>
|
139 |
|
140 |
|
141 |
{% else %} |
142 |
{% if user in o.members %} |
143 |
Pending |
144 |
{% else %} |
145 |
Not member |
146 |
<form action="{% url group_join o.id %}" method="post" class="link-like">{% csrf_token %} |
147 |
<input type="submit" value="JOIN GROUP" /> |
148 |
</form>
|
149 |
|
150 |
{% endif %} |
151 |
{% endif %} |
152 |
</td>
|
153 |
<td><a href="#" class="more-info" title="more info"> </a></td> |
154 |
</tr>
|
155 |
<tr class="{% cycle 'tmore1' 'tmore2' %}" style="display:none"> |
156 |
<td colspan="8" class="info-td"> |
157 |
<div>
|
158 |
<p>{{o.desc}}</p> |
159 |
<p>{% if o.homepage%}
|
160 |
Vistit group's home page: <a href="{{ o.homepage }}">{{ o.homepage }}</a> |
161 |
{% else %} |
162 |
There is no homepage for this group yet. |
163 |
{% endif %} |
164 |
</p>
|
165 |
</div>
|
166 |
</td>
|
167 |
</tr>
|
168 |
{% endfor %} |
169 |
</tbody>
|
170 |
</table>
|
171 |
|
172 |
</div>
|
173 |
{% endif %} |
174 |
{% endwith %} |
175 |
{% endwith %} |
176 |
{% else %} |
177 |
{% if is_search %} |
178 |
<h2>No groups found!</h2> |
179 |
{% endif %} |
180 |
{% endif %} |
181 |
{% endwith %} |
182 |
</div>
|
183 |
</div>
|
184 |
{% endblock %} |