decidim-sortitions 0.19.1 → 0.23.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (83) hide show
  1. checksums.yaml +4 -4
  2. data/app/assets/images/decidim/sortitions/icon.svg +1 -3
  3. data/app/assets/stylesheets/decidim/sortitions/_sortitions.scss +1 -1
  4. data/app/cells/decidim/sortitions/sortition_m/data.erb +3 -3
  5. data/app/cells/decidim/sortitions/sortition_m/footer.erb +1 -1
  6. data/app/controllers/decidim/sortitions/{sortition_widgets_controller.rb → widgets_controller.rb} +2 -2
  7. data/app/helpers/decidim/sortitions/sortitions_helper.rb +1 -0
  8. data/app/models/decidim/sortitions/sortition.rb +3 -0
  9. data/app/queries/decidim/sortitions/admin/participatory_space_proposals.rb +7 -1
  10. data/app/services/decidim/sortitions/sortition_search.rb +1 -18
  11. data/app/types/decidim/sortitions/sortition_type.rb +32 -0
  12. data/app/types/decidim/sortitions/sortitions_type.rb +32 -0
  13. data/app/views/decidim/sortitions/admin/sortitions/_form.html.erb +1 -1
  14. data/app/views/decidim/sortitions/admin/sortitions/confirm_destroy.html.erb +1 -1
  15. data/app/views/decidim/sortitions/admin/sortitions/edit.html.erb +1 -1
  16. data/app/views/decidim/sortitions/admin/sortitions/index.html.erb +1 -1
  17. data/app/views/decidim/sortitions/admin/sortitions/show.html.erb +1 -1
  18. data/app/views/decidim/sortitions/sortition_widgets/show.html.erb +1 -1
  19. data/app/views/decidim/sortitions/sortitions/_filters.html.erb +16 -8
  20. data/app/views/decidim/sortitions/sortitions/_linked_sortitions.html.erb +1 -1
  21. data/app/views/decidim/sortitions/sortitions/index.html.erb +4 -4
  22. data/app/views/decidim/sortitions/sortitions/show.html.erb +9 -3
  23. data/config/locales/am-ET.yml +1 -0
  24. data/config/locales/bg-BG.yml +7 -0
  25. data/config/locales/bg.yml +7 -0
  26. data/config/locales/ca.yml +2 -0
  27. data/config/locales/cs.yml +62 -60
  28. data/config/locales/da-DK.yml +1 -0
  29. data/config/locales/da.yml +1 -0
  30. data/config/locales/de.yml +2 -0
  31. data/config/locales/el-GR.yml +1 -0
  32. data/config/locales/el.yml +152 -0
  33. data/config/locales/en.yml +2 -0
  34. data/config/locales/eo.yml +1 -0
  35. data/config/locales/es-MX.yml +2 -0
  36. data/config/locales/es-PY.yml +2 -0
  37. data/config/locales/es.yml +2 -0
  38. data/config/locales/et-EE.yml +1 -0
  39. data/config/locales/et.yml +1 -0
  40. data/config/locales/fi-plain.yml +2 -0
  41. data/config/locales/fi.yml +5 -3
  42. data/config/locales/fr-CA.yml +153 -0
  43. data/config/locales/fr.yml +2 -0
  44. data/config/locales/ga-IE.yml +1 -0
  45. data/config/locales/hr-HR.yml +1 -0
  46. data/config/locales/hr.yml +1 -0
  47. data/config/locales/hu.yml +1 -0
  48. data/config/locales/is-IS.yml +122 -0
  49. data/config/locales/is.yml +122 -0
  50. data/config/locales/it.yml +26 -24
  51. data/config/locales/ja-JP.yml +147 -0
  52. data/config/locales/ja.yml +147 -0
  53. data/config/locales/ko-KR.yml +1 -0
  54. data/config/locales/ko.yml +1 -0
  55. data/config/locales/lt-LT.yml +1 -0
  56. data/config/locales/lt.yml +1 -0
  57. data/config/locales/lv.yml +158 -0
  58. data/config/locales/mt-MT.yml +1 -0
  59. data/config/locales/mt.yml +1 -0
  60. data/config/locales/nl.yml +2 -0
  61. data/config/locales/no.yml +110 -1
  62. data/config/locales/om-ET.yml +1 -0
  63. data/config/locales/pl.yml +78 -76
  64. data/config/locales/pt-BR.yml +1 -1
  65. data/config/locales/pt.yml +55 -53
  66. data/config/locales/ro-RO.yml +159 -0
  67. data/config/locales/sk-SK.yml +164 -0
  68. data/config/locales/sk.yml +164 -0
  69. data/config/locales/sl.yml +5 -0
  70. data/config/locales/so-SO.yml +1 -0
  71. data/config/locales/sr-CS.yml +6 -0
  72. data/config/locales/sv.yml +3 -1
  73. data/config/locales/ti-ER.yml +1 -0
  74. data/config/locales/vi-VN.yml +1 -0
  75. data/config/locales/vi.yml +1 -0
  76. data/config/locales/zh-CN.yml +147 -0
  77. data/config/locales/zh-TW.yml +1 -0
  78. data/db/migrate/20200320105926_index_foreign_keys_in_decidim_sortitions_sortitions.rb +7 -0
  79. data/db/migrate/20200827154036_add_commentable_counter_cache_to_sortitions.rb +9 -0
  80. data/lib/decidim/sortitions/component.rb +2 -0
  81. data/lib/decidim/sortitions/engine.rb +1 -1
  82. data/lib/decidim/sortitions/version.rb +1 -1
  83. metadata +55 -14
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1818bde5a6cba9e7201e994adb7cb2b84e2761ea52645f421cfcdb74d0f24b02
4
- data.tar.gz: 4edd8135b75c26bd7f6afe0436eac93d49a424e606d1d73d6efb0fdd87e604c4
3
+ metadata.gz: 22bf6e691196a48b11a7c36b6d840946c3e353a373df9bf950fdf517abdb2c05
4
+ data.tar.gz: 73c900037052f42883c035baad2988a2cb4a3a74d97ebdbc5eb8c4eff176d522
5
5
  SHA512:
