Commit Graph

317 Commits

Author SHA1 Message Date
유병철
e8da2ea1b1 feat: [dashboard-ceo] CEO 대시보드 섹션별 API 및 일일보고서 엑셀 추가
- DashboardCeoController/Service: 6개 섹션 API 신규 (매출/매입/생산/미출고/시공/근태)
- DailyReportController/Service: 엑셀 다운로드 API 추가 (GET /daily-report/export)
- 라우트: dashboard 하위 6개 + daily-report/export 엔드포인트 추가

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-05 09:35:30 +09:00
유병철
74a60e06bc feat: [calendar,vat] 캘린더 CRUD 및 부가세 상세 조회 API 추가
- CalendarController/Service: 일정 등록/수정/삭제 API 추가
- VatController/Service: getDetail() 상세 조회 (요약, 참조테이블, 미발행 목록, 신고기간 옵션)
- 라우트: POST/PUT/DELETE /calendar/schedules, GET /vat/detail 추가

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-04 20:33:04 +09:00
유병철
94b96e22f6 feat: [entertainment] 접대비 상세 조회 날짜 필터 파라미터 추가
- EntertainmentController: detail에 start_date/end_date 파라미터 전달
- EntertainmentService: getDetail 리스크/사용자분포/거래내역에 날짜 필터 적용

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-04 15:32:16 +09:00
유병철
66da2972fa feat: [entertainment,loan] 접대비 상세 조회 API 및 가지급금 날짜 필터 추가
- EntertainmentController/Service: getDetail() 상세 조회 API 추가 (손금한도, 월별추이, 사용자분포, 거래내역, 분기현황)
- EntertainmentService: 수입금액별 추가한도 계산(세법 기준), 거래건별 리스크 감지
- LoanController/Service: dashboard에 start_date/end_date 파라미터 지원
- LoanService: getCategoryBreakdown 날짜 필터 적용, 목록 limit 10→50 확대
- 라우트: GET /entertainment/detail 엔드포인트 추가

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-04 15:11:37 +09:00
김보곤
7cf70dbcaa fix: [address] 주소 필드 255자 → 500자 확장
- DB 마이그레이션: clients, tenants, site_briefings, sites 테이블 address 컬럼 varchar(500)
- FormRequest 8개 파일 max:255 → max:500 변경
2026-03-04 11:29:08 +09:00
유병철
1deeafc4de feat: [expense,loan] 대시보드 상세 필터 및 가지급금 카테고리 분류
- ExpectedExpenseController/Service: dashboardDetail에 start_date/end_date/search 파라미터 추가
- Loan 모델: category 상수 및 라벨 정의 (카드/경조사/상품권/접대비)
- LoanService: dashboard에 category_breakdown 집계 추가
- 마이그레이션: loans 테이블 category 컬럼 추가

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-04 10:42:53 +09:00
김보곤
4f3467c3b0 feat: [barobill] 바로빌 연동 API 엔드포인트 추가
- GET /api/v1/barobill/status — 연동 현황 조회
- POST /api/v1/barobill/login — 로그인 정보 등록
- POST /api/v1/barobill/signup — 회원가입 정보 등록
- GET /api/v1/barobill/bank-service-url — 은행 서비스 URL
- GET /api/v1/barobill/account-link-url — 계좌 연동 URL
- GET /api/v1/barobill/card-link-url — 카드 연동 URL
- GET /api/v1/barobill/certificate-url — 공인인증서 URL
2026-03-04 09:03:55 +09:00
김보곤
e9fd75fa74 feat: [inspection] 캘린더 스케줄 조회 API 추가
- GET /api/v1/inspections/calendar 엔드포인트 추가
- year, month, inspector, status 파라미터 지원
- React 프론트엔드 CalendarItemApi 형식에 맞춰 응답
2026-03-04 08:33:32 +09:00
유병철
42443349dc feat: [stock,client,status-board] 날짜 필터 및 조건 보완
- StockController/StockService: 입출고 이력 기반 날짜 범위 필터 추가
- ClientService: 등록일 기간 필터(start_date/end_date) 추가
- StatusBoardService: 부실채권 현황에 is_active 조건 추가 (목록 페이지 일치)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 21:53:30 +09:00
유병철
b7465becab feat: [approval] 결재 수신함 날짜 범위 필터 추가
- InboxIndexRequest에 start_date/end_date 검증 룰 추가
- ApprovalService.inbox()에 created_at 날짜 범위 필터 구현

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 20:02:07 +09:00
유병철
83a774572a feat: [today-issue] 날짜 기반 이전 이슈 조회 기능 추가
- TodayIssueController에 date 파라미터(YYYY-MM-DD) 추가
- TodayIssueService.summary()에 날짜 기반 필터링 로직 구현
- 이전 이슈 조회 시 만료(active) 필터 무시하여 과거 데이터 조회 가능

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 18:48:30 +09:00
f970b6bf4b feat: [inspection] Phase 3 절곡 검사 동적 구현 — inspection-config API + 트랜잭션 보강
- inspection-config API 신규: GET /work-orders/{id}/inspection-config
  - 공정 자동 판별 (resolveInspectionProcessType)
  - bending_info 기반 구성품 목록 + gap_points 반환
  - BENDING_GAP_PROFILES 상수 (6개 구성품 간격 기준치)
