mirror of
https://gitlink.org.cn/Gitlink/forgeplus.git
synced 2026-05-03 03:40:49 +08:00
change jobs
This commit is contained in:
@@ -1,9 +1,9 @@
|
||||
require 'uri'
|
||||
require 'net/http'
|
||||
|
||||
class SyncProjectsJob < ApplicationJob
|
||||
queue_as :default
|
||||
|
||||
require 'uri'
|
||||
require 'net/http'
|
||||
|
||||
def perform(sync_params)
|
||||
SyncLog.sync_log("==========begin to sync #{sync_params[:type]} to forge============")
|
||||
begin
|
||||
@@ -41,6 +41,8 @@ class SyncProjectsJob < ApplicationJob
|
||||
end
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def update_new_project(re, project_id)
|
||||
project = Project.find_by(id: project_id)
|
||||
project.update(re[:target_params].compact!) if re[:target_params].present?
|
||||
|
||||
Reference in New Issue
Block a user