feat:바로빌 계좌 거래 동기화 상태 테이블 마이그레이션 추가
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,36 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('barobill_bank_sync_status', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->foreignId('tenant_id')->constrained()->onDelete('cascade');
|
||||
$table->string('bank_account_num', 50)->comment('계좌번호');
|
||||
$table->string('synced_year_month', 6)->comment('동기화 완료된 월 (YYYYMM)');
|
||||
$table->timestamp('synced_at')->comment('마지막 동기화 시각');
|
||||
$table->timestamps();
|
||||
|
||||
$table->unique(
|
||||
['tenant_id', 'bank_account_num', 'synced_year_month'],
|
||||
'bb_sync_status_unique'
|
||||
);
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('barobill_bank_sync_status');
|
||||
}
|
||||
};
|
||||
Reference in New Issue
Block a user