Move mollie code ( srvice ) uit farmmapslib halen ( is open source ), naar farmmaps
All checks were successful
FarmMaps.Develop/FarmMapsLib/pipeline/head This commit looks good
All checks were successful
FarmMaps.Develop/FarmMapsLib/pipeline/head This commit looks good
This commit is contained in:
@@ -1,27 +0,0 @@
|
||||
import { Injectable } from '@angular/core';
|
||||
import { HttpClient } from "@angular/common/http";
|
||||
import { AppConfig } from "../shared/app.config";
|
||||
import { Observable } from 'rxjs';
|
||||
import { IMolliePaymentResponse } from '../models/mollie.payment.response';
|
||||
import { IMolliePaymentRequest } from '../models/mollie.payment.request';
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root',
|
||||
})
|
||||
|
||||
export class MollieService {
|
||||
constructor(
|
||||
public httpClient: HttpClient,
|
||||
public appConfig: AppConfig) {
|
||||
}
|
||||
|
||||
ApiEndpoint() {
|
||||
return this.appConfig.getConfig("apiEndPoint");
|
||||
}
|
||||
|
||||
createMolliePayment(paymentRequest: IMolliePaymentRequest): Observable<IMolliePaymentResponse> {
|
||||
return this.httpClient.post<IMolliePaymentResponse>(
|
||||
`${this.ApiEndpoint()}/api/v1/payments/create`,
|
||||
paymentRequest);
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user