SciPost Code Repository
Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
SciPost
Manage
Activity
Members
Labels
Plan
Issues
118
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
0
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
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
SciPost
SciPost
Commits
51b2f664
Commit
51b2f664
authored
7 years ago
by
Jorran de Wit
Browse files
Options
Downloads
Patches
Plain Diff
Migrations comply with Django 1.11
parent
18df2f2b
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
comments/migrations/0017_auto_20170729_0717.py
+2
-2
2 additions, 2 deletions
comments/migrations/0017_auto_20170729_0717.py
submissions/migrations/0061_auto_20170727_1012.py
+1
-3
1 addition, 3 deletions
submissions/migrations/0061_auto_20170727_1012.py
with
3 additions
and
5 deletions
comments/migrations/0017_auto_20170729_0717.py
+
2
−
2
View file @
51b2f664
...
...
@@ -11,10 +11,10 @@ from guardian.shortcuts import assign_perm
def
update_all_contenttypes
(
**
kwargs
):
from
django.apps
import
apps
from
django.contrib.contenttypes.management
import
upd
ate_contenttypes
from
django.contrib.contenttypes.management
import
cre
ate_contenttypes
for
app_config
in
apps
.
get_app_configs
():
upd
ate_contenttypes
(
app_config
,
**
kwargs
)
cre
ate_contenttypes
(
app_config
,
**
kwargs
)
def
create_all_permissions
(
**
kwargs
):
...
...
This diff is collapsed.
Click to expand it.
submissions/migrations/0061_auto_20170727_1012.py
+
1
−
3
View file @
51b2f664
...
...
@@ -6,8 +6,6 @@ from django.db import migrations
from
guardian.shortcuts
import
assign_perm
from
..models
import
Report
def
do_nothing
(
apps
,
schema_editor
):
return
...
...
@@ -18,7 +16,7 @@ def update_eic_permissions(apps, schema_editor):
Grant EIC of submission related to unvetted Reports
permission to vet his submission
'
s Report.
"""
#
Report = apps.get_model('submissions', 'Report')
-- This doesn't work due to shitty imports
Report
=
apps
.
get_model
(
'
submissions
'
,
'
Report
'
)
count
=
0
for
rep
in
Report
.
objects
.
filter
(
status
=
'
unvetted
'
):
eic_user
=
rep
.
submission
.
editor_in_charge
...
...
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