smitajoshi12 commented on code in PR #5176:
URL: https://github.com/apache/ozone/pull/5176#discussion_r1307748063
##########
hadoop-ozone/recon/src/main/resources/webapps/recon/ozone-recon-web/src/components/overviewCard/overviewCard.tsx:
##########
@@ -46,18 +46,31 @@ const defaultProps = {
interface IOverviewCardWrapperProps {
linkToUrl: string;
+ title:string
}
class OverviewCardWrapper extends React.Component<IOverviewCardWrapperProps> {
render() {
const {linkToUrl, children} = this.props;
- if (linkToUrl) {
+ if (linkToUrl ) {
+ if(linkToUrl === '/Om'){
return (
- <Link to={linkToUrl}>
+ <Link to={{
+ pathname: linkToUrl,
+ state: { activeTab: children._owner &&
children._owner.stateNode.props && children._owner.stateNode.props.title ===
"Open Keys Summary"? '2':'3'}
Review Comment:
@dombizita
Yes you are correct zita. If we add another card with a link to /Om to the
Overview page, we can pass currentTab value to another component.
We will use key value pair for below condition if we have to add another tab
will modify this condition accordingly. Will do next PR.
state: { activeTab: children._owner && children._owner.stateNode.props &&
children._owner.stateNode.props.title === "Open Keys Summary"? '2':'3'}
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]