]> git.openstreetmap.org Git - rails.git/commitdiff
Merge remote-tracking branch 'upstream/pull/5448'
authorTom Hughes <tom@compton.nu>
Sun, 29 Dec 2024 19:11:13 +0000 (19:11 +0000)
committerTom Hughes <tom@compton.nu>
Sun, 29 Dec 2024 19:11:13 +0000 (19:11 +0000)
1  2 
config/locales/en.yml
config/routes.rb

diff --combined config/locales/en.yml
index 417267808be8d922cb92cb71bf2d70e55ba1db1d,cb34b665dc7a03c899324f45665d9235426e4880..5628d3ea9476181b57fbecf684b0ca14201e5bc4
@@@ -1726,8 -1726,8 +1726,8 @@@ en
        success: "Confirmed your account, thanks for signing up!"
        already active: "This account has already been confirmed."
        unknown token: "That confirmation code has expired or does not exist."
 -      resend_html: "If you need us to resend the confirmation email, %{reconfirm_link}."
 -      click_here: click here
 +      if_need_resend: "If you need us to resend the confirmation email, click the button below."
 +      resend_button: Resend the confirmation email
      confirm_resend:
        failure: "User %{name} not found."
      confirm_email:
        confirmation_sent: We've sent a new confirmation note to %{email} and as soon as you confirm your account you'll be able to get mapping.
        whitelist: If you use an antispam system which sends confirmation requests then please make sure you whitelist %{sender} as we are unable to reply to any confirmation requests.
    messages:
-     inbox:
-       title: "Inbox"
-       messages: "You have %{new_messages} and %{old_messages}"
-       new_messages:
-         one: "%{count} new message"
-         other: "%{count} new messages"
-       old_messages:
-         one: "%{count} old message"
-         other: "%{count} old messages"
-       no_messages_yet_html: "You have no messages yet. Why not get in touch with some of the %{people_mapping_nearby_link}?"
-       people_mapping_nearby: "people mapping nearby"
-     messages_table:
-       from: "From"
-       to: "To"
-       subject: "Subject"
-       date: "Date"
-       actions: "Actions"
-     message_summary:
-       unread_button: "Mark as unread"
-       read_button: "Mark as read"
-       destroy_button: "Delete"
-       unmute_button: "Move to Inbox"
      new:
        title: "Send message"
        send_message_to_html: "Send a new message to %{name}"
        title: "No such message"
        heading: "No such message"
        body: "Sorry there is no message with that id."
-     outbox:
-       title: "Outbox"
-       messages:
-         one: "You have %{count} sent message"
-         other: "You have %{count} sent messages"
-       no_sent_messages_html: "You have no sent messages yet. Why not get in touch with some of the %{people_mapping_nearby_link}?"
-       people_mapping_nearby: "people mapping nearby"
-     muted:
-       title: "Muted Messages"
-       messages:
-         one: "%{count} muted message"
-         other: "You have %{count} muted messages"
      reply:
        wrong_user: "You are logged in as '%{user}' but the message you have asked to reply to was not sent to that user. Please log in as the correct user in order to reply."
      show:
        destroy_button: "Delete"
        back: "Back"
        wrong_user: "You are logged in as '%{user}' but the message you have asked to read was not sent by or to that user. Please log in as the correct user in order to read it."
-     sent_message_summary:
-       destroy_button: "Delete"
-     heading:
-       my_inbox: "My Inbox"
-       my_outbox: "My Outbox"
-       muted_messages: "Muted messages"
      mark:
        as_read: "Message marked as read"
        as_unread: "Message marked as unread"
        error: "The message could not be moved to the Inbox."
      destroy:
        destroyed: "Message deleted"
+     mailboxes:
+       heading:
+         my_inbox: "My Inbox"
+         my_outbox: "My Outbox"
+         muted_messages: "Muted messages"
+       messages_table:
+         from: "From"
+         to: "To"
+         subject: "Subject"
+         date: "Date"
+         actions: "Actions"
+       message:
+         unread_button: "Mark as unread"
+         read_button: "Mark as read"
+         destroy_button: "Delete"
+         unmute_button: "Move to Inbox"
+     inboxes:
+       show:
+         title: "Inbox"
+         messages: "You have %{new_messages} and %{old_messages}"
+         new_messages:
+           one: "%{count} new message"
+           other: "%{count} new messages"
+         old_messages:
+           one: "%{count} old message"
+           other: "%{count} old messages"
+         no_messages_yet_html: "You have no messages yet. Why not get in touch with some of the %{people_mapping_nearby_link}?"
+         people_mapping_nearby: "people mapping nearby"
+     muted_inboxes:
+       show:
+         title: "Muted Messages"
+         messages:
+           one: "%{count} muted message"
+           other: "You have %{count} muted messages"
+     outboxes:
+       show:
+         title: "Outbox"
+         messages:
+           one: "You have %{count} sent message"
+           other: "You have %{count} sent messages"
+         no_sent_messages_html: "You have no sent messages yet. Why not get in touch with some of the %{people_mapping_nearby_link}?"
+         people_mapping_nearby: "people mapping nearby"
+       message:
+         destroy_button: "Delete"
    passwords:
      new:
        title: "Lost password"
diff --combined config/routes.rb
index 068f3915e270053f5f98523fbe3ed21aaf5f0076,58d629d69ecce844b8646927f843baf5350a9cf2..d7b1acd3a99e73642115b26542da98f462f7a83f
@@@ -186,7 -186,7 +186,7 @@@ OpenStreetMap::Application.routes.draw 
    post "/user/new" => "users#create"
    get "/user/terms" => "users#terms"
    post "/user/save" => "users#save"
 -  get "/user/:display_name/confirm/resend" => "confirmations#confirm_resend", :as => :user_confirm_resend
 +  post "/user/:display_name/confirm/resend" => "confirmations#confirm_resend", :as => :user_confirm_resend
    match "/user/:display_name/confirm" => "confirmations#confirm", :via => [:get, :post]
    match "/user/confirm" => "confirmations#confirm", :via => [:get, :post]
    match "/user/confirm-email" => "confirmations#confirm_email", :via => [:get, :post]
    get "/export/embed" => "export#embed"
  
    # messages
-   resources :messages, :only => [:create, :show, :destroy] do
+   resources :messages, :id => /\d+/, :only => [:create, :show, :destroy] do
      post :mark
      patch :unmute
  
      match :reply, :via => [:get, :post]
-     collection do
-       get :inbox
-       get :muted
-       get :outbox
-     end
+   end
+   namespace :messages, :path => "/messages" do
+     resource :inbox, :only => :show
+     resource :muted_inbox, :path => "muted", :only => :show
+     resource :outbox, :only => :show
    end
    get "/user/:display_name/inbox", :to => redirect(:path => "/messages/inbox")
    get "/user/:display_name/outbox", :to => redirect(:path => "/messages/outbox")