Skip to content

Commit

Permalink
Merge pull request alibaba#905 from loadchange/fe/v1.0
Browse files Browse the repository at this point in the history
Fix: ServiceDetail groupName
  • Loading branch information
Fury Zhu authored Mar 15, 2019
2 parents 01feb23 + a3406a0 commit 5d66857
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ class ServiceDetail extends React.Component {
this.editClusterDialog = React.createRef();
this.state = {
serviceName: getParameter(props.location.search, 'name'),
groupName: getParameter(props.location.search, 'groupName'),
loading: false,
currentPage: 1,
clusters: [],
Expand All @@ -64,9 +65,9 @@ class ServiceDetail extends React.Component {
}

getServiceDetail() {
const { serviceName } = this.state;
const { serviceName, groupName } = this.state;
request({
url: `v1/ns/catalog/service?serviceName=${serviceName}`,
url: `v1/ns/catalog/service?serviceName=${serviceName}&groupName=${groupName}`,
beforeSend: () => this.openLoading(),
success: ({ clusters = [], service = {} }) => this.setState({ service, clusters }),
error: e => Message.error(e.responseText || 'error'),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,9 @@ class ServiceList extends React.Component {
<Button
type="normal"
onClick={() =>
this.props.history.push(`/serviceDetail?name=${record.name}`)
this.props.history.push(
`/serviceDetail?name=${record.name}&groupName=${record.groupName}`
)
}
>
{detail}
Expand Down
8 changes: 4 additions & 4 deletions console/src/main/resources/static/js/main.js

Large diffs are not rendered by default.

0 comments on commit 5d66857

Please sign in to comment.