aboutsummaryrefslogtreecommitdiffstats
path: root/src/api
diff options
context:
space:
mode:
authorLibravatar Stefan Malzner <stefan@adlk.io>2019-04-08 15:18:58 +0200
committerLibravatar Stefan Malzner <stefan@adlk.io>2019-04-08 15:18:58 +0200
commitea71fced95a6923926c92ada523840ebdbd0ef64 (patch)
treeed5542a00b12a870fd6c426cad65b6daa797ebd6 /src/api
parentremove console log (diff)
downloadferdium-app-ea71fced95a6923926c92ada523840ebdbd0ef64.tar.gz
ferdium-app-ea71fced95a6923926c92ada523840ebdbd0ef64.tar.zst
ferdium-app-ea71fced95a6923926c92ada523840ebdbd0ef64.zip
Replace invoices & subscription info with links to website
Diffstat (limited to 'src/api')
-rw-r--r--src/api/PaymentApi.js8
-rw-r--r--src/api/server/ServerApi.js17
2 files changed, 0 insertions, 25 deletions
diff --git a/src/api/PaymentApi.js b/src/api/PaymentApi.js
index 3f6bb442e..7325151e9 100644
--- a/src/api/PaymentApi.js
+++ b/src/api/PaymentApi.js
@@ -11,12 +11,4 @@ export default class PaymentApi {
11 getHostedPage(planId) { 11 getHostedPage(planId) {
12 return this.server.getHostedPage(planId); 12 return this.server.getHostedPage(planId);
13 } 13 }
14
15 getDashboardUrl() {
16 return this.server.getPaymentDashboardUrl();
17 }
18
19 getOrders() {
20 return this.server.getSubscriptionOrders();
21 }
22} 14}
diff --git a/src/api/server/ServerApi.js b/src/api/server/ServerApi.js
index bafeef005..f6bc9c283 100644
--- a/src/api/server/ServerApi.js
+++ b/src/api/server/ServerApi.js
@@ -418,23 +418,6 @@ export default class ServerApi {
418 return data; 418 return data;
419 } 419 }
420 420
421 async getPaymentDashboardUrl() {
422 const request = await sendAuthRequest(`${API_URL}/me/billing`);
423 if (!request.ok) throw request;
424 const data = await request.json();
425 debug('ServerApi::getPaymentDashboardUrl resolves', data);
426 return data;
427 }
428
429 async getSubscriptionOrders() {
430 const request = await sendAuthRequest(`${API_URL}/me/subscription`);
431 if (!request.ok) throw request;
432 const data = await request.json();
433 const orders = this._mapOrderModels(data);
434 debug('ServerApi::getSubscriptionOrders resolves', orders);
435 return orders;
436 }
437
438 // News 421 // News
439 async getLatestNews() { 422 async getLatestNews() {
440 const url = `${API_URL}/news?platform=${os.platform()}&arch=${os.arch()}&version=${app.getVersion()}`; 423 const url = `${API_URL}/news?platform=${os.platform()}&arch=${os.arch()}&version=${app.getVersion()}`;