11# Generated by Django 4.2.20 on 2025-05-15 03:30
22
3- from django .db import migrations
3+ from django .db import migrations , models
4+ import django .db .models .deletion
45
56
67class Migration (migrations .Migration ):
@@ -10,9 +11,26 @@ class Migration(migrations.Migration):
1011 ]
1112
1213 operations = [
13- migrations .RenameIndex (
14+ migrations .AlterField (
1415 model_name = 'studentmodulehistoryextended' ,
15- new_name = 'student_module_idx' ,
16- old_fields = ('student_module' ,),
16+ name = 'student_module' ,
17+ field = models .ForeignKey (db_constraint = False , db_index = False , on_delete = django .db .models .deletion .DO_NOTHING , to = 'courseware.studentmodule' ),
18+ ),
19+ # This SeparateDatabaseAndState operation updates the state to match the model.
20+ # database_operations is left empty because the indexes were already dropped
21+ # by the previous operation in the database.
22+ migrations .SeparateDatabaseAndState (
23+ database_operations = [],
24+ state_operations = [
25+ migrations .AlterIndexTogether (
26+ name = 'studentmodulehistoryextended' ,
27+ index_together = set (),
28+ ),
29+ ],
30+ ),
31+ # Adds back the index on 'student_module' to ensure there is a single index on this field.
32+ migrations .AddIndex (
33+ model_name = 'studentmodulehistoryextended' ,
34+ index = models .Index (fields = ['student_module' ], name = 'student_module_idx' ),
1735 ),
1836 ]
0 commit comments