Browse Source

新增:返回branch_id保存

pull/347/head
yystopf 2 years ago
parent
commit
831d314ebd
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      app/services/api/v1/projects/sync_repositories/create_service.rb

+ 2
- 2
app/services/api/v1/projects/sync_repositories/create_service.rb View File

@@ -58,8 +58,8 @@ class Api::V1::Projects::SyncRepositories::CreateService < ApplicationService
def create_sync_repository_branch
branch1 = Reposync::CreateSyncBranchService.call(repo_name(1),gitlink_branch_name, external_branch_name)
branch2 = Reposync::CreateSyncBranchService.call(repo_name(2),gitlink_branch_name, external_branch_name)
@sync_repository_branch1 = SyncRepositoryBranch.create!(sync_repository: @sync_repository1, gitlink_branch_name: gitlink_branch_name, external_branch_name: external_branch_name )
@sync_repository_branch2 = SyncRepositoryBranch.create!(sync_repository: @sync_repository2, gitlink_branch_name: gitlink_branch_name, external_branch_name: external_branch_name)
@sync_repository_branch1 = SyncRepositoryBranch.create!(sync_repository: @sync_repository1, gitlink_branch_name: gitlink_branch_name, external_branch_name: external_branch_name, reposync_branch_id: branch1[1]["id"])
@sync_repository_branch2 = SyncRepositoryBranch.create!(sync_repository: @sync_repository2, gitlink_branch_name: gitlink_branch_name, external_branch_name: external_branch_name, reposync_branch_id: branch2[1]["id"])
end

def touch_first_sync


Loading…
Cancel
Save