Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
scheduling-system
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
External wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD 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
SMASCH
scheduling-system
Commits
5f8d49a4
Commit
5f8d49a4
authored
6 years ago
by
Carlos Vega
Browse files
Options
Downloads
Patches
Plain Diff
add visit range of times to header only if the appointment is not general appointment
parent
04b79bd1
No related branches found
No related tags found
1 merge request
!171
Feature/daily availability
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
smash/web/templates/appointments/add.html
+7
-1
7 additions, 1 deletion
smash/web/templates/appointments/add.html
smash/web/views/appointment.py
+4
-2
4 additions, 2 deletions
smash/web/views/appointment.py
with
11 additions
and
3 deletions
smash/web/templates/appointments/add.html
+
7
−
1
View file @
5f8d49a4
...
...
@@ -16,7 +16,13 @@
{% endblock styles %}
{% block ui_active_tab %}'appointments'{% endblock ui_active_tab %}
{% block page_header %}New appointment for visit from {{visit_start}} to {{visit_end}}{% endblock page_header %}
{% block page_header %}
{% if isGeneral %}
New general appointment
{% else %}
New appointment for visit from {{visit_start}} to {{visit_end}}
{% endif %}
{% endblock page_header %}
{% block page_description %}{% endblock page_description %}
{% block title %}{{ block.super }} - Add new appointment{% endblock %}
...
...
This diff is collapsed.
Click to expand it.
smash/web/views/appointment.py
+
4
−
2
View file @
5f8d49a4
# coding=utf-8
import
logging
import
re
import
datetime
from
django.contrib
import
messages
from
django.core.exceptions
import
ValidationError
from
django.shortcuts
import
get_object_or_404
,
redirect
...
...
@@ -61,7 +61,9 @@ def appointment_add(request, visit_id=None):
form
=
AppointmentAddForm
(
user
=
request
.
user
)
return
wrap_response
(
request
,
'
appointments/add.html
'
,
{
'
form
'
:
form
,
'
visitID
'
:
visit_id
,
'
visit_start
'
:
visit_start
,
'
visit_end
'
:
visit_end
,
'
full_list
'
:
APPOINTMENT_LIST_GENERIC
})
{
'
form
'
:
form
,
'
visitID
'
:
visit_id
,
'
isGeneral
'
:
visit_id
is
None
,
'
visit_start
'
:
visit_start
,
'
visit_end
'
:
visit_end
,
'
full_list
'
:
APPOINTMENT_LIST_GENERIC
})
def
appointment_edit
(
request
,
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