lint.
Этот коммит содержится в:
@@ -209,4 +209,4 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -19,10 +19,7 @@ import FullScreenModal from 'components/widgets/modals/full_screen_modal';
|
|||||||
import Input from 'components/widgets/inputs/input/input';
|
import Input from 'components/widgets/inputs/input/input';
|
||||||
|
|
||||||
import BackgroundSvg from 'components/common/svg_images_components/background_svg';
|
import BackgroundSvg from 'components/common/svg_images_components/background_svg';
|
||||||
import {COUNTRIES} from 'utils/countries';
|
|
||||||
import StateSelector from 'components/payment_form/state_selector';
|
|
||||||
import {getTheme} from 'mattermost-redux/selectors/entities/preferences';
|
import {getTheme} from 'mattermost-redux/selectors/entities/preferences';
|
||||||
import DropdownInput from 'components/dropdown_input';
|
|
||||||
import StripeProvider from '../self_hosted_purchase_modal/stripe_provider';
|
import StripeProvider from '../self_hosted_purchase_modal/stripe_provider';
|
||||||
|
|
||||||
import {closeModal} from 'actions/views/modals';
|
import {closeModal} from 'actions/views/modals';
|
||||||
@@ -124,11 +121,11 @@ export function canSubmit(formState: FormState, progress: ValueOf<typeof SelfHos
|
|||||||
|
|
||||||
const validShippingAddress = Boolean(
|
const validShippingAddress = Boolean(
|
||||||
formState.shippingSame ||
|
formState.shippingSame ||
|
||||||
formState.shippingAddress &&
|
(formState.shippingAddress &&
|
||||||
formState.shippingCity &&
|
formState.shippingCity &&
|
||||||
formState.shippingState &&
|
formState.shippingState &&
|
||||||
formState.shippingPostalCode &&
|
formState.shippingPostalCode &&
|
||||||
formState.shippingCountry,
|
formState.shippingCountry),
|
||||||
);
|
);
|
||||||
|
|
||||||
const agreedToTerms = formState.agreedTerms;
|
const agreedToTerms = formState.agreedTerms;
|
||||||
@@ -140,28 +137,28 @@ export function canSubmit(formState: FormState, progress: ValueOf<typeof SelfHos
|
|||||||
const validSeats = formState.seats > 0;
|
const validSeats = formState.seats > 0;
|
||||||
|
|
||||||
switch (progress) {
|
switch (progress) {
|
||||||
case SelfHostedSignupProgress.PAID:
|
case SelfHostedSignupProgress.PAID:
|
||||||
case SelfHostedSignupProgress.CREATED_LICENSE:
|
case SelfHostedSignupProgress.CREATED_LICENSE:
|
||||||
case SelfHostedSignupProgress.CREATED_SUBSCRIPTION:
|
case SelfHostedSignupProgress.CREATED_SUBSCRIPTION:
|
||||||
return true;
|
return true;
|
||||||
case SelfHostedSignupProgress.CONFIRMED_INTENT: {
|
case SelfHostedSignupProgress.CONFIRMED_INTENT: {
|
||||||
return Boolean(
|
return Boolean(
|
||||||
validAddress && validShippingAddress && validSeats && agreedToTerms
|
validAddress && validShippingAddress && validSeats && agreedToTerms,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
case SelfHostedSignupProgress.START:
|
case SelfHostedSignupProgress.START:
|
||||||
case SelfHostedSignupProgress.CREATED_CUSTOMER:
|
case SelfHostedSignupProgress.CREATED_CUSTOMER:
|
||||||
case SelfHostedSignupProgress.CREATED_INTENT:
|
case SelfHostedSignupProgress.CREATED_INTENT:
|
||||||
return Boolean(
|
return Boolean(
|
||||||
validCard &&
|
validCard &&
|
||||||
validAddress &&
|
validAddress &&
|
||||||
validShippingAddress &&
|
validShippingAddress &&
|
||||||
validSeats &&
|
validSeats &&
|
||||||
agreedToTerms
|
agreedToTerms,
|
||||||
);
|
);
|
||||||
default: {
|
default: {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -273,7 +270,7 @@ export default function SelfHostedExpansionModal() {
|
|||||||
submitProgress,
|
submitProgress,
|
||||||
{
|
{
|
||||||
seats: formState.seats,
|
seats: formState.seats,
|
||||||
license_id: license.ID,
|
license_id: license.Id,
|
||||||
},
|
},
|
||||||
));
|
));
|
||||||
|
|
||||||
|
|||||||
@@ -3,7 +3,6 @@
|
|||||||
|
|
||||||
.form-view {
|
.form-view {
|
||||||
display: flex;
|
display: flex;
|
||||||
overflow-x: hidden;
|
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
@@ -16,6 +15,7 @@
|
|||||||
font-family: "Open Sans";
|
font-family: "Open Sans";
|
||||||
font-size: 16px;
|
font-size: 16px;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
|
overflow-x: hidden;
|
||||||
|
|
||||||
.title {
|
.title {
|
||||||
font-size: 22px;
|
font-size: 22px;
|
||||||
|
|||||||
@@ -3896,7 +3896,7 @@ export default class Client4 {
|
|||||||
confirmSelfHostedExpansion = (setupIntentId: string, expandRequest: SelfHostedExpansionRequest) => {
|
confirmSelfHostedExpansion = (setupIntentId: string, expandRequest: SelfHostedExpansionRequest) => {
|
||||||
return this.doFetch<SelfHostedSignupSuccessResponse>(
|
return this.doFetch<SelfHostedSignupSuccessResponse>(
|
||||||
`${this.getHostedCustomerRoute()}/confirm?expand=true`,
|
`${this.getHostedCustomerRoute()}/confirm?expand=true`,
|
||||||
{method: 'post', body: JSON.stringify({stripe_setup_intent_id: setupIntentId, subscription: expandRequest})},
|
{method: 'post', body: JSON.stringify({stripe_setup_intent_id: setupIntentId, expand_request: expandRequest})},
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user