- Удалено избыточное поле customer_is_recipient из модели Order - Добавлено свойство @property is_customer_recipient для обратной совместимости - Заменены радиокнопки recipient_mode на чекбокс 'Другой получатель' в форме - Добавлено поле recipient_source для выбора между историей и новым получателем - Обновлен AddressService.process_recipient_from_form() для работы с чекбоксом - Обновлены шаблоны: order_form.html (чекбокс вместо радиокнопок) и order_detail.html - Удалено customer_is_recipient из admin и demo команды - Создана миграция для удаления поля customer_is_recipient Логика упрощена: recipient is None = получатель = покупатель, иначе - отдельный получатель
22 lines
458 B
Python
22 lines
458 B
Python
# Generated by Django 5.0.10 on 2025-12-24 10:51
|
|
|
|
from django.db import migrations
|
|
|
|
|
|
class Migration(migrations.Migration):
|
|
|
|
dependencies = [
|
|
('orders', '0002_initial'),
|
|
]
|
|
|
|
operations = [
|
|
migrations.RemoveField(
|
|
model_name='historicalorder',
|
|
name='customer_is_recipient',
|
|
),
|
|
migrations.RemoveField(
|
|
model_name='order',
|
|
name='customer_is_recipient',
|
|
),
|
|
]
|