diff --git a/app/views/visitors/_hardrock_lottery_link.html.erb b/app/views/visitors/_hardrock_lottery_link.html.erb new file mode 100644 index 000000000..429c5616a --- /dev/null +++ b/app/views/visitors/_hardrock_lottery_link.html.erb @@ -0,0 +1,14 @@ +<% hardrock = Organization.find_by(slug: "hardrock") %> +<% lottery = hardrock.present? ? hardrock.lotteries.find_by(scheduled_start_date: "2023-12-02") : nil %> + +<% if hardrock.present? && lottery.present? && Date.today == lottery.scheduled_start_date %> + +<% end %> diff --git a/app/views/visitors/index.html.erb b/app/views/visitors/index.html.erb index 713daae47..5dd76140d 100644 --- a/app/views/visitors/index.html.erb +++ b/app/views/visitors/index.html.erb @@ -2,6 +2,9 @@ <% end %> <% content_for(:container_type) do %>skip <% end %> + +<%= render partial: "hardrock_lottery_link" %> +