mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-03-10 03:30:22 +00:00
Add alerts for unconfirmed enterprises to overview page
This commit is contained in:
10
app/assets/stylesheets/admin/alert.css.sass
Normal file
10
app/assets/stylesheets/admin/alert.css.sass
Normal file
@@ -0,0 +1,10 @@
|
||||
.alert
|
||||
border: 3px solid #DA5354
|
||||
border-radius: 6px
|
||||
margin-bottom: 20px
|
||||
color: #DA5354
|
||||
padding: 5px 10px
|
||||
h6
|
||||
color: #DA5354
|
||||
.message
|
||||
font-weight: bold
|
||||
4
app/views/spree/admin/overview/_unconfirmed.html.haml
Normal file
4
app/views/spree/admin/overview/_unconfirmed.html.haml
Normal file
@@ -0,0 +1,4 @@
|
||||
- @enterprises.unconfirmed.each do |enterprise|
|
||||
.alert
|
||||
%h6= "Action Required: Please confirm the email address for #{enterprise.name}."
|
||||
%span.message= "We've sent a confirmation email to #{enterprise.email}, so please check there for further instructions. Thanks!"
|
||||
@@ -1,17 +1,18 @@
|
||||
%h1{ :style => 'margin-bottom: 30px'} Dashboard
|
||||
|
||||
- if @enterprises.empty?
|
||||
- if @enterprises.unconfirmed.any?
|
||||
|
||||
= render partial: "spree/admin/overview/enterprises"
|
||||
= render partial: "spree/admin/overview/unconfirmed"
|
||||
|
||||
- else
|
||||
- if can? :admin, Spree::Product
|
||||
= render partial: "spree/admin/overview/products"
|
||||
%hr
|
||||
|
||||
%div.two.columns
|
||||
|
||||
- if can? :admin, Spree::Product
|
||||
= render partial: "spree/admin/overview/products"
|
||||
|
||||
- if can? :admin, OrderCycle
|
||||
= render partial: "spree/admin/overview/order_cycles"
|
||||
%div.two.columns
|
||||
|
||||
|
||||
= render partial: "spree/admin/overview/enterprises"
|
||||
- if can? :admin, OrderCycle
|
||||
= render partial: "spree/admin/overview/order_cycles"
|
||||
|
||||
= render partial: "spree/admin/overview/enterprises"
|
||||
|
||||
Reference in New Issue
Block a user