mirror of
https://github.com/Growstuff/growstuff.git
synced 2026-03-30 04:35:28 -04:00
16 lines
759 B
Plaintext
16 lines
759 B
Plaintext
%p
|
|
- if can? :create, Harvest
|
|
- if @planting && @planting.owner == current_member
|
|
= link_to 'Add harvest', new_planting_harvest_path(planting: @planting), class: 'btn btn-primary'
|
|
- elsif @owner
|
|
%p
|
|
- if @owner == current_member
|
|
= link_to 'Add harvest', new_harvest_path, class: 'btn btn-primary'
|
|
= link_to "View everyone's harvests", harvests_path, class: 'btn btn-default'
|
|
- else # everyone's harvests
|
|
= link_to 'Add harvest', new_harvest_path, class: 'btn btn-primary'
|
|
- if current_member
|
|
= link_to 'View your harvests', harvests_by_owner_path(owner: current_member.slug), class: 'btn btn-default'
|
|
- else
|
|
= render partial: 'shared/signin_signup', locals: { to: 'track your harvests' }
|