Created
January 12, 2010 16:19
-
-
Save anonymous/275319 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@destinations=Array.new | |
@harvest.people.find(:all).each do |p| | |
unless p.is_contractor | |
unless p.is_active==false | |
unless ["AM","Sales","Management","Executive","OPS","Marketing"].include? p.department | |
entries = p.entries :from => @beginning_date, :to => @ending_date | |
unless (entries and entries.length > 0) | |
@destinations << p.email | |
end | |
end | |
end | |
end | |
end | |
HarvestReminder::Email.send("Hey there!\n\nThis is a list of who recieved a friendly reminder to enter and submit their time for the week of #{@beginning_date.strftime("%Y-%m-%d")}\n\n #{@destinations.each { |i| print i, "\n"}}", ["bret.wilcox@effectiveui.com"]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment