Skip to content

v3.2.0 #586

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 9 commits into from
Jan 8, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 0 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,6 @@
# Ignore bundler config
/.bundle

# Ignore the default SQLite database.
/db/*.sqlite3
/db/*.sqlite3-journal

# Ignore all logfiles and tempfiles.
/log/*.log
/tmp
Expand All @@ -32,8 +28,6 @@ capybara-*.html
/vendor/bundle
/coverage/
/spec/tmp/*
timeoverflow_development
timeoverflow_test
.byebug_history
.env
.DS_Store
Expand Down
4 changes: 4 additions & 0 deletions app/assets/javascripts/application.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,7 @@ $(document).on('click', 'span.show-password', function(event) {
$(this).prev('input').attr('type', inputType);
$(this).find('.material-icons').html(icon);
});

$(function() {
$("#select2").select2();
});
31 changes: 2 additions & 29 deletions app/assets/stylesheets/application.scss
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,6 @@ html {
padding: 20px;
}


.row.exports {
padding: 10px;
}
Expand Down Expand Up @@ -352,17 +351,6 @@ label[required]::after{
}
}

.back-overlay {
background-color: $black;
background-size: cover;
display: none;
height: 100%;
position: absolute;
top: 0;
width: 100%;
z-index: -1;
}

.navbar .container-fluid {
padding: 0;
}
Expand Down Expand Up @@ -402,12 +390,6 @@ label[required]::after{
background-size: cover;
}

.back-overlay {
display: block;
filter: alpha(opacity = 60); /* For IE8 and earlier */
opacity: 0.2;
}

.login-wrapper {
position: absolute;
top: 51%;
Expand Down Expand Up @@ -455,11 +437,6 @@ label[required]::after{
background: image-url('home_back_mobile.jpg') no-repeat center center fixed;
background-size: cover;
}

.back-overlay {
filter: alpha(opacity = 15); /* For IE8 and earlier */
opacity: 0.15;
}
}

