change sponsorblock_categories to a textfield, fixing max charlen=255 for mysql, related to #338

This commit is contained in:
meeb 2023-02-20 13:24:38 +11:00
parent e4c0f0e98a
commit 2639d911ab
2 changed files with 20 additions and 1 deletions

View File

@ -49,7 +49,7 @@ class CommaSepChoiceField(models.Field):
return name, path, args, kwargs
def db_type(self, _connection):
return 'char(1024)'
return 'TextField'
def get_my_choices(self):
choiceArray = []

View File

@ -0,0 +1,19 @@
# Generated by Django 3.2.18 on 2023-02-20 02:23
from django.db import migrations
import sync.fields
class Migration(migrations.Migration):
dependencies = [
('sync', '0016_auto_20230214_2052'),
]
operations = [
migrations.AlterField(
model_name='source',
name='sponsorblock_categories',
field=sync.fields.CommaSepChoiceField(default='all', help_text='Select the sponsorblocks you want to enforce', separator=''),
),
]