* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
import * as React from 'react';
+import { FormattedMessage } from 'react-intl';
import NavBarNotif from '../../../../components/nav/NavBarNotif';
import RestartForm from '../../../../components/common/RestartForm';
import { dismissErrorMessage, Edition, EditionStatus } from '../../../../api/marketplace';
</span>
{edition &&
edition.key === 'datacenter' && (
- <a
- className="spacer-left"
- href="https://redirect.sonarsource.com/doc/how-to-install-an-edition.html"
- target="_blank">
- {translate('marketplace.how_to_configure_cluster')}
- </a>
+ <span className="little-spacer-left">
+ <FormattedMessage
+ defaultMessage={translate('marketplace.see_documentation_to_enable_cluster')}
+ id="marketplace.see_documentation_to_enable_cluster"
+ values={{
+ url: (
+ <a
+ href="https://redirect.sonarsource.com/doc/data-center-edition.html"
+ target="_blank">
+ {edition.name}
+ </a>
+ )
+ }}
+ />
+ </span>
)}
{!preventRestart && (
<button className="js-restart spacer-left" onClick={this.handleOpenRestart}>
) : (
translate('marketplace.status', editionStatus.installationStatus)
)}
+ <a
+ className="spacer-left"
+ href={
+ edition && edition.key === 'datacenter' ? (
+ 'https://redirect.sonarsource.com/doc/data-center-edition.html'
+ ) : (
+ 'https://redirect.sonarsource.com/doc/how-to-install-an-edition.html'
+ )
+ }
+ target="_blank">
+ {translate('marketplace.how_to_install')}
+ </a>
{edition && (
<a
className="button spacer-left"
{translate('marketplace.download_package')}
</a>
)}
- <a
- className="spacer-left"
- href="https://redirect.sonarsource.com/doc/how-to-install-an-edition.html"
- target="_blank">
- {translate('marketplace.how_to_install')}
- </a>
</NavBarNotif>
);
}
renderStatusAlert() {
- const { editionStatus } = this.props;
- const { currentEditionKey, installationStatus, nextEditionKey } = editionStatus;
+ const { currentEditionKey, installationStatus, nextEditionKey } = this.props.editionStatus;
const nextEdition =
this.props.editions && this.props.editions.find(edition => edition.key === nextEditionKey);
const currentEdition =
expect(wrapper.find('button.js-restart').exists()).toBeFalsy();
});
-it('should a link to cluster documentation for datacenter edition', () => {
+it('should have a link to cluster documentation for datacenter edition', () => {
const editions = [{ key: 'datacenter' }] as any;
const wrapper = shallow(
<SettingsEditionsNotif
setEditionStatus={jest.fn()}
/>
);
- expect(wrapper.find('a').exists()).toBeTruthy();
+ expect(wrapper.find('FormattedMessage').exists()).toBeTruthy();
});
>
marketplace.status_x.MANUAL_IN_PROGRESS.Foo
<a
- className="button spacer-left"
- download="sonarqube-Foo.zip"
- href="download_url"
+ className="spacer-left"
+ href="https://redirect.sonarsource.com/doc/how-to-install-an-edition.html"
target="_blank"
>
- marketplace.download_package
+ marketplace.how_to_install
</a>
<a
- className="spacer-left"
- href="https://redirect.sonarsource.com/doc/how-to-install-an-edition.html"
+ className="button spacer-left"
+ download="sonarqube-Foo.zip"
+ href="download_url"
target="_blank"
>
- marketplace.how_to_install
+ marketplace.download_package
</a>
</NavBarNotif>
`;
*/
import * as React from 'react';
import * as classNames from 'classnames';
+import { FormattedMessage } from 'react-intl';
import { stringify } from 'querystring';
import { debounce } from 'lodash';
import DeferredSpinner from '../../../components/common/DeferredSpinner';
{licenseEdition &&
licenseEdition.key === 'datacenter' &&
previewStatus !== 'NO_INSTALL' && (
- <a
- className="spacer-left"
- href="https://redirect.sonarsource.com/doc/how-to-install-an-edition.html"
- target="_blank">
- {translate('marketplace.how_to_configure_cluster')}
- </a>
+ <span className="little-spacer-left">
+ <FormattedMessage
+ defaultMessage={translate('marketplace.how_to_setup_cluster_url')}
+ id="marketplace.how_to_setup_cluster_url"
+ values={{
+ url: (
+ <a
+ href="https://redirect.sonarsource.com/doc/data-center-edition.html"
+ target="_blank">
+ {licenseEdition.name}
+ </a>
+ )
+ }}
+ />
+ </span>
)}
</p>
);
marketplace.status.AUTOMATIC_IN_PROGRESS=Installing your new Commercial Edition... Please wait...
marketplace.status.AUTOMATIC_READY=Commercial Edition successfully installed. Please restart the server to activate your new edition.
marketplace.status.UNINSTALL_IN_PROGRESS=Commercial Edition successfully downgraded. Please restart the server to remove the features.
-marketplace.status.MANUAL_IN_PROGRESS=Commercial Edition can't automatically be installed because of internet access issues. Please manually install the package in your SonarQube's plugins folder.
+marketplace.status.MANUAL_IN_PROGRESS=Commercial Edition can't automatically be installed because of internet access issues. Please manually install the package.
marketplace.status_x.AUTOMATIC_IN_PROGRESS=Installing your new {0}... Please wait...
marketplace.status_x.AUTOMATIC_READY={0} successfully installed. Please restart the server to activate your new edition.
marketplace.status_x.UNINSTALL_IN_PROGRESS=Successfully downgraded to {0}. Please restart the server to remove the features.
-marketplace.status_x.MANUAL_IN_PROGRESS={0} can't automatically be installed because of internet access issues. Please manually install the package in your SonarQube's plugins folder.
+marketplace.status_x.MANUAL_IN_PROGRESS={0} can't automatically be installed because of internet access issues. Please manually install the package.
marketplace.how_to_install=How to install it?
-marketplace.how_to_configure_cluster=How to configure a cluster?
+marketplace.see_documentation_to_enable_cluster=See {url} documentation to set up a cluster.
+marketplace.how_to_setup_cluster_url=Further setup and configuration are required to get a cluster. See {url} documentation.
marketplace.enter_license_for_x=Enter your license key for {0}
marketplace.wrong_license_type_x=Your license is not compatible with the selected edition. Please provide a valid license for {0}.
marketplace.i_need_a_license=I need a license key