feat(api): 사업자등록증 OCR용 biz_cert 테이블 마이그레이션 추가
- biz_cert 테이블 생성 (사업자등록번호, 상호, 대표자, 개업일, 주소, 업태, 종목, 발급일) - raw_text, ocr_method 필드 추가 (OCR 원본 텍스트 및 처리 방식 저장) - biz_no, company_name 인덱스 추가 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
<?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('biz_cert', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('biz_no', 12)->comment('사업자등록번호');
|
||||
$table->string('company_name', 100)->comment('상호');
|
||||
$table->string('representative', 50)->nullable()->comment('대표자');
|
||||
$table->date('open_date')->nullable()->comment('개업일');
|
||||
$table->string('address', 255)->nullable()->comment('주소');
|
||||
$table->string('biz_type', 100)->nullable()->comment('업태');
|
||||
$table->string('biz_item', 255)->nullable()->comment('종목');
|
||||
$table->date('issue_date')->nullable()->comment('발급일');
|
||||
$table->text('raw_text')->nullable()->comment('OCR 원본 텍스트');
|
||||
$table->string('ocr_method', 20)->default('claude')->comment('OCR 방식 (tesseract/claude)');
|
||||
$table->timestamps();
|
||||
|
||||
$table->index('biz_no');
|
||||
$table->index('company_name');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('biz_cert');
|
||||
}
|
||||
};
|
||||
Reference in New Issue
Block a user