Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
AlekSIS-Core
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Terraform modules
Monitor
Service Desk
Analyze
Contributor analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
AlekSIS®
Official
AlekSIS-Core
Commits
28e826cf
Commit
28e826cf
authored
6 years ago
by
Jonathan Weth
Browse files
Options
Downloads
Patches
Plain Diff
Redesign substitutions
parent
ebdc2314
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!86
Merge school-apps
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
schoolapps/static/common/style.css
+12
-1
12 additions, 1 deletion
schoolapps/static/common/style.css
schoolapps/timetable/templates/timetable/substitution.html
+19
-70
19 additions, 70 deletions
schoolapps/timetable/templates/timetable/substitution.html
with
31 additions
and
71 deletions
schoolapps/static/common/style.css
+
12
−
1
View file @
28e826cf
...
...
@@ -116,18 +116,25 @@ span.badge.new::after {
text-align
:
center
;
}
table
.substitutions
td
,
table
.substitutions
th
{
padding
:
10px
5px
;
}
/***************/
.btn-flat-large
{
line-height
:
60px
;
height
:
60px
;
}
.btn-flat-large
i
{
font-size
:
4rem
;
}
}
.btn-flat-medium
{
line-height
:
40px
;
height
:
40px
;
}
.btn-flat-medium
i
{
font-size
:
2rem
;
}
...
...
@@ -135,4 +142,8 @@ span.badge.new::after {
.btn-timetable-quicklaunch
{
margin
:
1%
;
width
:
30%
;
}
table
.striped
>
tbody
>
tr
:nth-child
(
odd
)
{
background-color
:
rgba
(
208
,
208
,
208
,
0.5
);
}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
schoolapps/timetable/templates/timetable/substitution.html
+
19
−
70
View file @
28e826cf
...
...
@@ -27,11 +27,20 @@
loadNew
();
}
function
onDateChanged
()
{
var
str
=
$
(
"
#date
"
).
val
();
var
split
=
str
.
split
(
"
.
"
)
activeDate
=
new
Date
(
split
[
2
],
split
[
1
]
-
1
,
split
[
0
]);
update
();
loadNew
();
}
var
activeDate
=
new
Date
({{
date_js
}});
$
(
document
).
ready
(
function
()
{
$
(
"
#date-before
"
).
click
(
onDateBeforeClick
);
$
(
"
#date-next
"
).
click
(
onDateNextClick
);
$
(
"
#date
"
).
change
(
onDateChanged
);
// Print the site
$
(
"
#print
"
).
click
(
function
()
{
...
...
@@ -73,114 +82,54 @@
<h5>
{{ date|date:"l, j. F Y" }}
</h5>
<table>
<table
class=
"substitutions striped"
>
<thead>
<tr>
<th><i
class=
"material-icons"
>
access_time
</i></th>
<th>
<i
class=
"material-icons"
>
people
</i>
</th>
<th>
Klassen
</th>
<th>
Lehrer
</th>
<th>
Fach
</th>
<th>
Raum
</th>
<th>
<i
class=
"material-icons"
>
info
</i>
</th>
<th>
i
</th>
<th>
Hinweis
</th>
<th></th>
</tr>
</thead>
<tbody>
{% for sub in sub_table %}
<tr
{
#
{%
if
sub.type =
=
1
or
sub.type =
=
2
%}
#
}
{
#
class=
"green-text"
#
}
{
#
{%
elif
sub.type =
=
3
%}
#
}
{
#
class=
"blue-text"
#
}
{
#
{%
endif
%}
#
}
class=
"{{ sub.css_class }}"
>
<tr
class=
"{{ sub.css_class }}"
>
<td>
<strong>
{# {% if sub.type == 3 %}#}
{# {{ sub.lesson|add:-1 }}./{{ sub.lesson }}.#}
{# {% else %}#}
{# {{ sub.lesson }}.#}
{# {% endif %}#}
{{ sub.lesson }}
</strong>
</td>
<td>
{# {% for class_ in sub.classes %}#}
{# {{ class_.name }}#}
{# {% endfor %}#}
{{ sub.classes }}
</td>
<td>
{# {% if sub.type == 1 %}#}
{#
<s>
{{ sub.teacher_old.shortcode }}
</s>
#}
{# {% elif sub.teacher_new and sub.teacher_old %}#}
{#
<s>
{{ sub.teacher_old.shortcode }}
</s>
→#}
{#
<strong>
{{ sub.teacher_new.shortcode }}
</strong>
#}
{# {% elif sub.teacher_new and not sub.teacher_old %}#}
{#
<strong>
{{ sub.teacher_new.shortcode }}
</strong>
#}
{# {% else %}#}
{#
<strong>
{{ sub.teacher_old.shortcode }}
</strong>
#}
{# {% endif %}#}
<span
class=
"tooltipped"
data-position=
"bottom"
data-tooltip=
"{{ sub.teacher_full|safe }}"
>
{{ sub.teacher|safe }}
</span>
</td>
<td>
{# {% if sub.type == 3 %}#}
{#
<span
class=
"badge new blue"
>
Aufsicht
</span>
#}
{# {% elif sub.type == 1 or sub.type == 2 %}#}
{#
<s>
{{ sub.subject_old.shortcode }}
</s>
#}
{# {% elif sub.subject_new and sub.subject_old %}#}
{#
<s>
{{ sub.subject_old.shortcode }}
</s>
→#}
{#
<strong>
{{ sub.subject_new.shortcode }}
</strong>
#}
{# {% elif sub.subject_new and not sub.subject_old %}#}
{#
<strong>
{{ sub.subject_new.shortcode }}
</strong>
#}
{# {% else %}#}
{#
<strong>
{{ sub.subject_old.shortcode }}
</strong>
#}
{# {% endif %}#}
{{ sub.subject|safe }}
</td>
<td>
{# {% if sub.type == 3 %}#}
{# {{ sub.corridor.name }}#}
{# {% elif sub.type == 1 or sub.type == 2 %}#}
{# {% elif sub.room_new and sub.room_old %}#}
{#
<s>
#}
{# {{ sub.room_old.shortcode }}#}
{#
</s>
→
<strong>
{{ sub.room_new.shortcode }}
</strong>
#}
{# {% elif sub.room_new and not sub.room_old %}#}
{#
<strong>
#}
{# {{ sub.room_new.shortcode }}#}
{#
</strong>
#}
{# {% else %}#}
{#
<strong>
#}
{# {{ sub.room_old.shortcode }}#}
{#
</strong>
#}
{# {% endif %}#}
<span
class=
"tooltipped"
data-position=
"bottom"
data-tooltip=
"{{ sub.room_full|safe }}"
>
{{ sub.room|safe }}
</span>
</td>
<td>
{#
<em>
{{ sub.text|default:"" }}
</em>
#}
{% if sub.badge %}
<span
class=
"badge new green hide-on-med-and-up"
>
{{ sub.badge }}
</span>
{% endif %}
<em>
{{ sub.text|default:"" }}
</em>
</td>
<td>
{# {% if sub.type == 1 %}#}
{#
<span
class=
"badge new green"
>
#}
{# Schüler frei
</span>
#}
{# {% elif sub.type == 2 %}#}
{#
<span
class=
"badge new green"
>
#}
{# Lehrer frei
</span>
#}
{# {% endif %}#}
<td
class=
"hide-on-small-and-down"
>
{% if sub.badge %}
<span
class=
"badge new green"
>
{{ sub.badge }}
</span>
{% endif %}
{#
<small>
{{ sub.id }} {{ sub.lesson_id }}
</small>
#}
<small>
{{ sub.extra }}
</small>
</td>
</tr>
{# {{ sub.date }}#}
{% endfor %}
</tbody>
</table>
...
...
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