add splash screen for deliverME

This commit is contained in:
Bilal
2020-06-30 19:41:02 +02:00
parent e49498bbbf
commit ba985b0af6
8 changed files with 137 additions and 4 deletions

View File

@@ -3,6 +3,7 @@ class VideosController < ApplicationController
before_action :set_project, only: [:index, :new, :create, :landing]
before_action :set_video, only: [:edit, :update]
before_action :show_splash_screen, only: :index
def landing
authorize Video, :new?
@@ -60,6 +61,10 @@ class VideosController < ApplicationController
private
def show_splash_screen
render :splash if videos.count.zero?
end
def set_project
@project = policy_scope(Project).find(params[:project_id])
end