Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refs #29796 - statistics extraction warning
(cherry picked from commit f7b79cd)
- Loading branch information
1 parent
ca2560a
commit 3e7eada
Showing
12 changed files
with
78 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<%= alert :class => 'alert-warning', :header => _("This functionality is deprecated"), | ||
:text => ("and will be removed in version 2.2. "\ | ||
"If you wish continue using it, you will need to install the Foreman Statistics plugin when upgrading to 2.2. " + | ||
link_to('Join discussion', external_link_path(type: 'forums', post: 't/trends-and-statistics-plugin/18745'), :target => '_blank') | ||
).html_safe %> |
4 changes: 4 additions & 0 deletions
4
.../assets/javascripts/react_app/routes/Statistics/StatisticsPage/StatisticsPage.fixtures.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 16 additions & 1 deletion
17
webpack/assets/javascripts/react_app/routes/Statistics/StatisticsPage/StatisticsPage.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,36 @@ | ||
import React from 'react'; | ||
import PropTypes from 'prop-types'; | ||
import { Alert } from 'patternfly-react'; | ||
import PageLayout from '../../common/PageLayout/PageLayout'; | ||
import Statistics from './Statistics/Statistics'; | ||
import { translate as __ } from '../../../common/I18n'; | ||
|
||
const StatisticsPage = ({ statisticsMeta, ...props }) => ( | ||
const StatisticsPage = ({ statisticsMeta, discussionUrl, ...props }) => ( | ||
<PageLayout header={__('Statistics')} searchable={false}> | ||
<Alert type="warning"> | ||
<span className="pficon pficon-warning-triangle-o" /> | ||
<strong>This functionality is deprecated </strong> | ||
<span className="text"> | ||
and will be removed in version 2.2. If you wish continue using it, you | ||
will need to install the Foreman Statistics plugin when upgrading to | ||
2.2. | ||
<a href={discussionUrl} target="_blank" rel="noreferrer"> | ||
Join discussion | ||
</a> | ||
</span> | ||
</Alert> | ||
<Statistics statisticsMeta={statisticsMeta} {...props} /> | ||
</PageLayout> | ||
); | ||
|
||
StatisticsPage.propTypes = { | ||
statisticsMeta: PropTypes.array, | ||
discussionUrl: PropTypes.string, | ||
}; | ||
|
||
StatisticsPage.defaultProps = { | ||
statisticsMeta: [], | ||
discussionUrl: '', | ||
}; | ||
|
||
export default StatisticsPage; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters