Fix bug with removing attributes (#4927)

main
Anastasia Yasakova 3 years ago committed by GitHub
parent 4f6e81eab3
commit 6bb343f4ca
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -60,6 +60,7 @@ Skeleton (<https://github.com/cvat-ai/cvat/pull/1>), (<https://github.com/opencv
- Fixed project filtration (<https://github.com/opencv/cvat/pull/4878>)
- Maximum callstack exceed when create task with 100000+ files from cloud storage (<https://github.com/opencv/cvat/pull/4836>)
- Fixed invocation of serverless functions (<https://github.com/opencv/cvat/pull/4907>)
- Removing label attributes (<https://github.com/opencv/cvat/pull/4927>)
### Security
- TDB

@ -0,0 +1,19 @@
# Generated by Django 3.2.15 on 2022-09-09 09:00
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('engine', '0059_labeledshape_outside'),
]
operations = [
migrations.AlterField(
model_name='label',
name='parent',
field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='sublabels', to='engine.label'),
),
]

@ -498,7 +498,7 @@ class Label(models.Model):
name = SafeCharField(max_length=64)
color = models.CharField(default='', max_length=8)
type = models.CharField(max_length=32, null=True, choices=LabelType.choices(), default=LabelType.ANY)
parent = models.ForeignKey('self', on_delete=models.CASCADE, null=True, related_name='sublabels')
parent = models.ForeignKey('self', on_delete=models.CASCADE, null=True, blank=True, related_name='sublabels')
def __str__(self):
return self.name

Loading…
Cancel
Save