From 591197f29ce68e75581041b0dd8a6773aef7964a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=B6=8C=ED=98=81=EC=84=B1?= Date: Fri, 30 Jan 2026 15:32:29 +0900 Subject: [PATCH] =?UTF-8?q?fix(API):=20fix=5Funique=5Fkey=20=EB=A7=88?= =?UTF-8?q?=EC=9D=B4=EA=B7=B8=EB=A0=88=EC=9D=B4=EC=85=98=EC=97=90=20?= =?UTF-8?q?=ED=85=8C=EC=9D=B4=EB=B8=94=20=EC=A1=B4=EC=9E=AC=20=EC=B2=B4?= =?UTF-8?q?=ED=81=AC=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 테이블 미존재 시 스킵하여 순서 무관하게 안전 실행 Co-Authored-By: Claude Opus 4.5 --- ...01_29_100500_fix_sales_scenario_checklists_unique_key.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/database/migrations/2026_01_29_100500_fix_sales_scenario_checklists_unique_key.php b/database/migrations/2026_01_29_100500_fix_sales_scenario_checklists_unique_key.php index 75fb113..08c66e3 100644 --- a/database/migrations/2026_01_29_100500_fix_sales_scenario_checklists_unique_key.php +++ b/database/migrations/2026_01_29_100500_fix_sales_scenario_checklists_unique_key.php @@ -12,6 +12,11 @@ */ public function up(): void { + // 테이블이 아직 없으면 스킵 (후속 마이그레이션에서 생성됨) + if (! Schema::hasTable('sales_scenario_checklists')) { + return; + } + // 기존 유니크 키가 존재하면 삭제 $indexes = DB::select("SHOW INDEX FROM sales_scenario_checklists WHERE Key_name = 'sales_scenario_unique'"); if (count($indexes) > 0) {