Fetch/store Web App metadata and icons, finish RS integration #153

Merged
raucao merged 39 commits from feature/142-webapp_database into master 2024-01-01 13:18:48 +00:00
2 changed files with 7 additions and 2 deletions
Showing only changes of commit aab6793b86 - Show all commits

View File

@ -9,6 +9,11 @@ class NotificationMailer < ApplicationMailer
def remotestorage_auth_created
@user = params[:user]
@auth = params[:auth]
@permissions = @auth.permissions.map do |p|
access = p.split(":")[1] == 'r' ? 'read' : 'read/write'
directory = p.split(':')[0] == '' ? 'all folders and files' : p.split(':')[0]
"#{access} #{directory}"
end
@subject = "New app connected to your storage"
mail to: @user.email, subject: @subject
end

View File

@ -15,9 +15,9 @@ Have fun!
---
You can disable email notifications for new app authorizations in your account settings:
<%= setting_path(:remotestorage) %>
<%= setting_url(:remotestorage) %>
<% if Setting.discourse_enabled %>
If you have any questions, please visit our community forums:
<%= Setting.discourse_public_url %>
<% end %>