From 65752b4f73cf8e1ce83cdaf8227b5d67923ac729 Mon Sep 17 00:00:00 2001 From: David Gay Date: Fri, 28 May 2021 21:45:50 -0400 Subject: Quickly port leaderboard and rankings from old Esoterra --- app/views/characters/rankings/index.html.erb | 36 ++++++++++++++++++++++++++++ app/views/characters/show.html.erb | 5 +++- 2 files changed, 40 insertions(+), 1 deletion(-) create mode 100644 app/views/characters/rankings/index.html.erb (limited to 'app/views/characters') diff --git a/app/views/characters/rankings/index.html.erb b/app/views/characters/rankings/index.html.erb new file mode 100644 index 0000000..8f41bd2 --- /dev/null +++ b/app/views/characters/rankings/index.html.erb @@ -0,0 +1,36 @@ +

Rankings for <%= render "application/components/text/name_and_title", character: @character %>

+ +
+ <%= link_to "Refresh", character_rankings_path %> +
+ +
+

Total Level: <%= @character.total_level %> (Rank <%= @character.total_level_rank %>)

+

Total XP: <%= @character.total_xp %> (Rank <%= @character.total_xp_rank %>)

+
+ +
+
+ + + + + + + + + + + <% Skill.all.each do |skill| %> + <% character_skill = @character.character_skills.find_by(skill: skill) %> + + + + + + + <% end %> + +
SkillRankLevelXP
<%= skill.name %><%= character_skill.rank %><%= character_skill.level %><%= character_skill.xp %>
+
+
diff --git a/app/views/characters/show.html.erb b/app/views/characters/show.html.erb index ce1c2db..1b5439a 100644 --- a/app/views/characters/show.html.erb +++ b/app/views/characters/show.html.erb @@ -3,7 +3,10 @@
- <%= link_to "Titles", character_titles_path(@character) %> +

First entered the planes -- cgit v1.2.3