.landing-page .content, .pages .banner {
Expand Down Expand Up @@ -586,11 +563,7 @@ label[required]::after{
margin-top: 1.5rem;
}

.back-overlay {
display: none;
}

.header, .banner, .empower, .donate {
.header, .banner, .section-block {
text-align: center;
}

Expand Down Expand Up @@ -672,7 +645,7 @@ label[required]::after{
}
}

.empower, .donate {
.section-block {
h2 {
margin-bottom: 4rem;
}
Expand Down
2 changes: 0 additions & 2 deletions app/assets/stylesheets/application/variables.scss
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ $palette-black: #333;
$bg-color: #f5f8fa;
$white: #ffffff;
$border: #e1e8ed;
$menu-disabled: #ddd;
$black: #000;
$form-input-glyph: #555;
$form-input-bg-color: #f5f5f5;
Expand All @@ -26,4 +25,3 @@ $pages-anchor: #4a4a4a;
$pages-anchor-hover: #8a8a8a;
$features-background: #f5f5f5;
$features-separator: #d8d8d8;

4 changes: 3 additions & 1 deletion app/decorators/post_report_decorator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ def name(extension)

def headers
[
"",
@type.model_name.human,
User.model_name.human
]
Expand All @@ -23,10 +24,11 @@ def rows
grouped_rows = []

@collection.each do |category, posts|
grouped_rows << [category.try(:name) || "-", ""]
grouped_rows << ["", category.try(:name) || "-", ""]

posts.each do |post|
grouped_rows << [
post.id,
post.title,
"#{post.user} (#{post.member_uid})"
]
Expand Down
28 changes: 24 additions & 4 deletions app/views/application/_navbar.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -52,11 +52,31 @@
<div class="row">
<div class="col-xs-12 col-sm-12 col-md-12 col-lg-12">
<ul class="nav nav-pills actions-menu">
<%= render 'application/menus/user_list_link' %>
<%= render 'application/menus/offers_list_link' %>
<%= render 'application/menus/inquiries_list_link' %>
<li class="<%= "active" if current_page?(users_path) %>">
<%= link_to users_path do %>
<%= glyph :user %>
<%= t("users.index.members") %>
<% end %>
</li>
<li class="<%= "active" if current_page?(offers_path) %>">
<%= link_to offers_path do %>
<%= glyph :offer %>
<%= Offer.model_name.human(count: :many) %>
<% end %>
</li>
<li class="<%= "active" if current_page?(inquiries_path) %>">
<%= link_to inquiries_path do %>
<%= glyph :inquiry %>
<%= Inquiry.model_name.human(count: :many) %>
<% end %>
</li>
<% if current_user.manages? current_organization %>
<%= render 'application/menus/offers_by_tag_link' %>
<li class="<%= "active" if current_page?(alpha_grouped_index_tags_path(post_type: "offer")) %>">
<%= link_to alpha_grouped_index_tags_path(post_type: "offer") do %>
<%= glyph :tags %>
<%= t ".tags" %>
<% end %>
</li>
<%= render 'application/menus/organization_reports_menu' %>
<%= render 'application/menus/organization_statistics_menu' %>
<%= render 'application/menus/organization_listings_menu' %>
Expand Down
6 changes: 0 additions & 6 deletions app/views/application/menus/_inquiries_list_link.html.erb

This file was deleted.

6 changes: 0 additions & 6 deletions app/views/application/menus/_offers_by_tag_link.html.erb

This file was deleted.

6 changes: 0 additions & 6 deletions app/views/application/menus/_offers_list_link.html.erb

This file was deleted.

11 changes: 0 additions & 11 deletions app/views/application/menus/_organization_switcher.html.erb

This file was deleted.

13 changes: 12 additions & 1 deletion app/views/application/menus/_user_admin_menu_items.html.erb
Original file line number Diff line number Diff line change
@@ -1,5 +1,16 @@
<% if current_user.organizations.count > 1 %>
<%= render 'application/menus/organization_switcher' %>
<li class="disabled">
<a href="#"><%= current_organization.name %></a>
</li>
<% (current_user.organizations - [current_organization]).each do |org| %>
<li>
<%= link_to set_current_organization_path(org), method: :post do %>
<%= glyph(:retweet) %>
<%= org.name %>
<% end %>
</li>
<% end %>

<li class="divider" role="presentation"></li>
<% end %>

Expand Down
6 changes: 0 additions & 6 deletions app/views/application/menus/_user_list_link.html.erb

This file was deleted.

2 changes: 0 additions & 2 deletions app/views/inquiries/index.js.erb

This file was deleted.

2 changes: 0 additions & 2 deletions app/views/layouts/application.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,5 @@

<%= render_brand_logo %>
<%= render 'application/footer' %>

<div class="back-overlay"></div>
</body>
</html>
2 changes: 0 additions & 2 deletions app/views/offers/index.js.erb

This file was deleted.

18 changes: 3 additions & 15 deletions app/views/pages/about.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
</div>
</div>
<div class="row">
<div class="col-sm-10 col-sm-offset-1 empower">
<div class="col-sm-10 col-sm-offset-1 section-block">
<h2><%= t("pages.about.empower-title") %></h2>
<p><%= t(
"pages.about.empower-text-1",
Expand Down Expand Up @@ -70,19 +70,7 @@
</div>
</div>
<div class="row">
<div class="col-sm-10 col-sm-offset-1 donate">
<h2><%= t("pages.about.donate-title") %></h2>
<p><%= t(
"pages.about.donate-text",
donate_link: link_to(
t("pages.about.donate-link"),
"https://www.teaming.net/poreldesarrollodelosbancosdetiempo",
)
).html_safe %></p>
</div>
</div>
<div class="row">
<div class="col-sm-10 col-sm-offset-1 donate">
<div class="col-sm-10 col-sm-offset-1 section-block">
<h2><%= t("pages.about.app-mobile") %></h2>
<p><%= t(
"pages.about.app-mobile-text",
Expand All @@ -93,7 +81,7 @@
).html_safe %></p>
</div>
</div>

<div class="row">
<div class="col-sm-12 text-center">
<a href="http://www.barcelonactiva.cat" ><%= image_tag("ajuntament_bcn_activa.png", width: '400', class: "img-responsive center-block") %></a>
Expand Down
6 changes: 4 additions & 2 deletions app/views/reports/post_list.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,19 @@
</colgroup>
<thead>
<tr>
<th></th>
<th><%= @post_type.model_name.human %></th>
<th><%= User.model_name.human %></th>
</tr>
</thead>
<tbody>
<% @posts.each do |cat, ps| %>
<tr class="success">
<td colspan="2"><h4><%= cat || '—' %></h4></td>
<tr class="info">
<td colspan="3"><h4><%= cat || '—' %></h4></td>
</tr>
<% ps.each do |post| %>
<tr>
<td><%= post.id %></td>
<td><strong><%= post.title %></strong></td>
<td><%= "#{post.user} (#{post.member_uid})" %></td>
</tr>
Expand Down
3 changes: 0 additions & 3 deletions app/views/reports/user_list.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
<table class="table table-condensed table-bordered table-striped">
<thead>
<tr>
<!-- %th= User.human_attribute_name(:registration_number)
-->
<th>N</th>
<th><%= User.human_attribute_name :username %></th>
<th><%= User.human_attribute_name :email %></th>
Expand All @@ -22,6 +20,5 @@
</tr>
<% end %>
</tbody>
<tfoot></tfoot>
</table>
</div>
7 changes: 0 additions & 7 deletions app/views/shared/_post_form.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,3 @@
</p>
<%= f.button label_button, class: "btn btn-default", style: "margin-bottom: 20px;" %>
<% end %>
<script>
$("#select2").select2({
formatNoMatches: function () {
return "<%= j t('application.tips.user_not_found') %>";
}
});
</script>
2 changes: 1 addition & 1 deletion app/views/transfers/_sources.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@
options_for_select(
TransferSourcesOptions.new(sources).to_a,
selected: current_user.member(current_organization).account.id
), {}, id: "select2-time", class: "form-control"
), {}, id: "select2", class: "form-control"
%>
</div>
8 changes: 0 additions & 8 deletions app/views/transfers/new.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,3 @@
<label class="js-error-amount error invisible"><%= t ".error_amount" %></label>
</div>
<% end %>

<script type="text/javascript">
$("#select2-time").select2({
formatNoMatches: function() {
return "<%= j t('application.tips.user_not_found') %>";
}
});
</script>
3 changes: 0 additions & 3 deletions config/locales/ca.yml
Original file line number Diff line number Diff line change
Expand Up @@ -403,9 +403,6 @@ ca:
banner-button: Sol·licita accés
banner-subtitle: Us ajudarem a posar-lo en marxa o fer-vos una demostració
banner-title: Ets un Banc de Temps?
donate-link: Dona 1€ al mes
donate-text: Amb la finalitat de donar suport a moltes comunitats la associació ADBdT ofereix la plataforma TimeOverflow a tots los Bancs de Temps. Considera %{donate_link} per contribuir a les despeses de manteniment i innovació.
donate-title: Participa amb una donació
empower-adbdt: ADBdT
empower-adbdt-title: Associació pel Desenvolupament dels Bancs de Temps
empower-coopdevs: CoopDevs
Expand Down
Loading