Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
AKPlanning
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
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
Aaron -
AKPlanning
Commits
25905bed
Commit
25905bed
authored
5 years ago
by
Nadja Geisler
Browse files
Options
Downloads
Patches
Plain Diff
allow AK slots without rooms
parent
11d84b16
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
AKModel/migrations/0016_slot_room_blank.py
+20
-0
20 additions, 0 deletions
AKModel/migrations/0016_slot_room_blank.py
AKModel/models.py
+3
-2
3 additions, 2 deletions
AKModel/models.py
with
23 additions
and
2 deletions
AKModel/migrations/0016_slot_room_blank.py
0 → 100644
+
20
−
0
View file @
25905bed
# Generated by Django 2.2.6 on 2019-10-18 23:15
import
django.db.models.deletion
from
django.db
import
migrations
,
models
class
Migration
(
migrations
.
Migration
):
dependencies
=
[
(
'
AKModel
'
,
'
0015_ak_present_field
'
),
]
operations
=
[
migrations
.
AlterField
(
model_name
=
'
akslot
'
,
name
=
'
room
'
,
field
=
models
.
ForeignKey
(
blank
=
True
,
help_text
=
'
Room the AK will take place in
'
,
null
=
True
,
on_delete
=
django
.
db
.
models
.
deletion
.
SET_NULL
,
to
=
'
AKModel.Room
'
,
verbose_name
=
'
Room
'
),
),
]
This diff is collapsed.
Click to expand it.
AKModel/models.py
+
3
−
2
View file @
25905bed
...
@@ -135,7 +135,8 @@ class AK(models.Model):
...
@@ -135,7 +135,8 @@ class AK(models.Model):
reso
=
models
.
BooleanField
(
verbose_name
=
_
(
'
Resolution Intention
'
),
default
=
False
,
reso
=
models
.
BooleanField
(
verbose_name
=
_
(
'
Resolution Intention
'
),
default
=
False
,
help_text
=
_
(
'
Intends to submit a resolution
'
))
help_text
=
_
(
'
Intends to submit a resolution
'
))
present
=
models
.
BooleanField
(
verbose_name
=
_
(
"
Present this AK
"
),
null
=
True
,
help_text
=
_
(
"
Present results of this AK
"
))
present
=
models
.
BooleanField
(
verbose_name
=
_
(
"
Present this AK
"
),
null
=
True
,
help_text
=
_
(
"
Present results of this AK
"
))
requirements
=
models
.
ManyToManyField
(
to
=
AKRequirement
,
blank
=
True
,
verbose_name
=
_
(
'
Requirements
'
),
requirements
=
models
.
ManyToManyField
(
to
=
AKRequirement
,
blank
=
True
,
verbose_name
=
_
(
'
Requirements
'
),
help_text
=
_
(
"
AK
'
s Requirements
"
))
help_text
=
_
(
"
AK
'
s Requirements
"
))
...
@@ -199,7 +200,7 @@ class AKSlot(models.Model):
...
@@ -199,7 +200,7 @@ class AKSlot(models.Model):
"""
An AK Mapping matches an AK to a room during a certain time.
"""
An AK Mapping matches an AK to a room during a certain time.
"""
"""
ak
=
models
.
ForeignKey
(
to
=
AK
,
on_delete
=
models
.
CASCADE
,
verbose_name
=
_
(
'
AK
'
),
help_text
=
_
(
'
AK being mapped
'
))
ak
=
models
.
ForeignKey
(
to
=
AK
,
on_delete
=
models
.
CASCADE
,
verbose_name
=
_
(
'
AK
'
),
help_text
=
_
(
'
AK being mapped
'
))
room
=
models
.
ForeignKey
(
to
=
Room
,
null
=
True
,
on_delete
=
models
.
SET_NULL
,
verbose_name
=
_
(
'
Room
'
),
room
=
models
.
ForeignKey
(
to
=
Room
,
blank
=
True
,
null
=
True
,
on_delete
=
models
.
SET_NULL
,
verbose_name
=
_
(
'
Room
'
),
help_text
=
_
(
'
Room the AK will take place in
'
))
help_text
=
_
(
'
Room the AK will take place in
'
))
start
=
models
.
DateTimeField
(
verbose_name
=
_
(
'
Slot Begin
'
),
help_text
=
_
(
'
Time and date the slot begins
'
))
start
=
models
.
DateTimeField
(
verbose_name
=
_
(
'
Slot Begin
'
),
help_text
=
_
(
'
Time and date the slot begins
'
))
duration
=
models
.
DecimalField
(
max_digits
=
4
,
decimal_places
=
2
,
default
=
2
,
verbose_name
=
_
(
'
Duration
'
),
duration
=
models
.
DecimalField
(
max_digits
=
4
,
decimal_places
=
2
,
default
=
2
,
verbose_name
=
_
(
'
Duration
'
),
...
...
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