6
- metadata.gz: 7f5e7a15ba8dacb89217b2666239f08372c80dfff9719a813a96b49f0ad2ba4ad65bc89f770451cb04d9d3c50cbbf8c67a0a6c8108b2a829fd064d86bfd9ac69
7
- data.tar.gz: 601db9e6e33c5284f6e85d506faa3797ffd471d81eeda8189eb0e2d2d2465cdc457a9524ee0bb3b4b04bacf656feb1f76abca04a08e7dbd266bd33770b397fdb
6
+ metadata.gz: c0b4b72346b82a273c8144779a6f42adfd3f3e65586921fd23abcf12c46ad8f7b84bb480012be2f657546f416fb28d3c8e75307460f148e62bf9e2ef0b61b493
7
+ data.tar.gz: aad4f465e8a28aeb52305bbc3c541fce38985e92cb108b32e92109ecd74039c1801aa51ee3a8e527f9d4456b6a5ea60e30fa0515cbc4e3ce673a8ff1da06fdaf
@@ -1,3 +1 @@
1
- <svg xmlns="http://www.w3.org/2000/svg" version="1.1" width="8" height="8" data-icon="aperture" viewBox="0 0 34 34">
2
- <path d="M17 0c9.389 0 17 7.611 17 17s-7.611 17-17 17S0 26.389 0 17 7.611 0 17 0zm0 1.889C8.654 1.889 1.889 8.654 1.889 17S8.654 32.111 17 32.111 32.111 25.346 32.111 17 25.346 1.889 17 1.889zm11.865 10.74a3.15 3.15 0 1 1-6.3 0 3.15 3.15 0 0 1 6.3 0zm-1.89 0a1.26 1.26 0 1 0-2.521 0 1.26 1.26 0 0 0 2.522 0zM15.25 19.136a.944.944 0 0 1 1.89 0v1.792a5.71 5.71 0 1 1-11.423 0v-1.792a.944.944 0 0 1 1.89 0v1.792a3.822 3.822 0 1 0 7.643 0v-1.792zm5.841-6.974l.018.019a.941.941 0 0 1-.02 1.335l-2.514 2.44a.944.944 0 0 1-1.316-1.355l.843-.818a6.237 6.237 0 0 0-6.177 6.23.944.944 0 0 1-1.889 0c0-4.492 3.653-8.12 8.12-8.12h.041l-.958-.986a.944.944 0 0 1 1.355-1.316l2.497 2.571a.941.941 0 0 0-.66-.268h-2.234z"/>
3
- </svg>
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="8" height="8" data-icon="aperture" version="1.1" viewBox="0 0 34 34"><path d="M17 0c9.389 0 17 7.611 17 17s-7.611 17-17 17S0 26.389 0 17 7.611 0 17 0zm0 1.889C8.654 1.889 1.889 8.654 1.889 17S8.654 32.111 17 32.111 32.111 25.346 32.111 17 25.346 1.889 17 1.889zm11.865 10.74a3.15 3.15 0 1 1-6.3 0 3.15 3.15 0 0 1 6.3 0zm-1.89 0a1.26 1.26 0 1 0-2.521 0 1.26 1.26 0 0 0 2.522 0zM15.25 19.136a.944.944 0 0 1 1.89 0v1.792a5.71 5.71 0 1 1-11.423 0v-1.792a.944.944 0 0 1 1.89 0v1.792a3.822 3.822 0 1 0 7.643 0v-1.792zm5.841-6.974l.018.019a.941.941 0 0 1-.02 1.335l-2.514 2.44a.944.944 0 0 1-1.316-1.355l.843-.818a6.237 6.237 0 0 0-6.177 6.23.944.944 0 0 1-1.889 0c0-4.492 3.653-8.12 8.12-8.12h.041l-.958-.986a.944.944 0 0 1 1.355-1.316l2.497 2.571a.941.941 0 0 0-.66-.268h-2.234z"/></svg>
@@ -36,9 +36,9 @@
36
36
  }
