feat: 매입 세금계산서 수취 토글 기능 추가

- Purchase 모델에 tax_invoice_received 필드 추가
- PurchaseService에 toggleTaxInvoice() 메서드 추가
- UpdatePurchaseRequest에 tax_invoice_received 검증 규칙 추가
- 마이그레이션: purchases 테이블에 tax_invoice_received 컬럼 추가
This commit is contained in:
2025-12-24 16:16:53 +09:00
parent 1e161c16b0
commit 6ee3378377
5 changed files with 72 additions and 2 deletions

View File

@@ -0,0 +1,28 @@
<?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::table('purchases', function (Blueprint $table) {
$table->boolean('tax_invoice_received')->default(false)->after('withdrawal_id')->comment('세금계산서 수취 여부');
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('purchases', function (Blueprint $table) {
$table->dropColumn('tax_invoice_received');
});
}
};