lint.
Этот коммит содержится в:
@@ -63,7 +63,6 @@ const OverageUsersBanner = () => {
|
|||||||
const prefixLicenseId = (license.Id || '').substring(0, 8);
|
const prefixLicenseId = (license.Id || '').substring(0, 8);
|
||||||
const preferenceName = `${prefixPreferences}_overage_seats_${prefixLicenseId}`;
|
const preferenceName = `${prefixPreferences}_overage_seats_${prefixLicenseId}`;
|
||||||
|
|
||||||
|
|
||||||
const overageByUsers = activeUsers - seatsPurchased;
|
const overageByUsers = activeUsers - seatsPurchased;
|
||||||
|
|
||||||
const isOverageState = isBetween5PercerntAnd10PercentPurchasedSeats || isOver10PercerntPurchasedSeats;
|
const isOverageState = isBetween5PercerntAnd10PercentPurchasedSeats || isOver10PercerntPurchasedSeats;
|
||||||
@@ -114,8 +113,7 @@ const OverageUsersBanner = () => {
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const message = (
|
||||||
let message = (
|
|
||||||
<FormattedMessage
|
<FormattedMessage
|
||||||
id='licensingPage.overageUsersBanner.text'
|
id='licensingPage.overageUsersBanner.text'
|
||||||
defaultMessage='Your workspace user count has exceeded your paid license seat count by {seats, number} {seats, plural, one {seat} other {seats}}. Purchase additional seats to remain compliant.'
|
defaultMessage='Your workspace user count has exceeded your paid license seat count by {seats, number} {seats, plural, one {seat} other {seats}}. Purchase additional seats to remain compliant.'
|
||||||
|
|||||||
@@ -16,7 +16,6 @@ import {STORAGE_KEY_EXPANSION_IN_PROGRESS} from 'components/self_hosted_purchase
|
|||||||
import SelfHostedExpansionModal from 'components/self_hosted_purchases/self_hosted_expansion_modal';
|
import SelfHostedExpansionModal from 'components/self_hosted_purchases/self_hosted_expansion_modal';
|
||||||
|
|
||||||
import {useControlModal, ControlModal} from './useControlModal';
|
import {useControlModal, ControlModal} from './useControlModal';
|
||||||
import useCanSelfHostedExpand from './useCanSelfHostedExpand';
|
|
||||||
|
|
||||||
interface HookOptions{
|
interface HookOptions{
|
||||||
trackingLocation?: string;
|
trackingLocation?: string;
|
||||||
@@ -34,7 +33,6 @@ export default function useControlSelfHostedExpansionModal(options: HookOptions)
|
|||||||
return {
|
return {
|
||||||
...controlModal,
|
...controlModal,
|
||||||
open: async () => {
|
open: async () => {
|
||||||
|
|
||||||
const purchaseInProgress = localStorage.getItem(STORAGE_KEY_EXPANSION_IN_PROGRESS) === 'true';
|
const purchaseInProgress = localStorage.getItem(STORAGE_KEY_EXPANSION_IN_PROGRESS) === 'true';
|
||||||
|
|
||||||
// check if user already has an open purchase modal in current browser.
|
// check if user already has an open purchase modal in current browser.
|
||||||
|
|||||||
@@ -4,7 +4,6 @@
|
|||||||
import React from 'react';
|
import React from 'react';
|
||||||
import {FormattedMessage} from 'react-intl';
|
import {FormattedMessage} from 'react-intl';
|
||||||
import {useDispatch, useSelector} from 'react-redux';
|
import {useDispatch, useSelector} from 'react-redux';
|
||||||
import {useHistory} from 'react-router-dom'
|
|
||||||
|
|
||||||
import {getCurrentUser, isCurrentUserSystemAdmin} from 'mattermost-redux/selectors/entities/users';
|
import {getCurrentUser, isCurrentUserSystemAdmin} from 'mattermost-redux/selectors/entities/users';
|
||||||
import {GlobalState} from 'types/store';
|
import {GlobalState} from 'types/store';
|
||||||
@@ -104,15 +103,15 @@ const OverageUsersBannerNotice = () => {
|
|||||||
className='overage_users_banner__button'
|
className='overage_users_banner__button'
|
||||||
href={`${siteURL}/${ConsolePages.LICENSE}?action=show_expansion_modal`}
|
href={`${siteURL}/${ConsolePages.LICENSE}?action=show_expansion_modal`}
|
||||||
rel='noopener noreferrer'
|
rel='noopener noreferrer'
|
||||||
target="_blank"
|
target='_blank'
|
||||||
>
|
>
|
||||||
{chunks}
|
{chunks}
|
||||||
</ExternalLink>
|
</ExternalLink>
|
||||||
)
|
);
|
||||||
}
|
},
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
)
|
);
|
||||||
} else if (!isGovSku) {
|
} else if (!isGovSku) {
|
||||||
message = (
|
message = (
|
||||||
<FormattedMessage
|
<FormattedMessage
|
||||||
|
|||||||
@@ -515,7 +515,7 @@ describe('components/invitation_modal/overage_users_banner_notice', () => {
|
|||||||
};
|
};
|
||||||
store.entities.general.license.IsGovSku = 'true';
|
store.entities.general.license.IsGovSku = 'true';
|
||||||
|
|
||||||
await act( async () => {
|
await act(async () => {
|
||||||
renderComponent({
|
renderComponent({
|
||||||
store,
|
store,
|
||||||
});
|
});
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user