播放地址问题

develop
daiao 5 years ago
parent d18f1dad2f
commit 07bd873683

@ -1,4 +1,4 @@
json.extract! video, :id, :title, :cover_url, :file_url, :play_url, :vv, :user_id, :transcoded
json.extract! video, :id, :title, :cover_url, :vv, :user_id, :transcoded
json.play_url url_base64_encode(video.play_url)
json.file_url url_base64_encode(video.file_url)
json.play_duration video.video_play_duration

@ -1,4 +1,15 @@
json.count @count
json.videos @videos do |video|
json.partial! 'users/videos/video', locals: { video: video }
#json.partial! 'users/videos/video', locals: { video: video }
json.extract! video, :id, :title, :cover_url, :file_url, :play_url, :vv, :user_id, :transcoded
#json.play_url url_base64_encode(video.play_url)
#json.file_url url_base64_encode(video.file_url)
json.play_duration video.video_play_duration
json.published_at video.display_published_at
json.created_at video.display_created_at
json.updated_at video.display_updated_at
user = video.user
json.user_name user&.real_name
json.user_img url_to_avatar(user)
json.user_login user&.login
end
Loading…
Cancel
Save