- PMIS 모델 21개 + DailyWorkLog 2개에 $connection = 'codebridge' 추가 - MNG 마이그레이션 파일 18개 전체 삭제 (API에서 관리) - 원칙: MNG는 마이그레이션 파일을 생성하지 않고 API에서만 관리
40 lines
841 B
PHP
40 lines
841 B
PHP
<?php
|
|
|
|
namespace App\Models\Juil;
|
|
|
|
use Illuminate\Database\Eloquent\Model;
|
|
use Illuminate\Database\Eloquent\Relations\BelongsTo;
|
|
use Illuminate\Database\Eloquent\SoftDeletes;
|
|
|
|
class PmisAttendanceEquipment extends Model
|
|
{
|
|
use SoftDeletes;
|
|
|
|
protected $connection = 'codebridge';
|
|
|
|
protected $table = 'pmis_attendance_equipments';
|
|
|
|
protected $fillable = [
|
|
'tenant_id',
|
|
'attendance_id',
|
|
'equipment_name',
|
|
'specification',
|
|
'equipment_number',
|
|
'operator',
|
|
'man_days',
|
|
'work_content',
|
|
'sort_order',
|
|
'options',
|
|
];
|
|
|
|
protected $casts = [
|
|
'man_days' => 'decimal:1',
|
|
'options' => 'array',
|
|
];
|
|
|
|
public function attendance(): BelongsTo
|
|
{
|
|
return $this->belongsTo(PmisDailyAttendance::class, 'attendance_id');
|
|
}
|
|
}
|