Skip to content

Commit

Permalink
fix: Add missing jobs for initiatives rake tasks (#474)
Browse files Browse the repository at this point in the history
  • Loading branch information
moustachu authored Jan 17, 2024
1 parent 6c7442a commit b6776e0
Show file tree
Hide file tree
Showing 6 changed files with 37 additions and 1 deletion.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -98,3 +98,5 @@ coverage/
public/sw.js*
app/compiled_views/
certificate-https-local/

.DS_Store
7 changes: 7 additions & 0 deletions app/jobs/check_published_initiatives.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# frozen_string_literal: true

class CheckPublishedInitiatives < ApplicationJob
def perform
system "rake decidim_initiatives:check_published"
end
end
7 changes: 7 additions & 0 deletions app/jobs/check_validating_initiatives.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# frozen_string_literal: true

class CheckValidatingInitiatives < ApplicationJob
def perform
system "rake decidim_initiatives:check_validating"
end
end
7 changes: 7 additions & 0 deletions app/jobs/notify_progress_initiatives.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# frozen_string_literal: true

class NotifyProgressInitiatives < ApplicationJob
def perform
system "rake decidim_initiatives:notify_progress"
end
end
2 changes: 1 addition & 1 deletion app/views/decidim/devise/shared/_omniauth_buttons.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<div class="social-register">
<% if provider.match?("france") %>
<span class="register__separator">
<span class="register__separator__text"><%= t("devise.shared.links.sign_in_with_france_connect")%></span>
<span class="register__separator__text"><%= t("devise.shared.links.sign_in_with_france_connect") %></span>
</span>
<div class="text-center">
<p><%= t("decidim.omniauth.france_connect.explanation") %></p>
Expand Down
13 changes: 13 additions & 0 deletions config/sidekiq.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
- reminders
- active_storage_analysis
- active_storage_purge
- initiatives

:scheduler:
:schedule:
Expand Down Expand Up @@ -44,3 +45,15 @@
class: NotificationsDigestMailJob
queue: mailers
args: :weekly
CheckPublishedInitiatives:
cron: '0 1 * * *'
class: CheckPublishedInitiatives
queue: initiatives
CheckValidatingInitiatives:
cron: '0 1 * * *'
class: CheckValidatingInitiatives
queue: initiatives
NotifyProgressInitiatives:
cron: '0 1 * * *'
class: NotifyProgressInitiatives
queue: initiatives

0 comments on commit b6776e0

Please sign in to comment.