This commit is contained in:
sylor_huang@126.com 2020-08-15 15:14:32 +08:00
parent 3e2d89724a
commit 7d315ebc47
1 changed files with 3 additions and 3 deletions

View File

@ -132,7 +132,7 @@ class NewMerge extends Component {
merge_head: is_fork_id,
data: {
is_original: is_fork_id,
fork_project_id: is_fork_id ? project_id : "",
fork_project_id: is_fork_id ? id : "",
merge_user_login: is_fork_id ? projects_names[0].project_user_login : undefined
}
})
@ -146,13 +146,13 @@ class NewMerge extends Component {
ischeckmerge = () => {
this.setState({ isSpin: true });
const { projectsId , owner } = this.props.match.params;
const { pull, merge, project_id, merge_head } = this.state;
const { pull, merge, project_id, merge_head, id } = this.state;
const url = `/${owner}/${projectsId}/pulls/check_can_merge.json`;
axios.post(url, {
head: pull,
base: merge,
is_original: merge_head,
fork_project_id: merge_head ? project_id : undefined
fork_project_id: merge_head ? id : undefined
})
.then((result) => {
if (result) {