Commit 1fca3c43 by zhaochengxiang

冲突详情问题

parent 53161aa0
...@@ -3,7 +3,7 @@ import { Modal } from 'antd' ...@@ -3,7 +3,7 @@ import { Modal } from 'antd'
import { dispatch } from '../../../../model' import { dispatch } from '../../../../model'
import Table from '../../../../util/Component/Table' import Table from '../../../../util/Component/Table'
import BranchModelSync from '../../Model/Component/branch-model-sync' import MergeToMaster from './merge-to-master'
const FC = ({ visible, item, onCancel }) => { const FC = ({ visible, item, onCancel }) => {
const [loading, setLoading] = React.useState(false) const [loading, setLoading] = React.useState(false)
...@@ -11,9 +11,9 @@ const FC = ({ visible, item, onCancel }) => { ...@@ -11,9 +11,9 @@ const FC = ({ visible, item, onCancel }) => {
const [animating, setAnimating] = React.useState(true) const [animating, setAnimating] = React.useState(true)
const [branchModelSyncParams, setBranchModelSyncParams] = React.useState({ const [mergeToMasterParams, setMergeToMasterParams] = React.useState({
visible: false, visible: false,
item: undefined, items: undefined,
}); });
React.useEffect(() => { React.useEffect(() => {
...@@ -67,9 +67,9 @@ const FC = ({ visible, item, onCancel }) => { ...@@ -67,9 +67,9 @@ const FC = ({ visible, item, onCancel }) => {
const onRightMenuItemClick = (key, record) => { const onRightMenuItemClick = (key, record) => {
if (key === '冲突详情') { if (key === '冲突详情') {
setBranchModelSyncParams({ setMergeToMasterParams({
visible: true, visible: true,
item: {...record, forkedName: item?.name, forkedLastModifiedTs: item?.modifiedTs} items: [{...record, forkedName: item?.name, forkedLastModifiedTs: item?.modifiedTs}]
}) })
} }
} }
...@@ -104,13 +104,13 @@ const FC = ({ visible, item, onCancel }) => { ...@@ -104,13 +104,13 @@ const FC = ({ visible, item, onCancel }) => {
/> />
} }
</Modal> </Modal>
<BranchModelSync <MergeToMaster
title='冲突详情' title='冲突详情'
{...branchModelSyncParams} {...mergeToMasterParams}
onCancel={(refresh) => { onCancel={(refresh) => {
setBranchModelSyncParams({ setMergeToMasterParams({
visible: false, visible: false,
item: undefined, items: undefined,
}) })
}} }}
/> />
......
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