- createInspectionDocument 트랜잭션 보강
  - DB::transaction() + lockForUpdate() 적용
  - 동시 생성 race condition 방지

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-27 23:18:09 +09:00
e6c02292d2 feat: [quote/quality] Phase 2B 견적 product_code 자동추출 + inspections work_order_id FK
- QuoteService: extractProductCodeFromInputs() 추가, store/update에서 자동 추출
- BackfillQuoteProductCodeCommand: 기존 quotes 25건 product_code 보정
- inspections 테이블에 work_order_id FK 마이그레이션 (nullable, nullOnDelete)
- Inspection↔WorkOrder 양방향 관계 추가
- InspectionService: store/show/index에 work_order_id 처리 + transformToFrontend
- InspectionStoreRequest: work_order_id 검증 규칙 추가
2026-02-27 23:18:09 +09:00
김보곤
1a2350db7d feat: [calendar] 달력 일정 관리 API 구현
- GET /api/v1/calendar-schedules — 연도별 일정 목록 조회
- GET /api/v1/calendar-schedules/stats — 통계 조회
- GET /api/v1/calendar-schedules/{id} — 단건 조회
- POST /api/v1/calendar-schedules — 등록
- PUT /api/v1/calendar-schedules/{id} — 수정
- DELETE /api/v1/calendar-schedules/{id} — 삭제
- POST /api/v1/calendar-schedules/bulk — 대량 등록
2026-02-26 14:29:12 +09:00
김보곤
433f3ee4ad Merge branch 'develop' of http://114.203.209.83:3000/SamProject/sam-api into develop 2026-02-25 14:10:53 +09:00
김보곤
240199af9d chore: [env] .env.example 업데이트 및 .gitignore 정리
- .env.example을 SAM 프로젝트 실제 키 구조로 업데이트
- .gitignore에 !.env.example 예외 추가
- GCS_* 중복 키 제거, Gemini/Claude/Vertex 키 섹션 추가
2026-02-23 10:17:37 +09:00
7eb5825d41 fix(WEB): 입고관리 저장 오류 3건 수정
- FormRequest에 manufacturer, material_no 규칙 추가 (validated()에서 누락 방지)
- store() 시 lot_no 자동 생성 (generateLotNo() 폴백)
- getOrCreateStock()에서 item_code 기반 2차 검색 추가 (unique key 충돌 방지)
  - 동일 item_code, 다른 item_id인 Stock 존재 시 item_id 업데이트
  - SoftDeletes 복원 로직 포함

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-22 04:19:48 +09:00
4f777d8cf9 feat(WEB): 절곡품 선생산→재고적재 Phase 3 - 수주 절곡 재고 확인 API
- OrderService: checkBendingStockForOrder() 메서드 추가
  - order_items에서 item_category='BENDING'인 품목 추출
  - 각 품목의 가용재고/부족수량 계산 후 반환
