Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Castellum
castellum_scheduler
Commits
18b00f36
Commit
18b00f36
authored
Nov 11, 2020
by
Hayat
Browse files
Merge branch 'fix-booked-timeslot' into 'master'
Fix booked timeslot See merge request
!6
parents
4c6aff19
020f3461
Pipeline
#7751
passed with stages
in 4 minutes and 2 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
scheduler/main/templates/main/invitation_form.html
View file @
18b00f36
...
...
@@ -9,7 +9,7 @@
<form
method=
"post"
>
{% csrf_token %}
{% bootstrap_form_errors form
type='non_fields'
%}
{% bootstrap_form_errors form %}
<p>
{% translate 'Please select one of the available timeslots to make an appointment. You will still be able to change your selection later.' %}
</p>
<table
class=
"table table-hover"
data-js=
"multi-datetime"
>
...
...
scheduler/main/views.py
View file @
18b00f36
...
...
@@ -21,6 +21,7 @@ from collections import OrderedDict
from
django.conf
import
settings
from
django.contrib.auth.mixins
import
LoginRequiredMixin
from
django.contrib
import
messages
from
django.db
import
models
from
django.core.exceptions
import
PermissionDenied
from
django.http
import
HttpResponse
from
django.http
import
JsonResponse
...
...
@@ -89,7 +90,9 @@ class InvitationUpdateView(UpdateView):
def
get_context_data
(
self
,
**
kwargs
):
context
=
super
().
get_context_data
(
**
kwargs
)
timeslots
=
list
(
self
.
object
.
schedule
.
timeslot_set
.
all
())
timeslots
=
list
(
self
.
object
.
schedule
.
timeslot_set
.
filter
(
models
.
Q
(
invitation
=
None
)
|
models
.
Q
(
invitation
=
self
.
object
)
))
dates
=
[]
times
=
[]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment