add: автоматическое создание slug с помощью pytils и чистка от html-мнемоник.
This commit is contained in:
18
etpgrf_site/blog/migrations/0005_alter_post_slug.py
Normal file
18
etpgrf_site/blog/migrations/0005_alter_post_slug.py
Normal file
@@ -0,0 +1,18 @@
|
||||
# Generated by Django 6.0.1 on 2026-02-12 16:45
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('blog', '0004_post_updated_at'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AlterField(
|
||||
model_name='post',
|
||||
name='slug',
|
||||
field=models.SlugField(blank=True, help_text='Уникальная часть адреса. Оставьте пустым для автогенерации.', max_length=255, unique=True, verbose_name='URL (slug)'),
|
||||
),
|
||||
]
|
||||
Reference in New Issue
Block a user