mirror of
https://github.com/Growstuff/growstuff.git
synced 2026-05-19 14:26:14 -04:00
improve copy for new request email
This commit is contained in:
@@ -123,7 +123,7 @@ class CropsController < ApplicationController
|
||||
|
||||
respond_to do |format|
|
||||
if @crop.save
|
||||
if current_member.has_role? :crop_wrangler
|
||||
unless current_member.has_role? :crop_wrangler
|
||||
Role.crop_wranglers.each do |w|
|
||||
Notifier.new_crop_request(w, @crop).deliver!
|
||||
end
|
||||
|
||||
@@ -24,7 +24,7 @@ class Notifier < ActionMailer::Base
|
||||
|
||||
def new_crop_request(member, request)
|
||||
@member, @request = member, request
|
||||
mail(:to => @member.email, :subject => "New crop request")
|
||||
mail(:to => @member.email, :subject => "#{@request.requester.login_name} has requested #{@request.name} as a new crop")
|
||||
end
|
||||
|
||||
def crop_request_approved(member, crop)
|
||||
|
||||
@@ -1,7 +1,24 @@
|
||||
- site_name = ENV['GROWSTUFF_SITE_NAME']
|
||||
|
||||
%p Hello #{@member.login_name},
|
||||
|
||||
%p
|
||||
A new crop has been requested. View, edit, approve or reject the request:
|
||||
%p
|
||||
#{@request.requester.login_name} has requested a new crop on #{site_name}.
|
||||
|
||||
= link_to "Request for #{@request}", crop_url(@request)
|
||||
%ul
|
||||
%li Name: #{@request.name}
|
||||
%li Wikipedia URL: #{@request.en_wikipedia_url.present? ? @request.en_wikipedia_url : "not specified"}
|
||||
|
||||
%p
|
||||
As a crop wrangler, you can #{link_to "approve or reject this request", edit_crop_url(@request)}.
|
||||
|
||||
%p
|
||||
Or, discuss this and other crop wrangling issues in our #{link_to "crop wrangling forum", "http://talk.growstuff.org/c/crop-wrangling"}.
|
||||
|
||||
%p
|
||||
Thanks for your help!
|
||||
|
||||
%p
|
||||
The Growstuff (staging) team
|
||||
%br/
|
||||
=link_to root_url, root_url
|
||||
@@ -285,6 +285,7 @@ ActiveRecord::Schema.define(version: 20150201064502) do
|
||||
t.datetime "updated_at"
|
||||
t.string "slug"
|
||||
t.integer "forum_id"
|
||||
t.integer "parent_id"
|
||||
end
|
||||
|
||||
add_index "posts", ["created_at", "author_id"], name: "index_posts_on_created_at_and_author_id", using: :btree
|
||||
|
||||
Reference in New Issue
Block a user