결재 템플릿 단계 적용 구현
- ApprovalTemplate 엔티티·DTO·원격 리포지토리 추가 - ApprovalController에 템플릿 로딩/적용 상태와 assignSteps 호출 연동 - ApprovalPage 단계 탭에 템플릿 선택 UI 및 적용 확인 다이얼로그 구현 - 템플릿 적용 단위 테스트와 IMPLEMENTATION_TASKS 현황 갱신
This commit is contained in:
@@ -0,0 +1,39 @@
|
||||
import 'package:superport_v2/core/common/models/paginated_result.dart';
|
||||
|
||||
import '../entities/approval.dart';
|
||||
|
||||
abstract class ApprovalRepository {
|
||||
Future<PaginatedResult<Approval>> list({
|
||||
int page = 1,
|
||||
int pageSize = 20,
|
||||
String? query,
|
||||
String? status,
|
||||
DateTime? from,
|
||||
DateTime? to,
|
||||
bool includeHistories = false,
|
||||
bool includeSteps = false,
|
||||
});
|
||||
|
||||
Future<Approval> fetchDetail(
|
||||
int id, {
|
||||
bool includeSteps = true,
|
||||
bool includeHistories = true,
|
||||
});
|
||||
|
||||
/// 활성화된 결재 행위(approve/reject/comment 등) 목록 조회
|
||||
Future<List<ApprovalAction>> listActions({bool activeOnly = true});
|
||||
|
||||
/// 결재 단계에 행위를 적용하고 최신 결재 정보를 반환
|
||||
Future<Approval> performStepAction(ApprovalStepActionInput input);
|
||||
|
||||
/// 결재 단계 일괄 생성/재배치
|
||||
Future<Approval> assignSteps(ApprovalStepAssignmentInput input);
|
||||
|
||||
Future<Approval> create(ApprovalInput input);
|
||||
|
||||
Future<Approval> update(int id, ApprovalInput input);
|
||||
|
||||
Future<void> delete(int id);
|
||||
|
||||
Future<Approval> restore(int id);
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
import '../entities/approval_template.dart';
|
||||
|
||||
abstract class ApprovalTemplateRepository {
|
||||
Future<List<ApprovalTemplate>> list({bool activeOnly = true});
|
||||
|
||||
Future<ApprovalTemplate> fetchDetail(int id, {bool includeSteps = true});
|
||||
}
|
||||
Reference in New Issue
Block a user