Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
O
oser-backend
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
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
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Hamza Touizrat
oser-backend
Merge requests
!55
Hamza
Code
Review changes
Check out branch
Download
Patches
Plain diff
Expand sidebar
Merged
Hamza
hamza
into
dev
Overview
1
Commits
20
Pipelines
0
Changes
7
Merged
Hamza Touizrat
requested to merge
hamza
into
dev
3 years ago
Overview
1
Commits
20
Pipelines
0
Changes
7
Created by: osergeek
0
0
Merge request reports
Compare
dev
dev (base)
and
latest version
latest version
a9f924dd
20 commits,
2 years ago
7 files
+
75
−
13
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
Files
7
visits/migrations/0003_fix_db_trouble.py
0 → 100644
+
18
−
0
View file @ a9f924dd
Edit in single-file editor
Open in Web IDE
from
django.db
import
migrations
from
..models
import
Participation
def
postgres_migration_prep
(
apps
,
schema_editor
):
participations
=
Participation
.
objects
.
filter
(
accepted
=
True
)
for
participation
in
participations
:
participation
.
accepted
=
1
class
Migration
(
migrations
.
Migration
):
dependencies
=
[(
"
visits
"
,
"
0002_visit_context_sheet
"
)]
operations
=
[
migrations
.
RunPython
(
postgres_migration_prep
,
migrations
.
RunPython
.
noop
)
]
Loading