Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
W
website
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Deploy
Releases
Container registry
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jannik Hellenkamp
website
Commits
d71c3368
Commit
d71c3368
authored
8 years ago
by
Andreas Valder
Browse files
Options
Downloads
Patches
Plain Diff
added "fsmpi" permission, closes #143
parent
c4dc313a
No related branches found
No related tags found
No related merge requests found
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
server.py
+5
-0
5 additions, 0 deletions
server.py
static/fsmpi.png
+0
-0
0 additions, 0 deletions
static/fsmpi.png
static/moderator.js
+4
-0
4 additions, 0 deletions
static/moderator.js
templates/macros.html
+3
-0
3 additions, 0 deletions
templates/macros.html
with
12 additions
and
0 deletions
server.py
+
5
−
0
View file @
d71c3368
...
@@ -140,6 +140,7 @@ def permdescr(perms):
...
@@ -140,6 +140,7 @@ def permdescr(perms):
password
=
False
password
=
False
l2p_courses
=
[]
l2p_courses
=
[]
rwth_intern
=
False
rwth_intern
=
False
fsmpi_intern
=
False
for
perm
in
perms
:
for
perm
in
perms
:
if
perm
[
'
type
'
]
==
'
public
'
:
if
perm
[
'
type
'
]
==
'
public
'
:
public
=
True
public
=
True
...
@@ -149,12 +150,16 @@ def permdescr(perms):
...
@@ -149,12 +150,16 @@ def permdescr(perms):
l2p_courses
.
append
(
perm
[
'
param1
'
])
l2p_courses
.
append
(
perm
[
'
param1
'
])
elif
perm
[
'
type
'
]
==
'
rwth
'
:
elif
perm
[
'
type
'
]
==
'
rwth
'
:
rwth_intern
=
True
rwth_intern
=
True
elif
perm
[
'
type
'
]
==
'
fsmpi
'
:
fsmpi_intern
=
True
if
public
or
not
perms
:
if
public
or
not
perms
:
return
'
public
'
,
'
Öffentlich verfügbar
'
return
'
public
'
,
'
Öffentlich verfügbar
'
if
rwth_intern
:
if
rwth_intern
:
if
password
:
if
password
:
return
'
rwth
'
,
'
Nur für RWTH-Angehörige und Nutzer mit Passwort verfügbar
'
return
'
rwth
'
,
'
Nur für RWTH-Angehörige und Nutzer mit Passwort verfügbar
'
return
'
rwth
'
,
'
Nur für RWTH-Angehörige verfügbar
'
return
'
rwth
'
,
'
Nur für RWTH-Angehörige verfügbar
'
if
fsmpi_intern
:
return
'
fsmpi
'
,
'
Nur für Fachschaftler verfügbar
'
if
l2p_courses
:
if
l2p_courses
:
if
password
:
if
password
:
return
'
l2p
'
,
'
Nur für Teilnehmer der Veranstaltung und Nutzer mit Passwort verfügbar
'
return
'
l2p
'
,
'
Nur für Teilnehmer der Veranstaltung und Nutzer mit Passwort verfügbar
'
...
...
This diff is collapsed.
Click to expand it.
static/fsmpi.png
0 → 100644
+
0
−
0
View file @
d71c3368
6.57 KiB
This diff is collapsed.
Click to expand it.
static/moderator.js
+
4
−
0
View file @
d71c3368
...
@@ -165,6 +165,9 @@ var moderator = {
...
@@ -165,6 +165,9 @@ var moderator = {
case
'
rwth
'
:
case
'
rwth
'
:
permstring
=
'
(rwth intern)
'
permstring
=
'
(rwth intern)
'
break
;
break
;
case
'
fsmpi
'
:
permstring
=
'
(fsmpi intern)
'
break
;
case
'
l2p
'
:
case
'
l2p
'
:
permstring
=
'
(
'
+
perm
.
param1
+
'
)
'
permstring
=
'
(
'
+
perm
.
param1
+
'
)
'
break
;
break
;
...
@@ -177,6 +180,7 @@ var moderator = {
...
@@ -177,6 +180,7 @@ var moderator = {
html
+=
'
<option value="public">Öffentlich</option>
'
;
html
+=
'
<option value="public">Öffentlich</option>
'
;
html
+=
'
<option selected value="password">Passwort</option>
'
;
html
+=
'
<option selected value="password">Passwort</option>
'
;
html
+=
'
<option value="rwth">RWTH intern</option>
'
;
html
+=
'
<option value="rwth">RWTH intern</option>
'
;
html
+=
'
<option value="fsmpi">FSMPI intern</option>
'
;
html
+=
'
<option value="l2p">L2P Lernraum</option>
'
;
html
+=
'
<option value="l2p">L2P Lernraum</option>
'
;
html
+=
'
</select>
'
;
html
+=
'
</select>
'
;
html
+=
'
<input class="col-xs-12 passwordinput authuser" type="text" placeholder="Benutzername">
'
;
html
+=
'
<input class="col-xs-12 passwordinput authuser" type="text" placeholder="Benutzername">
'
;
...
...
This diff is collapsed.
Click to expand it.
templates/macros.html
+
3
−
0
View file @
d71c3368
...
@@ -203,6 +203,9 @@ $('#embedcodebtn').popover(
...
@@ -203,6 +203,9 @@ $('#embedcodebtn').popover(
{% if permdescription[0] == 'rwth' %}
{% if permdescription[0] == 'rwth' %}
{% set permlogos = '
<span
class=
"fa"
aria-hidden=
"true"
style=
"width: 25px; height: 20px; background-size: cover; background-image: url(\'/static/rwth.png\');"
></span>
' %}
{% set permlogos = '
<span
class=
"fa"
aria-hidden=
"true"
style=
"width: 25px; height: 20px; background-size: cover; background-image: url(\'/static/rwth.png\');"
></span>
' %}
{% endif %}
{% endif %}
{% if permdescription[0] == 'fsmpi' %}
{% set permlogos = '
<span
class=
"fa"
aria-hidden=
"true"
style=
"width: 25px; height: 20px; background-size: cover; background-image: url(\'/static/fsmpi.png\');"
></span>
' %}
{% endif %}
{% if ismod() %}
{% if ismod() %}
<button
class=
"btn btn-default modmoderator_permissioneditor"
data-type=
"{{ type }}"
data-id=
"{{ id }}"
>
<button
class=
"btn btn-default modmoderator_permissioneditor"
data-type=
"{{ type }}"
data-id=
"{{ id }}"
>
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment