Skip to content
This repository has been archived by the owner on Mar 13, 2024. It is now read-only.

Commit

Permalink
MM-40218 - start trial from team edition, do upgrade and request lice…
Browse files Browse the repository at this point in the history
…nse (#9454)

* MM-40218 - start trial from team edition, do upgrade and request license

* add i18n texts

* fix snapshots

* show restarting text and define which button was clicked

* prevent the preference to get saved

* hide the update and request trial banner if normal button is clicked

* fix tests and snapshots

Co-authored-by: Pablo Velez Vidal <pablo.velez@mattermost.com>
  • Loading branch information
pvev and pvev authored Dec 21, 2021
1 parent dda6842 commit 3f9d6da
Show file tree
Hide file tree
Showing 7 changed files with 387 additions and 269 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ exports[`components/admin_console/license_settings/LicenseSettings load screen a
openEEModal={[Function]}
restartError={null}
restarting={false}
setClickNormalUpgradeBtn={[Function]}
upgradeError={null}
upgradingPercentage={100}
/>
Expand Down Expand Up @@ -212,6 +213,7 @@ exports[`components/admin_console/license_settings/LicenseSettings load screen w
openEEModal={[Function]}
restartError={null}
restarting={false}
setClickNormalUpgradeBtn={[Function]}
upgradeError={null}
upgradingPercentage={42}
/>
Expand Down Expand Up @@ -254,52 +256,19 @@ exports[`components/admin_console/license_settings/LicenseSettings should match
<div
className="admin-console__banner_section"
>
<AlertBanner
message={
<div
className="banner-start-trial"
>
<p
className="license-trial-legal-terms"
>
<Memo(MemoizedFormattedMessage)
defaultMessage="Experience Mattermost Enterprise Edition for free for the next 30 days. No obligation to buy or credit card required. "
id="admin.license.trial-request.title"
/>
<injectIntl(FormattedMarkdownMessage)
defaultMessage="By clicking **Start trial**, I agree to the [Mattermost Software Evaluation Agreement](!https://mattermost.com/software-evaluation-agreement/), [Privacy Policy](!https://mattermost.com/privacy-policy/), and receiving product emails."
id="admin.license.trial-request.accept-terms"
/>
</p>
<div
className="trial"
>
<button
className="btn btn-primary"
disabled={false}
onClick={[Function]}
type="button"
>
<LoadingWrapper
loading={false}
text="Getting trial"
>
<Memo(MemoizedFormattedMessage)
defaultMessage="Start trial"
id="admin.license.trial-request.submit"
/>
</LoadingWrapper>
</button>
</div>
</div>
}
mode="info"
title={
<Memo(MemoizedFormattedMessage)
defaultMessage="Free 30 day trial!"
id="licensingPage.infoBanner.startTrialTitle"
/>
}
<TrialBanner
enterpriseReady={true}
gettingTrial={false}
gettingTrialError={null}
handleRestart={[Function]}
handleUpgrade={[Function]}
isDisabled={false}
openEEModal={[Function]}
requestLicense={[Function]}
restartError={null}
restarting={false}
upgradeError={null}
upgradingPercentage={0}
/>
</div>
<div
Expand Down Expand Up @@ -1282,52 +1251,19 @@ exports[`components/admin_console/license_settings/LicenseSettings should match
<div
className="admin-console__banner_section"
>
<AlertBanner
message={
<div
className="banner-start-trial"
>
<p
className="license-trial-legal-terms"
>
<Memo(MemoizedFormattedMessage)
defaultMessage="Experience Mattermost Enterprise Edition for free for the next 30 days. No obligation to buy or credit card required. "
id="admin.license.trial-request.title"
/>
<injectIntl(FormattedMarkdownMessage)
defaultMessage="By clicking **Start trial**, I agree to the [Mattermost Software Evaluation Agreement](!https://mattermost.com/software-evaluation-agreement/), [Privacy Policy](!https://mattermost.com/privacy-policy/), and receiving product emails."
id="admin.license.trial-request.accept-terms"
/>
</p>
<div
className="trial"
>
<button
className="btn btn-primary"
disabled={false}
onClick={[Function]}
type="button"
>
<LoadingWrapper
loading={false}
text="Getting trial"
>
<Memo(MemoizedFormattedMessage)
defaultMessage="Start trial"
id="admin.license.trial-request.submit"
/>
</LoadingWrapper>
</button>
</div>
</div>
}
mode="info"
title={
<Memo(MemoizedFormattedMessage)
defaultMessage="Free 30 day trial!"
id="licensingPage.infoBanner.startTrialTitle"
/>
}
<TrialBanner
enterpriseReady={true}
gettingTrial={false}
gettingTrialError={null}
handleRestart={[Function]}
handleUpgrade={[Function]}
isDisabled={false}
openEEModal={[Function]}
requestLicense={[Function]}
restartError={null}
restarting={false}
upgradeError={null}
upgradingPercentage={0}
/>
</div>
<div
Expand Down Expand Up @@ -1435,52 +1371,19 @@ exports[`components/admin_console/license_settings/LicenseSettings should match
<div
className="admin-console__banner_section"
>
<AlertBanner
message={
<div
className="banner-start-trial"
>
<p
className="license-trial-legal-terms"
>
<Memo(MemoizedFormattedMessage)
defaultMessage="Experience Mattermost Enterprise Edition for free for the next 30 days. No obligation to buy or credit card required. "
id="admin.license.trial-request.title"
/>
<injectIntl(FormattedMarkdownMessage)
defaultMessage="By clicking **Start trial**, I agree to the [Mattermost Software Evaluation Agreement](!https://mattermost.com/software-evaluation-agreement/), [Privacy Policy](!https://mattermost.com/privacy-policy/), and receiving product emails."
id="admin.license.trial-request.accept-terms"
/>
</p>
<div
className="trial"
>
<button
className="btn btn-primary"
disabled={false}
onClick={[Function]}
type="button"
>
<LoadingWrapper
loading={false}
text="Getting trial"
>
<Memo(MemoizedFormattedMessage)
defaultMessage="Start trial"
id="admin.license.trial-request.submit"
/>
</LoadingWrapper>
</button>
</div>
</div>
}
mode="info"
title={
<Memo(MemoizedFormattedMessage)
defaultMessage="Free 30 day trial!"
id="licensingPage.infoBanner.startTrialTitle"
/>
}
<TrialBanner
enterpriseReady={true}
gettingTrial={false}
gettingTrialError={null}
handleRestart={[Function]}
handleUpgrade={[Function]}
isDisabled={false}
openEEModal={[Function]}
requestLicense={[Function]}
restartError={null}
restarting={false}
upgradeError={null}
upgradingPercentage={0}
/>
</div>
<div
Expand Down Expand Up @@ -1664,6 +1567,7 @@ exports[`components/admin_console/license_settings/LicenseSettings should match
openEEModal={[Function]}
restartError={null}
restarting={false}
setClickNormalUpgradeBtn={[Function]}
upgradeError={null}
upgradingPercentage={0}
/>
Expand Down Expand Up @@ -1705,7 +1609,22 @@ exports[`components/admin_console/license_settings/LicenseSettings should match
>
<div
className="admin-console__banner_section"
/>
>
<TrialBanner
enterpriseReady={false}
gettingTrial={false}
gettingTrialError={null}
handleRestart={[Function]}
handleUpgrade={[Function]}
isDisabled={false}
openEEModal={[Function]}
requestLicense={[Function]}
restartError={null}
restarting={false}
upgradeError={null}
upgradingPercentage={0}
/>
</div>
<div
className="top-wrapper"
>
Expand Down Expand Up @@ -1764,6 +1683,7 @@ exports[`components/admin_console/license_settings/LicenseSettings should match
openEEModal={[Function]}
restartError={null}
restarting={false}
setClickNormalUpgradeBtn={[Function]}
upgradeError={null}
upgradingPercentage={0}
/>
Expand Down
Loading

0 comments on commit 3f9d6da

Please sign in to comment.