From ae4e60f1568ac0829637e47d88eb506d321f193e Mon Sep 17 00:00:00 2001 From: Akira Date: Mon, 23 Feb 2026 12:42:03 +0900 Subject: [PATCH] =?UTF-8?q?=E8=BB=A2=E9=80=81=E6=A4=9C=E5=87=BA=E3=81=AE?= =?UTF-8?q?=E4=BB=95=E7=B5=84=E3=81=BF=20=E8=BB=A2=E9=80=81=E3=81=95?= =?UTF-8?q?=E3=82=8C=E3=81=9F=E3=83=A1=E3=83=BC=E3=83=AB=E3=81=AF=E5=85=83?= =?UTF-8?q?=E3=81=AE=E3=80=8CTo:=E3=80=8D=E3=83=98=E3=83=83=E3=83=80?= =?UTF-8?q?=E3=83=BC=E3=81=AB=20infoseek.jp=20=E3=81=8C=E6=AE=8B=E3=82=8A?= =?UTF-8?q?=E3=81=BE=E3=81=99=EF=BC=9A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit To: akiracraftwork@infoseek.jp ← Outlook が転送時に保持 このドメインが forwarding_map に一致したら account_code = "infoseek" に切り替えます。 変更まとめ ファイル 変更内容 models.py infoseek を ACCOUNT_CHOICES に追加 + migration mail_filter.flow.json forwarding_map追加、転送検出ロジック、ローカルにデプロイ済み history/page.tsx ACCOUNT_LABELS と フィルタに infoseek 追加 infoseek.jpにテストメールを送って、次回フロー実行時に「Infoseek (転送)」として表示されるか確認してください。 --- .claude/settings.json | 5 ++++- .../migrations/0003_add_infoseek_account.py | 18 ++++++++++++++++++ backend/apps/mail/models.py | 1 + docker-compose.yml | 2 -- frontend/src/app/mail/history/page.tsx | 2 ++ 5 files changed, 25 insertions(+), 3 deletions(-) create mode 100644 backend/apps/mail/migrations/0003_add_infoseek_account.py diff --git a/.claude/settings.json b/.claude/settings.json index dfad4e3..c3720b2 100644 --- a/.claude/settings.json +++ b/.claude/settings.json @@ -12,7 +12,10 @@ "Bash(STEP_JOB=\"019c8344-4fc4-f59e-1009-c3733e28b46c\")", "Bash(__NEW_LINE_94a6a83a7608650e__ curl -sk -H \"Authorization: Bearer $TOKEN\" \"http://localhost/api/w/admins/jobs_u/completed/get/$STEP_JOB\")", "Bash(docker start:*)", - "Bash(docker stop:*)" + "Bash(docker stop:*)", + "WebFetch(domain:tomo1joy.com)", + "Bash(bash wm-api.sh update-flow f/mail/mail_filter flows/mail_filter.flow.json)", + "Read(//c/Users/akira/Develop/windmill//**)" ] } } diff --git a/backend/apps/mail/migrations/0003_add_infoseek_account.py b/backend/apps/mail/migrations/0003_add_infoseek_account.py new file mode 100644 index 0000000..7493a39 --- /dev/null +++ b/backend/apps/mail/migrations/0003_add_infoseek_account.py @@ -0,0 +1,18 @@ +# Generated by Django 5.0 on 2026-02-22 07:30 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('mail', '0002_alter_mailemail_feedback_alter_mailsender_rule'), + ] + + operations = [ + migrations.AlterField( + model_name='mailemail', + name='account', + field=models.CharField(choices=[('xserver', 'Xserver'), ('gmail', 'Gmail'), ('hotmail', 'Hotmail'), ('infoseek', 'Infoseek (転送)')], max_length=20, verbose_name='アカウント'), + ), + ] diff --git a/backend/apps/mail/models.py b/backend/apps/mail/models.py index 2f5c4a6..09cdd8f 100644 --- a/backend/apps/mail/models.py +++ b/backend/apps/mail/models.py @@ -45,6 +45,7 @@ ACCOUNT_CHOICES = [ ('xserver', 'Xserver'), ('gmail', 'Gmail'), ('hotmail', 'Hotmail'), + ('infoseek', 'Infoseek (転送)'), ] FEEDBACK_CHOICES = [ diff --git a/docker-compose.yml b/docker-compose.yml index 34742e9..7cbcc80 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -31,8 +31,6 @@ services: DB_PORT: 5432 SECRET_KEY: ${SECRET_KEY} DEBUG: "True" - MAIL_API_KEY: ${MAIL_API_KEY} - FRONTEND_URL: http://localhost:3000 ports: - "8000:8000" volumes: diff --git a/frontend/src/app/mail/history/page.tsx b/frontend/src/app/mail/history/page.tsx index c449a4a..5d352e7 100644 --- a/frontend/src/app/mail/history/page.tsx +++ b/frontend/src/app/mail/history/page.tsx @@ -31,6 +31,7 @@ const ACCOUNT_LABELS: Record = { gmail: 'Gmail', hotmail: 'Hotmail', xserver: 'Xserver', + infoseek: 'Infoseek (転送)', }; export default function MailHistoryPage() { @@ -97,6 +98,7 @@ export default function MailHistoryPage() { +