fix: [address] 주소 필드 255자 → 500자 확장
- DB 마이그레이션: clients, tenants, site_briefings, sites 테이블 address 컬럼 varchar(500) - FormRequest 8개 파일 max:255 → max:500 변경
This commit is contained in:
@@ -65,7 +65,7 @@ public function rules(): array
|
||||
'mobile' => 'nullable|string|max:20',
|
||||
'fax' => 'nullable|string|max:20',
|
||||
'email' => 'nullable|email|max:100',
|
||||
'address' => 'nullable|string|max:255',
|
||||
'address' => 'nullable|string|max:500',
|
||||
// 담당자 정보
|
||||
'manager_name' => 'nullable|string|max:50',
|
||||
'manager_tel' => 'nullable|string|max:20',
|
||||
|
||||
@@ -65,7 +65,7 @@ public function rules(): array
|
||||
'mobile' => 'nullable|string|max:20',
|
||||
'fax' => 'nullable|string|max:20',
|
||||
'email' => 'nullable|email|max:100',
|
||||
'address' => 'nullable|string|max:255',
|
||||
'address' => 'nullable|string|max:500',
|
||||
// 담당자 정보
|
||||
'manager_name' => 'nullable|string|max:50',
|
||||
'manager_tel' => 'nullable|string|max:20',
|
||||
|
||||
@@ -29,7 +29,7 @@ public function rules(): array
|
||||
'briefing_time' => 'nullable|string|max:10',
|
||||
'briefing_type' => ['nullable', 'string', Rule::in(SiteBriefing::TYPES)],
|
||||
'location' => 'nullable|string|max:200',
|
||||
'address' => 'nullable|string|max:255',
|
||||
'address' => 'nullable|string|max:500',
|
||||
|
||||
// 상태 정보
|
||||
'status' => ['nullable', 'string', Rule::in(SiteBriefing::STATUSES)],
|
||||
|
||||
@@ -29,7 +29,7 @@ public function rules(): array
|
||||
'briefing_time' => 'nullable|string|max:10',
|
||||
'briefing_type' => ['nullable', 'string', Rule::in(SiteBriefing::TYPES)],
|
||||
'location' => 'nullable|string|max:200',
|
||||
'address' => 'nullable|string|max:255',
|
||||
'address' => 'nullable|string|max:500',
|
||||
|
||||
// 상태 정보
|
||||
'status' => ['nullable', 'string', Rule::in(SiteBriefing::STATUSES)],
|
||||
|
||||
@@ -17,7 +17,7 @@ public function rules(): array
|
||||
'company_name' => 'required|string|max:100',
|
||||
'email' => 'nullable|email|max:100',
|
||||
'phone' => 'nullable|string|max:20',
|
||||
'address' => 'nullable|string|max:255',
|
||||
'address' => 'nullable|string|max:500',
|
||||
'business_num' => 'nullable|string|max:20',
|
||||
'ceo_name' => 'nullable|string|max:100',
|
||||
];
|
||||
|
||||
@@ -18,7 +18,7 @@ public function rules(): array
|
||||
'company_name' => 'sometimes|string|max:100',
|
||||
'email' => 'nullable|email|max:100',
|
||||
'phone' => 'nullable|string|max:20',
|
||||
'address' => 'nullable|string|max:255',
|
||||
'address' => 'nullable|string|max:500',
|
||||
'business_num' => 'nullable|string|max:20',
|
||||
'ceo_name' => 'nullable|string|max:100',
|
||||
'logo' => 'nullable|string|max:255',
|
||||
|
||||
@@ -15,7 +15,7 @@ public function rules(): array
|
||||
{
|
||||
return [
|
||||
'name' => ['required', 'string', 'max:100'],
|
||||
'address' => ['nullable', 'string', 'max:255'],
|
||||
'address' => ['nullable', 'string', 'max:500'],
|
||||
'latitude' => ['nullable', 'numeric', 'between:-90,90'],
|
||||
'longitude' => ['nullable', 'numeric', 'between:-180,180'],
|
||||
'is_active' => ['sometimes', 'boolean'],
|
||||
|
||||
@@ -15,7 +15,7 @@ public function rules(): array
|
||||
{
|
||||
return [
|
||||
'name' => ['sometimes', 'string', 'max:100'],
|
||||
'address' => ['nullable', 'string', 'max:255'],
|
||||
'address' => ['nullable', 'string', 'max:500'],
|
||||
'latitude' => ['nullable', 'numeric', 'between:-90,90'],
|
||||
'longitude' => ['nullable', 'numeric', 'between:-180,180'],
|
||||
'is_active' => ['sometimes', 'boolean'],
|
||||
|
||||
@@ -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
|
||||
{
|
||||
$tables = ['clients', 'tenants', 'site_briefings', 'sites'];
|
||||
|
||||
foreach ($tables as $table) {
|
||||
if (Schema::hasColumn($table, 'address')) {
|
||||
Schema::table($table, function (Blueprint $t) {
|
||||
$t->string('address', 500)->nullable()->change();
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public function down(): void
|
||||
{
|
||||
$tables = ['clients', 'tenants', 'site_briefings', 'sites'];
|
||||
|
||||
foreach ($tables as $table) {
|
||||
if (Schema::hasColumn($table, 'address')) {
|
||||
Schema::table($table, function (Blueprint $t) {
|
||||
$t->string('address', 255)->nullable()->change();
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
Reference in New Issue
Block a user