Merge remote-tracking branch 'origin/develop' into develop
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
# 논리적 데이터베이스 관계 문서
|
||||
|
||||
> **자동 생성**: 2026-02-03 17:39:58
|
||||
> **자동 생성**: 2026-02-05 15:42:10
|
||||
> **소스**: Eloquent 모델 관계 분석
|
||||
|
||||
## 📊 모델별 관계 현황
|
||||
|
||||
@@ -0,0 +1,30 @@
|
||||
<?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('barobill_card_transaction_splits', function (Blueprint $table) {
|
||||
$table->decimal('split_supply_amount', 18, 2)->nullable()->after('split_amount')->comment('분개 공급가액');
|
||||
$table->decimal('split_tax', 18, 2)->nullable()->after('split_supply_amount')->comment('분개 부가세');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::table('barobill_card_transaction_splits', function (Blueprint $table) {
|
||||
$table->dropColumn(['split_supply_amount', 'split_tax']);
|
||||
});
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,34 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('barobill_card_transaction_hides', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->unsignedBigInteger('tenant_id');
|
||||
$table->string('original_unique_key', 255)->comment('cardNum|useDt|approvalNum|amount');
|
||||
$table->string('card_num', 50)->default('');
|
||||
$table->string('use_date', 8)->default('');
|
||||
$table->string('approval_num', 50)->default('');
|
||||
$table->decimal('original_amount', 15, 2)->default(0);
|
||||
$table->string('merchant_name', 255)->default('');
|
||||
$table->unsignedBigInteger('hidden_by')->nullable();
|
||||
$table->timestamps();
|
||||
|
||||
$table->index(['tenant_id', 'original_unique_key'], 'idx_tenant_unique_key');
|
||||
$table->index(['tenant_id', 'use_date'], 'idx_tenant_use_date');
|
||||
|
||||
$table->foreign('tenant_id')->references('id')->on('tenants')->onDelete('cascade');
|
||||
});
|
||||
}
|
||||
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('barobill_card_transaction_hides');
|
||||
}
|
||||
};
|
||||
Reference in New Issue
Block a user