Skip to content

Commit

Permalink
Created new index.
Browse files Browse the repository at this point in the history
  • Loading branch information
Luisella Strona committed Jan 13, 2025
1 parent a3116a0 commit c90a4b1
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Generated by Django 4.2.16 on 2025-01-13 10:43

from django.db import migrations
from django.db import models


class Migration(migrations.Migration):

dependencies = [
("common", "0012_user_sso_uuid"),
]

operations = [
migrations.AddIndex(
model_name="versiongroup",
index=models.Index(
fields=["current_version"],
name="common_vers_current_04c358_idx",
),
),
]
5 changes: 5 additions & 0 deletions common/models/trackedmodel.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,11 @@ class VersionGroup(TimestampedMixin):

versions: QuerySet[TrackedModel]

class Meta:
indexes = [
models.Index(fields=["current_version"]),
]


Cls = TypeVar("Cls", bound="TrackedModel")

Expand Down

0 comments on commit c90a4b1

Please sign in to comment.