-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
2,212 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
113 changes: 113 additions & 0 deletions
113
adminalerts/migrations/0001_squashed_0006_adminalert_require_auth.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,113 @@ | ||
# Generated by Django 4.2.14 on 2024-07-16 09:17 | ||
|
||
from django.conf import settings | ||
from django.db import migrations, models | ||
import django.db.models.deletion | ||
import markupfield.fields | ||
import uuid | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
replaces = [ | ||
('adminalerts', '0001_initial'), | ||
('adminalerts', '0002_adminalert_user'), | ||
('adminalerts', '0003_auto_20180802_1558'), | ||
('adminalerts', '0004_rename_uuid'), | ||
('adminalerts', '0005_update_uuid'), | ||
('adminalerts', '0006_adminalert_require_auth'), | ||
] | ||
|
||
initial = True | ||
|
||
dependencies = [ | ||
migrations.swappable_dependency(settings.AUTH_USER_MODEL), | ||
] | ||
|
||
operations = [ | ||
migrations.CreateModel( | ||
name='AdminAlert', | ||
fields=[ | ||
( | ||
'id', | ||
models.AutoField( | ||
auto_created=True, | ||
primary_key=True, | ||
serialize=False, | ||
verbose_name='ID', | ||
), | ||
), | ||
( | ||
'message', | ||
models.CharField( | ||
help_text='Alert message to be shown for users', max_length=255 | ||
), | ||
), | ||
( | ||
'description', | ||
markupfield.fields.MarkupField( | ||
blank=True, | ||
help_text='Full description of alert (optional, will be shown on a separate page)', | ||
null=True, | ||
rendered_field=True, | ||
), | ||
), | ||
( | ||
'date_created', | ||
models.DateTimeField( | ||
auto_now_add=True, help_text='Alert creation timestamp' | ||
), | ||
), | ||
( | ||
'date_expire', | ||
models.DateTimeField(help_text='Alert expiration timestamp'), | ||
), | ||
( | ||
'active', | ||
models.BooleanField( | ||
default=True, | ||
help_text='Alert status (for disabling the alert before expiration)', | ||
), | ||
), | ||
( | ||
'sodar_uuid', | ||
models.UUIDField( | ||
default=uuid.uuid4, | ||
help_text='Adminalerts SODAR UUID', | ||
unique=True, | ||
), | ||
), | ||
( | ||
'user', | ||
models.ForeignKey( | ||
help_text='Superuser who has set the alert', | ||
on_delete=django.db.models.deletion.CASCADE, | ||
related_name='alerts', | ||
to=settings.AUTH_USER_MODEL, | ||
), | ||
), | ||
('_description_rendered', models.TextField(editable=False, null=True)), | ||
( | ||
'description_markup_type', | ||
models.CharField( | ||
choices=[ | ||
('', '--'), | ||
('html', 'HTML'), | ||
('plain', 'Plain'), | ||
('markdown', 'Markdown'), | ||
('restructuredtext', 'Restructured Text'), | ||
], | ||
default='markdown', | ||
editable=False, | ||
max_length=30, | ||
), | ||
), | ||
( | ||
'require_auth', | ||
models.BooleanField( | ||
default=True, help_text='Require authorization to view alert' | ||
), | ||
), | ||
], | ||
), | ||
] |
148 changes: 148 additions & 0 deletions
148
bgjobs/migrations/0001_squashed_0006_auto_20200526_1657.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,148 @@ | ||
# Generated by Django 4.2.14 on 2024-07-16 09:22 | ||
|
||
from django.conf import settings | ||
from django.db import migrations, models | ||
import django.utils.timezone | ||
import uuid | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
replaces = [ | ||
('bgjobs', '0001_initial'), | ||
('bgjobs', '0002_backgroundjoblogentry'), | ||
('bgjobs', '0003_backgroundjob_date_created'), | ||
('bgjobs', '0004_backgroundjob_user'), | ||
('bgjobs', '0005_auto_20190128_1210'), | ||
('bgjobs', '0006_auto_20200526_1657'), | ||
] | ||
|
||
initial = True | ||
|
||
dependencies = [ | ||
('projectroles', '0005_update_uuid'), | ||
migrations.swappable_dependency(settings.AUTH_USER_MODEL), | ||
] | ||
|
||
operations = [ | ||
migrations.CreateModel( | ||
name='BackgroundJob', | ||
fields=[ | ||
( | ||
'id', | ||
models.AutoField( | ||
auto_created=True, | ||
primary_key=True, | ||
serialize=False, | ||
verbose_name='ID', | ||
), | ||
), | ||
( | ||
'date_modified', | ||
models.DateTimeField( | ||
auto_now=True, help_text='DateTime of last modification' | ||
), | ||
), | ||
( | ||
'sodar_uuid', | ||
models.UUIDField( | ||
default=uuid.uuid4, help_text='BG Job SODAR UUID', unique=True | ||
), | ||
), | ||
( | ||
'job_type', | ||
models.CharField(help_text='Type of the job', max_length=512), | ||
), | ||
('name', models.CharField(max_length=512)), | ||
('description', models.TextField()), | ||
( | ||
'status', | ||
models.CharField( | ||
choices=[ | ||
('initial', 'initial'), | ||
('running', 'running'), | ||
('done', 'done'), | ||
('failed', 'failed'), | ||
], | ||
default='initial', | ||
max_length=50, | ||
), | ||
), | ||
( | ||
'project', | ||
models.ForeignKey( | ||
help_text='Project in which this objects belongs', | ||
null=True, | ||
on_delete=django.db.models.deletion.CASCADE, | ||
to='projectroles.project', | ||
), | ||
), | ||
( | ||
'date_created', | ||
models.DateTimeField( | ||
auto_now_add=True, | ||
default=django.utils.timezone.now, | ||
help_text='DateTime of creation', | ||
), | ||
), | ||
( | ||
'user', | ||
models.ForeignKey( | ||
default=1, | ||
on_delete=django.db.models.deletion.CASCADE, | ||
related_name='background_jobs', | ||
to=settings.AUTH_USER_MODEL, | ||
), | ||
), | ||
], | ||
options={ | ||
'ordering': ['-date_created'], | ||
}, | ||
), | ||
migrations.CreateModel( | ||
name='BackgroundJobLogEntry', | ||
fields=[ | ||
( | ||
'id', | ||
models.AutoField( | ||
auto_created=True, | ||
primary_key=True, | ||
serialize=False, | ||
verbose_name='ID', | ||
), | ||
), | ||
( | ||
'date_created', | ||
models.DateTimeField( | ||
auto_now_add=True, help_text='DateTime of creation' | ||
), | ||
), | ||
( | ||
'level', | ||
models.CharField( | ||
choices=[ | ||
('debug', 'debug'), | ||
('info', 'info'), | ||
('warning', 'warning'), | ||
('error', 'error'), | ||
], | ||
help_text='Level of log entry', | ||
max_length=50, | ||
), | ||
), | ||
('message', models.TextField(help_text='Log level\'s message')), | ||
( | ||
'job', | ||
models.ForeignKey( | ||
help_text='Owning background job', | ||
on_delete=django.db.models.deletion.CASCADE, | ||
related_name='log_entries', | ||
to='bgjobs.backgroundjob', | ||
), | ||
), | ||
], | ||
options={ | ||
'ordering': ['date_created'], | ||
}, | ||
), | ||
] |
Oops, something went wrong.