- OrderController: checkBendingStock() 엔드포인트 추가
- Route: GET /api/v1/orders/{id}/bending-stock

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-22 04:19:47 +09:00
25e21ee6d7 feat(WEB): 절곡품 선생산→재고적재 Phase 2 - 품목 카테고리 필터 추가
- StockController: item_category 파라미터 수용
- StockService: items.item_category 기반 필터링 로직 추가

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-22 04:19:47 +09:00
37424b9cef feat(WEB): 수주 Bulk Delete API + 작업지시 Revert Force 통합
- 수주 일괄 삭제 API 추가 (DELETE /orders/bulk)
  - OrderBulkDeleteRequest (ids, force 검증)
  - force=true: hard delete (운영환경 차단), force=false: soft delete
  - 삭제 불가 건(상태/작업지시/출하) skip 처리 + skipped_ids 반환

- 작업지시 되돌리기 force/운영 모드 분기
  - force=true (개발): 기존 hard delete 로직 유지
  - force=false (운영): 작업지시 cancelled 상태 변경, options에 취소정보 기록, 자재 투입분 재고 역분개, 데이터 보존
  - reason 필수 (운영 모드)

- WorkOrder 모델에 STATUS_CANCELLED 상수 추가

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-22 04:19:47 +09:00
a2dbdae14b fix(WEB): 입고 등록 검증 실패 수정 - Store 규칙 보완 및 상태값 정합성
- StoreReceivingRequest에 receiving_qty, receiving_date, lot_no 규칙 추가
- UpdateReceivingRequest status에 inspection_completed 허용 추가
- ReceivingService store()에 receiving_qty/date/lot_no 저장 처리
- order_qty null 안전 처리, 기본 status를 receiving_pending으로 변경

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-22 04:19:47 +09:00
김보곤
ef33540940 fix: [tax-invoice] ApiResponse::handle() 호출 방식 수정
- named parameter(data:, message:) → callable 콜백 패턴으로 전환
- ApiResponse::handle(fn () => ..., '제목') 형식 적용
- 기존 scaffold 코드의 잘못된 호출 방식 전체 수정
2026-02-21 17:19:18 +09:00
김보곤
3b116c980b feat: [tax-invoice] 바로빌 SOAP 연동 및 공급자 설정 API 추가
- BarobillService HTTP→SOAP 전환 (MNG EtaxController 포팅)
- TI SOAP 클라이언트, callSoap(), buildTaxInvoiceData MNG 형식 적용
- issueTaxInvoice/cancelTaxInvoice/checkNtsSendStatus SOAP 방식
- 공급자 설정 조회/저장 API (GET/PUT /supplier-settings)
- 생성+즉시발행 통합 API (POST /issue-direct)
- SaveSupplierSettingsRequest FormRequest 추가
2026-02-21 17:19:18 +09:00
김보곤
83ddfabd7c fix: [card] 카드 상세 수정/저장 누락 필드 9개 보강
- 마이그레이션: card_type, alias, cvc_encrypted, payment_day, total_limit, used_amount, remaining_limit, is_manual, memo 컬럼 추가
- Card 모델: $fillable, $casts, $hidden 확장 + CVC 암호화/복호화 메서드 추가
- CardService: store(), update() 메서드에 9개 필드 처리 로직 추가
- StoreCardRequest, UpdateCardRequest: 9개 필드 검증 규칙 추가
2026-02-21 17:19:18 +09:00
김보곤
961ab47bac feat: [corporate-card] 법인카드 관리 API 7개 엔드포인트 구현
- CorporateCard 모델 (corporate_cards 테이블)
- CorporateCardService (CRUD + 토글 + 활성 목록)
- CorporateCardController (ApiResponse 패턴)
- Store/Update FormRequest 검증
- 라우트: /api/v1/corporate-cards (index, store, show, update, destroy, toggle, active)
2026-02-21 17:19:18 +09:00
김보곤
fdea1d0244 fix: [bank-account] 계좌 관리 API 누락 필드 8개 보강
- account_type, balance, currency, opened_at, branch_name, memo, sort_order, last_transaction_at 추가
- Model: fillable, casts, hidden, scopes, accessors를 MNG 모델 기준으로 통일
- Service: store/update에 누락 필드 반영
- FormRequest: Store/Update에 검증 규칙 추가
2026-02-21 17:19:18 +09:00
김보곤
b576fe97e8 feat: [barobill] 바로빌 연동 관리 API 7개 엔드포인트 구현
- SOAP 기반 BarobillSoapService 생성 (MNG 코드 포팅)
- BarobillMember, BarobillConfig 모델 생성
- BarobillController 7개 메서드 (login, signup, status, URL 조회)
- FormRequest 검증 클래스 3개 생성
- 라우트 등록 (POST /barobill/login, /signup, GET /status 등)
- i18n 메시지 키 추가 (ko/en)
- config/services.php에 barobill 설정 추가
2026-02-21 17:19:18 +09:00
김보곤
1dd9057540 refactor: [authz] 역할/권한 API 품질 개선
- Validator::make를 FormRequest로 분리 (6개 생성)
- 하드코딩 한글 문자열을 i18n 키로 교체
- RoleMenuPermission 데드코드 제거
- Role 모델 SpatieRole 상속으로 일원화
- 권한 변경 후 캐시 무효화 추가 (AccessService::bumpVersion)
- 미문서화 8개 Swagger 엔드포인트 추가
- 역할/권한 라우트에 perm.map+permission 미들웨어 추가
2026-02-21 17:19:17 +09:00
1429f22f11 fix: 견적 산출 가이드레일 혼합형(mixed) validation 허용
- QuoteBomBulkCalculateRequest: guideRailType, GT에 mixed 추가
- QuoteBomCalculateRequest: GT에 mixed 추가

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-20 10:50:23 +09:00
10b1b26c1b fix: 경동 BOM 계산 수정 및 품목-공정 매핑
- KyungdongFormulaHandler: product_type 자동 추론(item_category 기반), 철재 주자재 EGI코일로 변경, 조인트바 steel 공통 지원
- FormulaEvaluatorService: FG item_category에서 product_type 자동 판별
- MapItemsToProcesses: 경동 품목-공정 매핑 커맨드 정비
- KyungdongItemMasterSeeder: BOM child_item_id code 기반 재매핑
- ItemsBomController: ghost ID 유효성 검증 추가

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-20 10:50:21 +09:00
55270198d4 fix: 견적→수주 변환 시 담당자 정보 누락 수정
- Order::createFromQuote() 잘못된 필드명 수정 (contact_person→contact, delivery_date→completion_date)
- 견적 담당자(manager)를 orders.options.manager_name에 저장
- StoreOrderRequest/UpdateOrderRequest에 options.manager_name 유효성 검증 추가
- WorkOrderService show()에서 salesOrder.options 컬럼 포함하여 담당자 표시

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-20 10:50:13 +09:00
유병철
6f456f2cfd fix: 급여 수당/공제 상세 벨리데이션 규칙 수정 (array → numeric)
- StoreSalaryRequest, UpdateSalaryRequest의 allowance_details.*, deduction_details.* 벨리데이션을 array에서 numeric으로 변경
- 수당/공제 항목은 {항목명: 금액} 구조이므로 값은 숫자가 올바름

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 17:34:57 +09:00
6ac3f0c860 feat: 트리거 감사로그 operation_id 컬럼 추가 및 요청별 UUID 설정
- trigger_audit_logs 테이블에 operation_id(VARCHAR 36) 컬럼 추가
- ix_trig_operation 인덱스 생성 (일괄 롤백 조회용)
- SetAuditSessionVariables 미들웨어에서 요청마다 @sam_operation_id UUID 설정

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 11:22:08 +09:00
adfccc9af0 fix:생산지시 생성 시 다중 담당자(assignee_ids) 저장 누락 수정
- CreateProductionOrderRequest에 assignee_ids 배열 validation 추가
- OrderService::createProductionOrder에 work_order_assignees 저장 로직 추가
- 담당자 유무에 따른 status 분기 (pending/unassigned) 적용

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-13 15:57:39 +09:00
fc4fad6e75 refactor:공정 단계 completion_type 한글→영문 코드 전환
- completion_type 값을 한글(클릭 시 완료)에서 영문 코드(click_complete)로 변환
- FormRequest에 in 검증 규칙 추가 (click_complete, selection_complete, inspection_complete)
- 기존 데이터 마이그레이션 포함

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-13 03:41:41 +09:00
e4c53c7b17 feat:개소별 자재 투입 관리 API 추가
- work_order_material_inputs 테이블 신규 생성 (개소별 자재 투입 추적)
- 개소별 자재 조회/투입/이력/삭제/수정 API 5개 추가
- StockService.increaseToLot: LOT 수량 복원 메서드 추가
- WorkOrderService에 개소별 자재 투입 비즈니스 로직 구현
- WorkOrder, WorkOrderItem 모델에 materialInputs 관계 추가

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-13 03:41:35 +09:00
d730c2d91a feat:FQC 제품검사 문서 일괄생성 API 추가
- POST /v1/documents/bulk-create-fqc: 수주 개소별 제품검사 문서 일괄생성
- GET /v1/documents/fqc-status: 수주별 FQC 진행현황 조회
- BulkCreateFqcRequest FormRequest 추가
- error.php에 no_order_items, already_created 메시지 추가

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-13 03:41:27 +09:00
32cbb1071d Merge remote-tracking branch 'origin/develop' into develop 2026-02-12 14:16:32 +09:00
45dd18dbab feat(API): 작업일지 생성/조회 API 추가
- WorkOrderService: getWorkLogTemplate, getWorkLog, createWorkLog 메서드 추가
- WorkOrderController: 작업일지 3개 엔드포인트 추가
- 라우트: GET work-log-template, GET/POST work-log
- WorkOrder 모델: documents() MorphMany 관계 추가
- i18n: work_log_saved, no_work_log_template 메시지 추가

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-12 09:39:48 +09:00
김보곤
6958be1fd8 feat:E-Sign 전자계약 서명 솔루션 백엔드 구현
- 마이그레이션 4개 (esign_contracts, esign_signers, esign_sign_fields, esign_audit_logs)
- 모델 4개 (EsignContract, EsignSigner, EsignSignField, EsignAuditLog)
- 서비스 4개 (EsignContractService, EsignSignService, EsignPdfService, EsignAuditService)
- 컨트롤러 2개 (EsignContractController, EsignSignController)
- FormRequest 4개 (ContractStore, FieldConfigure, SignSubmit, SignReject)
- Mail 1개 (EsignRequestMail + 이메일 템플릿)
- API 라우트 (인증 계약 관리 + 토큰 기반 서명 프로세스)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-12 07:02:39 +09:00
376348a491 feat(API):자재 투입 LOT 조회 API 및 중간검사 데이터 정규화
- materialInputLots: stock_transactions 기반 투입 LOT 조회 엔드포인트 추가
- createInspectionDocument: 정규화 형식(section_id/column_id/field_key) 지원
- 레거시 형식(section_X_item_Y) 자동 변환 로직 추가

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-12 00:01:25 +09:00
51aad4e522 feat(API): 검사 문서/성적서 연동 개선
- DocumentService: formatTemplateForReact 필드명 정합성 수정 (column_type, sub_labels, section title/image_path)
- WorkOrderService: process.options 로딩, 검사데이터 document_data 변환 로직 추가
- StoreItemInspectionRequest: templateValues 유효성 규칙 추가

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-11 15:58:39 +09:00
8b78d62068 feat(API): 공정 options JSON 컬럼 마이그레이션
- needs_work_log 개별 컬럼 → options JSON 구조로 전환
- StoreProcessRequest, UpdateProcessRequest 유효성 규칙 갱신
- Process 모델 $fillable, $casts 갱신

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-11 15:58:35 +09:00
1d7ef66d19 feat: 작업일지/중간검사 설정을 ProcessStep → Process 레벨로 이동
- Process 모델에 document_template_id, needs_work_log, work_log_template_id 추가
- ProcessStep에서 해당 필드 제거
- WorkOrderService의 검사 관련 3개 메서드(getInspectionTemplate, resolveInspectionDocument, createInspectionDocument) 공정 레벨 참조로 변경
- ProcessService eager loading에 documentTemplate, workLogTemplateRelation 추가
- FormRequest 검증 규칙 이동 (ProcessStep → Process)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-11 09:51:35 +09:00
2d68e5e669 fix: 수주 삭제 시 견적 연결 해제 + 생산지시 공정 매핑 보완
- OrderService::destroy()에서 견적 order_id/status 초기화
- StoreOrderRequest/UpdateOrderRequest에 floor_code, symbol_code, item_code 추가
- createProductionOrder()에 item_code fallback 공정 매핑 추가

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-10 19:03:22 +09:00
6733a431bb feat:중간검사 API 다중단계/resolve/upsert 지원 (Phase 5.1.3)
- getInspectionTemplate: 전체 검사 단계 templates[] 반환 (기존 첫번째만→다중)
- resolveInspectionDocument 신규: step_id 기반 기존 문서 조회 또는 템플릿 반환
- createInspectionDocument 개선: step_id 파라미터, 기존 DRAFT/REJECTED 문서 update 지원
- GET inspection-resolve 라우트 추가

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-10 16:55:29 +09:00
e885b1ca45 feat(API): 중간검사 문서 템플릿 동적 연동 - process_steps ↔ document_templates 연결
- process_steps 테이블에 document_template_id FK 추가 (migration)
- ProcessStep 모델에 documentTemplate BelongsTo 관계 추가
- ProcessStepService에서 documentTemplate eager loading
- StoreProcessStepRequest/UpdateProcessStepRequest에 document_template_id 유효성 검증
- WorkOrderService에 getInspectionTemplate(), createInspectionDocument() 메서드 추가
- WorkOrderController에 inspection-template/inspection-document 엔드포인트 추가
- DocumentService.formatTemplateForReact() 접근자 public으로 변경
- i18n 메시지 키 추가 (inspection_document_created, no_inspection_template)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-10 08:35:57 +09:00
d07bad16df feat:DB 트리거 기반 데이터 변경 추적 시스템 구현
Phase 1: DB 기반 구축
- trigger_audit_logs 테이블 (RANGE 파티셔닝 15개, 3개 인덱스)
- 789개 MySQL AFTER 트리거 (263 테이블 × INSERT/UPDATE/DELETE)
- SetAuditSessionVariables 미들웨어 (@sam_actor_id, @sam_session_info)

