diff --git a/mycaldav/models.py b/mycaldav/models.py index ad5d327..ceafb20 100644 --- a/mycaldav/models.py +++ b/mycaldav/models.py @@ -67,6 +67,10 @@ class cls_caldav(): elif periode == 2: tomorow = date + timedelta(days=1) events = recurring_ical_events.of(Calendar.from_ical(self.data)).between(today,tomorow) + elif periode == 3: + today = date + timedelta(days=-1) + tomorow = date + timedelta(days=2) + events = recurring_ical_events.of(Calendar.from_ical(self.data)).between(today,tomorow) elif periode == 7: endweek = date + timedelta(days=7) events = recurring_ical_events.of(Calendar.from_ical(self.data)).between(today,endweek) @@ -113,7 +117,7 @@ class cls_caldav(): item.dtstart = event["DTSTART"].dt.strftime("%d.%m.%Y %H:%M") item.dtstamp = int(event["DTSTART"].dt.strftime("%Y%m%d%H%M")) - print(item.dtstamp) + #print(item.dtstamp) item.dtend = event["DTEND"].dt.strftime("%d.%m.%Y %H:%M") @@ -126,10 +130,11 @@ class cls_caldav(): if type(start) is Datetime.date: start = datetime.combine(start, datetime.min.time()) print("convert Date to datetime") - print(start) + print(f"Parse Data {item.name} start:{start}") if int(start.strftime("%H")) < 19: self.day.append(item) if int(start.strftime("%H")) >= 19: + print("add to night ****") self.night.append(item) diff --git a/mycaldav/static/mycaldav/style.css b/mycaldav/static/mycaldav/style.css index 32f4174..853cc9c 100644 --- a/mycaldav/static/mycaldav/style.css +++ b/mycaldav/static/mycaldav/style.css @@ -26,7 +26,7 @@ } .ifram_main_div{ - color: white + color: var(--main-text-color) } table{ diff --git a/mycaldav/templates/reskreen.html b/mycaldav/templates/reskreen.html index 0728de4..9a8dffd 100644 --- a/mycaldav/templates/reskreen.html +++ b/mycaldav/templates/reskreen.html @@ -134,8 +134,7 @@
Communications importantes
diff --git a/mycaldav/templates/rh/rh_view.html b/mycaldav/templates/rh/rh_view.html index 4d35aa3..87acc71 100644 --- a/mycaldav/templates/rh/rh_view.html +++ b/mycaldav/templates/rh/rh_view.html @@ -3,23 +3,44 @@
{{task.key}} {{task.str_start_date}} - {{task.str_end_date}} - |
+
{{ task.name }} {{task.desc}} |
+ {{task.key}} + {{task.str_start_date}} - {{task.str_end_date}} + + |
+
+ {{ task.name }} + {{task.desc}} + |
+
Aucune information d'accueil
{% endif %} diff --git a/mycaldav/templates/team/team_view.html b/mycaldav/templates/team/team_view.html index 0a43602..549d449 100644 --- a/mycaldav/templates/team/team_view.html +++ b/mycaldav/templates/team/team_view.html @@ -1,57 +1,295 @@ {% load static %} + + -- {{task.key}} - {% if task.team_transfert %} - - {% endif %} - {% if task.team_manif %} - Manif - {% endif %} - | -- {{ task.team_1 }} - {{ task.team_2 }} - | -
Nuit | -|
- {{task.key}} - {% if task.team_transfert %} - - {% endif %} - {% if task.team_manif %} - - {% endif %} - | -- {{ task.team_1 }} - {{ task.team_2 }} - | -
Aucune information d'équipage
-{% endif %} ++ {{task.key}} + {% if task.team_transfert %} + + {% endif %} + {% if task.team_manif %} + Manif + {% endif %} + | ++ {{ task.team_1 }} + {{ task.team_2 }} + | +
Nuit | +|
+ {{task.key}} + {% if task.team_transfert %} + + {% endif %} + {% if task.team_manif %} + + {% endif %} + | ++ {{ task.team_1 }} + {{ task.team_2 }} + | +
Aucune information d'équipage
+ {% endif %} + ++ {{task.key}} + {% if task.team_transfert %} + + {% endif %} + {% if task.team_manif %} + Manif + {% endif %} + | ++ {{ task.team_1 }} + {{ task.team_2 }} + | +
Nuit | +|
+ {{task.key}} + {% if task.team_transfert %} + + {% endif %} + {% if task.team_manif %} + + {% endif %} + | ++ {{ task.team_1 }} + {{ task.team_2 }} + | +
Aucune information d'équipage
+ {% endif %} +