public PrequalifyType(IFlowFinancePaymentService flowFinancePaymentService) { Name = "Prequalify"; Field(b => b.data.cnpj).Description("CNPJ"); Field(b => b.data.eligible).Description("Eligible"); }
public ApplicationResultType(IFlowFinancePaymentService flowFinancePaymentService) { Name = "ApplicationResult"; //Field(b => b.Id).Description("The id of the review."); Field(b => b.error).Description("Error message (if any)"); Field(b => b.success).Description("Success (true/false)"); }
public Mutation(IFlowFinancePaymentService flowFinancePaymentService) { Name = "Mutation"; Field <BooleanGraphType>( "checkPreQualify", arguments: new QueryArguments( new QueryArgument <NonNullGraphType <StringGraphType> > { Name = "cnpj", Description = "pre-qualify" } ), resolve: context => { var cnpj = context.GetArgument <string>("cnpj"); return(flowFinancePaymentService.PreQualify(cnpj)); }); Field <ApplicationResultType>( "processApplication", arguments: new QueryArguments( new QueryArgument <NonNullGraphType <ApplicationInputType> > { Name = "application", Description = "Application Input" }, new QueryArgument <NonNullGraphType <UploadGraphType> > { Name = "businessInfoFile" }, new QueryArgument <NonNullGraphType <UploadGraphType> > { Name = "personalInfoFile" } ), resolve: context => { var applicationInput = context.GetArgument <ApplicationInput>("application"); var businessInfoFile = context.GetArgument <IFormFile>("businessInfoFile"); var personalInfoFile = context.GetArgument <IFormFile>("personalInfoFile"); return(flowFinancePaymentService.ProcessApplication(applicationInput, businessInfoFile, personalInfoFile)); }); }
public Query(IFlowFinancePaymentService flowFinancePaymentService) { Name = "Query"; }
public RoutesController(IFlowFinancePaymentService flowFinancePaymentService, IIOServiceContext context) { this._flowFinancePaymentService = flowFinancePaymentService ?? throw new ArgumentNullException(nameof(flowFinancePaymentService)); this._context = context ?? throw new ArgumentNullException(nameof(context)); }