parent
427aa8794e
commit
07d0ed916d
9 changed files with 74 additions and 56 deletions
|
|
@ -7,6 +7,7 @@
|
||||||
## Features
|
## Features
|
||||||
* Change email without confirmation when mail is disabled [#7455](https://github.com/diaspora/diaspora/pull/7455)
|
* Change email without confirmation when mail is disabled [#7455](https://github.com/diaspora/diaspora/pull/7455)
|
||||||
* Warn users if they leave the profile editing page with unsaved changes [#7473](https://github.com/diaspora/diaspora/pull/7473)
|
* Warn users if they leave the profile editing page with unsaved changes [#7473](https://github.com/diaspora/diaspora/pull/7473)
|
||||||
|
* Add admin pages to the mobile interface [#7295](https://github.com/diaspora/diaspora/pull/7295)
|
||||||
|
|
||||||
# 0.6.6.0
|
# 0.6.6.0
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -2,9 +2,9 @@
|
||||||
@import 'bootstrap-variables';
|
@import 'bootstrap-variables';
|
||||||
@import 'animations';
|
@import 'animations';
|
||||||
|
|
||||||
/** ADMIN STYlES **/
|
// ADMIN STYlES
|
||||||
/** user search **/
|
|
||||||
|
|
||||||
|
// user search
|
||||||
.users {
|
.users {
|
||||||
li.user {
|
li.user {
|
||||||
border-bottom: 1px solid $light-grey;
|
border-bottom: 1px solid $light-grey;
|
||||||
|
|
@ -23,7 +23,7 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Invites panel **/
|
// Invites panel
|
||||||
.more_invites{
|
.more_invites{
|
||||||
#add-invites-section{
|
#add-invites-section{
|
||||||
line-height: 34px;
|
line-height: 34px;
|
||||||
|
|
@ -31,9 +31,13 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.invite-emails {
|
||||||
|
margin-bottom: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
// Weekly stats
|
// Weekly stats
|
||||||
.week-selector {
|
.week-selector {
|
||||||
margin-top: 18px;
|
margin-top: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Pod stats
|
// Pod stats
|
||||||
|
|
@ -44,8 +48,17 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/** reported posts **/
|
.percent-change {
|
||||||
|
&.increase {
|
||||||
|
color: $increase;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.decrease {
|
||||||
|
color: $decrease;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// reported posts
|
||||||
.reports {
|
.reports {
|
||||||
.reason-label {
|
.reason-label {
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
|
|
@ -60,8 +73,7 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/** pod list **/
|
// pod list
|
||||||
|
|
||||||
#pod-list {
|
#pod-list {
|
||||||
.pod-title {
|
.pod-title {
|
||||||
max-width: 200px;
|
max-width: 200px;
|
||||||
|
|
|
||||||
|
|
@ -32,3 +32,6 @@ $left-navbar-drawer-background: darken($white, 6%) !default;
|
||||||
$hovercard-background: $white !default;
|
$hovercard-background: $white !default;
|
||||||
|
|
||||||
$card-shadow: 0 1px 2px 0 rgba(0, 0, 0, .16), 0 2px 10px 0 rgba(0, 0, 0, .12) !default;
|
$card-shadow: 0 1px 2px 0 rgba(0, 0, 0, .16), 0 2px 10px 0 rgba(0, 0, 0, .12) !default;
|
||||||
|
|
||||||
|
$increase: #008000;
|
||||||
|
$decrease: #fe0000;
|
||||||
|
|
|
||||||
|
|
@ -1,49 +1,52 @@
|
||||||
- content_for :head do
|
- content_for :head do
|
||||||
= stylesheet_link_tag :admin
|
= stylesheet_link_tag :admin
|
||||||
|
|
||||||
%h1= t(".usage_statistic")
|
.container-fluid
|
||||||
|
.row
|
||||||
|
.col-sm-9
|
||||||
|
%h1= t(".usage_statistic")
|
||||||
|
.col-sm-3
|
||||||
|
= form_tag("/admins/stats", method: "get", class: "row form-inline segment-selection") do
|
||||||
|
.col-sm-8
|
||||||
|
%select.form-control{name: "range"}
|
||||||
|
- %w(daily week 2weeks month).each do |range|
|
||||||
|
%option{value: range, selected: ("selected" if params[:range] == range)}
|
||||||
|
= t(".#{range}")
|
||||||
|
.col-sm-4
|
||||||
|
= submit_tag t(".go"), class: "btn btn-primary btn-block"
|
||||||
|
|
||||||
.row
|
.row
|
||||||
= form_tag("/admins/stats", method: "get", class: "col-sm-12 form-inline segment-selection") do
|
.col-xs-12
|
||||||
.col-sm-2.col-sm-push-8
|
|
||||||
%select.form-control{name: "range"}
|
|
||||||
- %w(daily week 2weeks month).each do |range|
|
|
||||||
%option{value: range, selected: ("selected" if params[:range] == range)}
|
|
||||||
= t(".#{range}")
|
|
||||||
.col-sm-2.col-sm-push-8
|
|
||||||
= submit_tag t(".go"), class: "btn btn-primary btn-block"
|
|
||||||
|
|
||||||
.col-sm-8.col-sm-pull-4
|
|
||||||
%h4
|
|
||||||
!= t("admins.stats.display_results", segment: content_tag(:strong, segment))
|
|
||||||
|
|
||||||
.row
|
|
||||||
- %i(posts comments aspect_memberships users).each do |name|
|
|
||||||
:ruby
|
|
||||||
model = instance_variable_get("@#{name}")
|
|
||||||
count = model[:yesterday]
|
|
||||||
name = name == :aspect_memberships ? t(".shares", count: count) : t(".#{name}", count: count)
|
|
||||||
|
|
||||||
.col-md-3
|
|
||||||
%h2{style: "font-weight:bold;"}
|
|
||||||
= name.to_s
|
|
||||||
%h4
|
%h4
|
||||||
= model[:day_before]
|
!= t("admins.stats.display_results", segment: content_tag(:strong, segment))
|
||||||
%span.percent_change{class: (model[:change] > 0 ? "green" : "red")}
|
|
||||||
= "(#{model[:change]}%)"
|
|
||||||
|
|
||||||
.row
|
.row
|
||||||
%p.col-md-12.alert.alert-info.text-center{role: "alert"}
|
- %i(posts comments aspect_memberships users).each do |name|
|
||||||
!= t("admins.stats.current_segment",
|
:ruby
|
||||||
post_yest: content_tag(:strong, posts[:yesterday] / user_count),
|
model = instance_variable_get("@#{name}")
|
||||||
post_day: content_tag(:strong, posts[:day_before] / user_count))
|
count = model[:yesterday]
|
||||||
|
label_with_count = name == :aspect_memberships ? t(".shares", count: count) : t(".#{name}", count: count)
|
||||||
|
|
||||||
.row
|
.col-md-3
|
||||||
.col-md-12
|
%h2{style: "font-weight:bold;"}
|
||||||
%h3= t(".50_most")
|
= label_with_count
|
||||||
%ul
|
%h4
|
||||||
- @popular_tags.each do |name, count|
|
= model[:day_before]
|
||||||
%li
|
%span.percent-change{class: (model[:change] > 0 ? "increase" : "decrease")}
|
||||||
!= t("admins.stats.tag_name",
|
= "(#{model[:change]}%)"
|
||||||
name_tag: content_tag(:strong, name),
|
|
||||||
count_tag: content_tag(:strong, count))
|
.row
|
||||||
|
%p.col-md-12.alert.alert-info.text-center{role: "alert"}
|
||||||
|
!= t("admins.stats.current_segment",
|
||||||
|
post_yest: content_tag(:strong, posts[:yesterday] / user_count),
|
||||||
|
post_day: content_tag(:strong, posts[:day_before] / user_count))
|
||||||
|
|
||||||
|
.row
|
||||||
|
.col-md-12
|
||||||
|
%h3= t(".50_most")
|
||||||
|
%ul
|
||||||
|
- @popular_tags.each do |name, count|
|
||||||
|
%li
|
||||||
|
!= t("admins.stats.tag_name",
|
||||||
|
name_tag: content_tag(:strong, name),
|
||||||
|
count_tag: content_tag(:strong, count))
|
||||||
|
|
|
||||||
|
|
@ -52,6 +52,6 @@
|
||||||
%label.col-xs-12.col-md-2.control-label
|
%label.col-xs-12.col-md-2.control-label
|
||||||
= t(".email_to")
|
= t(".email_to")
|
||||||
.col-xs-12.col-md-8
|
.col-xs-12.col-md-8
|
||||||
= text_field_tag "identifier", nil, class: "form-control"
|
= text_field_tag "identifier", nil, class: "form-control invite-emails"
|
||||||
.col-xs-12.col-md-2
|
.col-xs-12.col-md-2
|
||||||
= submit_tag t(".invite"), class: "btn btn-block btn-primary"
|
= submit_tag t(".invite"), class: "btn btn-block btn-primary"
|
||||||
|
|
|
||||||
|
|
@ -10,12 +10,12 @@
|
||||||
= form_tag("/admins/weekly_user_stats", method: "get", class: "form-inline week-selector row") do
|
= form_tag("/admins/weekly_user_stats", method: "get", class: "form-inline week-selector row") do
|
||||||
.col-xs-9.center
|
.col-xs-9.center
|
||||||
= select_tag(:week,
|
= select_tag(:week,
|
||||||
options_for_select(created_users_by_week, selected_week),
|
options_for_select(created_users_by_week.keys.reverse, selected_week),
|
||||||
class: "form-control")
|
class: "form-control")
|
||||||
.col-xs-3.center
|
.col-xs-3.center
|
||||||
= submit_tag t("admins.stats.go"), class: "btn btn-primary"
|
= submit_tag t("admins.stats.go"), class: "btn btn-primary"
|
||||||
|
|
||||||
= t(".amount_of", count: counter)
|
= t(".amount_of", count: counter)
|
||||||
%br
|
%br
|
||||||
- @created_users_by_week[selected_week].each do |m|
|
- created_users_by_week[selected_week].each do |m|
|
||||||
= link_to m, "/u/#{m}"
|
= link_to m, "/u/#{m}"
|
||||||
|
|
|
||||||
|
|
@ -4,5 +4,4 @@
|
||||||
= render partial: "admins/admin_bar"
|
= render partial: "admins/admin_bar"
|
||||||
.col-md-9
|
.col-md-9
|
||||||
= render partial: "admins/weekly_user_stats",
|
= render partial: "admins/weekly_user_stats",
|
||||||
locals: {created_users_by_week: @created_users_by_week.keys.reverse,
|
locals: {created_users_by_week: @created_users_by_week, selected_week: @selected_week, counter: @counter}
|
||||||
selected_week: @selected_week, counter: @counter}
|
|
||||||
|
|
|
||||||
|
|
@ -1,2 +1,2 @@
|
||||||
= render partial: "admins/weekly_user_stats",
|
= render partial: "admins/weekly_user_stats",
|
||||||
locals: {created_users_by_week: @created_users_by_week.keys.reverse, selected_week: @selected_week, counter: @counter}
|
locals: {created_users_by_week: @created_users_by_week, selected_week: @selected_week, counter: @counter}
|
||||||
|
|
|
||||||
|
|
@ -117,7 +117,7 @@ en:
|
||||||
id: "ID"
|
id: "ID"
|
||||||
guid: "GUID"
|
guid: "GUID"
|
||||||
email: "Email"
|
email: "Email"
|
||||||
diaspora_handle: "diaspora* handle"
|
diaspora_handle: "diaspora* ID"
|
||||||
last_seen: "Last seen"
|
last_seen: "Last seen"
|
||||||
account_closed: "Account closed"
|
account_closed: "Account closed"
|
||||||
nsfw: "#nsfw"
|
nsfw: "#nsfw"
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue