From bb8ba56c7254cd914c07dee15e8e22e4ff1298a9 Mon Sep 17 00:00:00 2001 From: Jan Cizmar Date: Tue, 25 Feb 2025 17:42:56 +0100 Subject: [PATCH] feat: UI for creating cloud plan > first piece --- .run/Frontend localhost.run.xml | 4 +- e2e/cypress/support/dataCyType.d.ts | 4 +- .../src/constants/GlobalValidationSchema.tsx | 6 +- .../AdministrationEePlanCreateView.tsx | 1 + .../components/planForm/CloudPlanFormBase.tsx | 3 + .../components/planForm/EePlanForm.tsx | 46 +- .../planForm/fields/CloudPlanFields.tsx | 138 +-- .../fields/CloudPlanIncludedUsage.tsx | 79 ++ .../fields/CloudPlanMetricTypeSelectField.tsx | 50 + .../planForm/fields/CloudPlanPrices.tsx | 69 +- .../fields/CloudPlanPricesAndLimits.tsx | 41 +- .../fields/CloudPlanTypeSelectField.tsx | 56 + .../fields/PlanEnabledFeaturesField.tsx | 60 ++ .../fields/StripeProductSelectField.tsx | 54 + .../planForm/getCloudPlanInitialValues.ts | 10 +- .../planForm/useCloudPlanFormValues.ts | 12 + webapp/src/service/apiSchema.generated.ts | 22 +- .../src/service/billingApiSchema.generated.ts | 967 +++--------------- 18 files changed, 547 insertions(+), 1075 deletions(-) create mode 100644 webapp/src/ee/billing/administration/subscriptionPlans/components/planForm/fields/CloudPlanIncludedUsage.tsx create mode 100644 webapp/src/ee/billing/administration/subscriptionPlans/components/planForm/fields/CloudPlanMetricTypeSelectField.tsx create mode 100644 webapp/src/ee/billing/administration/subscriptionPlans/components/planForm/fields/CloudPlanTypeSelectField.tsx create mode 100644 webapp/src/ee/billing/administration/subscriptionPlans/components/planForm/fields/PlanEnabledFeaturesField.tsx create mode 100644 webapp/src/ee/billing/administration/subscriptionPlans/components/planForm/fields/StripeProductSelectField.tsx create mode 100644 webapp/src/ee/billing/administration/subscriptionPlans/components/planForm/useCloudPlanFormValues.ts diff --git a/.run/Frontend localhost.run.xml b/.run/Frontend localhost.run.xml index 7dc8b2b7db..cd78cf5baa 100644 --- a/.run/Frontend localhost.run.xml +++ b/.run/Frontend localhost.run.xml @@ -1,6 +1,6 @@ - +