Phase 2: 복구 메커니즘
- TriggerAuditLog 모델, TriggerAuditLogService, AuditRollbackService
- 6개 API 엔드포인트 (index, show, stats, history, rollback-preview, rollback)
- FormRequest 검증 (TriggerAuditLogIndexRequest, TriggerAuditRollbackRequest)

Phase 3: 관리 도구
- v_unified_audit VIEW (APP + TRIGGER 통합, COLLATE 처리)
- audit:partitions 커맨드 (파티션 추가/삭제, dry-run)
- audit:triggers 커맨드 (트리거 재생성, 테이블별/전체)
- 월 1회 파티션 자동 관리 스케줄러 등록

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-09 09:17:15 +09:00
ee6794be1a feat: [생산관리] 중간검사 데이터 저장/조회 API 구현
- POST /work-orders/{id}/items/{itemId}/inspection: 품목별 검사 데이터 저장
- GET /work-orders/{id}/inspection-data: 전체 품목 검사 데이터 조회
- GET /work-orders/{id}/inspection-report: 검사 성적서용 데이터 조회
- WorkOrderItem 모델에 getInspectionData/setInspectionData 헬퍼 추가
- StoreItemInspectionRequest FormRequest 생성
- work_order_items.options['inspection_data']에 검사 결과 저장

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-09 09:00:57 +09:00
78851ec04a feat: 테넌트별 채번 규칙 시스템 구현
- numbering_rules 테이블: JSON 패턴 기반 채번 규칙 저장 (tenant별)
- numbering_sequences 테이블: MySQL UPSERT 기반 atomic 시퀀스 관리
- NumberingService: generate/preview/nextSequence 핵심 서비스
- QuoteNumberService: NumberingService 우선, 폴백 QT{YYYYMMDD}{NNNN}
- OrderService: NumberingService 우선 (pair_code 지원), 폴백 ORD{YYYYMMDD}{NNNN}
- StoreOrderRequest: pair_code 필드 추가
- NumberingRuleSeeder: tenant_id=287 견적(KD-PR)/수주(KD-{pairCode}) 규칙

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-07 09:50:52 +09:00