Commit 262546b7 by zhaochengxiang

服务详情

parent 98c063dc
...@@ -205,6 +205,7 @@ export class App extends React.Component { ...@@ -205,6 +205,7 @@ export class App extends React.Component {
<AppContext.Provider value={{ <AppContext.Provider value={{
env: hostParams?.env, env: hostParams?.env,
user: hostParams?.user, user: hostParams?.user,
openDetail: hostParams?.openDetail,
setGlobalState, setGlobalState,
onGlobalStateChange onGlobalStateChange
}}> }}>
......
...@@ -127,7 +127,13 @@ const FC = React.forwardRef(function ({ item, reference, action }, ref) { ...@@ -127,7 +127,13 @@ const FC = React.forwardRef(function ({ item, reference, action }, ref) {
<Space> <Space>
<a onClick={(e) => { <a onClick={(e) => {
e.stopPropagation(); e.stopPropagation();
app?.openDetail?.({ service: { id: record.relatedServiceId }, isOnlyEnding: true }) app?.setGlobalState && app?.setGlobalState({
message: 'data-govern-show-service-detail',
data: {
id: record.relatedServiceId,
isOnlyEnding: true
}
})
}}> }}>
详情 详情
</a> </a>
......
...@@ -270,7 +270,13 @@ const FC = (props) => { ...@@ -270,7 +270,13 @@ const FC = (props) => {
} }
const onDetailClick = (record) => { const onDetailClick = (record) => {
app?.openDetail?.({ service: record, isOnlyEnding: true }) app?.setGlobalState && app?.setGlobalState({
message: 'data-govern-show-service-detail',
data: {
id: record.id,
isOnlyEnding: true
}
})
} }
return ( return (
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment