Files
sam-manage/app/Models/Interview/InterviewCategory.php
김보곤 a507f7dc69 feat:인터뷰 시나리오 관리 기능 추가
- InterviewScenarioController: 카테고리/항목/질문 CRUD + 세션 관리 API
- InterviewScenarioService: 비즈니스 로직 (트리 조회, 세션 시작/토글/완료)
- MNG 모델 5개: InterviewCategory, InterviewTemplate, InterviewQuestion, InterviewSession, InterviewAnswer
- React 뷰: 2-패널 레이아웃 (카테고리 사이드바 + 항목/질문 관리)
- 인터뷰 실시 모달: 카테고리 선택 → 체크리스트 → 완료
- 인터뷰 기록 모달: 기록 목록 + 상세 보기
- InterviewMenuSeeder: 영업관리 > 인터뷰 시나리오 메뉴 추가
- 라우트 18개 추가 (sales/interviews/api/*)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-06 21:01:35 +09:00

40 lines
837 B
PHP

<?php
namespace App\Models\Interview;
use App\Traits\BelongsToTenant;
use App\Traits\ModelTrait;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;
class InterviewCategory extends Model
{
use BelongsToTenant, ModelTrait, SoftDeletes;
protected $fillable = [
'tenant_id',
'name',
'description',
'sort_order',
'is_active',
'created_by',
'updated_by',
'deleted_by',
];
protected $casts = [
'is_active' => 'boolean',
'sort_order' => 'integer',
];
public function templates()
{
return $this->hasMany(InterviewTemplate::class, 'interview_category_id');
}
public function sessions()
{
return $this->hasMany(InterviewSession::class, 'interview_category_id');
}
}