|
|
@@ -28,7 +28,7 @@ def create_queries ( |
|
|
|
) -> None: |
|
|
|
with SCHEMA.create ('queries') as table: |
|
|
|
table.big_increments ('id') |
|
|
|
table.big_integer ('user_id').unsigned ().nullable ().comment ('クエリ主') |
|
|
|
table.big_integer ('user_id').nullable ().comment ('クエリ主').unsigned () |
|
|
|
table.integer ('target_character').comment ('クエリ先キャラクタ') |
|
|
|
table.text ('content').comment ('クエリ内容') |
|
|
|
table.string ('image_url').nullable ().default (None).comment ('添附画像 URL') |
|
|
@@ -42,7 +42,7 @@ def create_answers ( |
|
|
|
) -> None: |
|
|
|
with SCHEMA.create ('answers') as table: |
|
|
|
table.big_increments ('id') |
|
|
|
table.big_integer ('query_id').unsigned ().nullable ().comment ('クエリ') |
|
|
|
table.big_integer ('query_id').nullable ().comment ('クエリ').unsigned () |
|
|
|
table.integer ('character').comment ('キャラクタ区分') |
|
|
|
table.text ('content').comment ('回答内容') |
|
|
|
table.integer ('answer_type').comment ('回答区分') |
|
|
|