From 75b357a0694601ab2c94f5bf96272ec9dc04aead Mon Sep 17 00:00:00 2001
From: Jai Agrawal <18202329+Geometrically@users.noreply.github.com>
Date: Fri, 17 Jan 2025 16:41:49 -0800
Subject: [PATCH] Staff support dashboard routes (#3160)
* Staff support dashboard routes
* Fix clippy
---
.../frontend/src/pages/admin/billing/[id].vue | 210 ++++++++++++++++++
.../src/pages/settings/billing/charges.vue | 18 +-
apps/frontend/src/pages/user/[id].vue | 89 +++++++-
.../src/database/models/loader_fields.rs | 7 +-
apps/labrinth/src/routes/internal/billing.rs | 38 +++-
apps/labrinth/src/routes/v2/users.rs | 4 +-
.../src/routes/v3/project_creation.rs | 4 -
apps/labrinth/src/routes/v3/users.rs | 21 +-
.../src/routes/v3/version_creation.rs | 16 +-
9 files changed, 371 insertions(+), 36 deletions(-)
create mode 100644 apps/frontend/src/pages/admin/billing/[id].vue
diff --git a/apps/frontend/src/pages/admin/billing/[id].vue b/apps/frontend/src/pages/admin/billing/[id].vue
new file mode 100644
index 000000000..c5c72b5d4
--- /dev/null
+++ b/apps/frontend/src/pages/admin/billing/[id].vue
@@ -0,0 +1,210 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ (unprovision = !unprovision)"
+ />
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/apps/frontend/src/pages/settings/billing/charges.vue b/apps/frontend/src/pages/settings/billing/charges.vue
index c1195d2a4..a4c8eddc1 100644
--- a/apps/frontend/src/pages/settings/billing/charges.vue
+++ b/apps/frontend/src/pages/settings/billing/charges.vue
@@ -25,7 +25,7 @@
⋅
- {{ formatPrice(charge.amount, charge.currency_code) }}
+ {{ formatPrice(vintl.locale, charge.amount, charge.currency_code) }}
@@ -39,6 +39,7 @@
diff --git a/apps/frontend/src/pages/user/[id].vue b/apps/frontend/src/pages/user/[id].vue
index fe48a8485..14c1af888 100644
--- a/apps/frontend/src/pages/user/[id].vue
+++ b/apps/frontend/src/pages/user/[id].vue
@@ -2,6 +2,57 @@
+
+
+
+
Email
+
+
+ {{ user.email }}
+
+
+
+
+
+
+
+ Auth providers
+ {{ user.auth_providers.join(", ") }}
+
+
+
+ Payment methods
+
+
+ Paypal ({{ user.payout_data.paypal_address }} - {{ user.payout_data.paypal_country }})
+
+
+ ,
+
+
+ Venmo ({{ user.payout_data.venmo_address }})
+
+
+
+
+
+ Has password
+
+ {{ user.has_password ? "Yes" : "No" }}
+
+
+
+
+ Has TOTP
+
+ {{ user.has_totp ? "Yes" : "No" }}
+
+
+
+