using CashLineERP.Contracts.IslamicFinance;

namespace CashLineERP.Application.IslamicFinance.Requests;

public interface IIslamicFinanceRequestService
{
    IReadOnlyCollection<IslamicFinanceFinancingRequestResponse> GetRequests(
        string? statusCode = null,
        long? customerPartyId = null,
        long? productProfileId = null);

    IslamicFinanceFinancingRequestResponse? GetRequest(long financingRequestId);
    IslamicFinanceFinancingRequestResponse CreateRequest(CreateIslamicFinanceFinancingRequestRequest request);
    IslamicFinanceFinancingRequestResponse SubmitRequest(long financingRequestId, long actorUserId);
    IslamicFinanceFinancingRequestResponse ApproveRequest(long financingRequestId, long actorUserId);
    IslamicFinanceFinancingRequestResponse ReturnRequest(long financingRequestId, long actorUserId);
    IslamicFinanceFinancingRequestResponse RejectRequest(long financingRequestId, long actorUserId);
    IslamicFinanceFinancingRequestResponse AssignPartnerLender(
        long financingRequestId,
        AssignIslamicFinancePartnerLenderRequest request,
        long actorUserId);
    IslamicFinancePartnerOrchestrationResponse RoutePartnerLenders(long financingRequestId, long actorUserId);
    IslamicFinanceFinancingRequestResponse SelectOffer(long financingRequestId, long financingDecisionId, long actorUserId);
    IslamicFinanceOfficerWorkbenchResponse GetOfficerWorkbench();
    IslamicFinanceExecutionWorkbenchResponse GetExecutionWorkbench();
    IslamicFinancePartnerOrchestrationResponse? GetPartnerOrchestration(long financingRequestId);
    IReadOnlyCollection<IslamicFinanceRequestHistoryEntryResponse> GetRequestHistory(long financingRequestId);
    IslamicFinanceRequestAuditResponse? GetRequestAudit(long financingRequestId);
    IReadOnlyCollection<IslamicFinanceDecisionResponse> GetDecisions(long financingRequestId);
    IslamicFinanceDecisionResponse? GetDecision(long financingDecisionId);
    IslamicFinanceDecisionAuditResponse? GetDecisionAudit(long financingDecisionId);
    IslamicFinanceDecisionResponse CreateDecision(long financingRequestId, CreateIslamicFinanceDecisionRequest request);
    IslamicFinanceDecisionResponse SubmitDecision(long financingDecisionId, long actorUserId);
    IslamicFinanceDecisionResponse ApproveDecision(long financingDecisionId, long actorUserId);
    IslamicFinanceDecisionResponse ReturnDecision(long financingDecisionId, long actorUserId);
    IslamicFinanceDecisionResponse RejectDecision(long financingDecisionId, long actorUserId);
    IslamicFinanceFinancingRequestResponse AttachShariahReview(
        long financingRequestId,
        AttachIslamicFinanceShariahReviewRequest request,
        long actorUserId);
}
