igs-slm 0.1.4b0__py3-none-any.whl → 0.1.5b0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- igs_slm-0.1.5b0.dist-info/METADATA +115 -0
- {igs_slm-0.1.4b0.dist-info → igs_slm-0.1.5b0.dist-info}/RECORD +192 -172
- {igs_slm-0.1.4b0.dist-info → igs_slm-0.1.5b0.dist-info}/WHEEL +1 -1
- igs_slm-0.1.5b0.dist-info/entry_points.txt +3 -0
- {igs_slm-0.1.4b0.dist-info → igs_slm-0.1.5b0.dist-info/licenses}/LICENSE +1 -1
- slm/__init__.py +17 -14
- slm/admin.py +32 -5
- slm/api/edit/views.py +22 -9
- slm/api/public/views.py +9 -7
- slm/api/views.py +45 -6
- slm/apps.py +28 -6
- slm/authentication.py +3 -2
- slm/bin/startproject.py +102 -31
- slm/bin/templates/{{ project_dir }}/pyproject.toml +30 -21
- slm/bin/templates/{{ project_dir }}/{sites → src/sites}/{{ site }}/base.py +12 -1
- slm/bin/templates/{{ project_dir }}/{sites → src/sites}/{{ site }}/develop/__init__.py +5 -27
- slm/bin/templates/{{ project_dir }}/{sites → src/sites}/{{ site }}/production/__init__.py +6 -27
- slm/bin/templates/{{ project_dir }}/src/sites/{{ site }}/validation.py +29 -0
- slm/context.py +5 -0
- slm/defines/AlertLevel.py +10 -2
- slm/defines/AntennaCalibration.py +6 -4
- slm/defines/AntennaFeatures.py +12 -9
- slm/defines/AntennaReferencePoint.py +12 -10
- slm/defines/Aspiration.py +4 -2
- slm/defines/CardinalDirection.py +6 -4
- slm/defines/CollocationStatus.py +3 -1
- slm/defines/EquipmentState.py +6 -12
- slm/defines/FlagSeverity.py +4 -2
- slm/defines/FractureSpacing.py +7 -5
- slm/defines/FrequencyStandardType.py +6 -4
- slm/defines/GeodesyMLVersion.py +2 -0
- slm/defines/Instrumentation.py +9 -7
- slm/defines/LogEntryType.py +17 -15
- slm/defines/SLMFileType.py +4 -2
- slm/defines/SiteFileUploadStatus.py +7 -24
- slm/defines/SiteLogFormat.py +8 -32
- slm/defines/SiteLogStatus.py +9 -28
- slm/defines/TectonicPlates.py +18 -16
- slm/manage.py +24 -0
- slm/management/commands/check_upgrade.py +142 -0
- slm/management/commands/generate_sinex.py +110 -92
- slm/management/commands/head_from_index.py +11 -8
- slm/management/commands/import_archive.py +27 -18
- slm/management/commands/import_equipment.py +1 -1
- slm/management/commands/sitelog.py +1 -3
- slm/management/commands/synchronize.py +1 -1
- slm/management/commands/validate_db.py +6 -4
- slm/map/defines.py +18 -14
- slm/map/templates/slm/map.html +4 -6
- slm/migrations/0001_remove_archiveindex_no_overlapping_ranges_per_site_and_more.py +26 -0
- slm/migrations/0002_alter_archivedsitelog_file_and_more.py +44 -0
- slm/migrations/0003_alter_archivedsitelog_name_and_more.py +35 -0
- slm/migrations/0004_alter_site_name.py +24 -0
- slm/migrations/0005_slmversion.py +30 -0
- slm/migrations/0017_alter_logentry_unique_together_and_more.py +3 -1
- slm/migrations/0018_afix_deleted.py +3 -1
- slm/migrations/0018_alter_siteantenna_options_and_more.py +87 -56
- slm/migrations/0019_remove_siteantenna_marker_enu_siteantenna_marker_une_and_more.py +1 -1
- slm/migrations/0023_archivedsitelog_gml_version_and_more.py +1 -1
- slm/migrations/0031_alter_antenna_features.py +44 -0
- slm/migrations/0032_archiveindex_valid_range_and_more.py +84 -0
- slm/migrations/add_index_order_index.py +54 -0
- slm/migrations/normalize_index.py +147 -0
- slm/migrations/simplify_index.py +48 -0
- slm/migrations/verify_index.py +67 -0
- slm/models/__init__.py +2 -0
- slm/models/alerts.py +7 -10
- slm/models/data.py +1 -2
- slm/models/equipment.py +1 -1
- slm/models/fields.py +41 -0
- slm/models/index.py +183 -53
- slm/models/sitelog.py +35 -38
- slm/models/system.py +72 -31
- slm/models/user.py +1 -1
- slm/parsing/__init__.py +33 -16
- slm/parsing/legacy/binding.py +65 -34
- slm/parsing/legacy/parser.py +2 -2
- slm/parsing/xsd/binding.py +1 -1
- slm/parsing/xsd/parser.py +1 -2
- slm/receivers/__init__.py +2 -2
- slm/receivers/index.py +2 -1
- slm/receivers/migration.py +21 -0
- slm/settings/__init__.py +192 -4
- slm/settings/assets.py +26 -0
- slm/settings/auth.py +18 -14
- slm/settings/ckeditor.py +12 -6
- slm/settings/debug.py +2 -2
- slm/settings/emails.py +50 -0
- slm/settings/internationalization.py +8 -6
- slm/settings/logging.py +100 -88
- slm/settings/platform/darwin.py +16 -6
- slm/settings/rest.py +20 -15
- slm/settings/root.py +192 -98
- slm/settings/routines.py +5 -1
- slm/settings/secrets.py +20 -31
- slm/settings/security.py +7 -5
- slm/settings/slm.py +35 -16
- slm/settings/static_templates.py +12 -9
- slm/settings/templates.py +31 -25
- slm/settings/uploads.py +33 -5
- slm/settings/urls.py +1 -1
- slm/settings/validation.py +165 -165
- slm/signals.py +3 -2
- slm/static/slm/css/style.css +37 -36
- slm/static/slm/js/autocomplete.js +6 -4
- slm/static/slm/js/file_modal.js +62 -0
- slm/static/slm/js/form.js +3 -3
- slm/static/slm/js/formWidget.js +3 -3
- slm/static/slm/js/persistable.js +5 -1
- slm/templates/admin/base.html +1 -0
- slm/templates/rest_framework/base.html +23 -11
- slm/templates/slm/base.html +27 -22
- slm/templates/slm/forms/widgets/auto_complete.html +12 -11
- slm/templates/slm/forms/widgets/auto_complete_multiple.html +8 -7
- slm/templates/slm/station/download.html +6 -6
- slm/templates/slm/station/edit.html +9 -17
- slm/templates/slm/station/review.html +5 -3
- slm/templates/slm/station/upload.html +4 -1
- slm/templates/slm/station/uploads/legacy.html +1 -1
- slm/templates/slm/widgets/alert_scroll.html +4 -8
- slm/templates/slm/widgets/filelist.html +0 -5
- slm/templates/slm/widgets/log_scroll.html +2 -13
- slm/templates/slm/widgets/stationlist.html +2 -8
- slm/templatetags/slm.py +70 -9
- slm/utils.py +13 -4
- slm/validators.py +14 -14
- slm/views.py +6 -6
- slm/wsgi.py +16 -0
- igs_slm-0.1.4b0.dist-info/METADATA +0 -154
- igs_slm-0.1.4b0.dist-info/entry_points.txt +0 -3
- slm/bin/templates/{{ project_dir }}/sites/{{ site }}/validation.py +0 -11
- /slm/bin/templates/{{ project_dir }}/{sites → src/sites}/__init__.py +0 -0
- /slm/bin/templates/{{ project_dir }}/{sites → src/sites}/{{ site }}/__init__.py +0 -0
- /slm/bin/templates/{{ project_dir }}/{sites → src/sites}/{{ site }}/develop/local.py +0 -0
- /slm/bin/templates/{{ project_dir }}/{sites → src/sites}/{{ site }}/develop/wsgi.py +0 -0
- /slm/bin/templates/{{ project_dir }}/{sites → src/sites}/{{ site }}/manage.py +0 -0
- /slm/bin/templates/{{ project_dir }}/{sites → src/sites}/{{ site }}/production/wsgi.py +0 -0
- /slm/bin/templates/{{ project_dir }}/{sites → src/sites}/{{ site }}/urls.py +0 -0
- /slm/bin/templates/{{ project_dir }}/{{{ extension_app }} → src/{{ extension_app }}}/__init__.py +0 -0
- /slm/bin/templates/{{ project_dir }}/{{{ extension_app }} → src/{{ extension_app }}}/admin.py +0 -0
- /slm/bin/templates/{{ project_dir }}/{{{ extension_app }} → src/{{ extension_app }}}/apps.py +0 -0
- /slm/bin/templates/{{ project_dir }}/{{{ extension_app }} → src/{{ extension_app }}}/management/__init__.py +0 -0
- /slm/bin/templates/{{ project_dir }}/{{{ extension_app }} → src/{{ extension_app }}}/management/commands/__init__.py +0 -0
- /slm/bin/templates/{{ project_dir }}/{{{ extension_app }} → src/{{ extension_app }}}/management/commands/import_archive.py +0 -0
- /slm/bin/templates/{{ project_dir }}/{{{ extension_app }} → src/{{ extension_app }}}/migrations/__init__.py +0 -0
- /slm/bin/templates/{{ project_dir }}/{{{ extension_app }} → src/{{ extension_app }}}/models.py +0 -0
- /slm/bin/templates/{{ project_dir }}/{{{ extension_app }} → src/{{ extension_app }}}/templates/slm/base.html +0 -0
- /slm/bin/templates/{{ project_dir }}/{{{ extension_app }} → src/{{ extension_app }}}/urls.py +0 -0
- /slm/bin/templates/{{ project_dir }}/{{{ extension_app }} → src/{{ extension_app }}}/views.py +0 -0
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"""
|
|
2
2
|
The SLM supports pluggable validation logic for all site log sections and fields. Since
|
|
3
|
-
this logic is
|
|
3
|
+
this logic is configuration specific, it may change, diverging from the validation flags
|
|
4
4
|
recorded against the previous validation configuration in the database.
|
|
5
5
|
|
|
6
|
-
Run this command to run all validation routines against all current
|
|
6
|
+
Run this command to run all validation routines against all current site log fields
|
|
7
7
|
in the database.
|
|
8
8
|
"""
|
|
9
9
|
|
|
@@ -159,7 +159,7 @@ class Command(TyperCommand):
|
|
|
159
159
|
|
|
160
160
|
new_flags = Site.objects.aggregate(Sum("num_flags"))["num_flags__sum"]
|
|
161
161
|
|
|
162
|
-
delta = new_flags - old_flag_count
|
|
162
|
+
delta = (new_flags or 0) - (old_flag_count or 0)
|
|
163
163
|
|
|
164
164
|
if delta >= 0:
|
|
165
165
|
change = "added"
|
|
@@ -180,7 +180,9 @@ class Command(TyperCommand):
|
|
|
180
180
|
"There are a total of {new_flags} validation flags across "
|
|
181
181
|
"{site_count} sites. {critical} are critical."
|
|
182
182
|
).format(
|
|
183
|
-
new_flags=new_flags
|
|
183
|
+
new_flags=(new_flags or 0),
|
|
184
|
+
site_count=sites.count(),
|
|
185
|
+
critical=critical,
|
|
184
186
|
)
|
|
185
187
|
)
|
|
186
188
|
)
|
slm/map/defines.py
CHANGED
|
@@ -10,15 +10,17 @@ class MapBoxStyle(IntegerChoices, s("slug", case_fold=True), p("version")):
|
|
|
10
10
|
|
|
11
11
|
_symmetric_builtins_ = ["name", s("label", case_fold=True), "uri"]
|
|
12
12
|
|
|
13
|
+
# fmt: off
|
|
13
14
|
# name value label slug version
|
|
14
|
-
STREETS
|
|
15
|
-
OUTDOORS
|
|
16
|
-
LIGHT
|
|
17
|
-
DARK
|
|
18
|
-
SATELLITE
|
|
15
|
+
STREETS = 1, _("Streets"), "streets", 12
|
|
16
|
+
OUTDOORS = 2, _("Outdoors"), "outdoors", 12
|
|
17
|
+
LIGHT = 3, _("Light"), "light", 11
|
|
18
|
+
DARK = 4, _("Dark"), "dark", 11
|
|
19
|
+
SATELLITE = 5, _("Satellite"), "satellite", 9
|
|
19
20
|
SATELLITE_STREETS = 6, _("Satellite Streets"), "satellite-streets", 12
|
|
20
|
-
NAVIGATION_DAY
|
|
21
|
-
NAVIGATION_NIGHT
|
|
21
|
+
NAVIGATION_DAY = 7, _("Navigation Day"), "navigation-day", 1
|
|
22
|
+
NAVIGATION_NIGHT = 8, _("Navigation Night"), "navigation-night", 1
|
|
23
|
+
# fmt: on
|
|
22
24
|
|
|
23
25
|
@property
|
|
24
26
|
def uri(self):
|
|
@@ -39,15 +41,17 @@ class MapBoxProjection(IntegerChoices, s("slug", case_fold=True)):
|
|
|
39
41
|
|
|
40
42
|
_symmetric_builtins_ = ["name", "label"]
|
|
41
43
|
|
|
44
|
+
# fmt: off
|
|
42
45
|
# name value label slug
|
|
43
|
-
ALBERS
|
|
44
|
-
EQUAL_EARTH
|
|
45
|
-
EQUI_RECTANGULAR
|
|
46
|
+
ALBERS = 0, _("Albers"), "albers"
|
|
47
|
+
EQUAL_EARTH = 1, _("Equal Earth"), "equalEarth"
|
|
48
|
+
EQUI_RECTANGULAR = 2, _("Equi-Rectangular"), "equirectangular"
|
|
46
49
|
LAMBERT_CONFORMAL_CONIC = 3, _("Lambert Conformal Conic"), "lambertConformalConic"
|
|
47
|
-
MERCATOR
|
|
48
|
-
NATURAL_EARTH
|
|
49
|
-
WINKEL_TRIPEL
|
|
50
|
-
GLOBE
|
|
50
|
+
MERCATOR = 4, _("Mercator"), "mercator"
|
|
51
|
+
NATURAL_EARTH = 5, _("Natural Earth"), "naturalEarth"
|
|
52
|
+
WINKEL_TRIPEL = 6, _("Winkel Tripel"), "winkelTripel"
|
|
53
|
+
GLOBE = 7, _("Globe"), "globe"
|
|
54
|
+
# fmt: on
|
|
51
55
|
|
|
52
56
|
def __str__(self):
|
|
53
57
|
return self.slug
|
slm/map/templates/slm/map.html
CHANGED
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
|
|
4
4
|
{% block stylesheets %}
|
|
5
5
|
{{ block.super }}
|
|
6
|
+
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/mapbox-gl/3.9.3/mapbox-gl.min.css" integrity="sha512-9RAPfS3YMZi1yEe+yT65HNwrqhOw++yaDYFxElkl141OBieVWznObzeAYNijFmvVe97u9Oh5oNXyTZTZD04iGQ==" crossorigin="anonymous" referrerpolicy="no-referrer" />
|
|
7
|
+
<link href='https://cdn.datatables.net/1.13.2/css/jquery.dataTables.min.css' rel='stylesheet' />
|
|
6
8
|
{% compress css %}
|
|
7
|
-
<link href='https://api.mapbox.com/mapbox-gl-js/v2.13.0/mapbox-gl.css' rel='stylesheet' />
|
|
8
|
-
<link href='https://cdn.datatables.net/1.13.2/css/jquery.dataTables.min.css' rel='stylesheet' />
|
|
9
9
|
<link rel='stylesheet' type='text/css' media='screen' href='{% static "slm/css/map.css" %}'>
|
|
10
10
|
{% endcompress %}
|
|
11
11
|
{% endblock %}
|
|
@@ -14,9 +14,9 @@
|
|
|
14
14
|
{{ block.super }}
|
|
15
15
|
{% compress js %}
|
|
16
16
|
<script src="{% static 'slm/js/map.js' %}"></script>
|
|
17
|
-
<script src='https://api.mapbox.com/mapbox-gl-js/v2.13.0/mapbox-gl.js'></script>
|
|
18
|
-
<script src='https://cdn.datatables.net/1.13.2/js/jquery.dataTables.min.js'></script>
|
|
19
17
|
{% endcompress %}
|
|
18
|
+
<script src="https://cdnjs.cloudflare.com/ajax/libs/mapbox-gl/3.9.3/mapbox-gl.js" integrity="sha512-tJBCVRTEYq4MVF7pQQNJ0vWc+ij9oTnNq10/txpa2ISQ/cIUzwb9VEwHKSQVe2l4Ni5EyrwjB2/R+4WIRJSVXg==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
|
|
19
|
+
<script src='https://cdn.datatables.net/1.13.2/js/jquery.dataTables.min.js'></script>
|
|
20
20
|
{% endblock %}
|
|
21
21
|
|
|
22
22
|
{% block page_content %}
|
|
@@ -133,7 +133,6 @@
|
|
|
133
133
|
</table>
|
|
134
134
|
</div>
|
|
135
135
|
</div>
|
|
136
|
-
{% compress js %}
|
|
137
136
|
<script>
|
|
138
137
|
const agencySelect = $('#slm-agency-select');
|
|
139
138
|
const networkSelect = $('#slm-network-select');
|
|
@@ -366,7 +365,6 @@
|
|
|
366
365
|
});
|
|
367
366
|
//slm.addColumnFiltering( stationTable );
|
|
368
367
|
</script>
|
|
369
|
-
{% endcompress %}
|
|
370
368
|
{% else %}
|
|
371
369
|
{% trans "To enable maps, create a MapBox account and configure the api key in the admin:" %} <a href="https://mapbox.com">mapbox.com</a>
|
|
372
370
|
{% endif %}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
# Generated by Django 4.2.20 on 2025-05-09 21:04
|
|
2
|
+
|
|
3
|
+
import django.contrib.postgres.constraints
|
|
4
|
+
import django.db.models.constraints
|
|
5
|
+
from django.db import migrations
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
class Migration(migrations.Migration):
|
|
9
|
+
dependencies = [
|
|
10
|
+
("slm", "verify_index"),
|
|
11
|
+
]
|
|
12
|
+
|
|
13
|
+
operations = [
|
|
14
|
+
migrations.RemoveConstraint(
|
|
15
|
+
model_name="archiveindex",
|
|
16
|
+
name="no_overlapping_ranges_per_site",
|
|
17
|
+
),
|
|
18
|
+
migrations.AddConstraint(
|
|
19
|
+
model_name="archiveindex",
|
|
20
|
+
constraint=django.contrib.postgres.constraints.ExclusionConstraint(
|
|
21
|
+
deferrable=django.db.models.constraints.Deferrable["DEFERRED"],
|
|
22
|
+
expressions=[("site", "="), ("valid_range", "&&")],
|
|
23
|
+
name="no_overlapping_ranges_per_site",
|
|
24
|
+
),
|
|
25
|
+
),
|
|
26
|
+
]
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
# Generated by Django 4.2.20 on 2025-06-27 20:37
|
|
2
|
+
|
|
3
|
+
from django.db import migrations, models
|
|
4
|
+
|
|
5
|
+
import slm.models.system
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
class Migration(migrations.Migration):
|
|
9
|
+
dependencies = [
|
|
10
|
+
("slm", "0001_remove_archiveindex_no_overlapping_ranges_per_site_and_more"),
|
|
11
|
+
]
|
|
12
|
+
|
|
13
|
+
operations = [
|
|
14
|
+
migrations.AlterField(
|
|
15
|
+
model_name="archivedsitelog",
|
|
16
|
+
name="file",
|
|
17
|
+
field=models.FileField(
|
|
18
|
+
help_text="A pointer to the uploaded file on disk.",
|
|
19
|
+
max_length=255,
|
|
20
|
+
unique=True,
|
|
21
|
+
upload_to=slm.models.system.site_upload_path,
|
|
22
|
+
),
|
|
23
|
+
),
|
|
24
|
+
migrations.AlterField(
|
|
25
|
+
model_name="geodesymlinvalid",
|
|
26
|
+
name="file",
|
|
27
|
+
field=models.FileField(
|
|
28
|
+
help_text="A pointer to the uploaded file on disk.",
|
|
29
|
+
max_length=255,
|
|
30
|
+
unique=True,
|
|
31
|
+
upload_to=slm.models.system.site_upload_path,
|
|
32
|
+
),
|
|
33
|
+
),
|
|
34
|
+
migrations.AlterField(
|
|
35
|
+
model_name="sitefileupload",
|
|
36
|
+
name="file",
|
|
37
|
+
field=models.FileField(
|
|
38
|
+
help_text="A pointer to the uploaded file on disk.",
|
|
39
|
+
max_length=255,
|
|
40
|
+
unique=True,
|
|
41
|
+
upload_to=slm.models.system.site_upload_path,
|
|
42
|
+
),
|
|
43
|
+
),
|
|
44
|
+
]
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# Generated by Django 4.2.20 on 2025-06-30 18:12
|
|
2
|
+
|
|
3
|
+
from django.db import migrations, models
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
class Migration(migrations.Migration):
|
|
7
|
+
dependencies = [
|
|
8
|
+
("slm", "0002_alter_archivedsitelog_file_and_more"),
|
|
9
|
+
]
|
|
10
|
+
|
|
11
|
+
operations = [
|
|
12
|
+
migrations.AlterField(
|
|
13
|
+
model_name="archivedsitelog",
|
|
14
|
+
name="name",
|
|
15
|
+
field=models.CharField(db_index=True, max_length=50),
|
|
16
|
+
),
|
|
17
|
+
migrations.AlterField(
|
|
18
|
+
model_name="archivedsitelog",
|
|
19
|
+
name="timestamp",
|
|
20
|
+
field=models.DateTimeField(
|
|
21
|
+
auto_now_add=True,
|
|
22
|
+
db_index=True,
|
|
23
|
+
help_text="When the file was created or uploaded.",
|
|
24
|
+
),
|
|
25
|
+
),
|
|
26
|
+
migrations.AlterField(
|
|
27
|
+
model_name="sitefileupload",
|
|
28
|
+
name="timestamp",
|
|
29
|
+
field=models.DateTimeField(
|
|
30
|
+
auto_now_add=True,
|
|
31
|
+
db_index=True,
|
|
32
|
+
help_text="When the file was created or uploaded.",
|
|
33
|
+
),
|
|
34
|
+
),
|
|
35
|
+
]
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
# Generated by Django 4.2.20 on 2025-07-08 19:42
|
|
2
|
+
|
|
3
|
+
from django.db import migrations
|
|
4
|
+
|
|
5
|
+
import slm.models.fields
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
class Migration(migrations.Migration):
|
|
9
|
+
dependencies = [
|
|
10
|
+
("slm", "0003_alter_archivedsitelog_name_and_more"),
|
|
11
|
+
]
|
|
12
|
+
|
|
13
|
+
operations = [
|
|
14
|
+
migrations.AlterField(
|
|
15
|
+
model_name="site",
|
|
16
|
+
name="name",
|
|
17
|
+
field=slm.models.fields.StationNameField(
|
|
18
|
+
db_index=True,
|
|
19
|
+
help_text="The name of the station.",
|
|
20
|
+
max_length=50,
|
|
21
|
+
unique=True,
|
|
22
|
+
),
|
|
23
|
+
),
|
|
24
|
+
]
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
# Generated by Django 4.2.20 on 2025-07-09 22:10
|
|
2
|
+
|
|
3
|
+
from django.db import migrations, models
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
class Migration(migrations.Migration):
|
|
7
|
+
dependencies = [
|
|
8
|
+
("slm", "0004_alter_site_name"),
|
|
9
|
+
]
|
|
10
|
+
|
|
11
|
+
operations = [
|
|
12
|
+
migrations.CreateModel(
|
|
13
|
+
name="SLMVersion",
|
|
14
|
+
fields=[
|
|
15
|
+
(
|
|
16
|
+
"id",
|
|
17
|
+
models.BigAutoField(
|
|
18
|
+
auto_created=True,
|
|
19
|
+
primary_key=True,
|
|
20
|
+
serialize=False,
|
|
21
|
+
verbose_name="ID",
|
|
22
|
+
),
|
|
23
|
+
),
|
|
24
|
+
("version_str", models.CharField(blank=True, default="")),
|
|
25
|
+
],
|
|
26
|
+
options={
|
|
27
|
+
"abstract": False,
|
|
28
|
+
},
|
|
29
|
+
),
|
|
30
|
+
]
|
|
@@ -46,7 +46,9 @@ class Migration(migrations.Migration):
|
|
|
46
46
|
name="logentry",
|
|
47
47
|
index_together={("timestamp", "type", "site", "section", "subsection")},
|
|
48
48
|
),
|
|
49
|
-
migrations.RunPython(
|
|
49
|
+
migrations.RunPython(
|
|
50
|
+
clean_duplicate_logs, migrations.RunPython.noop, elidable=True
|
|
51
|
+
),
|
|
50
52
|
migrations.AlterUniqueTogether(
|
|
51
53
|
name="logentry",
|
|
52
54
|
unique_together={("timestamp", "type", "site", "section", "subsection")},
|
|
@@ -31,4 +31,6 @@ class Migration(migrations.Migration):
|
|
|
31
31
|
("slm", "0017_alter_logentry_unique_together_and_more"),
|
|
32
32
|
]
|
|
33
33
|
|
|
34
|
-
operations = [
|
|
34
|
+
operations = [
|
|
35
|
+
migrations.RunPython(migrate_deleted, migrations.RunPython.noop, elidable=True)
|
|
36
|
+
]
|
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
# Generated by Django 4.2.6 on 2023-10-25 23:57
|
|
2
2
|
|
|
3
|
+
from django import VERSION
|
|
3
4
|
from django.db import migrations, models
|
|
4
5
|
|
|
6
|
+
check_param = "check" if VERSION[0:2] < (5, 1) else "condition"
|
|
7
|
+
|
|
5
8
|
|
|
6
9
|
class Migration(migrations.Migration):
|
|
7
10
|
dependencies = [
|
|
@@ -118,127 +121,155 @@ class Migration(migrations.Migration):
|
|
|
118
121
|
migrations.AddConstraint(
|
|
119
122
|
model_name="siteantenna",
|
|
120
123
|
constraint=models.CheckConstraint(
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
124
|
+
**{
|
|
125
|
+
check_param: models.Q(
|
|
126
|
+
("published", False), ("is_deleted", True), _negated=True
|
|
127
|
+
),
|
|
128
|
+
"name": "slm_siteantenna_no_mod_deleted",
|
|
129
|
+
}
|
|
125
130
|
),
|
|
126
131
|
),
|
|
127
132
|
migrations.AddConstraint(
|
|
128
133
|
model_name="sitecollocation",
|
|
129
134
|
constraint=models.CheckConstraint(
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
135
|
+
**{
|
|
136
|
+
check_param: models.Q(
|
|
137
|
+
("published", False), ("is_deleted", True), _negated=True
|
|
138
|
+
),
|
|
139
|
+
"name": "slm_sitecollocation_no_mod_deleted",
|
|
140
|
+
}
|
|
134
141
|
),
|
|
135
142
|
),
|
|
136
143
|
migrations.AddConstraint(
|
|
137
144
|
model_name="sitefrequencystandard",
|
|
138
145
|
constraint=models.CheckConstraint(
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
146
|
+
**{
|
|
147
|
+
check_param: models.Q(
|
|
148
|
+
("published", False), ("is_deleted", True), _negated=True
|
|
149
|
+
),
|
|
150
|
+
"name": "slm_sitefrequencystandard_no_mod_deleted",
|
|
151
|
+
}
|
|
143
152
|
),
|
|
144
153
|
),
|
|
145
154
|
migrations.AddConstraint(
|
|
146
155
|
model_name="sitehumiditysensor",
|
|
147
156
|
constraint=models.CheckConstraint(
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
157
|
+
**{
|
|
158
|
+
check_param: models.Q(
|
|
159
|
+
("published", False), ("is_deleted", True), _negated=True
|
|
160
|
+
),
|
|
161
|
+
"name": "slm_sitehumiditysensor_no_mod_deleted",
|
|
162
|
+
}
|
|
152
163
|
),
|
|
153
164
|
),
|
|
154
165
|
migrations.AddConstraint(
|
|
155
166
|
model_name="sitelocalepisodiceffects",
|
|
156
167
|
constraint=models.CheckConstraint(
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
168
|
+
**{
|
|
169
|
+
check_param: models.Q(
|
|
170
|
+
("published", False), ("is_deleted", True), _negated=True
|
|
171
|
+
),
|
|
172
|
+
"name": "slm_sitelocalepisodiceffects_no_mod_deleted",
|
|
173
|
+
}
|
|
161
174
|
),
|
|
162
175
|
),
|
|
163
176
|
migrations.AddConstraint(
|
|
164
177
|
model_name="sitemultipathsources",
|
|
165
178
|
constraint=models.CheckConstraint(
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
179
|
+
**{
|
|
180
|
+
check_param: models.Q(
|
|
181
|
+
("published", False), ("is_deleted", True), _negated=True
|
|
182
|
+
),
|
|
183
|
+
"name": "slm_sitemultipathsources_no_mod_deleted",
|
|
184
|
+
}
|
|
170
185
|
),
|
|
171
186
|
),
|
|
172
187
|
migrations.AddConstraint(
|
|
173
188
|
model_name="siteotherinstrumentation",
|
|
174
189
|
constraint=models.CheckConstraint(
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
190
|
+
**{
|
|
191
|
+
check_param: models.Q(
|
|
192
|
+
("published", False), ("is_deleted", True), _negated=True
|
|
193
|
+
),
|
|
194
|
+
"name": "slm_siteotherinstrumentation_no_mod_deleted",
|
|
195
|
+
}
|
|
179
196
|
),
|
|
180
197
|
),
|
|
181
198
|
migrations.AddConstraint(
|
|
182
199
|
model_name="sitepressuresensor",
|
|
183
200
|
constraint=models.CheckConstraint(
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
201
|
+
**{
|
|
202
|
+
check_param: models.Q(
|
|
203
|
+
("published", False), ("is_deleted", True), _negated=True
|
|
204
|
+
),
|
|
205
|
+
"name": "slm_sitepressuresensor_no_mod_deleted",
|
|
206
|
+
}
|
|
188
207
|
),
|
|
189
208
|
),
|
|
190
209
|
migrations.AddConstraint(
|
|
191
210
|
model_name="siteradiointerferences",
|
|
192
211
|
constraint=models.CheckConstraint(
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
212
|
+
**{
|
|
213
|
+
check_param: models.Q(
|
|
214
|
+
("published", False), ("is_deleted", True), _negated=True
|
|
215
|
+
),
|
|
216
|
+
"name": "slm_siteradiointerferences_no_mod_deleted",
|
|
217
|
+
}
|
|
197
218
|
),
|
|
198
219
|
),
|
|
199
220
|
migrations.AddConstraint(
|
|
200
221
|
model_name="sitereceiver",
|
|
201
222
|
constraint=models.CheckConstraint(
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
223
|
+
**{
|
|
224
|
+
check_param: models.Q(
|
|
225
|
+
("published", False), ("is_deleted", True), _negated=True
|
|
226
|
+
),
|
|
227
|
+
"name": "slm_sitereceiver_no_mod_deleted",
|
|
228
|
+
}
|
|
206
229
|
),
|
|
207
230
|
),
|
|
208
231
|
migrations.AddConstraint(
|
|
209
232
|
model_name="sitesignalobstructions",
|
|
210
233
|
constraint=models.CheckConstraint(
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
234
|
+
**{
|
|
235
|
+
check_param: models.Q(
|
|
236
|
+
("published", False), ("is_deleted", True), _negated=True
|
|
237
|
+
),
|
|
238
|
+
"name": "slm_sitesignalobstructions_no_mod_deleted",
|
|
239
|
+
}
|
|
215
240
|
),
|
|
216
241
|
),
|
|
217
242
|
migrations.AddConstraint(
|
|
218
243
|
model_name="sitesurveyedlocalties",
|
|
219
244
|
constraint=models.CheckConstraint(
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
245
|
+
**{
|
|
246
|
+
check_param: models.Q(
|
|
247
|
+
("published", False), ("is_deleted", True), _negated=True
|
|
248
|
+
),
|
|
249
|
+
"name": "slm_sitesurveyedlocalties_no_mod_deleted",
|
|
250
|
+
}
|
|
224
251
|
),
|
|
225
252
|
),
|
|
226
253
|
migrations.AddConstraint(
|
|
227
254
|
model_name="sitetemperaturesensor",
|
|
228
255
|
constraint=models.CheckConstraint(
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
256
|
+
**{
|
|
257
|
+
check_param: models.Q(
|
|
258
|
+
("published", False), ("is_deleted", True), _negated=True
|
|
259
|
+
),
|
|
260
|
+
"name": "slm_sitetemperaturesensor_no_mod_deleted",
|
|
261
|
+
}
|
|
233
262
|
),
|
|
234
263
|
),
|
|
235
264
|
migrations.AddConstraint(
|
|
236
265
|
model_name="sitewatervaporradiometer",
|
|
237
266
|
constraint=models.CheckConstraint(
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
267
|
+
**{
|
|
268
|
+
check_param: models.Q(
|
|
269
|
+
("published", False), ("is_deleted", True), _negated=True
|
|
270
|
+
),
|
|
271
|
+
"name": "slm_sitewatervaporradiometer_no_mod_deleted",
|
|
272
|
+
}
|
|
242
273
|
),
|
|
243
274
|
),
|
|
244
275
|
]
|
|
@@ -39,7 +39,7 @@ class Migration(migrations.Migration):
|
|
|
39
39
|
verbose_name="Marker->ARP UNE Ecc (m)",
|
|
40
40
|
),
|
|
41
41
|
),
|
|
42
|
-
migrations.RunPython(switch_enu_to_une, switch_une_to_enu),
|
|
42
|
+
migrations.RunPython(switch_enu_to_une, switch_une_to_enu, elidable=True),
|
|
43
43
|
migrations.RemoveField(
|
|
44
44
|
model_name="siteantenna",
|
|
45
45
|
name="marker_enu",
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
# Generated by Django 4.2.14 on 2024-11-13 23:19
|
|
2
|
+
|
|
3
|
+
import django_enum.fields
|
|
4
|
+
from django.db import migrations
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
class Migration(migrations.Migration):
|
|
8
|
+
dependencies = [
|
|
9
|
+
("slm", "0030_alter_antenna_state_alter_radome_state_and_more"),
|
|
10
|
+
]
|
|
11
|
+
|
|
12
|
+
operations = [
|
|
13
|
+
migrations.AlterField(
|
|
14
|
+
model_name="antenna",
|
|
15
|
+
name="features",
|
|
16
|
+
field=django_enum.fields.EnumPositiveSmallIntegerField(
|
|
17
|
+
blank=True,
|
|
18
|
+
choices=[
|
|
19
|
+
(1, "(MMI) Man-Machine Interface"),
|
|
20
|
+
(2, "(NOM) North Orientation Mark"),
|
|
21
|
+
(3, "(RXC) Receiver Connector"),
|
|
22
|
+
(4, "(BAT) Battery Compartment Door Release"),
|
|
23
|
+
(5, "(BTD) Bottom of Tear Drop Shape"),
|
|
24
|
+
(6, "(CMP) Mounted Compass"),
|
|
25
|
+
(7, "(DIS) Display/Digital Readout"),
|
|
26
|
+
(8, "(DRY) Cap or Cover for Drying Agent"),
|
|
27
|
+
(9, "(PCS) PC Card Slot"),
|
|
28
|
+
(10, "(TMT) Tape Measure Tab or Notch for Slant Height Pole"),
|
|
29
|
+
(11, "(CAC) Nonspecific Cable Connector"),
|
|
30
|
+
(12, "(CTC) External Controller Connector"),
|
|
31
|
+
(13, "(DAC) Data Cable Connector"),
|
|
32
|
+
(14, "(PWC) Power Port"),
|
|
33
|
+
(15, "(RTC) RTK Connector"),
|
|
34
|
+
(16, "(UNK) Unknown"),
|
|
35
|
+
(17, "(OMM) Opposite of Man-Machine Interface"),
|
|
36
|
+
],
|
|
37
|
+
db_index=True,
|
|
38
|
+
default=None,
|
|
39
|
+
help_text='NOM/RXC/XXX from "antenna.gra"; see NRP abbreviations.',
|
|
40
|
+
null=True,
|
|
41
|
+
verbose_name="Antenna Features",
|
|
42
|
+
),
|
|
43
|
+
),
|
|
44
|
+
]
|