Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Daniel W Bond
advisor
Commits
4cb0d9bd
Commit
4cb0d9bd
authored
Feb 02, 2014
by
Daniel W Bond
Browse files
the student manage forms are not yet correct
parent
fa34bfa7
Changes
1
Hide whitespace changes
Inline
Side-by-side
advisor/trajectories/forms.py
View file @
4cb0d9bd
...
@@ -34,12 +34,17 @@ class NewTrajectoryForm( ModelForm ):
...
@@ -34,12 +34,17 @@ class NewTrajectoryForm( ModelForm ):
class
Meta
:
class
Meta
:
model
=
Program
model
=
Program
fields
=
(
'name'
,
'degreeType'
,
'programType'
,
'isHonors'
,
fields
=
(
'name'
,
)
)
exclude
=
(
'courseReqs'
,
'created'
,
'last_modified'
,
'catalogYear'
,
exclude
=
(
'courseReqs'
,
'created'
,
'last_modified'
,
'catalogYear'
,
'isCompleted'
,
'isCompleted'
,
'programType'
,
'degreeType'
,
)
)
labels
=
{
'name'
:
'Select your Majors'
#'name' : 'Select your Minor'
}
widgets
=
{
widgets
=
{
# I know you can't actually have it assigned twice...
# name of major(s)
# name of major(s)
'name'
:
TextInput
(
attrs
=
{
'name'
:
TextInput
(
attrs
=
{
'class'
:
'form-control'
,
'class'
:
'form-control'
,
...
@@ -54,4 +59,34 @@ class NewTrajectoryForm( ModelForm ):
...
@@ -54,4 +59,34 @@ class NewTrajectoryForm( ModelForm ):
# class CreateTrajectoryForm ( ModelForm ):
# class CreateTrajectoryForm ( ModelForm ):
# class StudentInfoForm( ModelForm ):
class
StudentInfoForm
(
ModelForm
):
# def __init__(self, *args, **kwargs):
class
Meta
:
model
=
Student
fields
=
(
'completedCourses'
,
'isHonors'
,
'semester'
,
)
exclude
=
(
'user'
,
'trajectories'
,
)
labels
=
{
'completedCourses'
:
'Completed Courses'
,
'isHonors'
:
'Are you in the Honors College?'
,
'semester'
:
'Semester'
,
}
widgets
=
{
# this should be done above, but I don't know how that works with the models ^^^
'completedCourses'
:
TextInput
(
attrs
=
{
'class'
:
'form-control'
,
'placeholder'
=
'Type in courses you
\'
ve taken'
,
}),
# is the student honors?
'isHonors'
:
CheckboxInput
(
attrs
=
{
'class'
=
'form-control'
,
}),
# semester
'semester'
:
TextInput
(
attrs
=
{
'class'
:
'form-control'
,
'placeholder'
:
'What year are you?'
}),
}
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