40 lines
2.1 KiB
Python
40 lines
2.1 KiB
Python
# Generated by Django 5.2.1 on 2025-05-29 09:24
|
|
|
|
import django.db.models.deletion
|
|
from django.db import migrations, models
|
|
|
|
|
|
class Migration(migrations.Migration):
|
|
|
|
initial = True
|
|
|
|
dependencies = [
|
|
('brands', '0001_initial'),
|
|
('daren_detail', '0001_initial'),
|
|
]
|
|
|
|
operations = [
|
|
migrations.CreateModel(
|
|
name='Negotiation',
|
|
fields=[
|
|
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
|
('status', models.CharField(choices=[('brand_review', '品牌回顾'), ('price_negotiation', '价格谈判'), ('contract_review', '合同确认'), ('draft_ready', '准备合同'), ('draft_approved', '合同提交'), ('accepted', '已接受'), ('abandoned', '已放弃')], default='price_negotiation', max_length=20)),
|
|
('current_round', models.IntegerField(default=1)),
|
|
('context', models.JSONField(default=dict)),
|
|
('creator', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='daren_detail.creatorprofile')),
|
|
('product', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='brands.product')),
|
|
],
|
|
),
|
|
migrations.CreateModel(
|
|
name='Message',
|
|
fields=[
|
|
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
|
('role', models.CharField(max_length=10)),
|
|
('content', models.TextField()),
|
|
('created_at', models.DateTimeField(auto_now_add=True)),
|
|
('stage', models.CharField(choices=[('brand_review', '品牌回顾'), ('price_negotiation', '价格谈判'), ('contract_review', '合同确认'), ('draft_ready', '准备合同'), ('draft_approved', '合同提交'), ('accepted', '已接受'), ('abandoned', '已放弃')], default='brand_review', max_length=32)),
|
|
('negotiation', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='expertproducts.negotiation')),
|
|
],
|
|
),
|
|
]
|