dev_local_2
daiao 5 years ago
parent ac9fd0ed77
commit af76f7f050

@ -9,12 +9,12 @@ class Videos::BatchPublishService < ApplicationService
end end
def call def call
video_params = Array.wrap(params[:videos]).compact video_params = Array.wrap().compact
return if video_params.blank? return if video_params.blank?
video_ids = [] video_ids = []
ActiveRecord::Base.transaction do ActiveRecord::Base.transaction do
video_params.each do |param| video_params.each do |param|params[:videos]
video = user.videos.find_by(uuid: param[:video_id]) video = user.videos.find_by(uuid: param[:video_id])
next if video.blank? || video.processing_video_apply.present? next if video.blank? || video.processing_video_apply.present?

@ -970,6 +970,10 @@ Rails.application.routes.draw do
resources :carousels, only: [:index, :create, :update, :destroy] do resources :carousels, only: [:index, :create, :update, :destroy] do
post :drag, on: :collection post :drag, on: :collection
end end
resources :laboratories, only: [:index, :create, :destroy] do
resource :laboratory_setting, only: [:show, :update]
resource :laboratory_user, only: [:create, :destroy]
end
end end
resources :colleges, only: [] do resources :colleges, only: [] do

Loading…
Cancel
Save