chore: [인프라] Slack 채널 분리 + logging 권한 + 문서 갱신
- Slack 알림 채널: product_infra → deploy_api - logging.php daily/api 채널 permission 0664 추가 - CLAUDE.md, INDEX.md, 변경이력 문서 갱신 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -509,6 +509,7 @@ ### 2. Multi-tenancy & Models
|
||||
- SoftDeletes by default
|
||||
- Common columns: tenant_id, created_by, updated_by, deleted_by (COMMENT required)
|
||||
- FK constraints: Created during design, minimal in production
|
||||
- **🔴 쿼리 수정 시 모델 스코프 우선**: `where('컬럼', '값')` 하드코딩 전에 반드시 모델에 정의된 스코프(scopeActive 등)를 먼저 확인하고, 스코프가 있으면 `Model::active()` 형태로 사용할 것
|
||||
|
||||
### 3. Middleware Stack
|
||||
- ApiKeyMiddleware, CheckSwaggerAuth, CorsMiddleware, CheckPermission, PermMapper
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# 논리적 데이터베이스 관계 문서
|
||||
|
||||
> **자동 생성**: 2026-02-21 16:28:35
|
||||
> **자동 생성**: 2026-03-07 02:57:21
|
||||
> **소스**: Eloquent 모델 관계 분석
|
||||
|
||||
## 📊 모델별 관계 현황
|
||||
@@ -580,17 +580,10 @@ ### roles
|
||||
**모델**: `App\Models\Permissions\Role`
|
||||
|
||||
- **tenant()**: belongsTo → `tenants`
|
||||
- **menuPermissions()**: hasMany → `role_menu_permissions`
|
||||
- **userRoles()**: hasMany → `user_roles`
|
||||
- **users()**: belongsToMany → `users`
|
||||
- **permissions()**: belongsToMany → `permissions`
|
||||
|
||||
### role_menu_permissions
|
||||
**모델**: `App\Models\Permissions\RoleMenuPermission`
|
||||
|
||||
- **role()**: belongsTo → `roles`
|
||||
- **menu()**: belongsTo → `menus`
|
||||
|
||||
### popups
|
||||
**모델**: `App\Models\Popups\Popup`
|
||||
|
||||
@@ -637,6 +630,7 @@ ### work_orders
|
||||
- **stepProgress()**: hasMany → `work_order_step_progress`
|
||||
- **materialInputs()**: hasMany → `work_order_material_inputs`
|
||||
- **shipments()**: hasMany → `shipments`
|
||||
- **inspections()**: hasMany → `inspections`
|
||||
- **bendingDetail()**: hasOne → `work_order_bending_details`
|
||||
- **documents()**: morphMany → `documents`
|
||||
|
||||
@@ -743,6 +737,7 @@ ### push_notification_settings
|
||||
### inspections
|
||||
**모델**: `App\Models\Qualitys\Inspection`
|
||||
|
||||
- **workOrder()**: belongsTo → `work_orders`
|
||||
- **item()**: belongsTo → `items`
|
||||
- **inspector()**: belongsTo → `users`
|
||||
- **creator()**: belongsTo → `users`
|
||||
@@ -758,6 +753,38 @@ ### lot_sales
|
||||
|
||||
- **lot()**: belongsTo → `lots`
|
||||
|
||||
### performance_reports
|
||||
**모델**: `App\Models\Qualitys\PerformanceReport`
|
||||
|
||||
- **qualityDocument()**: belongsTo → `quality_documents`
|
||||
- **confirmer()**: belongsTo → `users`
|
||||
- **creator()**: belongsTo → `users`
|
||||
|
||||
### quality_documents
|
||||
**모델**: `App\Models\Qualitys\QualityDocument`
|
||||
|
||||
- **client()**: belongsTo → `clients`
|
||||
- **inspector()**: belongsTo → `users`
|
||||
- **creator()**: belongsTo → `users`
|
||||
- **documentOrders()**: hasMany → `quality_document_orders`
|
||||
- **locations()**: hasMany → `quality_document_locations`
|
||||
- **performanceReport()**: hasOne → `performance_reports`
|
||||
|
||||
### quality_document_locations
|
||||
**모델**: `App\Models\Qualitys\QualityDocumentLocation`
|
||||
|
||||
- **qualityDocument()**: belongsTo → `quality_documents`
|
||||
- **qualityDocumentOrder()**: belongsTo → `quality_document_orders`
|
||||
- **orderItem()**: belongsTo → `order_items`
|
||||
- **document()**: belongsTo → `documents`
|
||||
|
||||
### quality_document_orders
|
||||
**모델**: `App\Models\Qualitys\QualityDocumentOrder`
|
||||
|
||||
- **qualityDocument()**: belongsTo → `quality_documents`
|
||||
- **order()**: belongsTo → `orders`
|
||||
- **locations()**: hasMany → `quality_document_locations`
|
||||
|
||||
### quotes
|
||||
**모델**: `App\Models\Quote\Quote`
|
||||
|
||||
@@ -836,6 +863,7 @@ ### approvals
|
||||
- **steps()**: hasMany → `approval_steps`
|
||||
- **approverSteps()**: hasMany → `approval_steps`
|
||||
- **referenceSteps()**: hasMany → `approval_steps`
|
||||
- **linkable()**: morphTo → `(Polymorphic)`
|
||||
|
||||
### approval_forms
|
||||
**모델**: `App\Models\Tenants\ApprovalForm`
|
||||
@@ -933,6 +961,16 @@ ### expense_accounts
|
||||
|
||||
- **vendor()**: belongsTo → `clients`
|
||||
|
||||
### journal_entrys
|
||||
**모델**: `App\Models\Tenants\JournalEntry`
|
||||
|
||||
- **lines()**: hasMany → `journal_entry_lines`
|
||||
|
||||
### journal_entry_lines
|
||||
**모델**: `App\Models\Tenants\JournalEntryLine`
|
||||
|
||||
- **journalEntry()**: belongsTo → `journal_entries`
|
||||
|
||||
### leaves
|
||||
**모델**: `App\Models\Tenants\Leave`
|
||||
|
||||
@@ -961,7 +999,10 @@ ### leave_policys
|
||||
### loans
|
||||
**모델**: `App\Models\Tenants\Loan`
|
||||
|
||||
- **user()**: belongsTo → `users`
|
||||
- **withdrawal()**: belongsTo → `withdrawals`
|
||||
- **creator()**: belongsTo → `users`
|
||||
- **updater()**: belongsTo → `users`
|
||||
|
||||
### payments
|
||||
**모델**: `App\Models\Tenants\Payment`
|
||||
@@ -1043,6 +1084,7 @@ ### shipments
|
||||
- **creator()**: belongsTo → `users`
|
||||
- **updater()**: belongsTo → `users`
|
||||
- **items()**: hasMany → `shipment_items`
|
||||
- **vehicleDispatches()**: hasMany → `shipment_vehicle_dispatches`
|
||||
|
||||
### shipment_items
|
||||
**모델**: `App\Models\Tenants\ShipmentItem`
|
||||
@@ -1050,6 +1092,11 @@ ### shipment_items
|
||||
- **shipment()**: belongsTo → `shipments`
|
||||
- **stockLot()**: belongsTo → `stock_lots`
|
||||
|
||||
### shipment_vehicle_dispatchs
|
||||
**모델**: `App\Models\Tenants\ShipmentVehicleDispatch`
|
||||
|
||||
- **shipment()**: belongsTo → `shipments`
|
||||
|
||||
### sites
|
||||
**모델**: `App\Models\Tenants\Site`
|
||||
|
||||
@@ -1147,6 +1194,8 @@ ### tenant_user_profiles
|
||||
### today_issues
|
||||
**모델**: `App\Models\Tenants\TodayIssue`
|
||||
|
||||
- **reader()**: belongsTo → `users`
|
||||
- **targetUser()**: belongsTo → `users`
|
||||
|
||||
### withdrawals
|
||||
**모델**: `App\Models\Tenants\Withdrawal`
|
||||
|
||||
@@ -67,6 +67,7 @@
|
||||
|
||||
'daily' => [
|
||||
'driver' => 'daily',
|
||||
'permission' => 0664,
|
||||
'path' => storage_path('logs/laravel.log'),
|
||||
'level' => env('LOG_LEVEL', 'debug'),
|
||||
'days' => env('LOG_DAILY_DAYS', 14),
|
||||
@@ -138,6 +139,7 @@
|
||||
*/
|
||||
'api' => [
|
||||
'driver' => 'daily',
|
||||
'permission' => 0664,
|
||||
'path' => storage_path('logs/api/api.log'),
|
||||
'level' => 'info',
|
||||
'days' => env('API_LOG_DAYS', 14),
|
||||
|
||||
@@ -43,7 +43,7 @@
|
||||
*/
|
||||
'gemini' => [
|
||||
'api_key' => env('GEMINI_API_KEY'),
|
||||
'model' => env('GEMINI_MODEL', 'gemini-2.0-flash'),
|
||||
'model' => env('GEMINI_MODEL', 'gemini-2.5-flash'),
|
||||
'base_url' => env('GEMINI_BASE_URL', 'https://generativelanguage.googleapis.com/v1beta'),
|
||||
],
|
||||
|
||||
|
||||
@@ -37,7 +37,7 @@ ## 🔗 프로젝트 문서 (SAM/docs로 이동됨)
|
||||
|
||||
| 이전 위치 | 새 위치 | 설명 |
|
||||
|-----------|---------|------|
|
||||
| `analysis/` | `docs/data/analysis/` | Item DB 분석 문서 |
|
||||
| `analysis/` | `docs/dev/data/analysis/` | Item DB 분석 문서 |
|
||||
| `front/` | `docs/front/` | 프론트엔드 요청 문서 |
|
||||
| `specs/` | `docs/specs/` | 기능 스펙 문서 |
|
||||
|
||||
@@ -49,6 +49,6 @@ ## 📝 문서 추가 가이드
|
||||
|-----------|-----------|
|
||||
| Swagger 스펙 | `api/docs/swagger/` |
|
||||
| API Flow 테스트 | `api/docs/api-flows/` 또는 `flow-tests/` |
|
||||
| 프로젝트 분석 | `SAM/docs/data/` |
|
||||
| 프로젝트 분석 | `SAM/docs/dev/data/` |
|
||||
| 기능 스펙 | `SAM/docs/specs/` |
|
||||
| 프론트 요청 | `SAM/docs/front/` |
|
||||
|
||||
@@ -74,5 +74,5 @@ ## ⚠️ 배포 시 주의사항
|
||||
- 테넌트별 초기 데이터 설정 필요
|
||||
|
||||
## 🔗 관련 문서
|
||||
- `docs/plans/quote-calculation-api-plan.md`
|
||||
- `docs/dev/dev_plans/quote-calculation-api-plan.md`
|
||||
- `mng/app/Services/Quote/FormulaEvaluatorService.php` (원본)
|
||||
|
||||
@@ -2,7 +2,7 @@ # 변경 내용 요약
|
||||
|
||||
**날짜:** 2026-01-02 13:00
|
||||
**작업명:** Phase 1.2 입력 변수 처리 - React QuoteItem 매핑
|
||||
**계획 문서:** docs/plans/quote-calculation-api-plan.md
|
||||
**계획 문서:** docs/dev/dev_plans/quote-calculation-api-plan.md
|
||||
|
||||
## 변경 개요
|
||||
|
||||
@@ -151,4 +151,4 @@ ## API 사용 예시
|
||||
## 관련 문서
|
||||
|
||||
- Phase 1.1: `20251230_2339_quote_calculation_mng_logic.md` (BOM 단건 산출)
|
||||
- 계획 문서: `docs/plans/quote-calculation-api-plan.md`
|
||||
- 계획 문서: `docs/dev/dev_plans/quote-calculation-api-plan.md`
|
||||
2
package-lock.json
generated
2
package-lock.json
generated
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"name": "api",
|
||||
"name": "sam-api",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
|
||||
Reference in New Issue
Block a user