diff --git a/app/controllers/profiles_controller.rb b/app/controllers/profiles_controller.rb index 4ee5e8a1c..23e28a270 100644 --- a/app/controllers/profiles_controller.rb +++ b/app/controllers/profiles_controller.rb @@ -19,6 +19,7 @@ def show @posts = @user.posts.select_overview_columns.public?.order("#{ allowed_sort_params.include?(params[:sort_posts]) ? params[:sort_posts] : "created_at" } DESC").page(params[:page]) @blocks = Block.where(user_id: @user.id, content_type: :profile).order(position: :asc, created_at: :asc) @collections = @user.collections.includes(:posts).where("posts_count > ?", 0) + @updates = Revision.where(post_id: @user.posts.pluck(:id)).order(created_at: :desc).limit(50) respond_to do |format| format.html diff --git a/app/views/blocks/profile/_update_log.html.erb b/app/views/blocks/profile/_update_log.html.erb new file mode 100644 index 000000000..c4a0c7a16 --- /dev/null +++ b/app/views/blocks/profile/_update_log.html.erb @@ -0,0 +1,88 @@ +<%# app/views/blocks/profile/_update_log.html.erb %> +
+ <%= time_ago_in_words(revision.created_at) %> ago +
+v<%= revision.version %>
+ <% end %> + + <% if revision.description.blank? %> ++ No update notes provided. +
+ <% else %> +No updates found for this user's gamemodes.
+