37
37
 
38
38
  .sortition-details-text{
39
- text-transform: uppercase;
40
39
  letter-spacing: .03em;
41
40
  font-size: 90%;
41
+ text-transform: uppercase;
42
42
  color: #3d393c;
43
43
  font-weight: 600;
44
44
  line-height: 1;
@@ -1,14 +1,14 @@
1
1
  <div class="card__icondata">
2
2
  <ul class="card-data">
3
3
  <li class="card-data__item">
4
- <%= icon "random-seed", class: "icon--big" %>
4
+ <%= icon "random-seed", class: "icon--big", aria_label: t("decidim.sortitions.sortitions.sortition.random_seed"), role: "img" %>
5
5
  </li>
6
6
  <li class="card-data__item">
7
- <div class="text-left text-uppercase">
7
+ <div class="text-left">
8
8
  <strong class="heading4">
9
9
  <%= model.seed %>
10
10
  </strong>
11
- &nbsp;<small><%= t("decidim.sortitions.sortitions.sortition.random_seed") %></small>
11
+ &nbsp;<small aria-hidden="true"><%= t("decidim.sortitions.sortitions.sortition.random_seed") %></small>
12
12
  </div>
13
13
  </li>
14
14
  </ul>
@@ -1,6 +1,6 @@
1
1
  <div class="card__footer">
2
2
  <div class="card__support">
3
- <div class="text-uppercase">
3
+ <div>
4
4
  <strong class="text-large">
5
5
  <%= proposals_count %>
6
6
  </strong>
@@ -2,7 +2,7 @@
2
2
 
3
3
  module Decidim
4
4
  module Sortitions
5
- class SortitionWidgetsController < Decidim::WidgetsController
5
+ class WidgetsController < Decidim::WidgetsController
6
6
  helper Decidim::SanitizeHelper
7
7
  helper Sortitions::SortitionsHelper
8
8
 
@@ -13,7 +13,7 @@ module Decidim
13
13
  end
14
14
 
15
15
  def iframe_url
16
- @iframe_url ||= sortition_sortition_widget_url(model)
16
+ @iframe_url ||= sortition_widget_url(model)
17
17
  end
18
18
  end
19
19
  end
@@ -3,6 +3,7 @@
3
3
  module Decidim
4
4
  module Sortitions
5
5
  module SortitionsHelper
6
+ include Decidim::SanitizeHelper
6
7
  include Decidim::TranslationsHelper
7
8
 
8
9
  def proposal_path(proposal)
@@ -13,9 +13,12 @@ module Decidim
13
13
  include Decidim::Loggable
14
14
  include Decidim::Comments::Commentable
15
15
  include Decidim::Randomable
16
+ include Decidim::TranslatableResource
16
17
 
17
18
  component_manifest_name "sortitions"
18
19
 
20
+ translatable_fields :title, :witnesses, :additional_info, :cancel_reason
21
+
19
22
  belongs_to :decidim_proposals_component,
20
23
  foreign_key: "decidim_proposals_component_id",
21
24
  class_name: "Decidim::Component"
@@ -25,7 +25,10 @@ module Decidim
25
25
  if category.nil?
26
26
  return Decidim::Proposals::Proposal
27
27
  .except_withdrawn
28
- .where("created_at < ?", request_timestamp)
28
+ .except_drafts
29
+ .except_rejected
30
+ .not_hidden
31
+ .where("decidim_proposals_proposals.created_at < ?", request_timestamp)
29
32
  .where(component: sortition.decidim_proposals_component)
30
33
  .order(id: :asc)
31
34
  end
@@ -34,6 +37,9 @@ module Decidim
34
37
  Decidim::Proposals::Proposal
35
38
  .joins(:categorization)
36
39
  .except_withdrawn
40
+ .except_drafts
41
+ .except_rejected
42
+ .not_hidden
37
43
  .where(component: sortition.decidim_proposals_component)
38
44
  .where("decidim_proposals_proposals.created_at < ?", request_timestamp)
39
45
  .where("decidim_categorizations.decidim_category_id = ?", category.id)
@@ -5,6 +5,7 @@ module Decidim
5
5
  # A service to encapsualte all the logic when searching and filtering
6
6
  # sortitions in a participatory process.
7
7
  class SortitionSearch < ResourceSearch
8
+ text_search_fields :title, :additional_info, :witnesses
8
9
  # Public: Initializes the service.
9
10
  # component - A Decidim::Component to get the proposals from.
10
11
  # page - The page number to paginate the results.
@@ -13,18 +14,6 @@ module Decidim
13
14
  super(Sortition.all, options)
14
15
  end
15
16
 
16
- # Handle the search_text filter
17
- def search_search_text
18
- query
19
- .where("title->>'#{current_locale}' ILIKE ?", "%#{search_text}%")
20
- .or(
21
- query.where("additional_info->>'#{current_locale}' ILIKE ?", "%#{search_text}%")
22
- )
23
- .or(
24
- query.where("witnesses->>'#{current_locale}' ILIKE ?", "%#{search_text}%")
25
- )
26
- end
27
-
28
17
  # Handle the state filter
29
18
  def search_state
30
19
  case state
@@ -36,12 +25,6 @@ module Decidim
36
25
  query
37
26
  end
38
27
  end
39
-
40
- private
41
-
42
- def current_locale
43
- I18n.locale.to_s
44
- end
45
28
  end
46
29
  end
47
30
  end
@@ -0,0 +1,32 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Decidim
4
+ module Sortitions
5
+ SortitionType = GraphQL::ObjectType.define do
6
+ interfaces [
7
+ -> { Decidim::Core::AuthorableInterface },
8
+ -> { Decidim::Comments::CommentableInterface },
9
+ -> { Decidim::Core::CategorizableInterface }
10
+ ]
11
+
12
+ name "Sortition"
13
+ description "A sortition"
14
+
15
+ field :id, !types.ID, "The internal ID for this sortition"
16
+ field :dice, types.Int, "The dice for this sortition"
17
+ field :targetItems, types.Int, "The target items for this sortition", property: :target_items
18
+ field :requestTimestamp, Decidim::Core::DateType, "The request time stamp for this request", property: :request_timestamp
19
+ field :selectedProposals, types[types.Int], "The selected proposals for this sortition", property: :selected_proposals
20
+ field :createdAt, Decidim::Core::DateTimeType, "When this sortition was created", property: :created_at
21
+ field :updatedAt, Decidim::Core::DateTimeType, "When this sortition was updated", property: :updated_at
22
+ field :witnesses, Decidim::Core::TranslatedFieldType, "The witnesses for this sortition"
23
+ field :additionalInfo, Decidim::Core::TranslatedFieldType, "The additional info for this sortition", property: :additional_info
24
+ field :reference, types.String, "The reference for this sortition"
25
+ field :title, Decidim::Core::TranslatedFieldType, "The title for this sortition"
26
+ field :cancelReason, Decidim::Core::TranslatedFieldType, "The cancel reason for this sortition", property: :cancel_reason
27
+ field :cancelledOn, Decidim::Core::DateType, "When this sortition was cancelled", property: :cancelled_on
28
+ field :cancelledByUser, Decidim::Core::UserType, "Who cancelled this sortition", property: :cancelled_by_user
29
+ field :candidateProposals, Decidim::Core::TranslatedFieldType, "The candidate proposal for this sortition", property: :candidate_proposals
30
+ end
31
+ end
32
+ end
@@ -0,0 +1,32 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Decidim
4
+ module Sortitions
5
+ SortitionsType = GraphQL::ObjectType.define do
6
+ interfaces [-> { Decidim::Core::ComponentInterface }]
7
+
8
+ name "Sortitions"
9
+ description "A sortition component of a participatory space."
10
+
11
+ connection :sortitions, SortitionType.connection_type do
12
+ resolve ->(component, _args, _ctx) {
13
+ SortitionTypeHelper.base_scope(component).includes(:component)
14
+ }
15
+ end
16
+
17
+ field(:sortition, SortitionType) do
18
+ argument :id, !types.ID
19
+
20
+ resolve ->(component, args, _ctx) {
21
+ SortitionTypeHelper.base_scope(component).find_by(id: args[:id])
22
+ }
23
+ end
24
+ end
25
+
26
+ module SortitionTypeHelper
27
+ def self.base_scope(component)
28
+ Sortition.where(component: component)
29
+ end
30
+ end
31
+ end
32
+ end
@@ -18,7 +18,7 @@
18
18
  <div class="columns xlarge-4">
19
19
  <%= form.categories_select :decidim_category_id,
20
20
  @form.categories,
21
- prompt: t(".all_categories") %>
21
+ include_blank: t(".all_categories") %>
22
22
  </div>
23
23
 
24
24
  <div class="columns xlarge-4">
@@ -3,7 +3,7 @@
3
3
  <%= decidim_form_for(@form, html: { class: "form confirm_destroy_sortition" }, method: :delete) do |form| %>
4
4
  <div class="card">
5
5
  <div class="card-divider">
6
- <h2 class="card-title"><%= translated_attribute sortition.title %></h2>
6
+ <h2 class="card-title"><%= decidim_html_escape(translated_attribute(sortition.title)) %></h2>
7
7
  </div>
8
8
 
9
9
  <div class="card-section">
@@ -1,5 +1,5 @@
1
1
  <h2 class="process-title-summary">
2
- <%= translated_attribute(sortition.title) %>
2
+ <%= decidim_html_escape(translated_attribute(sortition.title)) %>
3
3
  </h2>
4
4
 
5
5
  <%= decidim_form_for(@form, html: { class: "form edit_sortition" }) do |form| %>
@@ -25,7 +25,7 @@
25
25
  <% sortitions.each do |sortition| %>
26
26
  <tr>
27
27
  <td><%= sortition.reference %></td>
28
- <td><%= translated_attribute sortition.title %></td>
28
+ <td><%= decidim_html_escape(translated_attribute(sortition.title)) %></td>
29
29
  <td><%= l sortition.created_at, format: :short %></td>
30
30
  <td class="table-list__actions">
31
31
  <%= icon_link_to "eye",
@@ -1,7 +1,7 @@
1
1
  <div class="card" id="sortition">
2
2
  <div class="card-divider">
3
3
  <h2 class="card-title">
4
- <%= translated_attribute(sortition.title) %>
4
+ <%= decidim_html_escape(translated_attribute(sortition.title)) %>
5
5
  </h2>
6
6
  </div>
7
7
  <div class="card-section">
@@ -1,4 +1,4 @@
1
- <% content_for(:title, translated_attribute(model.title)) %>
1
+ <% content_for(:title, decidim_html_escape(translated_attribute(model.title))) %>
2
2
  <p>
3
3
  <%= decidim_sanitize html_truncate(translated_attribute(model.additional_info), length: 100, separator: "...") %>
4
4
  </p>
@@ -1,11 +1,13 @@
1
+ <%= render partial: "decidim/shared/filter_form_help", locals: { skip_to_id: "sortitions" } %>
2
+
1
3
  <%= filter_form_for filter do |form| %>
2
4
  <div class="filters__section">
3
5
  <div class="filters__search">
4
6
  <div class="input-group">
5
- <%= form.search_field :search_text, label: false, class: "input-group-field", placeholder: t(".search") %>
7
+ <%= form.search_field :search_text, label: false, class: "input-group-field", placeholder: t(".search"), title: t(".search"), data: { disable_dynamic_change: true } %>
6
8
  <div class="input-group-button">
7
- <button type="submit" class="button button--muted">
8
- <%= icon "magnifying-glass", aria_label: t(".search") %>
9
+ <button type="submit" class="button" aria-controls="sortitions">
10
+ <%= icon "magnifying-glass", aria_label: t(".search"), role: "img" %>
9
11
  </button>
10
12
  </div>
11
13
  </div>
@@ -15,17 +17,23 @@
15
17
  <% if current_participatory_space.categories.any? %>
16
18
  <%= form.categories_select :category_id,
17
19
  current_participatory_space.categories,
18
- legend_title: t(".category"),
19
- disable_parents: false,
20
- label: false,
21
- prompt: t(".category_prompt") %>
20
+ {
21
+ legend_title: t(".category"),
22
+ disable_parents: false,
23
+ label: "",
24
+ include_blank: t(".category_prompt"),
25
+ aria_label: t(".category")
26
+ },
27
+ "aria-label": t(".category"),
28
+ "aria-controls": "sortitions" %>
22
29
  <% end %>
23
30
 
24
31
  <%= form.collection_radio_buttons :state,
25
32
  [["all", t(".all")], ["active", t(".active")], ["cancelled", t(".cancelled")]],
26
33
  :first,
27
34
  :last,
28
- legend_title: t(".state") %>
35
+ { legend_title: t(".state") },
36
+ "aria-controls": "sortitions" %>
29
37
 
30
38
  <%= hidden_field_tag :order, order, id: nil, class: "order_filter" %>
31
39
  <% end %>
@@ -7,7 +7,7 @@
7
7
  <% end %>
8
8
  <div>
9
9
  <%= link_to resource_locator(sortition).path, class: "card__link" do %>
10
- <h5 class="card--list__heading"><%= translated_attribute sortition.title %></h5>
10
+ <h5 class="card--list__heading"><%= decidim_html_escape(translated_attribute(sortition.title)) %></h5>
11
11
  <% end %>
12
12
  <div class="author">
13
13
  <span class="author__avatar">
@@ -1,8 +1,8 @@
1
1
  <div class="row columns">
2
2
  <div class="title-action">
3
- <h2 id="sortitions-count" class="title-action__title section-heading">
3
+ <h3 id="sortitions-count" class="title-action__title section-heading">
4
4
  <%= render partial: "sortitions_count" %>
5
- </h2>
5
+ </h3>
6
6
  </div>
7
7
  </div>
8
8
  <div class="row">
@@ -12,10 +12,10 @@
12
12
  <%= render partial: "filters" %>
13
13
  </div>
14
14
  </div>
15
- <div id="sortitions" class="columns mediumlarge-8 large-9">
15
+ <div id="sortitions" class="columns mediumlarge-8 large-9" aria-live="polite">
16
16
  <%= render partial: "sortitions" %>
17
17
  </div>
18
18
  </div>
19
19
 
20
20
  <%= javascript_include_tag("decidim/filters") %>
21
- <%= javascript_include_tag "decidim/orders" %>
21
+ <%= javascript_include_tag "decidim/results_listing" %>
@@ -1,6 +1,6 @@
1
1
  <% add_decidim_meta_tags({
2
2
  description: decidim_sanitize(translated_attribute(sortition.additional_info)),
3
- title: translated_attribute(sortition.title),
3
+ title: decidim_html_escape(translated_attribute(sortition.title)),
4
4
  url: sortition_url(sortition.to_param)
5
5
  }) %>
6
6
 
@@ -11,7 +11,13 @@
11
11
  </div>
12
12
 
13
13
  <div class="row column view-header">
14
- <h2 class="heading2"><%= translated_attribute sortition.title %></h2>
14
+
15
+ <%= link_to :sortitions, class: "small hollow" do %>
16
+ <%= icon "chevron-left", class: "icon--small", role: "img", "aria-hidden": true %>
17
+ <%= t(".back") %>
18
+ <% end %>
19
+
20
+ <h2 class="heading2"><%= decidim_html_escape(translated_attribute(sortition.title)) %></h2>
15
21
  <div class="author-data">
16
22
  <%= render partial: "sortition_author", locals: { sortition: sortition } %>
17
23
  </div>
@@ -26,7 +32,7 @@
26
32
  </div>
27
33
  <%= resource_reference(sortition) %>
28
34
  <%= render partial: "decidim/shared/share_modal" %>
29
- <%= embed_modal_for sortition_sortition_widget_url(sortition, format: :js) %>
35
+ <%= embed_modal_for sortition_widget_url(sortition, format: :js) %>
30
36
  </div>
31
37
 
32
38
  <div class="columns mediumlarge-8 mediumlarge-pull-4">
@@ -0,0 +1 @@
1
+ am:
@@ -0,0 +1,7 @@
1
+ bg:
2
+ activemodel:
3
+ attributes:
4
+ sortition:
5
+ additional_info: Сортиране на информация
6
+ decidim_category_id: Категории от набора от предложения, в които искате да приложите жребий
7
+ decidim_proposals_component_id: Предложенията са зададени
@@ -0,0 +1,7 @@
1
+ bg:
2
+ activemodel:
3
+ attributes:
4
+ sortition:
5
+ additional_info: Сортиране на информация
6
+ decidim_category_id: Категории от набора от предложения, в които искате да приложите жребий
7
+ decidim_proposals_component_id: Предложенията са зададени
@@ -23,6 +23,7 @@ ca:
23
23
  settings:
24
24
  global:
25
25
  comments_enabled: Comentaris habilitats
26
+ comments_max_length: Longitud màxima dels comentaris (deixa 0 si vols mantenir la configuració per defecte)
26
27
  events:
27
28
  sortitions:
28
29
  sortition_created:
@@ -124,6 +125,7 @@ ca:
124
125
  show:
125
126
  algorithm: Codi d'algoritme del sorteig
126
127
  any_category: de totes les categories
128
+ back: Torna al llistat
127
129
  cancelled: Sorteig cancel·lat
128
130
  candidate_proposal_ids: Ordre i IDs de les propostes del sorteig
129
131
  candidate_proposals_info: 'La resolució es va dur a terme entre les següents propostes (%{category_label}), amb les següents IDs (en negreta, les propostes seleccionades) '
@@ -10,119 +10,120 @@ cs:
10
10
  title: Titul
11
11
  witnesses: Svědkové
12
12
  models:
13
- decidim/sortitions/create_sortition_event: Sortiment
13
+ decidim/sortitions/create_sortition_event: Losování
14
14
  activerecord:
15
15
  models:
16
16
  decidim/sortitions/sortition:
17
17
  one: Sortiment
18
18
  few: Sortitions
19
19
  many: Sortitions
20
- other: Sortitions
20
+ other: Losování
21
21
  decidim:
22
22
  components:
23
23
  sortitions:
24
- name: Sortitions
24
+ name: Losování
25
25
  settings:
26
26
  global:
27
27
  comments_enabled: Komentáře povoleny
28
+ comments_max_length: Maximální délka komentáře (ponechte 0 pro výchozí hodnotu)
28
29
  events:
29
30
  sortitions:
30
31
  sortition_created:
31
- email_intro: Řádek "%{resource_title}" byl přidán k "%{participatory_space_title}", který sledujete.
32
- email_outro: Toto oznámení jste obdrželi, protože jste sledovali "%{participatory_space_title}". Můžete jej odhlásit od předchozího odkazu.
33
- email_subject: Nová sortie byla přidána k číslu %{participatory_space_title}
34
- notification_title: Výsledek <a href="%{resource_path}">%{resource_title}</a> byl přidán k %{participatory_space_title}
32
+ email_intro: Losování "%{resource_title}" bylo přidáno k "%{participatory_space_title}", který sledujete.
33
+ email_outro: Toto oznámení jste obdrželi, protože sledujete "%{participatory_space_title}". Můžete sledování odhlásit na předchozím odkazu.
34
+ email_subject: Nové losování bylo přidáno k %{participatory_space_title}
35
+ notification_title: Losování <a href="%{resource_path}">%{resource_title}</a> bylo přidáno k %{participatory_space_title}
35
36
  pages:
36
37
  home:
37
38
  statistics:
38
- sortitions_count: Sortitions
39
+ sortitions_count: Losování
39
40
  participatory_processes:
40
41
  statistics:
41
- sortitions_count: Sortitions
42
+ sortitions_count: Losování
42
43
  sortitions:
43
44
  admin:
44
45
  actions:
45
- destroy: Zrušit výběr
46
+ destroy: Zrušit losování
46
47
  edit: Upravit
47
- new: Nové rozvržení
48
- show: Podrobnosti o sortimentu
48
+ new: Nové losování
49
+ show: Detaily losování
49
50
  models:
50
51
  sortition:
51
52
  fields:
52
53
  category: Kategorie
53
- created_at: Datum vzniku
54
+ created_at: Datum vytvoření
54
55
  decidim_proposals_component: Součást návrhů
55
56
  dice: Kostky
56
57
  reference: Odkaz
57
- request_timestamp: Doba kreslení
58
- seed: Semínko
59
- target_items: Položky, které chcete vybrat
60
- title: Titul
58
+ request_timestamp: Čas vržení kostek
59
+ seed: Založení
60
+ target_items: Položky k výběru
61
+ title: Název
61
62
  name:
62
- one: Sortiment
63
- few: Sortitions
63
+ one: Třídění
64
+ few: Třídění
64
65
  many: Sortitions
65
- other: Sortitions
66
+ other: Losování
66
67
  sortitions:
67
68
  confirm_destroy:
68
- confirm_destroy: Opravdu chcete tuto nabídku zrušit?
69
- destroy: Zrušit výběr
70
- title: Zrušení výběrového řízení
69
+ confirm_destroy: Opravdu chcete zrušit toto losování?
70
+ destroy: Zrušit losování
71
+ title: Zrušení losování
71
72
  create:
72
- error: Při vytváření nového rozvržení došlo k chybě.
73
- success: Sorta byla úspěšně vytvořena
73
+ error: Při vytváření nového losování došlo k chybě.
74
+ success: Losování bylo úspěšně vytvořeno
74
75
  destroy:
75
- error: Výběr nelze zrušit.
76
- success: Sorta byla úspěšně zrušena
76
+ error: Nelze zrušit losování.
77
+ success: Losování bylo úspěšně zrušeno
77
78
  edit:
78
- title: Aktualizujte informace o sortimentu
79
+ title: Aktualizovat informace o losování
79
80
  update: Aktualizace
80
81
  form:
81
82
  all_categories: Všechny kategorie
82
- select_proposal_component: Vyberte návrhy
83
- title: Nové návrhy na návrhy
83
+ select_proposal_component: Vyberte sadu návrhů
84
+ title: Nové losování pro návrhy
84
85
  index:
85
- title: Sortitions
86
+ title: Losování
86
87
  new:
87
- confirm: Stisknutím dalšího tlačítka Decidim zaznamenáte datum a čas (s přesností na sekundy) a společně s kolečkem o kostkách budou tyto informace použity pro generování náhodného výběru. Akce bude nevratná, po kliknutí na tlačítko se výsledky této kresby zveřejní společně s údaji uvedenými v tomto formuláři a nelze je změnit, zkontrolujte prosím pozorně obsah
88
+ confirm: Stisknutím dalšího tlačítka Decidim zaznamená datum a čas (s přesností sekund) a spolu s vržením kostkou tyto informace budou použity k vytvoření náhodného výběru. Akce bude nevratná, po kliknutí na tlačítko bude výsledek tohoto vrhu publikován, spolu s údaji zadanými v tomto formuláři a nelze je změnit, pečlivě zkontrolujte obsah
88
89
  create: Vytvořit
89
- title: Nové rozvržení
90
+ title: Nové losování
90
91
  show:
91
- selected_proposals: Návrhy vybrané pro kreslení
92
+ selected_proposals: Návrhy vybrané pro losování
92
93
  update:
93
- error: Při aktualizaci výběru došlo k chybě.
94
- success: Sortifikace byla úspěšně aktualizována
94
+ error: Při aktualizaci losování došlo k chybě.
95
+ success: Losování úspěšně aktualizováno
95
96
  admin_log:
96
97
  sortition:
97
98
  create: "%{user_name} vytvořil %{resource_name} sortit v %{space_name}"
98
- delete: "%{user_name} zrušil %{resource_name} sortit v %{space_name}"
99
- update: "%{user_name} aktualizoval %{resource_name} sorotu v %{space_name}"
99
+ delete: "%{user_name} zrušil losování %{resource_name} v %{space_name}"
100
+ update: "%{user_name} aktualizoval losování %{resource_name} v %{space_name}"
100
101
  sortitions:
101
102
  count:
102
103
  proposals_count:
103
- one: 1
104
+ one: návrh
104
105
  few: "%{count} návrhů"
105
106
  many: "%{count} návrhů"
106
107
  other: "%{count} návrhů"
107
108
  filters:
108
109
  active: Aktivní
109
- all: Všechno
110
+ all: Vše
110
111
  cancelled: Zrušeno
111
112
  category: Kategorie
112
113
  category_prompt: Vyberte kategorii
113
114
  search: Vyhledávání
114
- state: Stát
115
+ state: Stav
115
116
  filters_small_view:
116
- close_modal: Zavřít modální
117
+ close_modal: Zavřít okno
117
118
  filter: Filtr
118
119
  filter_by: Filtrovat podle
119
- unfold: Rozvinout
120
+ unfold: Rozbalit
120
121
  linked_sortitions:
121
122
  selected_proposals: Vybrané návrhy
122
123
  orders:
123
- label: 'Objednat sortitions podle:'
124
+ label: 'Řazení losování podle:'
124
125
  random: Náhodný
125
- recent: Nedávno
126
+ recent: Nedávné
126
127
  results_count:
127
128
  count:
128
129
  one: vybraný návrh
@@ -130,34 +131,35 @@ cs:
130
131
  many: vybrané návrhy
131
132
  other: vybrané návrhy
132
133
  show:
133
- algorithm: Kód algoritmu Sortition
134
+ algorithm: Kód algoritmu losování
134
135
  any_category: ze všech kategorií
135
- cancelled: Zrušený výběr
136
- candidate_proposal_ids: Sortimentní objednávky a ID
137
- candidate_proposals_info: 'Rozbor byl proveden mezi následujícími návrhy (%{category_label}), s následujícími ID (označené tučně vybranými návrhy) '
136
+ back: Zpět na seznam
137
+ cancelled: Zrušené losování
138
+ candidate_proposal_ids: Pořadí a ID návrhů k losování
139
+ candidate_proposals_info: 'Losování bylo provedeno mezi následujícími návrhy (%{category_label}), s následujícími ID (označené tučně vybrané návrhy) '
138
140
  category: z kategorie %{category}
139
- dice_result: "(1) Výsledek kostky"
140
- introduction: 'Tato stránka obsahuje výsledky výběru %{reference}. Prostřednictvím tohoto výběru bylo vybráno %{target_items} počet výsledků náhodně a se stejným rozdělením pravděpodobnosti ze souboru návrhů zobrazených níže. Spolu s výsledky informace zobrazené na této stránce poskytují všechny informace potřebné pro maximalizaci záruk a reprodukci výsledků. Klíčem k kvalitě tohoto rozvratu je dvojitá náhodnost, kterou poskytuje vázání kostky (ověřené svědky) a přesný čas výběru, který poskytuje vstup pro algoritmus, který generuje náhodný výběr. Časové osivo pro sortiment je tak přesné (sekundy), že není možné ovládat lidi, a tak poskytnout dvojitý "nekontrolovatelný" vstup, který zaručí spravedlivý výsledek. '
141
+ dice_result: "(1) Výsledek hodu kostkou"
142
+ introduction: 'Tato stránka obsahuje výsledky losování %{reference}. Prostřednictvím tohoto losování bylo vybráno %{target_items} počet výsledků náhodně a se stejným rozdělením pravděpodobnosti ze souboru návrhů zobrazených níže. Spolu s výsledky informace zobrazené na této stránce poskytují všechny informace potřebné pro maximalizaci záruk a reprodukci výsledků. Klíčem ke kvalitě tohoto losování je dvojitá náhodnost, kterou poskytuje hod kostkou (ověřený svědky) a přesný čas výběru, který poskytuje vstup pro algoritmus, který generuje náhodný výběr. Časový základ pro losování je tak přesný(sekundy), že není možné ovládat lidi, a tak lze poskytnout dvojitý "nekontrolovatelný" vstup, který zaručí spravedlivý výsledek. '
141
143
  mathematical_result: Výsledek (1) x (2)
142
- proposals_selected_by_sortition: Návrhy vybrané výběrem
143
- sortition_reproducibility_details: Sortifikace reprodukovatelnosti
144
- time_seed: "(2) Časové osivo"
145
- witnesses: Svědkové
144
+ proposals_selected_by_sortition: Návrhy vybrané losováním
145
+ sortition_reproducibility_details: Detaily reprodukovatelnosti losování
146
+ time_seed: "(2) Časový základ"
147
+ witnesses: Svědci
146
148
  sortition:
147
- random_seed: Náhodné osivo
149
+ random_seed: Náhodný časový základ
148
150
  selected_proposals:
149
151
  one: vybraný návrh
150
152
  few: vybraných návrhů
151
153
  many: vybraných návrhů
152
154
  other: vybraných návrhů
153
- view: Pohled
155
+ view: Zobrazit
154
156
  sortition_author:
155
- deleted: Vymazaný uživatel
157
+ deleted: Odstraněný uživatel
156
158
  sortition_cancel_author:
157
- deleted: Vymazaný uživatel
159
+ deleted: Odstraněný uživatel
158
160
  sortitions_count:
159
161
  count:
160
162
  one: 1 sortie
161
163
  few: "%{count} sortitions"
162
164
  many: "%{count} sortitions"
163
- other: "%{count} sortitions"
165
+ other: "%{count} losování"