You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
educoder/app/views/courses/own_watch_histories.json.jb...

14 lines
392 B

json.data do
json.array! @videos.each do |d|
json.watch_course_video_id d['watch_course_video_id']
json.title d.title
json.user_name d.video.user&.real_name
json.is_finished d.is_finished == 1 ? true : false
json.total_duration d.total_duration.round(0)
json.freq d['freq']
json.start_at d.start_at.to_s
json.end_at d.end_at.to_s
end
end
json.count @count