diff --git a/.decidim-version b/.decidim-version index 6b0ed1aeebd7b..9c2255d5e8c09 100644 --- a/.decidim-version +++ b/.decidim-version @@ -1 +1 @@ -0.29.4 \ No newline at end of file +0.29.6 \ No newline at end of file diff --git a/.erb-lint.yml b/.erb-lint.yml index 111cc6c0970d8..2b7f7188f3be0 100644 --- a/.erb-lint.yml +++ b/.erb-lint.yml @@ -123,7 +123,6 @@ linters: - author-data__extra - author-data__main - author__avatar--small - - author__badge - author__date - author__name--container - author__nickname diff --git a/.github/workflows/test_app.yml b/.github/workflows/test_app.yml index e809bbbd79d92..38fe9263d4b70 100644 --- a/.github/workflows/test_app.yml +++ b/.github/workflows/test_app.yml @@ -41,7 +41,7 @@ on: chrome_version: description: 'Chrome & Chromedriver version' required: false - default: "126.0.6478.182" + default: "139.0.7258.66" type: string jobs: diff --git a/CHANGELOG.md b/CHANGELOG.md index 645435e1204f7..03515160227f4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,131 @@ # Changelog +## [0.29.6](https://github.com/decidim/decidim/tree/0.29.6) + +### Added + +Nothing. + +### Changed + +Nothing. + +### Fixed + +- **decidim-design**: Backport 'Fix some accessibility violations in design's a11y page' to v0.29 [\#15232](https://github.com/decidim/decidim/pull/15232) +- **decidim-core**: Backport 'Prevent reload on filters when the 'Skip to' links are clicked' to v0.29 [\#15243](https://github.com/decidim/decidim/pull/15243) +- **decidim-participatory processes**: Backport 'Fix translation missing for duplicate landing blocks' to v0.29 [\#15250](https://github.com/decidim/decidim/pull/15250) +- **decidim-accountability**, **decidim-admin**, **decidim-assemblies**, **decidim-conferences**, **decidim-core**, **decidim-demographics**, **decidim-design**, **decidim-elections**, **decidim-forms**, **decidim-meetings**, **decidim-participatory processes**, **decidim-surveys**: Backport 'Fix drag and drop sorting for questionnaires' to v0.29 [\#15248](https://github.com/decidim/decidim/pull/15248) +- **decidim-verifications**: Backport 'Fix incorrectly named initialize methods in `decidim-verifications`' to v0.29 [\#15294](https://github.com/decidim/decidim/pull/15294) +- **decidim-admin**: Backport 'Fix officialization view for users without nickname' to v0.29 [\#15246](https://github.com/decidim/decidim/pull/15246) +- **decidim-core**: Backport 'Fix focus with tab navigation on small avatar images' to v0.29 [\#15304](https://github.com/decidim/decidim/pull/15304) +- **decidim-core**, **decidim-proposals**: Backport 'Fix adjacent links in the related documents/attachments links' to v0.29 [\#15332](https://github.com/decidim/decidim/pull/15332) +- Backport 'Fix w3c validator CI pipeline (NuValidator json errors)' to v0.29 [\#15344](https://github.com/decidim/decidim/pull/15344) +- **decidim-core**: Backport 'Allow password validator to use the fallback translation' to v0.29 [\#15335](https://github.com/decidim/decidim/pull/15335) +- **decidim-core**: Backport 'Fix error unexpected value at params[:host]' to v0.29 [\#15338](https://github.com/decidim/decidim/pull/15338) +- Fix displaying the map for new proposals for v0.29 [\#15363](https://github.com/decidim/decidim/pull/15363) +- **decidim-core**: Backport 'Make the WYSIWYG editor vertical resizable' to v0.29 [\#15372](https://github.com/decidim/decidim/pull/15372) +- **decidim-core**: Backport 'Fix deleted comments on public profile' to v0.29 [\#15378](https://github.com/decidim/decidim/pull/15378) +- **decidim-core**: Backport 'Show badges next to user nicknames' to v0.29 [\#15351](https://github.com/decidim/decidim/pull/15351) +- Revert "Fix w3c validator CI pipeline (#15344)" [\#15382](https://github.com/decidim/decidim/pull/15382) +- **decidim-forms**: Backport 'Fix drag_and_drop on mobile without scrolling' to v0.29 [\#15389](https://github.com/decidim/decidim/pull/15389) +- **decidim-core**: Backport "Add format validation for name in UserGroup" (#15368) [\#15391](https://github.com/decidim/decidim/pull/15391) +- **decidim-admin**: Backport 'Add missing translation key for enable machine translation' to v0.29 [\#15386](https://github.com/decidim/decidim/pull/15386) + +### Removed + +Nothing. + +### Developer improvements + +Nothing. + +### Internal + +Nothing. + +## [0.29.5](https://github.com/decidim/decidim/tree/0.29.5) + +### Added + +Nothing. + +### Changed + +Nothing. + +### Fixed + +- **decidim-core**: Backport 'Fix accessibility on filters label' to v0.29 [\#14816](https://github.com/decidim/decidim/pull/14816) +- **decidim-core**: Backport 'Fix background color of default avatar image for accessibility' to v0.29 [\#14820](https://github.com/decidim/decidim/pull/14820) +- **decidim-core**, **decidim-proposals**: Backport 'Fix get rid of preview alt' to v0.29 [\#14818](https://github.com/decidim/decidim/pull/14818) +- **decidim-core**: Backport 'Fix missing for attribute on label and id on input' to v0.29 [\#14813](https://github.com/decidim/decidim/pull/14813) +- **decidim-core**, **decidim-debates**, **decidim-proposals**: Backport 'Fix view mode active icon in proposals for accessibility' to v0.29 [\#14825](https://github.com/decidim/decidim/pull/14825) +- **decidim-core**: Backport 'Fix accessibility on svg in card metadata cell' to v0.29 [\#14822](https://github.com/decidim/decidim/pull/14822) +- **decidim-core**: Backport 'Hide empty announcement block when no text is present' to v0.29 [\#14827](https://github.com/decidim/decidim/pull/14827) +- Backport 'Fix CORS instructions for cloud providers' to v0.29 [\#14843](https://github.com/decidim/decidim/pull/14843) +- **decidim-core**: Backport 'Fix flaky spec in announcements' to v0.29 [\#14839](https://github.com/decidim/decidim/pull/14839) +- **decidim-proposals**: Backport 'Prevent importing withdrawn or moderated proposals to another component' to v0.29 [\#14840](https://github.com/decidim/decidim/pull/14840) +- **decidim-comments**: Backport 'Fix opinion buttons on comments for accessibility' to v0.29 [\#14841](https://github.com/decidim/decidim/pull/14841) +- Fix specs for multiple_file_field_include_hidden [\#14873](https://github.com/decidim/decidim/pull/14873) +- **decidim-core**: Backport 'Fix report modals to improve accessibility' to v0.29 [\#14877](https://github.com/decidim/decidim/pull/14877) +- **decidim-comments**: Backport 'Fix Accessibility Like/Dislike Buttons on Comments' to v0.29 [\#14879](https://github.com/decidim/decidim/pull/14879) +- **decidim-conferences**: Backport 'Fix grammar in conference admin registration count info' to v0.29 [\#14893](https://github.com/decidim/decidim/pull/14893) +- **decidim-core**: Backport 'Fix aria label in date pickers of meetings form' to v0.29 [\#14918](https://github.com/decidim/decidim/pull/14918) +- **decidim-core**: Backport 'Re enable the localized specs' to v0.29 [\#14922](https://github.com/decidim/decidim/pull/14922) +- **decidim-core**: Backport 'Fix structure of search page's filters' to v0.29 [\#14924](https://github.com/decidim/decidim/pull/14924) +- **decidim-comments**: Backport 'Add aria labels for comment 'like' and 'dislike' buttons' to v0.29 [\#14926](https://github.com/decidim/decidim/pull/14926) +- **decidim-core**: Backport 'Fix hidden content in "More information"' to v0.29 [\#14927](https://github.com/decidim/decidim/pull/14927) +- **decidim-core**: Backport 'Fix truncated document name' to v0.29 [\#14930](https://github.com/decidim/decidim/pull/14930) +- Backport 'Fix UX modal for the admin to a group' to v0.29 [\#14932](https://github.com/decidim/decidim/pull/14932) +- **decidim-core**: Backport 'Fix search filter area for accessibility' to v0.29 [\#14954](https://github.com/decidim/decidim/pull/14954) +- **decidim-core**: Backport 'Fix main bar dropdown container fo accessibility' to v0.29 [\#14958](https://github.com/decidim/decidim/pull/14958) +- **decidim-assemblies**, **decidim-participatory processes**: Backport 'Fix importing attachments collections for processes and assemblies' to v0.29 [\#14956](https://github.com/decidim/decidim/pull/14956) +- **decidim-core**: Backport 'Breadcrumb mobile responsiveness nitpicks' to v0.29 [\#14964](https://github.com/decidim/decidim/pull/14964) +- **decidim-blogs**, **decidim-core**, **decidim-participatory processes**: Backport 'Participatory process card & blog post author fix' to v0.29 [\#15004](https://github.com/decidim/decidim/pull/15004) +- **decidim-core**: Backport 'Sticky footer 404 page' to v0.29 [\#15015](https://github.com/decidim/decidim/pull/15015) +- **decidim-proposals**: Backport 'Fixed proposal creation in admin when "Participants can create proposals" to v0.29 [\#15050](https://github.com/decidim/decidim/pull/15050) +- Backport 'Upgrade Chrome and ChromeDriver to 139.0.7258.66' to v0.29 [\#15072](https://github.com/decidim/decidim/pull/15072) +- **decidim-core**: Backport 'Fix specs running on local development environments' to v0.29 [\#15069](https://github.com/decidim/decidim/pull/15069) +- **decidim-core**: Backport 'Change minimun_characters to minimum_characters' to v0.29 [\#15078](https://github.com/decidim/decidim/pull/15078) +- **decidim-core**: Backport 'Fix aria-current on active filter in search page' to v0.29 [\#15110](https://github.com/decidim/decidim/pull/15110) +- **decidim-core**: Backport 'Fix editor mention selection range when selecting item with mouse' to v0.29 [\#15095](https://github.com/decidim/decidim/pull/15095) +- **decidim-forms**: Backport 'Error saving survey with empty mandatory fields' to v0.29 [\#15099](https://github.com/decidim/decidim/pull/15099) +- **decidim-core**: Backport 'Fix callout/flash message announcement to the screen reader' to v0.29 [\#15098](https://github.com/decidim/decidim/pull/15098) +- **decidim-surveys**: Backport 'Previewing questionnaires as a process admin' to v0.29 [\#15103](https://github.com/decidim/decidim/pull/15103) +- **decidim-core**: Backport 'Fix accessibility in header ' to v0.29 [\#15102](https://github.com/decidim/decidim/pull/15102) +- **decidim-core**, **decidim-proposals**: Backport 'Fix accessibility in footer' to v0.29 [\#15113](https://github.com/decidim/decidim/pull/15113) +- Backport 'Remove `Platoniq/decidim-install` references' to v0.29 [\#15137](https://github.com/decidim/decidim/pull/15137) +- **decidim-generators**: Backport 'Define the generated app's sidekiq version based on the redis version' to v0.29 [\#15139](https://github.com/decidim/decidim/pull/15139) +- Backport 'Fixed formatting error in documentation' to v0.29 [\#15153](https://github.com/decidim/decidim/pull/15153) +- **decidim-proposals**: Backport 'Fix proposal cards render alt-text when PDF attached' to v0.29 [\#15150](https://github.com/decidim/decidim/pull/15150) +- **decidim-core**: Backport 'Fix accessibility in breadcrumb_menu by replacing div and span by p' to v0.29 [\#15161](https://github.com/decidim/decidim/pull/15161) +- **decidim-core**, **decidim-newsletters**: Backport 'Unsubscribed page redesign ' to v0.29 [\#15166](https://github.com/decidim/decidim/pull/15166) +- **decidim-core**, **decidim-dev**, **decidim-proposals**: Backport 'Refactor amendment permissions' to v0.29 [\#15169](https://github.com/decidim/decidim/pull/15169) +- **decidim-core**: Backport 'Remove the word "new" in front of GDPR from the newsletter opt-in mail' to v0.29 [\#15203](https://github.com/decidim/decidim/pull/15203) +- **decidim-core**: Backport 'Fix 'Skip to main content' button visualization' to v0.29 [\#15205](https://github.com/decidim/decidim/pull/15205) +- **decidim-core**: Backport 'Fix size of the search button and contrast of the search form' to v0.29 [\#15207](https://github.com/decidim/decidim/pull/15207) + +### Removed + +Nothing. + +### Developer improvements + +- Backport 'Fix specs running on local development environments' to v0.29 [\#15069](https://github.com/decidim/decidim/pull/15069) +- Backport 'Refactor amendment permissions' to v0.29 [\#15169](https://github.com/decidim/decidim/pull/15169) + +### Internal + +- **decidim-core**: Backport 'Fix flaky spec in announcements' to v0.29 [\#14839](https://github.com/decidim/decidim/pull/14839) +- **decidim-conferences**: Backport 'Fix grammar in conference admin registration count info' to v0.29 [\#14893](https://github.com/decidim/decidim/pull/14893) +- Update Releases Notes after v0.29.4 [\#14946](https://github.com/decidim/decidim/pull/14946) +- Backport 'Upgrade Chrome and ChromeDriver to 139.0.7258.66' to v0.29 [\#15072](https://github.com/decidim/decidim/pull/15072) +- **decidim-core**: Backport 'Fix specs running on local development environments' to v0.29 [\#15069](https://github.com/decidim/decidim/pull/15069) +- **decidim-core**: Backport 'Remove the word "new" in front of GDPR from the newsletter opt-in mail' to v0.29 [\#15203](https://github.com/decidim/decidim/pull/15203) +- Bump charlock_holmes to v0.7.9 [\#15208](https://github.com/decidim/decidim/pull/15208) + ## [0.29.4](https://github.com/decidim/decidim/tree/0.29.4) ### Added diff --git a/Gemfile.lock b/Gemfile.lock index e638fd53d16c2..b84a40204b6d3 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,57 +1,57 @@ PATH remote: . specs: - decidim (0.29.4) - decidim-accountability (= 0.29.4) - decidim-admin (= 0.29.4) - decidim-api (= 0.29.4) - decidim-assemblies (= 0.29.4) - decidim-blogs (= 0.29.4) - decidim-budgets (= 0.29.4) - decidim-comments (= 0.29.4) - decidim-core (= 0.29.4) - decidim-debates (= 0.29.4) - decidim-forms (= 0.29.4) - decidim-generators (= 0.29.4) - decidim-meetings (= 0.29.4) - decidim-pages (= 0.29.4) - decidim-participatory_processes (= 0.29.4) - decidim-proposals (= 0.29.4) - decidim-sortitions (= 0.29.4) - decidim-surveys (= 0.29.4) - decidim-system (= 0.29.4) - decidim-verifications (= 0.29.4) - decidim-accountability (0.29.4) - decidim-comments (= 0.29.4) - decidim-core (= 0.29.4) - decidim-admin (0.29.4) + decidim (0.29.6) + decidim-accountability (= 0.29.6) + decidim-admin (= 0.29.6) + decidim-api (= 0.29.6) + decidim-assemblies (= 0.29.6) + decidim-blogs (= 0.29.6) + decidim-budgets (= 0.29.6) + decidim-comments (= 0.29.6) + decidim-core (= 0.29.6) + decidim-debates (= 0.29.6) + decidim-forms (= 0.29.6) + decidim-generators (= 0.29.6) + decidim-meetings (= 0.29.6) + decidim-pages (= 0.29.6) + decidim-participatory_processes (= 0.29.6) + decidim-proposals (= 0.29.6) + decidim-sortitions (= 0.29.6) + decidim-surveys (= 0.29.6) + decidim-system (= 0.29.6) + decidim-verifications (= 0.29.6) + decidim-accountability (0.29.6) + decidim-comments (= 0.29.6) + decidim-core (= 0.29.6) + decidim-admin (0.29.6) active_link_to (~> 1.0) - decidim-core (= 0.29.4) + decidim-core (= 0.29.6) devise (~> 4.7) devise-i18n (~> 1.2) devise_invitable (~> 2.0, >= 2.0.9) - decidim-api (0.29.4) - decidim-core (= 0.29.4) + decidim-api (0.29.6) + decidim-core (= 0.29.6) graphql (~> 2.2.6) graphql-docs (~> 4.0) rack-cors (~> 1.0) - decidim-assemblies (0.29.4) - decidim-core (= 0.29.4) - decidim-blogs (0.29.4) - decidim-admin (= 0.29.4) - decidim-comments (= 0.29.4) - decidim-core (= 0.29.4) - decidim-budgets (0.29.4) - decidim-comments (= 0.29.4) - decidim-core (= 0.29.4) - decidim-comments (0.29.4) - decidim-core (= 0.29.4) + decidim-assemblies (0.29.6) + decidim-core (= 0.29.6) + decidim-blogs (0.29.6) + decidim-admin (= 0.29.6) + decidim-comments (= 0.29.6) + decidim-core (= 0.29.6) + decidim-budgets (0.29.6) + decidim-comments (= 0.29.6) + decidim-core (= 0.29.6) + decidim-comments (0.29.6) + decidim-core (= 0.29.6) redcarpet (~> 3.5, >= 3.5.1) - decidim-conferences (0.29.4) - decidim-core (= 0.29.4) - decidim-meetings (= 0.29.4) + decidim-conferences (0.29.6) + decidim-core (= 0.29.6) + decidim-meetings (= 0.29.6) wicked_pdf (~> 2.7) - decidim-core (0.29.4) + decidim-core (0.29.6) active_link_to (~> 1.0) acts_as_list (~> 1.0) batch-loader (~> 1.2) @@ -102,16 +102,16 @@ PATH valid_email2 (~> 4.0) web-push (~> 3.0) wisper (~> 2.0) - decidim-debates (0.29.4) - decidim-comments (= 0.29.4) - decidim-core (= 0.29.4) - decidim-design (0.29.4) - decidim-core (= 0.29.4) - decidim-dev (0.29.4) + decidim-debates (0.29.6) + decidim-comments (= 0.29.6) + decidim-core (= 0.29.6) + decidim-design (0.29.6) + decidim-core (= 0.29.6) + decidim-dev (0.29.6) bullet (~> 7.1.6) byebug (~> 11.0) capybara (~> 3.39) - decidim (= 0.29.4) + decidim (= 0.29.6) erb_lint (~> 0.4.0) factory_bot_rails (~> 6.2) faker (~> 3.2) @@ -143,50 +143,50 @@ PATH w3c_rspec_validators (~> 0.3.0) webmock (~> 3.18) wisper-rspec (~> 1.0) - decidim-forms (0.29.4) - decidim-core (= 0.29.4) + decidim-forms (0.29.6) + decidim-core (= 0.29.6) wicked_pdf (~> 2.1) - decidim-generators (0.29.4) - decidim-core (= 0.29.4) - decidim-initiatives (0.29.4) - decidim-admin (= 0.29.4) - decidim-comments (= 0.29.4) - decidim-core (= 0.29.4) - decidim-verifications (= 0.29.4) + decidim-generators (0.29.6) + decidim-core (= 0.29.6) + decidim-initiatives (0.29.6) + decidim-admin (= 0.29.6) + decidim-comments (= 0.29.6) + decidim-core (= 0.29.6) + decidim-verifications (= 0.29.6) hexapdf (~> 0.32.0) wicked_pdf (~> 2.1) - decidim-meetings (0.29.4) - decidim-core (= 0.29.4) - decidim-forms (= 0.29.4) + decidim-meetings (0.29.6) + decidim-core (= 0.29.6) + decidim-forms (= 0.29.6) icalendar (~> 2.5) - decidim-pages (0.29.4) - decidim-core (= 0.29.4) - decidim-participatory_processes (0.29.4) - decidim-core (= 0.29.4) - decidim-proposals (0.29.4) - decidim-comments (= 0.29.4) - decidim-core (= 0.29.4) + decidim-pages (0.29.6) + decidim-core (= 0.29.6) + decidim-participatory_processes (0.29.6) + decidim-core (= 0.29.6) + decidim-proposals (0.29.6) + decidim-comments (= 0.29.6) + decidim-core (= 0.29.6) doc2text (~> 0.4.7) redcarpet (~> 3.5, >= 3.5.1) - decidim-sortitions (0.29.4) - decidim-admin (= 0.29.4) - decidim-comments (= 0.29.4) - decidim-core (= 0.29.4) - decidim-proposals (= 0.29.4) - decidim-surveys (0.29.4) - decidim-core (= 0.29.4) - decidim-forms (= 0.29.4) - decidim-system (0.29.4) + decidim-sortitions (0.29.6) + decidim-admin (= 0.29.6) + decidim-comments (= 0.29.6) + decidim-core (= 0.29.6) + decidim-proposals (= 0.29.6) + decidim-surveys (0.29.6) + decidim-core (= 0.29.6) + decidim-forms (= 0.29.6) + decidim-system (0.29.6) active_link_to (~> 1.0) - decidim-core (= 0.29.4) + decidim-core (= 0.29.6) devise (~> 4.7) devise-i18n (~> 1.2) devise_invitable (~> 2.0, >= 2.0.9) - decidim-templates (0.29.4) - decidim-core (= 0.29.4) - decidim-forms (= 0.29.4) - decidim-verifications (0.29.4) - decidim-core (= 0.29.4) + decidim-templates (0.29.6) + decidim-core (= 0.29.6) + decidim-forms (= 0.29.6) + decidim-verifications (0.29.6) + decidim-core (= 0.29.6) GEM remote: https://rubygems.org/ @@ -305,7 +305,7 @@ GEM cells-rails (0.1.5) actionpack (>= 5.0) cells (>= 4.1.6, < 5.0.0) - charlock_holmes (0.7.7) + charlock_holmes (0.7.9) cmdparse (3.0.7) commonmarker (0.23.10) concurrent-ruby (1.3.4) diff --git a/decidim-accountability/config/locales/bs-BA.yml b/decidim-accountability/config/locales/bs-BA.yml index c14bdf378f32e..64b3755e869c3 100644 --- a/decidim-accountability/config/locales/bs-BA.yml +++ b/decidim-accountability/config/locales/bs-BA.yml @@ -21,6 +21,7 @@ bs: progress: Napredak timeline_entry: description: Opis + entry_date: Datum title: Naslov models: decidim/accountability/proposal_linked_event: Predlog uključen u rezultat @@ -104,6 +105,7 @@ bs: progress: Napredak timeline_entry: fields: + entry_date: Datum title: Naslov results: count: diff --git a/decidim-accountability/config/locales/de.yml b/decidim-accountability/config/locales/de.yml index 312c80615ed0c..d2fd69806b700 100644 --- a/decidim-accountability/config/locales/de.yml +++ b/decidim-accountability/config/locales/de.yml @@ -8,7 +8,7 @@ de: decidim_scope_id: Umfang description: Beschreibung end_date: Enddatum - meetings_ids: Enthaltene Sitzungen + meetings_ids: Enthaltene Veranstaltungen progress: Fortschritt project_ids: Enthaltene Projekte proposals: Enthaltene Vorschläge @@ -266,12 +266,12 @@ de: events: accountability: proposal_linked: - email_intro: 'Der Vorschlag "%{proposal_title}" wurde in ein Ergebnis aufgenommen. Sie können das auf dieser Seite sehen:' + email_intro: 'Der Vorschlag "%{proposal_title}" wurde in ein Ergebnis aufgenommen. Sehen Sie es sich auf dieser Seite an:' email_outro: Sie haben diese Benachrichtigung erhalten, weil Sie "%{proposal_title}" folgen. Falls Sie keine solchen Benachrichtigungen mehr erhalten möchten, besuchen Sie den obigen Link. email_subject: Eine Aktualisierung auf %{proposal_title} notification_title: Der Vorschlag %{proposal_title} wurde im Ergebnis %{resource_title} aufgenommen. result_progress_updated: - email_intro: 'Das Ergebnis "%{resource_title}", das den Vorschlag "%{proposal_title}" enthält, ist jetzt zu %{progress}% abgeschlossen. Sie können das auf dieser Seite sehen:' + email_intro: 'Das Ergebnis "%{resource_title}", das den Vorschlag "%{proposal_title}" enthält, ist jetzt zu %{progress}% abgeschlossen. Sehen Sie es sich auf dieser Seite an:' email_outro: Sie haben diese Benachrichtigung erhalten, weil Sie "%{proposal_title}" folgen und dieser Vorschlag in das Ergebnis "%{resource_title}" aufgenommen wurde. Falls Sie keine solchen Benachrichtigungen mehr erhalten möchten, besuchen Sie den obigen Link. email_subject: Fortschritt von %{resource_title} aktualisiert notification_title: Das Ergebnis %{resource_title}, das den Vorschlag %{proposal_title} enthält, ist jetzt zu %{progress}% abgeschlossen. diff --git a/decidim-accountability/config/locales/sr-CS.yml b/decidim-accountability/config/locales/sr-CS.yml index 93a3a60192e52..2f5e598d32e5e 100644 --- a/decidim-accountability/config/locales/sr-CS.yml +++ b/decidim-accountability/config/locales/sr-CS.yml @@ -113,6 +113,8 @@ sr: other: "%{count} rezultata" filters: all: Sve + home: + subcategories_label: Pod kategorije home_header: global_status: Sveopšte stanje izvršenja nav_breadcrumb: diff --git a/decidim-accountability/lib/decidim/accountability/version.rb b/decidim-accountability/lib/decidim/accountability/version.rb index 286ea7d19ef9b..e33a2f53eee62 100644 --- a/decidim-accountability/lib/decidim/accountability/version.rb +++ b/decidim-accountability/lib/decidim/accountability/version.rb @@ -4,7 +4,7 @@ module Decidim # This holds decidim-accountability version. module Accountability def self.version - "0.29.4" + "0.29.6" end end end diff --git a/decidim-accountability/spec/system/preview_accountability_with_share_token_spec.rb b/decidim-accountability/spec/system/preview_accountability_with_share_token_spec.rb index e3701b7eace20..52e838eac9c96 100644 --- a/decidim-accountability/spec/system/preview_accountability_with_share_token_spec.rb +++ b/decidim-accountability/spec/system/preview_accountability_with_share_token_spec.rb @@ -2,9 +2,9 @@ require "spec_helper" -describe "Preview accountability with share token" do +describe "preview accountability with a share token" do let(:manifest_name) { "accountability" } include_context "with a component" - it_behaves_like "preview component with share_token" + it_behaves_like "preview component with a share_token" end diff --git a/decidim-admin/app/commands/decidim/admin/create_share_token.rb b/decidim-admin/app/commands/decidim/admin/create_share_token.rb new file mode 100644 index 0000000000000..85a3669d6672c --- /dev/null +++ b/decidim-admin/app/commands/decidim/admin/create_share_token.rb @@ -0,0 +1,39 @@ +# frozen_string_literal: true + +module Decidim + module Admin + # A command with all the business logic to create a share token. + # This command is called from the controller. + class CreateShareToken < Decidim::Commands::CreateResource + fetch_form_attributes :token, :expires_at, :registered_only, :organization, :user, :token_for + + protected + + def resource_class = Decidim::ShareToken + + def extra_params + { + participatory_space: { + title: participatory_space&.title + }, + resource: { + title: component&.name + } + } + end + + def participatory_space + return form.token_for if form.token_for.try(:manifest).is_a?(Decidim::ParticipatorySpaceManifest) + return current_participatory_space if respond_to?(:current_participatory_space) + + component&.participatory_space + end + + def component + return form.token_for if form.token_for.is_a?(Decidim::Component) + + form.token_for.try(:component) + end + end + end +end diff --git a/decidim-admin/app/commands/decidim/admin/destroy_share_token.rb b/decidim-admin/app/commands/decidim/admin/destroy_share_token.rb new file mode 100644 index 0000000000000..f4b9371aabfcf --- /dev/null +++ b/decidim-admin/app/commands/decidim/admin/destroy_share_token.rb @@ -0,0 +1,22 @@ +# frozen_string_literal: true + +module Decidim + module Admin + # A command with all the business logic to destroy a share token. + # This command is called from the controller. + class DestroyShareToken < Decidim::Commands::DestroyResource + delegate :participatory_space, :component, to: :resource + + def extra_params + { + participatory_space: { + title: participatory_space&.title + }, + resource: { + title: component&.name + } + } + end + end + end +end diff --git a/decidim-admin/app/commands/decidim/admin/update_share_token.rb b/decidim-admin/app/commands/decidim/admin/update_share_token.rb new file mode 100644 index 0000000000000..0a3bfee53db81 --- /dev/null +++ b/decidim-admin/app/commands/decidim/admin/update_share_token.rb @@ -0,0 +1,24 @@ +# frozen_string_literal: true + +module Decidim + module Admin + # A command with all the business logic to update a share token. + # This command is called from the controller. + class UpdateShareToken < Decidim::Commands::UpdateResource + fetch_form_attributes :expires_at, :registered_only + + delegate :participatory_space, :component, to: :resource + + def extra_params + { + participatory_space: { + title: participatory_space&.title + }, + resource: { + title: component&.name + } + } + end + end + end +end diff --git a/decidim-admin/app/controllers/decidim/admin/share_tokens_controller.rb b/decidim-admin/app/controllers/decidim/admin/share_tokens_controller.rb index 273fcf34fc280..abe6e9a1d043f 100644 --- a/decidim-admin/app/controllers/decidim/admin/share_tokens_controller.rb +++ b/decidim-admin/app/controllers/decidim/admin/share_tokens_controller.rb @@ -2,11 +2,66 @@ module Decidim module Admin + # This is an abstract controller allows sharing unpublished things. + # Final implementation must inherit from this controller and implement the `resource` method. class ShareTokensController < Decidim::Admin::ApplicationController + include Decidim::Admin::Filterable + + helper_method :current_token, :resource, :resource_title, :share_tokens_path + + def index + enforce_permission_to :read, :share_tokens + @share_tokens = filtered_collection + end + + def new + enforce_permission_to :create, :share_tokens + @form = form(ShareTokenForm).instance + end + + def create + enforce_permission_to :create, :share_tokens + @form = form(ShareTokenForm).from_params(params, resource:) + + CreateShareToken.call(@form) do + on(:ok) do + flash[:notice] = I18n.t("share_tokens.create.success", scope: "decidim.admin") + redirect_to share_tokens_path + end + + on(:invalid) do + flash.now[:alert] = I18n.t("share_tokens.create.invalid", scope: "decidim.admin") + render action: "new" + end + end + end + + def edit + enforce_permission_to(:update, :share_tokens, share_token: current_token) + @form = form(ShareTokenForm).from_model(current_token) + end + + def update + enforce_permission_to(:update, :share_tokens, share_token: current_token) + @form = form(ShareTokenForm).from_params(params, resource:) + + UpdateShareToken.call(@form, current_token) do + on(:ok) do + flash[:notice] = I18n.t("share_tokens.update.success", scope: "decidim.admin") + redirect_to share_tokens_path + end + + on(:invalid) do + flash.now[:alert] = I18n.t("share_tokens.update.error", scope: "decidim.admin") + render :edit + end + end + end + def destroy - enforce_permission_to(:destroy, :share_token, share_token:) + enforce_permission_to(:destroy, :share_tokens, share_token: current_token) - Decidim::Commands::DestroyResource.call(share_token, current_user) do + DestroyShareToken.call(current_token, current_user) do on(:ok) do flash[:notice] = I18n.t("share_tokens.destroy.success", scope: "decidim.admin") end @@ -15,15 +70,62 @@ def destroy end end - redirect_back(fallback_location: root_path) + redirect_to share_tokens_path end private - def share_token - @share_token ||= Decidim::ShareToken.where( - organization: current_organization - ).find(params[:id]) + # override this method in the destination controller to specify the resource associated with the shared token (ie: a component) + def resource + raise NotImplementedError + end + + # Override also this method if resource does not respond to a translatable name or title + def resource_title + translated_attribute(resource.try(:name) || resource.title) + end + + # sets the prefix for the route helper methods (this may vary depending on the resource type) + # This setup works fine for participatory spaces and components, override if needed + def route_name + @route_name ||= "#{resource.manifest.route_name}_" + end + + def route_proxy + @route_proxy ||= EngineRouter.admin_proxy(resource.try(:participatory_space) || resource) + end + + # returns the proper path for managing a share token according to the resource + # this works fine for components and participatory spaces, override if needed + def share_tokens_path(method = :index, options = {}) + args = resource.is_a?(Decidim::Component) ? [resource, options] : [options] + + case method + when :index, :create + route_proxy.send("#{route_name}share_tokens_path", *args) + when :new + route_proxy.send("new_#{route_name}share_token_path", *args) + when :update, :destroy + route_proxy.send("#{route_name}share_token_path", *args) + when :edit + route_proxy.send("edit_#{route_name}share_token_path", *args) + end + end + + def base_query + collection + end + + def collection + @collection ||= Decidim::ShareToken.where(organization: current_organization, token_for: resource) + end + + def filters + [] + end + + def current_token + @current_token ||= collection.find(params[:id]) end end end diff --git a/decidim-admin/app/forms/decidim/admin/share_token_form.rb b/decidim-admin/app/forms/decidim/admin/share_token_form.rb new file mode 100644 index 0000000000000..849d52f6259bd --- /dev/null +++ b/decidim-admin/app/forms/decidim/admin/share_token_form.rb @@ -0,0 +1,55 @@ +# frozen_string_literal: true + +module Decidim + module Admin + class ShareTokenForm < Decidim::Form + mimic :share_token + + attribute :token, String + attribute :automatic_token, Boolean, default: true + attribute :expires_at, Decidim::Attributes::TimeWithZone + attribute :no_expiration, Boolean, default: true + attribute :registered_only, Boolean, default: false + + validates :token, presence: true, if: ->(form) { form.automatic_token.blank? } + validate :token_uniqueness, if: ->(form) { form.automatic_token.blank? } + + validates_format_of :token, with: /\A[a-zA-Z0-9_-]+\z/, allow_blank: true + validates :expires_at, presence: true, if: ->(form) { form.no_expiration.blank? } + + def map_model(model) + self.no_expiration = model.expires_at.blank? + end + + def token + super.strip.upcase.gsub(/\s+/, "-") if super.present? + end + + def expires_at + return nil if no_expiration.present? + + super + end + + def token_for + context[:resource] + end + + def organization + context[:current_organization] + end + + def user + context[:current_user] + end + + private + + def token_uniqueness + return unless Decidim::ShareToken.where(organization:, token_for:, token:).where.not(id:).any? + + errors.add(:token, :taken) + end + end + end +end diff --git a/decidim-admin/app/packs/stylesheets/decidim/admin/_forms.scss b/decidim-admin/app/packs/stylesheets/decidim/admin/_forms.scss index 2a5c2f8fd1c00..661aae0fb41ac 100644 --- a/decidim-admin/app/packs/stylesheets/decidim/admin/_forms.scss +++ b/decidim-admin/app/packs/stylesheets/decidim/admin/_forms.scss @@ -58,24 +58,33 @@ } } -.questionnaire-question { - button[aria-expanded="true"] { - .icon-collapse { - @apply block; - } +.questionnaire-questions { + .questionnaire-question { + transition: all 0.2s ease; - .icon-expand { - @apply hidden; + svg[role="img"] { + cursor: default !important; + transition: color 0.2s ease; } - } - button[aria-expanded="false"] { - .icon-collapse { - @apply hidden; + button[aria-expanded="true"] { + .icon-collapse { + @apply block; + } + + .icon-expand { + @apply hidden; + } } - .icon-expand { - @apply block; + button[aria-expanded="false"] { + .icon-collapse { + @apply hidden; + } + + .icon-expand { + @apply block; + } } } } diff --git a/decidim-admin/app/views/decidim/admin/components/_actions.html.erb b/decidim-admin/app/views/decidim/admin/components/_actions.html.erb index 23904d799f08d..3e5527c59e300 100644 --- a/decidim-admin/app/views/decidim/admin/components/_actions.html.erb +++ b/decidim-admin/app/views/decidim/admin/components/_actions.html.erb @@ -4,11 +4,12 @@ <% end %> -<% if allowed_to? :share, :component, component: component %> - <%= icon_link_to "share-line", url_for(action: :share, id: component, controller: "components"), t("actions.share", scope: "decidim.admin"), target: :blank, class: "action-icon--share" %> +<% if component.manifest.admin_engine && allowed_to?(:share, :component, component: component) %> + <%= icon_link_to "share-line", component_share_tokens_path(component_id: component), t("actions.share_tokens", scope: "decidim.admin"), class: "action-icon--share" %> <% else %> <% end %> + <% if allowed_to? :update, :component, component: component %> <%= icon_link_to "settings-4-line", url_for(action: :edit, id: component, controller: "components"), t("actions.configure", scope: "decidim.admin"), class: "action-icon--configure" %> <% else %> diff --git a/decidim-admin/app/views/decidim/admin/components/_form.html.erb b/decidim-admin/app/views/decidim/admin/components/_form.html.erb index 7e50d45c4d01e..8369f16c7e3f8 100644 --- a/decidim-admin/app/views/decidim/admin/components/_form.html.erb +++ b/decidim-admin/app/views/decidim/admin/components/_form.html.erb @@ -114,13 +114,4 @@ <% end %> - <% if component && component.persisted? && !component.published? %> -
-
-
- <%= render partial: "decidim/admin/share_tokens/share_tokens", locals: { share_tokens: form.object.share_tokens } %> -
-
-
- <% end %> diff --git a/decidim-admin/app/views/decidim/admin/officializations/index.html.erb b/decidim-admin/app/views/decidim/admin/officializations/index.html.erb index 18f0ddfd86be1..59a3fbe464624 100644 --- a/decidim-admin/app/views/decidim/admin/officializations/index.html.erb +++ b/decidim-admin/app/views/decidim/admin/officializations/index.html.erb @@ -20,8 +20,13 @@ <% @users.each do |user| %> - <%= link_to_if user.nickname.present?, user.name, decidim.profile_path(user.nickname) %> - <%= link_to_if user.nickname.present?, user.nickname, decidim.profile_path(user.nickname) %> + <% if user.nickname.present? %> + <%= link_to user.name, decidim.profile_path(user.nickname) %> + <%= link_to user.nickname, decidim.profile_path(user.nickname) %> + <% else %> + <%= user.name %> + <%= user.nickname %> + <% end %> <%= l user.created_at, format: :short %> <%= user.officialized? ? t(".officialized") : t(".not_officialized") %> <%= translated_attribute(user.officialized_as) %> diff --git a/decidim-admin/app/views/decidim/admin/share_tokens/_form.html.erb b/decidim-admin/app/views/decidim/admin/share_tokens/_form.html.erb new file mode 100644 index 0000000000000..5b6e0be978c4e --- /dev/null +++ b/decidim-admin/app/views/decidim/admin/share_tokens/_form.html.erb @@ -0,0 +1,52 @@ +
+ + <%= form.collection_radio_buttons :no_expiration, [[true, t("share_tokens.form.never_expire", scope: "decidim.admin")], [false, t("share_tokens.form.custom", scope: "decidim.admin")]], :first, :last do |b| %> +
+ <%= b.radio_button %> + <%= b.label %> +
+ <% end %> + +
+ +
+ + <%= form.collection_radio_buttons :registered_only, [ + [t("share_tokens.form.true", scope: "decidim.admin"), true], + [t("share_tokens.form.false", scope: "decidim.admin"), false] + ], :last, :first do |b| %> +
+ <%= b.label do %> + <%= b.radio_button %> + <%= b.text %> + <% end %> +
+ <% end %> +
+ + diff --git a/decidim-admin/app/views/decidim/admin/share_tokens/_share_tokens.html.erb b/decidim-admin/app/views/decidim/admin/share_tokens/_share_tokens.html.erb deleted file mode 100644 index 4b9d7999c96ff..0000000000000 --- a/decidim-admin/app/views/decidim/admin/share_tokens/_share_tokens.html.erb +++ /dev/null @@ -1,45 +0,0 @@ -
-
- <%= t ".title" %> -
-
-
-

<%= t ".help" %>

-
- <% if share_tokens.any? %> -
- - - - - - - - - - - - - - <% share_tokens.each do |share_token| %> - - - - - - - - - - <% end %> - -
<%= t("models.share_token.fields.token", scope: "decidim.admin") %><%= t("models.share_token.fields.user", scope: "decidim.admin") %><%= t("models.share_token.fields.times_used", scope: "decidim.admin") %><%= t("models.share_token.fields.last_used_at", scope: "decidim.admin") %><%= t("models.share_token.fields.created_at", scope: "decidim.admin") %><%= t("models.share_token.fields.expires_at", scope: "decidim.admin") %>
<%= share_token.token %><%= share_token.user.name %><%= share_token.times_used %><%= l share_token.last_used_at, format: :short if share_token.last_used_at.present? %><%= l share_token.created_at, format: :short %><%= l share_token.expires_at, format: :short if share_token.expires_at.present? %> - <%= icon_link_to "share-line", share_token.url, t("actions.share", scope: "decidim.admin.share_tokens"), class: "action-icon--share", target: :blank %> - <%= icon_link_to "delete-bin-line", decidim_admin.share_token_path(share_token, url: request.fullpath), t("actions.destroy", scope: "decidim.admin.share_tokens"), class: "action-icon--remove", method: :delete, data: { confirm: t("actions.confirm_destroy", scope: "decidim.admin.share_tokens") } %> -
-
- <% else %> -

<%= t ".empty" %>

- <% end %> -
-
diff --git a/decidim-admin/app/views/decidim/admin/share_tokens/edit.html.erb b/decidim-admin/app/views/decidim/admin/share_tokens/edit.html.erb new file mode 100644 index 0000000000000..350e59e0ff4d1 --- /dev/null +++ b/decidim-admin/app/views/decidim/admin/share_tokens/edit.html.erb @@ -0,0 +1,33 @@ +<% add_decidim_page_title(t(".title", name: resource_title)) %> + +
+

+ <%= t ".title", name: resource_title %> + <%= t("share_tokens.index.back_to_share_tokens", scope: "decidim.admin") %> +

+
+
+ <%= decidim_form_for(@form, url: share_tokens_path(:update, id: current_token), html: { class: "form-defaults form edit_share_token" }) do |f| %> +
+
+
+
+
+ +
+ <%= text_field_tag :token, current_token.token, id: "share_token-token", aria: { label: t("token", scope: "decidim.admin.models.share_token.fields") }, disabled: true %> + +
+
+ <%= render partial: "form", object: f %> +
+
+
+
+
+
+ <%= f.submit t(".update"), class: "button button__sm button__secondary" %> +
+
+ <% end %> +
diff --git a/decidim-admin/app/views/decidim/admin/share_tokens/index.html.erb b/decidim-admin/app/views/decidim/admin/share_tokens/index.html.erb new file mode 100644 index 0000000000000..c98cbcb7db298 --- /dev/null +++ b/decidim-admin/app/views/decidim/admin/share_tokens/index.html.erb @@ -0,0 +1,47 @@ +
+
+

+ <%= t(".title", name: resource_title) %> + <%= icon "add-line" %><%= t(".new_share_token_button") %> +

+
+
+

<%= t(".share_tokens_help_html", clipboard: icon("clipboard-line", class: "inline-block mb-1")) %>

+
+ <% if @share_tokens.any? %> +
+ + + + + + + + + + + + <% @share_tokens.each do |share_token| %> + + + + + + + + <% end %> + +
<%= sort_link(query, :token, t("models.share_token.fields.token", scope: "decidim.admin"), default_order: :desc) %><%= sort_link(query, :expires_at, t("models.share_token.fields.expires_at", scope: "decidim.admin"), default_order: :desc) %><%= sort_link(query, :registered_only, t("models.share_token.fields.registered_only", scope: "decidim.admin"), default_order: :desc) %><%= sort_link(query, :times_used, t("models.share_token.fields.times_used", scope: "decidim.admin"), default_order: :desc) %><%= t("models.share_token.fields.actions", scope: "decidim.admin") %>
<%= share_token.token %><%= share_token.expires_at.present? ? + content_tag(:span, l(share_token.expires_at, format: :decidim_short), class: share_token.expired? ? "text-warning" : nil ) : + content_tag(:em, t(".never")) %><%= t("booleans.#{share_token.registered_only.present?}") %><%= share_token.times_used %> + <%= icon_link_to "pencil-line", share_tokens_path(:edit, id: share_token ), t("actions.edit", scope: "decidim.admin.share_tokens"), class: "action-icon--edit" %> + <%= icon_link_to "clipboard-line", "#", t("actions.copy_link", scope: "decidim.admin.share_tokens"), class: "action-icon--copy", data: { "clipboard-copy" => "#js-token-#{share_token.id}", "clipboard-content" => share_token.url,"clipboard-copy-label" => t(".copied"),"clipboard-copy-message" => t(".copy_message") } %> + <%= icon_link_to "eye-line", share_token.url, t("actions.preview", scope: "decidim.admin.share_tokens"), class: "action-icon--preview", target: :blank %> + <%= icon_link_to "delete-bin-line", share_tokens_path(:destroy, id: share_token ), t("actions.destroy", scope: "decidim.admin.share_tokens"), class: "action-icon--remove", method: :delete, data: { confirm: t("actions.confirm_destroy", scope: "decidim.admin.share_tokens") } %> +
+
+ <% else %> +

<%= t(".empty_html", new_token_link: link_to(t(".create_new_token"), share_tokens_path(:new) , class: "button button__text-secondary")) %>

+ <% end %> +
+<%= decidim_paginate @share_tokens %> diff --git a/decidim-admin/app/views/decidim/admin/share_tokens/new.html.erb b/decidim-admin/app/views/decidim/admin/share_tokens/new.html.erb new file mode 100644 index 0000000000000..69b0eb638ca87 --- /dev/null +++ b/decidim-admin/app/views/decidim/admin/share_tokens/new.html.erb @@ -0,0 +1,69 @@ +<% add_decidim_page_title(t(".title", name: resource_title)) %> + +
+

+ <%= t ".title", name: resource_title %> + <%= t("share_tokens.index.back_to_share_tokens", scope: "decidim.admin") %> +

+
+
+ <%= decidim_form_for(@form, url: share_tokens_path(:create), html: { class: "form-defaults form new_share_token" }) do |f| %> +
+
+
+
+
+ + <%= f.collection_radio_buttons :automatic_token, [ + [t("share_tokens.form.automatic", scope: "decidim.admin"), true], + [t("share_tokens.form.custom", scope: "decidim.admin"), false] + ], :last, :first do |b| %> +
+ <%= b.label do %> + <%= b.radio_button %> + <%= b.text %> + <% end %> +
+ <% end %> + +
+ <%= render partial: "form", object: f %> +
+
+
+
+
+
+ <%= f.submit t(".create"), class: "button button__sm button__secondary" %> +
+
+ <% end %> +
+ + diff --git a/decidim-admin/config/locales/bg.yml b/decidim-admin/config/locales/bg.yml index 4b8d7858c84b1..4e75bbea736bc 100644 --- a/decidim-admin/config/locales/bg.yml +++ b/decidim-admin/config/locales/bg.yml @@ -806,7 +806,7 @@ bg: reports: Доклади show_email: Показване на електронната поща status: Статус - unblock: Разблокирай Потребител + unblock: Разблокирай потребител unofficialize: Премахване на официализирането new: badge: Бадж за официализиране diff --git a/decidim-admin/config/locales/ca-IT.yml b/decidim-admin/config/locales/ca-IT.yml index bbbbd93386b3a..69ae113ac2396 100644 --- a/decidim-admin/config/locales/ca-IT.yml +++ b/decidim-admin/config/locales/ca-IT.yml @@ -53,6 +53,7 @@ ca-IT: customize_welcome_notification: Personalitza la notificació de benvinguda default_locale: Idioma per defecte description: Descripció + enable_machine_translations: Habilitar traduccions automàtiques enable_omnipresent_banner: Mostrar el banner omnipresent enable_participatory_space_filters: Habilitar els filtres a l'espai de participació facebook_handler: Nom d'usuari de Facebook @@ -802,7 +803,7 @@ ca-IT: success: S'ha retirat correctament l'oficialització de la participant. index: actions: Accions - badge: Insígnia + badge: Ensenya block: Bloquejar usuària created_at: Creat el name: Nom @@ -817,7 +818,7 @@ ca-IT: unblock: Desbloquejar usuària unofficialize: Des-oficialitzar new: - badge: Insígnia d'oficialització + badge: Ensenya d'oficialització officialize: Oficialitza title: Oficialitza la participant "%{name}" show_email_modal: diff --git a/decidim-admin/config/locales/ca.yml b/decidim-admin/config/locales/ca.yml index dc08a3f247e39..9e2b9a0f53b24 100644 --- a/decidim-admin/config/locales/ca.yml +++ b/decidim-admin/config/locales/ca.yml @@ -53,6 +53,7 @@ ca: customize_welcome_notification: Personalitza la notificació de benvinguda default_locale: Idioma per defecte description: Descripció + enable_machine_translations: Habilitar traduccions automàtiques enable_omnipresent_banner: Mostrar el banner omnipresent enable_participatory_space_filters: Habilitar els filtres a l'espai de participació facebook_handler: Nom d'usuari de Facebook @@ -802,7 +803,7 @@ ca: success: S'ha retirat correctament l'oficialització de la participant. index: actions: Accions - badge: Insígnia + badge: Ensenya block: Bloquejar usuària created_at: Creat el name: Nom @@ -817,7 +818,7 @@ ca: unblock: Desbloquejar usuària unofficialize: Des-oficialitzar new: - badge: Insígnia d'oficialització + badge: Ensenya d'oficialització officialize: Oficialitza title: Oficialitza la participant "%{name}" show_email_modal: diff --git a/decidim-admin/config/locales/cs.yml b/decidim-admin/config/locales/cs.yml index de972e68de63d..782966c8d8f04 100644 --- a/decidim-admin/config/locales/cs.yml +++ b/decidim-admin/config/locales/cs.yml @@ -53,6 +53,7 @@ cs: customize_welcome_notification: Přizpůsobit uvítací oznámení default_locale: Výchozí jazyk description: Popis + enable_machine_translations: Povolit strojové překlady enable_omnipresent_banner: Zobrazit všudypřítomný banner enable_participatory_space_filters: Povolit filtry participačního prostoru facebook_handler: Facebook handler @@ -813,7 +814,7 @@ cs: index: actions: Akce badge: Odznak - block: Zablokovat uživatele + block: Blokovat uživatele created_at: Vytvořeno na name: Název nickname: Přezdívka diff --git a/decidim-admin/config/locales/de.yml b/decidim-admin/config/locales/de.yml index 5980d8bd88caf..e9bc08681c381 100644 --- a/decidim-admin/config/locales/de.yml +++ b/decidim-admin/config/locales/de.yml @@ -53,6 +53,7 @@ de: customize_welcome_notification: Willkommens-Benachrichtigung anpassen default_locale: Standardgebietsschema description: Beschreibung + enable_machine_translations: Maschinelle Übersetzungen aktivieren enable_omnipresent_banner: Zeige allgegenwärtiges Banner enable_participatory_space_filters: Bereichs- und Gebietsfilter aktivieren facebook_handler: Facebook-Handler @@ -519,7 +520,7 @@ de: and: und data_errors: duplicate_headers: - detail: Bitte überprüfen Sie, dass die Datei benötigte Spalten oder Kopfzeilen nur einmal enthält. + detail: Bitte überprüfen Sie, dass die Datei die benötigten Spalten oder Kopfzeilen nur einmal enthält. message: one: Spalte %{columns} duplizieren. other: Spalten %{columns} duplizieren. @@ -776,7 +777,7 @@ de: recipients_count: Dieser Newsletter wird an %{count} Teilnehmer gesendet. scopes_help: Sendet den Newsletter an Teilnehmer, die einen der gewählten Themenbereiche in den "Meine Interessen" Einstellungen ihres Kontos aktiviert haben. select_scopes: Nur Teilnehmer anzeigen, die einen der gewählten Themenbereiche in Ihren "Meine Interessen" Einstellungen ihres Kontos aktiviert haben. - select_spaces: Wählen Sie Abschnitte, um den Newsletter zu unterteilen + select_spaces: Bereiche zum Segmentieren des Newsletters auswählen select_users: Wählen Sie aus, welchen Benutzern Sie den Newsletter senden möchten title: Empfänger auswählen warning: "Achtung: Dieser Newsletter wird nur an Benutzer gesendet, die Ich möchte Newsletter empfangen in ihren Benachrichtigungseinstellungen aktiviert haben." @@ -814,7 +815,7 @@ de: reports: Berichte show_email: E-Mail-Adresse anzeigen status: Status - unblock: Blockierung des Users aufheben + unblock: Blockierung des Benutzers aufheben unofficialize: Nicht offiziell new: badge: Offizielles Abzeichen @@ -884,7 +885,7 @@ de: participatory_space_private_users: create: error: Beim Hinzufügen eines privaten Benutzers für diesen partizipativen Bereich ist ein Fehler aufgetreten. - success: Participatory Space Privater Benutzerzugriff erfolgreich erstellt. + success: Ein privater Zugriff für diesen Beteiligungsbereich wurde erfolgreich für das Konto erstellt. destroy: error: Beim Löschen eines privaten Benutzers für diesen partizipativen Bereich ist ein Fehler aufgetreten. success: Privater Zugriff zum partizipativen Raum erfolgreich gelöscht. diff --git a/decidim-admin/config/locales/en.yml b/decidim-admin/config/locales/en.yml index 97ff698b8a72c..a64db426135c0 100644 --- a/decidim-admin/config/locales/en.yml +++ b/decidim-admin/config/locales/en.yml @@ -53,6 +53,7 @@ en: customize_welcome_notification: Customize welcome notification default_locale: Default locale description: Description + enable_machine_translations: Enable machine translations enable_omnipresent_banner: Show omnipresent banner enable_participatory_space_filters: Enable participatory space filters facebook_handler: Facebook handler @@ -200,6 +201,7 @@ en: reject: Reject send_me_a_test_email: Send me a test email share: Share + share_tokens: Access links user: new: New admin verify: Verify @@ -592,6 +594,7 @@ en: scopes: Scopes see_site: See site settings: Settings + share_tokens: Access links static_page_topics: Topics static_pages: Pages user_groups: Groups @@ -647,12 +650,11 @@ en: plural: Plural share_token: fields: - created_at: Created at + actions: Actions expires_at: Expires at - last_used_at: Last time used + registered_only: Registered only? times_used: Times used - token: Token - user: Created by + token: Access link static_page: fields: created_at: Created at @@ -965,16 +967,50 @@ en: success: Scope updated successfully share_tokens: actions: - confirm_destroy: Are you sure you want to delete this token? + confirm_destroy: Are you sure you want to delete this access? + copy_link: Copy link destroy: Delete - share: Share + edit: Edit + preview: Preview + create: + invalid: There was a problem generating the access link. + success: Access link created successfully. destroy: - error: There was a problem destroying the token. - success: Token destroyed successfully. - share_tokens: - empty: There are no active tokens. - help: These tokens are used to publicly share this unpublished resource to any user. They will be hidden when the resource is published. Click on the token's share icon to visit the shareable URL. - title: Share tokens + error: There was a problem destroying the access link. + success: Access link successfully destroyed. + edit: + title: 'Edit access links for: %{name}' + update: Update + form: + automatic: Automatic + custom: Custom + custom_expiration: Custom expiration + custom_token: Custom word + expires_at: Expires at + 'false': 'No' + never_expire: Never + registered_only: Registered only? + token: Access key + 'true': 'Yes' + index: + back_to_share_tokens: Back to access links + copied: Access link Copied! + copy_message: The text was successfully copied to clipboard. + create_new_token: Create your first access link! + empty_html: There are no active access links. %{new_token_link} + never: Never + new_share_token_button: New access link + share_tokens_help_html: | + Create and share an access link to allow others to view this unpublished resource. + Access links can be valid for registered participants only or have and expiration date if necessary. + To share a new access link with someone, create it and then copy the link using the "%{clipboard} clipboard" action icon. + title: 'access links for: %{name}' + new: + create: Create + title: 'New access link for: %{name}' + update: + error: There was a problem updating this access. + success: Access link updated successfully. shared: adjacent_navigation: next: Next diff --git a/decidim-admin/config/locales/es-MX.yml b/decidim-admin/config/locales/es-MX.yml index a20de9d545d71..77e7dd55be96f 100644 --- a/decidim-admin/config/locales/es-MX.yml +++ b/decidim-admin/config/locales/es-MX.yml @@ -53,6 +53,7 @@ es-MX: customize_welcome_notification: Personalizar notificación de bienvenida default_locale: Idioma predeterminado description: Descripción + enable_machine_translations: Habilitar traducciones automáticas enable_omnipresent_banner: Mostrar banner omnipresente enable_participatory_space_filters: Habilitar los filtros en el espacio de participación facebook_handler: Nombre en Facebook diff --git a/decidim-admin/config/locales/es-PY.yml b/decidim-admin/config/locales/es-PY.yml index bcf4b4c5e1a95..51026b4ab1667 100644 --- a/decidim-admin/config/locales/es-PY.yml +++ b/decidim-admin/config/locales/es-PY.yml @@ -53,6 +53,7 @@ es-PY: customize_welcome_notification: Personalizar notificación de bienvenida default_locale: Idioma predeterminado description: Descripción + enable_machine_translations: Habilitar traducciones automáticas enable_omnipresent_banner: Mostrar banner omnipresente enable_participatory_space_filters: Habilitar los filtros en el espacio de participación facebook_handler: Nombre en Facebook diff --git a/decidim-admin/config/locales/es.yml b/decidim-admin/config/locales/es.yml index 178d31a12e80d..9cfbae5f5d36e 100644 --- a/decidim-admin/config/locales/es.yml +++ b/decidim-admin/config/locales/es.yml @@ -53,6 +53,7 @@ es: customize_welcome_notification: Personalizar notificación de bienvenida default_locale: Idioma predeterminado description: Descripción + enable_machine_translations: Habilitar traducciones automáticas enable_omnipresent_banner: Mostrar banner omnipresente enable_participatory_space_filters: Habilitar los filtros en el espacio de participación facebook_handler: Nombre en Facebook diff --git a/decidim-admin/config/locales/eu.yml b/decidim-admin/config/locales/eu.yml index d02f75b158d05..772c80b666184 100644 --- a/decidim-admin/config/locales/eu.yml +++ b/decidim-admin/config/locales/eu.yml @@ -53,6 +53,7 @@ eu: customize_welcome_notification: Pertsonalizatu ongi etorri jakinarazpena default_locale: Kokapen lehenetsia description: Deskribapena + enable_machine_translations: Gaitu itzulpen automatikoak enable_omnipresent_banner: Erakutsi banner nonahikoa enable_participatory_space_filters: Gaitu iragazkiak parte hartzeko espazioan facebook_handler: Facebook kudeatzailea @@ -803,7 +804,7 @@ eu: index: actions: Ekintzak badge: Garaikurra - block: Blokeatu parte-hartzailea + block: Blokeatu erabiltzailea created_at: Noiz sortua name: Izena nickname: Ezizena diff --git a/decidim-admin/config/locales/fi-plain.yml b/decidim-admin/config/locales/fi-plain.yml index 0d72c99b8b9e1..10e891d3b7cf6 100644 --- a/decidim-admin/config/locales/fi-plain.yml +++ b/decidim-admin/config/locales/fi-plain.yml @@ -53,6 +53,7 @@ fi-pl: customize_welcome_notification: Muokkaa tervetuloilmoitusta default_locale: Oletuskieli description: Kuvaus + enable_machine_translations: Ota konekäännökset käyttöön enable_omnipresent_banner: Näytä kaikkialla näkyvä banneri enable_participatory_space_filters: Ota käyttöön osallistumistilan suodattimet facebook_handler: Facebook-käsittelijä diff --git a/decidim-admin/config/locales/fi.yml b/decidim-admin/config/locales/fi.yml index ece53efbc2ea5..6bcb5c9bdb1f3 100644 --- a/decidim-admin/config/locales/fi.yml +++ b/decidim-admin/config/locales/fi.yml @@ -53,6 +53,7 @@ fi: customize_welcome_notification: Muokkaa tervetuloilmoitusta default_locale: Oletuskieli description: Kuvaus + enable_machine_translations: Ota konekäännökset käyttöön enable_omnipresent_banner: Näytä kaikkialla näkyvä banneri enable_participatory_space_filters: Ota käyttöön osallistumistilan suodattimet facebook_handler: Facebook-käsittelijä diff --git a/decidim-admin/config/locales/fr-CA.yml b/decidim-admin/config/locales/fr-CA.yml index c06eb25e6850e..118a2e66ca352 100644 --- a/decidim-admin/config/locales/fr-CA.yml +++ b/decidim-admin/config/locales/fr-CA.yml @@ -876,7 +876,7 @@ fr-CA: external_domain: down: Descendre external_domain: Domaine externe - remove: Retirer + remove: Supprimer up: Monter form: add: Ajouter à la liste autorisée diff --git a/decidim-admin/config/locales/fr.yml b/decidim-admin/config/locales/fr.yml index 938f58557dd6a..5be21694f5f73 100644 --- a/decidim-admin/config/locales/fr.yml +++ b/decidim-admin/config/locales/fr.yml @@ -876,7 +876,7 @@ fr: external_domain: down: Descendre external_domain: Domaine externe - remove: Retirer + remove: Supprimer up: Monter form: add: Ajouter à la liste autorisée diff --git a/decidim-admin/config/locales/hu.yml b/decidim-admin/config/locales/hu.yml index b2ed74ed987b2..008e4c66cee39 100644 --- a/decidim-admin/config/locales/hu.yml +++ b/decidim-admin/config/locales/hu.yml @@ -798,7 +798,7 @@ hu: reports: Jelentések show_email: E-mail cím megjelenítése status: Állapot - unblock: Felhasználó tiltásának törlése + unblock: Felhasználó feloldása unofficialize: Hivatalossá tétel visszavonása new: badge: A hivatalosság jelvénye diff --git a/decidim-admin/config/locales/it.yml b/decidim-admin/config/locales/it.yml index 3104beacfdaeb..4b978f0de8bbb 100644 --- a/decidim-admin/config/locales/it.yml +++ b/decidim-admin/config/locales/it.yml @@ -699,10 +699,14 @@ it: blocked: Bloccato unblocked: Non Bloccato moderations: + index: + title: Contenuto segnalato report: reasons: does_not_belong: Non appartiene + hidden_during_block: Nascosto durante il blocco dell'utente offensive: Offensivo + parent_hidden: Il contenuto padre è stato nascosto spam: Spam reports: index: @@ -846,11 +850,20 @@ it: edit: update: Aggiorna form: + colors: + choose_color: Scegli un colore primario + colors_title: Colori dell'organizzazione + colors_warning_html: Attenzione! Cambiare questi colori può violare l'accessibilità dei contrasti dei colori. Puoi controllare il contrasto della tua scelta dei colori con WebAIM Contrast Checker o altri strumenti simili. + explanation: Questo strumento ti aiuta a scegliere uno schema di colori, composto da tonalità ugualmente distanziate intorno alla gamma dei colori, che saranno utilizzate nel sito web dell'organizzazione. + legend_html: I principali colori dell'applicazione, basati sull'algoritmo Triadic. Il colore secondario è calcolato a partire dal colore primario e dalla saturazione che hai scelto. + saturation: Saturazione + title: Selettore colore + update_suggested_colors: Aggiorna i colori suggeriti cta_button_path_help_html: 'È possibile modificare la posizione in cui il pulsante "Chiamata all''Azione" nella home page viene mostrato. Per farlo utilizzare URL relativi, non URL assoluti. Accetta lettere, numeri, trattini e barre, e deve iniziare con una lettera. Il pulsante "Chiamata all''Azione" è mostrato nella home page tra il testo di benvenuto e la descrizione. Ad esempio: %{url}' cta_button_text_help: Puoi sovrascrivere il testo del pulsante Chiamata all'azione nella home page per ogni lingua disponibile nell'organizzazione. Se non è impostato, verrà utilizzato il valore predefinito. Il pulsante Chiamata all'azione è mostrato nella homepage tra il testo di benvenuto e la descrizione. header_snippets: header_snippets_help_html: Usa questo campo per aggiungere funzionalità all head HTML. L'uso più comune è quello di integrare servizi di terze parti che richiedono alcuni JavaScript o CSS aggiuntivi. Inoltre, è possibile utilizzarlo per aggiungere meta tag extra per l'HTML. Nota che questo sarà reso solo nelle pagine pubbliche, non nella sezione amministrazione. Se il codice interagisce con API esterne o non è conforme alle linee guida di sicurezza dell’applicazione, sarà necessario modificare la Content Security Policy. Per saperne di più su nella documentazione di Decidim. - title: Frammenti di intestazione HTML + title: Frammenti d'intestazione HTML homepage_appearance_title: Modifica l'aspetto della home page homepage_highlighted_content_banner_title: Banner con contenuti Highligted images: @@ -867,6 +880,7 @@ it: up: Su form: add: Aggiungi alla lista consentita + title: Elenco di domini esterni consentiti participatory_space_private_users: create: error: Si è verificato un errore durante l'aggiunta di un utente privato per questo spazio partecipativo. @@ -881,9 +895,24 @@ it: create: Creare title: Nuovo utente privato dello spazio partecipativo. participatory_space_private_users_csv_imports: + create: + invalid: Si è verificato un problema durante la lettura del file CSV. Assicurati di aver seguito le istruzioni. + success: File CSV caricato con successo, stiamo inviando un'email di invito ai partecipanti. Potrebbe richiedere un po' di tempo. new: csv_upload: title: Carica il tuo file CSV + destroy: + button: Elimina tutti i partecipanti privati + confirm: Sei sicuro di voler eliminare tutti i partecipanti privati? Questa azione non può essere annullata, non sarai in grado di recuperarli. + empty: Non hai partecipanti privati. + explanation: Hai %{count} partecipanti privati. + title: Elimina tutti i partecipanti privati + example_file: 'File di esempio:' + explanation: 'Carica il file CSV. Il file deve contenere due colonne (e-mail e nome) senza intestazioni: nella prima sono elencati gli indirizzi e-mail degli utenti che si desidera aggiungere allo spazio partecipativo, nella seconda i loro nomi. Evita di usare caratteri non validi come `<>?%&^*#@()[]=+:;"{}\|` nella colonna dei nomi.' + explanation_example: | + john.doe@example.org%{csv_col_sep}John Doe + jane.doe@example.org%{csv_col_sep}Jane Doe + title: Importa partecipanti privati tramite CSV upload: Carica File reminders: create: @@ -919,6 +948,8 @@ it: create: error: Si è verificato un errore creando un nuovo ambito. success: OK, è stato creato il nuovo àmbito. + destroy: + success: Ambito eliminato correttamente. edit: title: Modifica l'àmbito update: Aggiorna @@ -1018,6 +1049,7 @@ it: verify_via_csv: Verifica tramite CSV user_groups_csv_verifications: new: + example_file: 'File di esempio:' explanation: Carica il tuo file CSV. Deve avere le e-mail ufficiali dei gruppi di utenti nella tua organizzazione nella prima colonna del file, senza intestazioni. Verranno convalidati solo i gruppi di utenti che hanno confermato la loro e-mail e che hanno una e-mail che appare nel file CSV. explanation_example: | acme@example.org @@ -1077,10 +1109,14 @@ it: models: moderation: fields: + deleted_resource: Risorsa eliminata hidden_at: Nascosto a participatory_space: Spazio partecipativo + report_count: Numero di segnalazioni + reportable_id: ID reportable_type: Tipo reported_content_url: URL del contenuto riportato + reports: Motivo visit_url: Visita URL report: fields: diff --git a/decidim-admin/config/locales/ja.yml b/decidim-admin/config/locales/ja.yml index 591e52eba5c73..4f4555ed57f57 100644 --- a/decidim-admin/config/locales/ja.yml +++ b/decidim-admin/config/locales/ja.yml @@ -53,6 +53,7 @@ ja: customize_welcome_notification: ウェルカム通知をカスタマイズ default_locale: 既定のロケール: description: 説明 + enable_machine_translations: 機械翻訳を有効にする enable_omnipresent_banner: Omnipresentバナーを表示 enable_participatory_space_filters: 参加型スペースフィルタを有効にする facebook_handler: Facebook ハンドラー diff --git a/decidim-admin/config/locales/ko.yml b/decidim-admin/config/locales/ko.yml index 92e01f63cf604..f8bae96a14fe1 100644 --- a/decidim-admin/config/locales/ko.yml +++ b/decidim-admin/config/locales/ko.yml @@ -587,12 +587,10 @@ ko: success: 참가자가 성공적으로 차단되었습니다. index: badge: 뱃지 - block: 사용자 차단 name: 이름 nickname: 닉네임 show_email: 이메일 주소 보기 status: 상태 - unblock: 사용자 차단 해제 show_email_modal: email_address: 이메일 주소 full_name: 전체 이름 diff --git a/decidim-admin/config/locales/lb.yml b/decidim-admin/config/locales/lb.yml index 3c89e3f12d854..195b21c505754 100644 --- a/decidim-admin/config/locales/lb.yml +++ b/decidim-admin/config/locales/lb.yml @@ -638,7 +638,7 @@ lb: reports: Berichte show_email: E-Mail-Adresse anzeigen status: Status - unblock: Blockierung des Users aufheben + unblock: Blockierung des Benutzers aufheben unofficialize: Nicht offiziell new: badge: Offizielles Abzeichen diff --git a/decidim-admin/config/locales/pt-BR.yml b/decidim-admin/config/locales/pt-BR.yml index 6d784ae5e5706..edf0c6fc8230c 100644 --- a/decidim-admin/config/locales/pt-BR.yml +++ b/decidim-admin/config/locales/pt-BR.yml @@ -803,7 +803,7 @@ pt-BR: reports: Denúncias show_email: Mostrar endereço de e-mail status: Status - unblock: Desbloquear Usuário + unblock: Desbloquear usuário unofficialize: Não oficializar new: badge: Emblema de oficialização diff --git a/decidim-admin/config/locales/ro-RO.yml b/decidim-admin/config/locales/ro-RO.yml index 45fd8edde8a76..bbca4c669e8f5 100644 --- a/decidim-admin/config/locales/ro-RO.yml +++ b/decidim-admin/config/locales/ro-RO.yml @@ -761,7 +761,7 @@ ro: index: actions: Acțiuni badge: Insignă - block: Blochează utilizator + block: Blochează utilizatorul created_at: Creat la name: Nume nickname: Pseudonim diff --git a/decidim-admin/config/locales/sq-AL.yml b/decidim-admin/config/locales/sq-AL.yml index 7c60992c0f6a4..8dc8a4c9f3d7d 100644 --- a/decidim-admin/config/locales/sq-AL.yml +++ b/decidim-admin/config/locales/sq-AL.yml @@ -476,7 +476,6 @@ sq: officializations: index: actions: Veprimet - block: Blloko përdoruesin created_at: Krijuar më name: Emri nickname: Nofka diff --git a/decidim-admin/config/routes.rb b/decidim-admin/config/routes.rb index 1f1e85dece383..4a73f91af43ee 100644 --- a/decidim-admin/config/routes.rb +++ b/decidim-admin/config/routes.rb @@ -109,8 +109,6 @@ put :accept end - resources :share_tokens, only: :destroy - resources :moderations, controller: "global_moderations" do member do put :unreport diff --git a/decidim-admin/lib/decidim/admin/version.rb b/decidim-admin/lib/decidim/admin/version.rb index 92ec01c38c963..eb00be50562f3 100644 --- a/decidim-admin/lib/decidim/admin/version.rb +++ b/decidim-admin/lib/decidim/admin/version.rb @@ -4,7 +4,7 @@ module Decidim # This holds the decidim-admin version. module Admin def self.version - "0.29.4" + "0.29.6" end end end diff --git a/decidim-admin/spec/commands/decidim/admin/create_share_token_spec.rb b/decidim-admin/spec/commands/decidim/admin/create_share_token_spec.rb new file mode 100644 index 0000000000000..4c43b5631c185 --- /dev/null +++ b/decidim-admin/spec/commands/decidim/admin/create_share_token_spec.rb @@ -0,0 +1,97 @@ +# frozen_string_literal: true + +require "spec_helper" + +module Decidim::Admin + describe CreateShareToken do + subject { described_class.new(form) } + + let(:organization) { create(:organization) } + let(:current_user) { create(:user, :admin, organization:) } + let(:component) { create(:component, participatory_space: create(:participatory_process, organization:)) } + + let(:form) do + ShareTokenForm.from_params( + token:, + expires_at:, + automatic_token:, + no_expiration:, + registered_only: + ).with_context( + current_user:, + current_organization: organization, + resource: component + ) + end + + let(:token) { "ABC123" } + let(:expires_at) { Time.zone.today + 10.days } + let(:automatic_token) { false } + let(:no_expiration) { false } + let(:registered_only) { true } + let(:extra) do + { + participatory_space: { + title: component.participatory_space.title + }, + resource: { + title: component.name + } + } + end + + context "when the form is valid" do + it "creates a share token" do + expect { subject.call }.to change(Decidim::ShareToken, :count).by(1) + + share_token = Decidim::ShareToken.last + expect(share_token.token).to eq(token) + expect(share_token.expires_at).to eq(expires_at) + expect(share_token.registered_only).to be(true) + expect(share_token.organization).to eq(organization) + expect(share_token.user).to eq(current_user) + expect(share_token.token_for).to eq(component) + end + + it "broadcasts :ok with the resource" do + expect(subject).to receive(:broadcast).with(:ok, instance_of(Decidim::ShareToken)) + subject.call + end + + it "traces the action", versioning: true do + expect(Decidim.traceability) + .to receive(:create!) + .with(Decidim::ShareToken, current_user, + { + expires_at:, + registered_only:, + token:, + organization:, + token_for: component, + user: current_user + }, + extra) + .and_call_original + + expect { subject.call }.to change(Decidim::ActionLog, :count) + action_log = Decidim::ActionLog.last + expect(action_log.version).to be_present + end + end + + context "when the form is invalid" do + before do + allow(form).to receive(:invalid?).and_return(true) + end + + it "does not create a share token" do + expect { subject.call }.not_to(change(Decidim::ShareToken, :count)) + end + + it "broadcasts :invalid" do + expect(subject).to receive(:broadcast).with(:invalid) + subject.call + end + end + end +end diff --git a/decidim-admin/spec/commands/decidim/admin/destroy_share_token_spec.rb b/decidim-admin/spec/commands/decidim/admin/destroy_share_token_spec.rb new file mode 100644 index 0000000000000..1c66c2d3b77d1 --- /dev/null +++ b/decidim-admin/spec/commands/decidim/admin/destroy_share_token_spec.rb @@ -0,0 +1,45 @@ +# frozen_string_literal: true + +require "spec_helper" + +module Decidim::Admin + describe DestroyShareToken do + subject { described_class.new(share_token, user) } + + let(:organization) { create(:organization) } + let(:user) { create(:user, :admin, :confirmed, organization:) } + let(:share_token) { create(:share_token, organization:, user:) } + let(:extra) do + { + participatory_space: { + title: share_token.participatory_space.title + }, + resource: { + title: share_token.component.name + } + } + end + + it "destroys the share_token" do + subject.call + expect { share_token.reload }.to raise_error(ActiveRecord::RecordNotFound) + end + + it "broadcasts ok" do + expect do + subject.call + end.to broadcast(:ok) + end + + it "traces the action", versioning: true do + expect(Decidim.traceability) + .to receive(:perform_action!) + .with(:delete, share_token, user, extra) + .and_call_original + + expect { subject.call }.to change(Decidim::ActionLog, :count) + action_log = Decidim::ActionLog.last + expect(action_log.version).to be_present + end + end +end diff --git a/decidim-admin/spec/commands/decidim/admin/update_share_token_spec.rb b/decidim-admin/spec/commands/decidim/admin/update_share_token_spec.rb new file mode 100644 index 0000000000000..db92c4319fbac --- /dev/null +++ b/decidim-admin/spec/commands/decidim/admin/update_share_token_spec.rb @@ -0,0 +1,84 @@ +# frozen_string_literal: true + +require "spec_helper" + +module Decidim::Admin + describe UpdateShareToken do + subject { described_class.new(form, share_token) } + + let(:organization) { create(:organization) } + let(:user) { create(:user, :admin, organization:) } + let(:component) { create(:component, participatory_space: create(:participatory_process, organization:)) } + let!(:share_token) { create(:share_token, organization:, user:, token_for: component) } + + let(:form) do + ShareTokenForm.from_params( + token:, + expires_at:, + automatic_token:, + no_expiration:, + registered_only: + ).with_context( + current_user: user, + current_organization: organization, + resource: component + ) + end + + let(:token) { "ABCDEF97765544" } + let(:expires_at) { Time.zone.today + 20.days } + let(:automatic_token) { false } + let(:no_expiration) { false } + let(:registered_only) { false } + let(:extra) do + { + participatory_space: { + title: component.participatory_space.title + }, + resource: { + title: component.name + } + } + end + + context "when the form is valid" do + it "updates the expiration date" do + expect { subject.call }.to change { share_token.reload.expires_at }.to(expires_at) + .and change { share_token.reload.registered_only }.to(registered_only) + end + + it "broadcasts :ok with the resource" do + expect(subject).to receive(:broadcast).with(:ok, share_token) + subject.call + end + + it "traces the action", versioning: true do + expect(Decidim.traceability) + .to receive(:update!) + .with(share_token, user, { expires_at:, registered_only: }, extra) + .and_call_original + + expect { subject.call }.to change(Decidim::ActionLog, :count) + + action_log = Decidim::ActionLog.last + expect(action_log.version).to be_present + expect(action_log.version.event).to eq "update" + end + end + + context "when the form is invalid" do + before do + allow(form).to receive(:invalid?).and_return(true) + end + + it "does not update the share token" do + expect { subject.call }.not_to(change { share_token.reload.attributes }) + end + + it "broadcasts :invalid" do + expect(subject).to receive(:broadcast).with(:invalid) + subject.call + end + end + end +end diff --git a/decidim-admin/spec/forms/share_token_form_spec.rb b/decidim-admin/spec/forms/share_token_form_spec.rb new file mode 100644 index 0000000000000..1bc0a0a4ae32a --- /dev/null +++ b/decidim-admin/spec/forms/share_token_form_spec.rb @@ -0,0 +1,120 @@ +# frozen_string_literal: true + +require "spec_helper" + +module Decidim::Admin + describe ShareTokenForm do + let(:organization) { create(:organization) } + let(:current_user) { create(:user, :admin, organization:) } + let(:component) { create(:component, participatory_space: create(:participatory_process, organization:)) } + + let(:form) do + described_class.from_params( + token:, + automatic_token:, + expires_at:, + no_expiration:, + registered_only: + ).with_context( + current_user:, + current_organization: organization, + resource: component + ) + end + + let(:token) { "ABC123" } + let(:automatic_token) { true } + let(:expires_at) { Time.zone.today + 3.days } + let(:no_expiration) { false } + let(:registered_only) { true } + + it "returns defaults" do + expect(form.token).to eq("ABC123") + expect(form.automatic_token).to be(true) + expect(form.expires_at).to eq(Time.zone.today + 3.days) + expect(form.no_expiration).to be(false) + expect(form.registered_only).to be(true) + end + + context "when automatic_token validation is false" do + let(:automatic_token) { false } + + it "validates presence of token" do + form.token = nil + expect(form).to be_invalid + expect(form.errors[:token]).to include("cannot be blank") + end + + context "when automatic_token is set" do + let(:token) { "" } + let(:automatic_token) { true } + + it "does not validate presence of token" do + expect(form).to be_valid + end + end + end + + context "when expires_at is nil" do + let(:expires_at) { nil } + + it "validates presence of expires_at" do + expect(form).to be_invalid + expect(form.errors[:expires_at]).to include("cannot be blank") + end + + context "when no_expiration is set" do + let(:no_expiration) { true } + + it "does not expires" do + expect(form).to be_valid + end + end + end + + context "when token is custom" do + let(:token) { "abc 123 " } + + it "returns the token in uppercase" do + expect(form.token).to eq("ABC-123") + end + + context "and has strange characters" do + let(:token) { "abc 123 !@#$%^&*()_+" } + + it "returns the token in uppercase" do + expect(form).to be_invalid + expect(form.errors[:token]).to include("is invalid") + end + end + end + + context "when token exists" do + let(:automatic_token) { false } + let!(:share_token) { create(:share_token, organization:, token_for: component, token:) } + + it "validates uniqueness of token" do + expect(form).to be_invalid + expect(form.errors[:token]).to include("has already been taken") + end + end + + describe "#token_for" do + it "returns the component from the context" do + expect(form.token_for).to eq(component) + end + end + + describe "#organization" do + it "returns the current organization from the context" do + expect(form.organization).to eq(organization) + end + end + + describe "#user" do + it "returns the current user from the context" do + expect(form.user).to eq(current_user) + end + end + end +end diff --git a/decidim-admin/spec/system/admin_manages_officializations_spec.rb b/decidim-admin/spec/system/admin_manages_officializations_spec.rb index 11f765c27f1c8..f55599c1e81f4 100644 --- a/decidim-admin/spec/system/admin_manages_officializations_spec.rb +++ b/decidim-admin/spec/system/admin_manages_officializations_spec.rb @@ -66,6 +66,23 @@ end end + describe "when user's nickname is blank" do + let!(:user) { create(:user, :managed, organization:, nickname: "") } + + before do + within_admin_sidebar_menu do + click_on "Participants" + end + end + + it "has no user link" do + within "tr[data-user-id=\"#{user.id}\"]" do + expect(page).to have_content(user.name) + expect(page).to have_no_link(user.name) + end + end + end + describe "officializating users" do context "when not yet officialized" do let!(:user) { create(:user, organization:) } diff --git a/decidim-api/lib/decidim/api/version.rb b/decidim-api/lib/decidim/api/version.rb index 67252dc5f1456..dbf4fb76f90c3 100644 --- a/decidim-api/lib/decidim/api/version.rb +++ b/decidim-api/lib/decidim/api/version.rb @@ -4,7 +4,7 @@ module Decidim # This holds the decidim-api version. module Api def self.version - "0.29.4" + "0.29.6" end end end diff --git a/decidim-assemblies/app/controllers/decidim/assemblies/admin/assembly_share_tokens_controller.rb b/decidim-assemblies/app/controllers/decidim/assemblies/admin/assembly_share_tokens_controller.rb new file mode 100644 index 0000000000000..9d1f1854d35bf --- /dev/null +++ b/decidim-assemblies/app/controllers/decidim/assemblies/admin/assembly_share_tokens_controller.rb @@ -0,0 +1,18 @@ +# frozen_string_literal: true + +module Decidim + module Assemblies + module Admin + # This controller allows sharing unpublished things. + # It is targeted for customizations for sharing unpublished things that lives under + # an assembly. + class AssemblyShareTokensController < Decidim::Admin::ShareTokensController + include Concerns::AssemblyAdmin + + def resource + current_assembly + end + end + end + end +end diff --git a/decidim-assemblies/app/controllers/decidim/assemblies/admin/component_share_tokens_controller.rb b/decidim-assemblies/app/controllers/decidim/assemblies/admin/component_share_tokens_controller.rb new file mode 100644 index 0000000000000..e03eb766121e0 --- /dev/null +++ b/decidim-assemblies/app/controllers/decidim/assemblies/admin/component_share_tokens_controller.rb @@ -0,0 +1,18 @@ +# frozen_string_literal: true + +module Decidim + module Assemblies + module Admin + # This controller allows sharing unpublished things. + # It is targeted for customizations for sharing unpublished things that lives under + # an assembly. + class ComponentShareTokensController < Decidim::Admin::ShareTokensController + include Concerns::AssemblyAdmin + + def resource + @resource ||= current_participatory_space.components.find(params[:component_id]) + end + end + end + end +end diff --git a/decidim-assemblies/app/models/decidim/assembly.rb b/decidim-assemblies/app/models/decidim/assembly.rb index 09d8e9031b3e3..c77b715ef0988 100644 --- a/decidim-assemblies/app/models/decidim/assembly.rb +++ b/decidim-assemblies/app/models/decidim/assembly.rb @@ -36,6 +36,7 @@ class Assembly < ApplicationRecord include Decidim::TranslatableResource include Decidim::HasArea include Decidim::FilterableResource + include Decidim::ShareableWithToken CREATED_BY = %w(city_council public others).freeze @@ -168,6 +169,10 @@ def self.ransackable_scopes(_auth_object = nil) [:with_any_area, :with_any_scope, :with_any_type] end + def shareable_url(share_token) + EngineRouter.main_proxy(self).assembly_url(self, share_token: share_token.token) + end + private # When an assembly changes their parent, we need to update the parents_path attribute diff --git a/decidim-assemblies/app/permissions/decidim/assemblies/permissions.rb b/decidim-assemblies/app/permissions/decidim/assemblies/permissions.rb index 162856418508e..741d8c91de756 100644 --- a/decidim-assemblies/app/permissions/decidim/assemblies/permissions.rb +++ b/decidim-assemblies/app/permissions/decidim/assemblies/permissions.rb @@ -127,6 +127,7 @@ def public_read_assembly_action? return disallow! unless can_view_private_space? return allow! if user&.admin? return allow! if assembly.published? + return allow! if user_can_preview_space? toggle_allow(can_manage_assembly?) end @@ -267,6 +268,7 @@ def assembly_admin_action? :assembly_user_role, :assembly_member, :export_space, + :share_tokens, :import ].include?(permission_action.subject) allow! if is_allowed @@ -286,11 +288,18 @@ def org_admin_action? :assembly_user_role, :assembly_member, :export_space, + :share_tokens, :import ].include?(permission_action.subject) allow! if is_allowed end + def user_can_preview_space? + context[:share_token].present? && Decidim::ShareToken.use!(token_for: assembly, token: context[:share_token], user:) + rescue ActiveRecord::RecordNotFound, StandardError + nil + end + # Checks if the permission_action is to read the admin assemblies list or # not. def read_assembly_list_permission_action? diff --git a/decidim-assemblies/app/views/decidim/assemblies/admin/assemblies/index.html.erb b/decidim-assemblies/app/views/decidim/assemblies/admin/assemblies/index.html.erb index 6773dfed6ce8d..391c7c91a1d2a 100644 --- a/decidim-assemblies/app/views/decidim/assemblies/admin/assemblies/index.html.erb +++ b/decidim-assemblies/app/views/decidim/assemblies/admin/assemblies/index.html.erb @@ -65,6 +65,7 @@ <% end %> + <% if assembly.published? %> <%= t("assemblies.index.published", scope: "decidim.admin") %> <% else %> @@ -72,6 +73,12 @@ <% end %> + <% if allowed_to? :read, :share_tokens, current_participatory_space: assembly %> + <%= icon_link_to "share-line", decidim_admin_assemblies.assembly_share_tokens_path(assembly), t("actions.share_tokens", scope: "decidim.admin"), class: "action-icon--new" %> + <% else %> + + <% end %> + <% if allowed_to? :update, :assembly, assembly: assembly %> <%= icon_link_to "pencil-line", edit_assembly_path(assembly), t("actions.configure", scope: "decidim.admin"), class: "action-icon--new" %> <% else %> diff --git a/decidim-assemblies/config/locales/ar.yml b/decidim-assemblies/config/locales/ar.yml index 8dba287dc9049..ac4d908c79119 100644 --- a/decidim-assemblies/config/locales/ar.yml +++ b/decidim-assemblies/config/locales/ar.yml @@ -119,10 +119,6 @@ ar: update: error: حدثت مشكلة أثناء تحديث هذه الجمعية. success: تم تحديث الجمعية بنجاح. - assemblies_copies: - create: - error: حدثت مشكلة في تكرار هذا التجميع. - success: الجمعية مكررة بنجاح. assemblies_types: create: error: حدثت مشكلة أثناء إنشاء جمعية جديدة. @@ -138,8 +134,6 @@ ar: assembly_copies: new: copy: نسخ - select: حدد البيانات التي ترغب في تكرارها - title: نسخ الجمعية assembly_imports: create: error: حدثت مشكلة أثناء استيراد هذه الجمعية. diff --git a/decidim-assemblies/config/locales/bg.yml b/decidim-assemblies/config/locales/bg.yml index 51dca0de987f7..da54c29c75d06 100644 --- a/decidim-assemblies/config/locales/bg.yml +++ b/decidim-assemblies/config/locales/bg.yml @@ -116,10 +116,6 @@ bg: update: error: Възникна проблем при актуализирането на това събрание. success: Събранието беше актуализирано успешно. - assemblies_copies: - create: - error: Възникна проблем при дублирането на това събрание. - success: Събранието беше дублирано успешно. assemblies_types: create: error: Възникна проблем при създаването на нов тип събрание. @@ -135,8 +131,6 @@ bg: assembly_copies: new: copy: Копиране - select: Изберете кои данни искате да дублирате - title: Дублиране на събрание assembly_imports: create: error: Възникна проблем при импортирането на това събрание. diff --git a/decidim-assemblies/config/locales/cs.yml b/decidim-assemblies/config/locales/cs.yml index fa7b7f444177c..77ef075641f6e 100644 --- a/decidim-assemblies/config/locales/cs.yml +++ b/decidim-assemblies/config/locales/cs.yml @@ -142,7 +142,7 @@ cs: new: copy: Kopírovat select: Vyberte, která data chcete duplikovat - title: Zduplikovat shromáždění + title: Duplikovat shromáždění assembly_imports: create: error: Při importu tohoto shromáždění došlo k chybě. diff --git a/decidim-assemblies/config/locales/de.yml b/decidim-assemblies/config/locales/de.yml index 7e2b4d60aca21..f13d8570866f6 100644 --- a/decidim-assemblies/config/locales/de.yml +++ b/decidim-assemblies/config/locales/de.yml @@ -135,7 +135,7 @@ de: assembly_copies: new: copy: Kopieren - select: Wählen Sie die Daten aus, die Sie duplizieren möchten + select: Wählen Sie, welche Daten Sie duplizieren möchten title: Dupliziertes Gremium assembly_imports: create: @@ -255,7 +255,7 @@ de: admin_log: assembly: create: "%{user_name} hat das Gremium %{resource_name} erstellt" - duplicate: "%{user_name} hat das Gremium %{resource_name} aktualisiert" + duplicate: "%{user_name} hat das Gremium %{resource_name} dupliziert" export: "%{user_name} hat das Gremium %{resource_name} exportiert" import: "%{user_name} hat das Gremium %{resource_name} importiert" publish: "%{user_name} hat das Gremium %{resource_name} veröffentlicht" diff --git a/decidim-assemblies/config/locales/el.yml b/decidim-assemblies/config/locales/el.yml index eceac95b084f4..bab2c0032c5c0 100644 --- a/decidim-assemblies/config/locales/el.yml +++ b/decidim-assemblies/config/locales/el.yml @@ -112,10 +112,6 @@ el: update: error: Υπήρξε ένα πρόβλημα κατά την ενημέρωση αυτής της συνέλευσης. success: Η συνέλευση ενημερώθηκε με επιτυχία. - assemblies_copies: - create: - error: Υπήρξε ένα πρόβλημα κατά την αντιγραφή αυτής της συνέλευσης. - success: Η συνέλευση αντιγράφτηκε με επιτυχία. assemblies_types: create: error: Υπήρξε ένα πρόβλημα κατά τη δημιουργία ενός νέου τύπου συνέλευσης. @@ -131,8 +127,6 @@ el: assembly_copies: new: copy: Αντιγραφή - select: Επιλέξτε ποια δεδομένα θέλετε να αντιγράψετε - title: Αντιγραφή συνέλευσης assembly_imports: create: error: Προέκυψε ένα πρόβλημα κατά την εισαγωγή αυτής της συνέλευσης. diff --git a/decidim-assemblies/config/locales/es-MX.yml b/decidim-assemblies/config/locales/es-MX.yml index fbf83f6357f6f..f576fc1497e3c 100644 --- a/decidim-assemblies/config/locales/es-MX.yml +++ b/decidim-assemblies/config/locales/es-MX.yml @@ -118,8 +118,8 @@ es-MX: success: La asamblea se ha actualizado correctamente. assemblies_copies: create: - error: Se produjo un error al duplicar esta asamblea. - success: Asamblea duplicada correctamente. + error: Se ha producido un error al duplicar esta asamblea. + success: La asamblea se ha duplicado correctamente. assemblies_types: create: error: Se ha producido un error al crear un nuevo tipo de asamblea. @@ -135,7 +135,7 @@ es-MX: assembly_copies: new: copy: Copiar - select: Seleccione los datos que desea duplicar + select: Selecciona qué datos quieres duplicar title: Duplicar asamblea assembly_imports: create: diff --git a/decidim-assemblies/config/locales/es-PY.yml b/decidim-assemblies/config/locales/es-PY.yml index 06fd70799feac..f63be6043aec4 100644 --- a/decidim-assemblies/config/locales/es-PY.yml +++ b/decidim-assemblies/config/locales/es-PY.yml @@ -118,8 +118,8 @@ es-PY: success: La asamblea se ha actualizado correctamente. assemblies_copies: create: - error: Se produjo un error al duplicar esta asamblea. - success: Asamblea duplicada correctamente. + error: Se ha producido un error al duplicar esta asamblea. + success: La asamblea se ha duplicado correctamente. assemblies_types: create: error: Se ha producido un error al crear un nuevo tipo de asamblea. @@ -135,7 +135,7 @@ es-PY: assembly_copies: new: copy: Copiar - select: Seleccione los datos que desea duplicar + select: Selecciona qué datos quieres duplicar title: Duplicar asamblea assembly_imports: create: diff --git a/decidim-assemblies/config/locales/es.yml b/decidim-assemblies/config/locales/es.yml index 6f37a22026e70..40bf7be220b47 100644 --- a/decidim-assemblies/config/locales/es.yml +++ b/decidim-assemblies/config/locales/es.yml @@ -119,7 +119,7 @@ es: assemblies_copies: create: error: Se ha producido un error al duplicar esta asamblea. - success: Asamblea duplicada correctamente. + success: La asamblea se ha duplicado correctamente. assemblies_types: create: error: Se ha producido un error al crear un nuevo tipo de asamblea. diff --git a/decidim-assemblies/config/locales/eu.yml b/decidim-assemblies/config/locales/eu.yml index 500240488f5da..070443770a67d 100644 --- a/decidim-assemblies/config/locales/eu.yml +++ b/decidim-assemblies/config/locales/eu.yml @@ -135,8 +135,8 @@ eu: assembly_copies: new: copy: Kopiatu - select: Hautatu bikoiztu nahi dituzun datuak - title: Kopiatu batzarra + select: Hautatu zein datu bikoiztu nahi dituzun + title: Batzarra bikoiuztu assembly_imports: create: error: Arazo bat egon da batzar hau inportatzean. diff --git a/decidim-assemblies/config/locales/fi-plain.yml b/decidim-assemblies/config/locales/fi-plain.yml index 2236417102db6..803b6c364fe7e 100644 --- a/decidim-assemblies/config/locales/fi-plain.yml +++ b/decidim-assemblies/config/locales/fi-plain.yml @@ -118,8 +118,8 @@ fi-pl: success: Ryhmä päivitettiin onnistuneesti. assemblies_copies: create: - error: Virhe kopioitaessa ryhmää. - success: Ryhmä kopioitu onnistuneesti. + error: Ryhmän kopioiminen epäonnistui. + success: Ryhmän kopioiminen onnistui. assemblies_types: create: error: Uuden ryhmätyypin luonti epäonnistui. diff --git a/decidim-assemblies/config/locales/fi.yml b/decidim-assemblies/config/locales/fi.yml index b612d1bf4a705..6a9f1267b8ce3 100644 --- a/decidim-assemblies/config/locales/fi.yml +++ b/decidim-assemblies/config/locales/fi.yml @@ -118,8 +118,8 @@ fi: success: Ryhmän päivitys onnistui. assemblies_copies: create: - error: Ryhmän kopiointi epäonnistui. - success: Ryhmän kopiointi onnistui. + error: Ryhmän kopioiminen epäonnistui. + success: Ryhmän kopioiminen onnistui. assemblies_types: create: error: Uuden ryhmätyypin luonti epäonnistui. diff --git a/decidim-assemblies/config/locales/fr-CA.yml b/decidim-assemblies/config/locales/fr-CA.yml index 191ae636a6ecf..69e45e82eed29 100644 --- a/decidim-assemblies/config/locales/fr-CA.yml +++ b/decidim-assemblies/config/locales/fr-CA.yml @@ -302,7 +302,7 @@ fr-CA: title: Titre assembly_copies: form: - slug_help_html: 'Les identifiants d''URL sont utilisés pour générer les URL qui pointent vers cette assemblée. N''accepte que des lettres, des chiffres et des tirets et doit commencer par une lettre. Exemple: %{url}' + slug_help_html: 'Les identifiants d''URL sont utilisés pour générer les URL qui pointent vers cette assemblée. N''accepte que des lettres, des chiffres et des tirets et doit commencer par une lettre. Exemple : %{url}' assembly_imports: form: slug_help_html: 'Les identifiants d''URL sont utilisés pour générer les URL qui pointent vers cette assemblée. N''accepte que des lettres, des chiffres et des tirets et doit commencer par une lettre. Exemple: %{url}' diff --git a/decidim-assemblies/config/locales/fr.yml b/decidim-assemblies/config/locales/fr.yml index 1c37063d0ec49..ddd3a3a5b0727 100644 --- a/decidim-assemblies/config/locales/fr.yml +++ b/decidim-assemblies/config/locales/fr.yml @@ -302,7 +302,7 @@ fr: title: Modifier le type d'assemblée assembly_copies: form: - slug_help_html: 'Les identifiants d''URL sont utilisés pour générer les URL qui pointent vers cette assemblée. N''accepte que des lettres, des chiffres et des tirets et doit commencer par une lettre. Exemple: %{url}' + slug_help_html: 'Les identifiants d''URL sont utilisés pour générer les URL qui pointent vers cette assemblée. N''accepte que des lettres, des chiffres et des tirets et doit commencer par une lettre. Exemple : %{url}' assembly_imports: form: slug_help_html: 'Les identifiants d''URL sont utilisés pour générer les URL qui pointent vers cette assemblée. N''accepte que des lettres, des chiffres et des tirets et doit commencer par une lettre. Exemple: %{url}' diff --git a/decidim-assemblies/config/locales/gl.yml b/decidim-assemblies/config/locales/gl.yml index 4a2e9132298c7..456c5805f651f 100644 --- a/decidim-assemblies/config/locales/gl.yml +++ b/decidim-assemblies/config/locales/gl.yml @@ -100,10 +100,6 @@ gl: update: error: Produciuse un erro ao actualizar este conxunto. success: Asemblea actualizouse con éxito. - assemblies_copies: - create: - error: Produciuse un erro ao duplicar este conxunto. - success: Asemblea duplicouse con éxito. assemblies_types: create: error: Produciuse un problema ao crear un novo tipo de xuntanza. @@ -119,8 +115,6 @@ gl: assembly_copies: new: copy: Copiar - select: Seleccione os datos que desexa duplicar - title: Conxunto duplicado assembly_imports: create: error: Produciuse un problema ao importar esta xuntanza. diff --git a/decidim-assemblies/config/locales/he-IL.yml b/decidim-assemblies/config/locales/he-IL.yml index 195cce0eab1da..226ffe7961a13 100644 --- a/decidim-assemblies/config/locales/he-IL.yml +++ b/decidim-assemblies/config/locales/he-IL.yml @@ -114,10 +114,6 @@ he: update: error: יש בעיה בעדכון אסיפה זו. success: האסיפה עודכנה בהצלחה. - assemblies_copies: - create: - error: יש בעיה בשכפול אסיפה זו. - success: אסיפה השתכפלה בהצלחה. assemblies_types: create: error: יש בעיה ביצירת סוג אסיפה חדש. @@ -133,7 +129,6 @@ he: assembly_copies: new: copy: העתקה - title: שכפל אסיפה assembly_imports: create: error: הייתה בעיה בייבוא ​​אסיפה זו. diff --git a/decidim-assemblies/config/locales/hu.yml b/decidim-assemblies/config/locales/hu.yml index 0b7428c472b30..f92d2c31f04e8 100644 --- a/decidim-assemblies/config/locales/hu.yml +++ b/decidim-assemblies/config/locales/hu.yml @@ -116,10 +116,6 @@ hu: update: error: Hiba történt a gyűlés frissítése során. success: Gyűlés frissítése sikeres. - assemblies_copies: - create: - error: Hiba történt a gyűlés duplikációja során. - success: Gyűlés duplikációja sikeres. assemblies_types: create: error: Hiba történt az új gyűlés létrehozása során. @@ -135,8 +131,6 @@ hu: assembly_copies: new: copy: Másolás - select: Válaszd ki, mely adatokat szeretnéd duplikálni - title: Gyűlés duplikálása assembly_imports: create: error: Hiba történt a gyűlés importálása során. diff --git a/decidim-assemblies/config/locales/id-ID.yml b/decidim-assemblies/config/locales/id-ID.yml index ac5ce1b90a62c..0345776d22bf8 100644 --- a/decidim-assemblies/config/locales/id-ID.yml +++ b/decidim-assemblies/config/locales/id-ID.yml @@ -92,18 +92,12 @@ id: update: error: Ada kesalahan saat memperbarui perakitan ini. success: Majelis berhasil diperbarui. - assemblies_copies: - create: - error: Ada kesalahan saat menduplikasi majelis ini. - success: Majelis berhasil digandakan. assemblies_types: new: create: Membuat assembly_copies: new: copy: Salinan - select: Pilih data mana yang ingin Anda gandakan - title: Rakitan duplikat assembly_members: create: error: Terjadi kesalahan saat menambahkan anggota untuk majelis ini. diff --git a/decidim-assemblies/config/locales/is-IS.yml b/decidim-assemblies/config/locales/is-IS.yml index ca4c1d796e3ff..272e18976ee36 100644 --- a/decidim-assemblies/config/locales/is-IS.yml +++ b/decidim-assemblies/config/locales/is-IS.yml @@ -92,8 +92,6 @@ is: assembly_copies: new: copy: Afrita - select: Veldu hvaða gögn þú vilt afrita - title: Afrit samkoma assembly_imports: new: import: Flytja inn diff --git a/decidim-assemblies/config/locales/it.yml b/decidim-assemblies/config/locales/it.yml index a476aae961b03..9630ab57e2dee 100644 --- a/decidim-assemblies/config/locales/it.yml +++ b/decidim-assemblies/config/locales/it.yml @@ -68,7 +68,7 @@ it: gender: Genere non_user_avatar: Avatar position: Posizione - user_id: Utente + user_id: Utente o gruppo weight: Posizione nell'elenco assembly_user_role: email: E-mail @@ -96,6 +96,7 @@ it: actions: import_assembly: Importa new_assembly: Nuova assemblea + new_assembly_member: Nuovo membro dell'assemblea new_assembly_type: Nuovo tipo di assemblea new_assembly_user_role: Nuovo amministratore dello spazio assemblies: @@ -115,10 +116,6 @@ it: update: error: Si è verificato un errore durante l'aggiornamento di questa assemblea. success: L'assemblea è stata aggiornata correttamente. - assemblies_copies: - create: - error: Si è verificato un errore durante la duplicazione di questa assemblea. - success: L'assemblea è stata duplicata con successo. assemblies_types: create: error: Si è verificato un errore durante la creazione di un nuovo tipo di assemblea. @@ -134,8 +131,6 @@ it: assembly_copies: new: copy: Copia - select: Scegli quale dato vuoi duplicare - title: Duplica l'assemblea assembly_imports: create: error: Si è verificato un errore durante l'aggiornamento di questa assemblea. @@ -151,11 +146,13 @@ it: destroy: success: Membro cancellato con successo per questa assemblea. edit: + title: Aggiorna membro dell'assemblea update: Aggiorna index: assembly_members_title: Membri dell'Assemblea new: create: Crea + title: Nuovo membro dell'assemblea update: error: Si è verificato un errore durante l'aggiornamento del membro per questa assemblea. success: Membro aggiornato correttamente per questa assemblea. @@ -165,7 +162,7 @@ it: success: L'Assemblea è stata pubblicata con successo. destroy: error: Si è verificato un errore durante la pubblicazione di questo assembly. - success: Assemblea cancellata con successo. + success: Assemblea non pubblicata con successo. assembly_user_roles: create: error: Si è verificato un errore durante l'aggiunta di un utente per questa assemblea. @@ -173,7 +170,7 @@ it: destroy: success: Utente rimosso con successo da questa assemblea. edit: - title: Aggiorna gli amministratori dello spazio + title: Aggiorna gli amministratori dell'assemblea update: Aggiorna index: assembly_admins_title: Amministratori dell'assemblea @@ -185,7 +182,9 @@ it: success: Admin aggiornato correttamente per questa assemblea. filters: ceased_date_not_null: + label: Concluso values: + 'false': Non concluso 'true': Conclusq decidim_assemblies_type_id_eq: label: Tipo di assemblea @@ -202,7 +201,7 @@ it: categories: Categorie components: Componenti info: Info su questo spazio - landing_page: Pagina iniziale + landing_page: Pagina di atterraggio moderations: Moderazione private_users: Partecipanti privati see_assembly: Guarda l'assemblea @@ -230,7 +229,7 @@ it: name: Membro positions: other: Altro - president: Presidentessa/Presidente + president: Presidente secretary: Segretario vice_president: Vicepresidente assembly_user_role: @@ -306,7 +305,7 @@ it: existing_user: Utente esistente explanation: 'Guida per l''immagine:' image_guide: È preferibile un'immagine verticale priva di testo. - non_user: Non utente + non_user: Non partecipante non_user_avatar_help: Si dovrebbe ottenere il consenso delle persone prima di renderle pubbliche come membri dell'assemblea. select_a_position: Seleziona una posizione select_user: Seleziona un utente @@ -402,6 +401,7 @@ it: assemblies: create_assembly_member: email_intro: Un amministratore dell'assemblea %{resource_name} ti ha aggiunto come membro. + email_outro: Hai ricevuto questa notifica perché sei stato invitato in un assemblea. Controlla la pagina assembly per contribuire! email_subject: Hai ricevuto un invito a far parte dell'Assemblea %{resource_name}! notification_title: Sei stato registrato come membro dell'Assemblea %{resource_name}. Controlla la pagina dell'assemblea per contribuire! assembly: @@ -442,6 +442,10 @@ it: take_part: Partecipa index: promoted_assemblies: Assemblee in evidenza + metadata: + children_item: + one: "%{count} assemblee" + other: "%{count} assemblee" order_by_assemblies: assemblies: one: "%{count} assemblee" diff --git a/decidim-assemblies/config/locales/lb.yml b/decidim-assemblies/config/locales/lb.yml index 3a2cdc042c007..ddcbf55a7243c 100644 --- a/decidim-assemblies/config/locales/lb.yml +++ b/decidim-assemblies/config/locales/lb.yml @@ -100,10 +100,6 @@ lb: update: error: Beim Aktualisieren dieses Gremiums ist ein Fehler aufgetreten. success: Das Gremium wurde erfolgreich aktualisiert. - assemblies_copies: - create: - error: Beim Duplizieren dieses Gremiums ist ein Fehler aufgetreten. - success: Das Gremium wurde erfolgreich dupliziert. assemblies_types: create: error: Beim Erstellen eines neuen Gremiumtyps ist ein Fehler aufgetreten. @@ -119,8 +115,6 @@ lb: assembly_copies: new: copy: Kopieren - select: Wählen Sie die Daten aus, die Sie duplizieren möchten - title: Doppelte Montage assembly_imports: create: error: Beim Importieren dieses Gremiums ist ein Fehler aufgetreten. diff --git a/decidim-assemblies/config/locales/lt.yml b/decidim-assemblies/config/locales/lt.yml index 5d5d38a6b2825..872685d9c8407 100644 --- a/decidim-assemblies/config/locales/lt.yml +++ b/decidim-assemblies/config/locales/lt.yml @@ -118,10 +118,6 @@ lt: update: error: Atnaujinant šią asamblėją iškilo problema. success: Asamblėja atnaujinta. - assemblies_copies: - create: - error: Dubliuojant šią asamblėją iškilo problema. - success: Asamblėja dubliuota. assemblies_types: create: error: Kuriant naujos asamblėjos tipą iškilo problema. @@ -137,8 +133,6 @@ lt: assembly_copies: new: copy: Kopijuoti - select: Pasirinkite, kuriuos duomenis norėtumėte dubliuoti - title: Dublikuoti asamblėją assembly_imports: create: error: Importuojant asamblėją iškilo problema. diff --git a/decidim-assemblies/config/locales/lv.yml b/decidim-assemblies/config/locales/lv.yml index e3aef39cbe6c8..c08b5c1b5e1ab 100644 --- a/decidim-assemblies/config/locales/lv.yml +++ b/decidim-assemblies/config/locales/lv.yml @@ -95,10 +95,6 @@ lv: update: error: Šīs asamblejas atjaunināšanas laikā radās problēma. success: Asambleja ir veiksmīgi atjaunināta. - assemblies_copies: - create: - error: Šīs asamblejas dublēšanas laikā radās problēma. - success: Asamblejas dublēšana ir veiksmīgi pabeigta. assemblies_types: create: error: Jaunas asamblejas veida izveides laikā radās problēma. @@ -114,8 +110,6 @@ lv: assembly_copies: new: copy: Kopēt - select: Atlasiet, kurus datus vēlaties dublēt - title: Dublēt asambleju assembly_members: create: error: Pievienojot dalībnieku šai asamblejai, radās problēma. diff --git a/decidim-assemblies/config/locales/nl.yml b/decidim-assemblies/config/locales/nl.yml index 53dfa03258e07..abb37d011184e 100644 --- a/decidim-assemblies/config/locales/nl.yml +++ b/decidim-assemblies/config/locales/nl.yml @@ -100,10 +100,6 @@ nl: update: error: Er is een fout opgetreden bij het bijwerken van deze groep. success: Groep is succesvol bijgewerkt. - assemblies_copies: - create: - error: Er was een fout bij het dupliceren van deze groep. - success: Groep succesvol gedupliceerd. assemblies_types: create: error: Er is een fout opgetreden bij het maken van een nieuw groepstype. @@ -119,8 +115,6 @@ nl: assembly_copies: new: copy: Kopiëren - select: Selecteer welke gegevens u wilt dupliceren - title: Dupliceer bijeenkomst assembly_imports: create: error: Er is een probleem opgetreden bij het importeren van deze groep. diff --git a/decidim-assemblies/config/locales/no.yml b/decidim-assemblies/config/locales/no.yml index 636fc469db2e9..d8a90c6af3680 100644 --- a/decidim-assemblies/config/locales/no.yml +++ b/decidim-assemblies/config/locales/no.yml @@ -100,10 +100,6 @@ update: error: Det oppstod et problem med å oppdatere denne forsamlingen. success: Forsamlingen ble oppdatert. - assemblies_copies: - create: - error: Det oppstod et problem med å publisere denne forsamlingen. - success: Forsamlingen ble duplisert. assemblies_types: create: error: Det oppstod et problem med å lage en ny forsamlingstype. @@ -119,8 +115,6 @@ assembly_copies: new: copy: Kopier - select: Velg hvilke data du vil duplisere - title: Dupliser forsamling assembly_imports: create: error: Det oppstod et problem med å importere denne forsamlingen. diff --git a/decidim-assemblies/config/locales/pl.yml b/decidim-assemblies/config/locales/pl.yml index 43d45263c1dc8..2b30ffd7765ee 100644 --- a/decidim-assemblies/config/locales/pl.yml +++ b/decidim-assemblies/config/locales/pl.yml @@ -122,10 +122,6 @@ pl: update: error: Podczas aktualizowania tego zespołu wystąpił błąd. success: Zespół został zaktualizowany. - assemblies_copies: - create: - error: Podczas duplikowania tego zespołu wystąpił błąd. - success: Zespół został zduplikowany. assemblies_types: create: error: Podczas tworzenia nowego typu zespołu wystąpił błąd. @@ -141,8 +137,6 @@ pl: assembly_copies: new: copy: Kopiuj - select: Wybierz dane, które chcesz zduplikować - title: Zduplikuj zespół assembly_imports: create: error: Wystąpił błąd podczas importowania tego zespołu. diff --git a/decidim-assemblies/config/locales/pt-BR.yml b/decidim-assemblies/config/locales/pt-BR.yml index 626f5d616ecd2..d7be97c5db3b9 100644 --- a/decidim-assemblies/config/locales/pt-BR.yml +++ b/decidim-assemblies/config/locales/pt-BR.yml @@ -116,10 +116,6 @@ pt-BR: update: error: Ocorreu um erro ao atualizar esta assembleia. success: Assembleia atualizada com sucesso. - assemblies_copies: - create: - error: Ocorreu um erro ao duplicar esta assembleia. - success: Assembleia duplicada com sucesso. assemblies_types: create: error: Ocorreu um erro ao criar um novo tipo de assembleia. @@ -135,8 +131,6 @@ pt-BR: assembly_copies: new: copy: Cópia - select: Selecione os dados que você gostaria de duplicar - title: Duplicar assembleia assembly_imports: create: error: Ocorreu um erro ao importar esta assembleia. diff --git a/decidim-assemblies/config/locales/pt.yml b/decidim-assemblies/config/locales/pt.yml index de5ead485b9f5..a67b4553944ca 100644 --- a/decidim-assemblies/config/locales/pt.yml +++ b/decidim-assemblies/config/locales/pt.yml @@ -115,10 +115,6 @@ pt: update: error: Ocorreu um problema ao atualizar esta reunião. success: Reunião atualizada corretamente. - assemblies_copies: - create: - error: Ocorreu um problema ao duplicar esta reunião. - success: Reunião duplicada corretamente. assemblies_types: create: error: Ocorreu um problema ao criar um novo tipo de reunião. @@ -134,8 +130,6 @@ pt: assembly_copies: new: copy: Cópia - select: Selecione os dados que pretende duplicar - title: Duplicar assembléia assembly_imports: create: error: Ocorreu um problema ao atualizar esta reunião. diff --git a/decidim-assemblies/config/locales/ro-RO.yml b/decidim-assemblies/config/locales/ro-RO.yml index 375110a39b770..9f8c894310fbc 100644 --- a/decidim-assemblies/config/locales/ro-RO.yml +++ b/decidim-assemblies/config/locales/ro-RO.yml @@ -115,10 +115,6 @@ ro: update: error: A apărut o eroare la actualizarea acestui grup de lucru. success: Grupul de lucru a fost actualizat cu succes. - assemblies_copies: - create: - error: A apărut o problemă la duplicarea acestui grup de lucru. - success: Grupul de lucru a fost duplicat cu succes. assemblies_types: create: error: A apărut o problemă la crearea unui nou tip de grup de lucru. @@ -134,8 +130,6 @@ ro: assembly_copies: new: copy: Copiază - select: Selectați datele pe care doriți să le duplicați - title: Duplică grupul de lucru assembly_imports: create: error: A apărut o problemă la importul acestui grup de lucru. diff --git a/decidim-assemblies/config/locales/ru.yml b/decidim-assemblies/config/locales/ru.yml index bb59def9251ae..e4cc3ae3aa487 100644 --- a/decidim-assemblies/config/locales/ru.yml +++ b/decidim-assemblies/config/locales/ru.yml @@ -100,18 +100,12 @@ ru: update: error: При попытке обновить это собрание произошла ошибка. success: Собрание успешно обновлено. - assemblies_copies: - create: - error: При попытке создать копию этого собрания произошла ошибка. - success: Успешно создана копия собрания. assemblies_types: new: create: Добавить assembly_copies: new: copy: Копировать - select: Выберите, какие данные вы хотите продублировать - title: Создать копию собрания assembly_members: create: error: При попытке добавить члена президиума этого собрания произошла ошибка. diff --git a/decidim-assemblies/config/locales/sl.yml b/decidim-assemblies/config/locales/sl.yml index e40be44e1b619..a66cb3c72cee0 100644 --- a/decidim-assemblies/config/locales/sl.yml +++ b/decidim-assemblies/config/locales/sl.yml @@ -99,10 +99,6 @@ sl: update: error: Pojavila se je težava pri urejanju združbe. success: Združba uspešno posodobljena. - assemblies_copies: - create: - error: Pojavila se je težava pri podvajanju združbe. - success: Združba uspešno podvojena. assemblies_types: create: error: Pojavila se je težava pri kreiranju nove združbe. @@ -118,8 +114,6 @@ sl: assembly_copies: new: copy: Kopiraj - select: Izberi, katere podatke želiš podvojiti - title: Podvoji združbo assembly_imports: create: error: Pojavila se je težava pri uvozu te združbe. diff --git a/decidim-assemblies/config/locales/sq-AL.yml b/decidim-assemblies/config/locales/sq-AL.yml index aeffdc23e555a..cdf7bb09f15c9 100644 --- a/decidim-assemblies/config/locales/sq-AL.yml +++ b/decidim-assemblies/config/locales/sq-AL.yml @@ -104,10 +104,6 @@ sq: update: error: Ndodhi një gabim gjatë përditësimit të asamblesë. success: Asambleja u përditësua me sukses. - assemblies_copies: - create: - error: Ndodhi një gabim gjatë duplikimit të asamblesë. - success: Asambleja e duplikua me sukses. assemblies_types: create: error: Ndodhi një gabim gjatë krijimit të tipit të ri të asamblesë. @@ -123,8 +119,6 @@ sq: assembly_copies: new: copy: Kopjo - select: Zgjidh cilën të dhënë dëshiron të duplikosh - title: Dupliko asamblenë assembly_imports: create: error: Ndodhi një gabim gjatë importimit të asamblesë. diff --git a/decidim-assemblies/config/locales/sv.yml b/decidim-assemblies/config/locales/sv.yml index 08cbb97d4eb50..9f490abe8b258 100644 --- a/decidim-assemblies/config/locales/sv.yml +++ b/decidim-assemblies/config/locales/sv.yml @@ -42,7 +42,7 @@ sv: meta_scope: Omfattning parent_id: Överordnat samråd participatory_processes_ids: Relaterade deltagandeprocesser - participatory_scope: Vad bestäms + participatory_scope: Vad beslutas participatory_structure: Hur fattas beslut private_space: Privat utrymme promoted: Utvald @@ -54,7 +54,7 @@ sv: slug: URL-slug special_features: Specialfunktioner subtitle: Underrubrik - target: Vem deltar + target: Vilka deltar title: Titel twitter: X weight: Position i listan @@ -135,7 +135,7 @@ sv: assembly_copies: new: copy: Kopiera - select: Välj vilka data som ska dupliceras + select: Välj vilka data som du vill duplicera title: Duplicera samråd assembly_imports: create: @@ -327,11 +327,11 @@ sv: area_name: Område closing_date: Slutdatum created_by: Skapad av - creation_date: Skapad + creation_date: Startdatum data: Data från samråd developer_group: Arrangör duration: Varaktighet - included_at: Inkluderad + included_at: Publicerad indefinite_duration: Permanent local_area: Område meta_scope: Indelning @@ -368,9 +368,9 @@ sv: related_assemblies: name: Relaterade samråd created_by: - city_council: Stadsfullmäktige + city_council: Staden others: Övriga - public: Offentligt + public: Medborgare filter: all: Alla typer commission: Kommission diff --git a/decidim-assemblies/config/locales/tr-TR.yml b/decidim-assemblies/config/locales/tr-TR.yml index b6997dcb86f4d..1f842b0084765 100644 --- a/decidim-assemblies/config/locales/tr-TR.yml +++ b/decidim-assemblies/config/locales/tr-TR.yml @@ -108,10 +108,6 @@ tr: update: error: Bu kurul güncellenirken bir hata oluştu. success: Kurul başarıyla güncellendi. - assemblies_copies: - create: - error: Bu kurul çoğaltırken bir hata oluştu. - success: Kurul başarıyla kopyalandı. assemblies_types: create: error: Yeni bir kurul türü oluşturulurken bir sorun meydana geldi. @@ -127,8 +123,6 @@ tr: assembly_copies: new: copy: Kopya - select: Çoğaltmak istediğiniz verileri seçin - title: Kurulu çoğalt assembly_imports: create: error: Bu kurul derlenirken, içeri aktarılırken bir hata oluştu. diff --git a/decidim-assemblies/config/locales/uk.yml b/decidim-assemblies/config/locales/uk.yml index 5414d9bbad612..c523d49664047 100644 --- a/decidim-assemblies/config/locales/uk.yml +++ b/decidim-assemblies/config/locales/uk.yml @@ -100,18 +100,12 @@ uk: update: error: При спробі оновити ці збори сталася помилка. success: Збори успішно оновлено. - assemblies_copies: - create: - error: При спробі створити копію цих зборів сталася помилка. - success: Успішно створено копію зборів. assemblies_types: new: create: Додати assembly_copies: new: copy: Скопіювати - select: Оберіть відомості, копію яких ви хотіли б створити - title: Створити копію зборів assembly_members: create: error: При спробі додати члена президії цих зборів сталася помилка. diff --git a/decidim-assemblies/config/locales/zh-CN.yml b/decidim-assemblies/config/locales/zh-CN.yml index db5e95825e893..78354bd554818 100644 --- a/decidim-assemblies/config/locales/zh-CN.yml +++ b/decidim-assemblies/config/locales/zh-CN.yml @@ -94,10 +94,6 @@ zh-CN: update: error: 更新这个组件时出现问题。 success: 程序更新成功。 - assemblies_copies: - create: - error: 复制这个组件时出现问题。 - success: 已成功复制组合。 assemblies_types: create: error: 创建新组装类型时出现问题。 @@ -113,8 +109,6 @@ zh-CN: assembly_copies: new: copy: 复制 - select: 选择要重复的数据 - title: 复制程序集 assembly_imports: create: error: 导入此组件时出现问题。 diff --git a/decidim-assemblies/config/locales/zh-TW.yml b/decidim-assemblies/config/locales/zh-TW.yml index 435f5b42bd741..9ac92a4046497 100644 --- a/decidim-assemblies/config/locales/zh-TW.yml +++ b/decidim-assemblies/config/locales/zh-TW.yml @@ -109,10 +109,6 @@ zh-TW: update: error: 更新此大會時出現問題 success: 此大會成功更新 - assemblies_copies: - create: - error: 複製此大會時出現問題 - success: 大會已成功複製 assemblies_types: create: error: 創建新大會類型時出現問題 @@ -128,8 +124,6 @@ zh-TW: assembly_copies: new: copy: 複製 - select: 請選擇您想要複製的資料 - title: 複製大會 assembly_imports: create: error: 這個大會匯入時發生了問題 diff --git a/decidim-assemblies/lib/decidim/assemblies/admin_engine.rb b/decidim-assemblies/lib/decidim/assemblies/admin_engine.rb index 6256e34abd99f..1408f21dd26d8 100644 --- a/decidim-assemblies/lib/decidim/assemblies/admin_engine.rb +++ b/decidim-assemblies/lib/decidim/assemblies/admin_engine.rb @@ -53,6 +53,7 @@ class AdminEngine < ::Rails::Engine put :unpublish get :share end + resources :component_share_tokens, except: [:show], path: "share_tokens", as: "share_tokens" resources :exports, only: :create resources :imports, only: [:new, :create] do get :example, on: :collection @@ -79,6 +80,8 @@ class AdminEngine < ::Rails::Engine end end end + + resources :assembly_share_tokens, except: [:show], path: "share_tokens" end scope "/assemblies/:assembly_slug/components/:component_id/manage" do diff --git a/decidim-assemblies/lib/decidim/assemblies/menu.rb b/decidim-assemblies/lib/decidim/assemblies/menu.rb index ca721b929a1d8..382e2ec9bb857 100644 --- a/decidim-assemblies/lib/decidim/assemblies/menu.rb +++ b/decidim-assemblies/lib/decidim/assemblies/menu.rb @@ -78,6 +78,7 @@ def self.register_admin_assemblies_components_menu! active: is_active_link?(manage_component_path(component)) || is_active_link?(decidim_admin_assemblies.edit_component_path(current_participatory_space, component)) || is_active_link?(decidim_admin_assemblies.edit_component_permissions_path(current_participatory_space, component)) || + is_active_link?(decidim_admin_assemblies.component_share_tokens_path(current_participatory_space, component)) || participatory_space_active_link?(component), if: component.manifest.admin_engine && user_role_config.component_is_accessible?(component.manifest_name) end @@ -145,6 +146,13 @@ def self.register_admin_assembly_menu! decidim_admin_assemblies.moderations_path(current_participatory_space), icon_name: "flag-line", if: allowed_to?(:read, :moderation, assembly: current_participatory_space) + + menu.add_item :assembly_share_tokens, + I18n.t("menu.share_tokens", scope: "decidim.admin"), + decidim_admin_assemblies.assembly_share_tokens_path(current_participatory_space), + active: is_active_link?(decidim_admin_assemblies.assembly_share_tokens_path(current_participatory_space)), + icon_name: "share-line", + if: allowed_to?(:read, :share_tokens, current_participatory_space:) end end diff --git a/decidim-assemblies/lib/decidim/assemblies/version.rb b/decidim-assemblies/lib/decidim/assemblies/version.rb index ba9883548bb51..6ebfd29a73da3 100644 --- a/decidim-assemblies/lib/decidim/assemblies/version.rb +++ b/decidim-assemblies/lib/decidim/assemblies/version.rb @@ -4,7 +4,7 @@ module Decidim # This holds the decidim-assemblies version. module Assemblies def self.version - "0.29.4" + "0.29.6" end end end diff --git a/decidim-assemblies/spec/shared/manage_assembly_components_examples.rb b/decidim-assemblies/spec/shared/manage_assembly_components_examples.rb index 803c083182491..065e34997b62c 100644 --- a/decidim-assemblies/spec/shared/manage_assembly_components_examples.rb +++ b/decidim-assemblies/spec/shared/manage_assembly_components_examples.rb @@ -209,8 +209,6 @@ } )) end - - it_behaves_like "manage component share tokens" end context "when the component is published" do diff --git a/decidim-assemblies/spec/system/admin/admin_manages_assembly_component_share_tokens_spec.rb b/decidim-assemblies/spec/system/admin/admin_manages_assembly_component_share_tokens_spec.rb new file mode 100644 index 0000000000000..10bdf5dec0f50 --- /dev/null +++ b/decidim-assemblies/spec/system/admin/admin_manages_assembly_component_share_tokens_spec.rb @@ -0,0 +1,12 @@ +# frozen_string_literal: true + +require "spec_helper" + +describe "Admin manages assembly component share tokens" do + include_context "when admin administrating an assembly" + + it_behaves_like "manage component share tokens" do + let(:participatory_space) { assembly } + let(:participatory_space_engine) { decidim_admin_assemblies } + end +end diff --git a/decidim-assemblies/spec/system/admin/admin_manages_assembly_share_tokens_spec.rb b/decidim-assemblies/spec/system/admin/admin_manages_assembly_share_tokens_spec.rb new file mode 100644 index 0000000000000..aab9636ad0eea --- /dev/null +++ b/decidim-assemblies/spec/system/admin/admin_manages_assembly_share_tokens_spec.rb @@ -0,0 +1,21 @@ +# frozen_string_literal: true + +require "spec_helper" + +describe "Admin manages assembly share tokens" do + let!(:user) { create(:user, :admin, :confirmed, organization:) } + let(:organization) { create(:organization) } + let!(:assembly) { create(:assembly, organization:, private_space: true) } + let(:participatory_space) { assembly } + let(:participatory_space_path) { decidim_admin_assemblies.edit_assembly_path(assembly) } + let(:participatory_spaces_path) { decidim_admin_assemblies.assemblies_path } + + it_behaves_like "manage participatory space share tokens" + + context "when the user is an assembly admin" do + let(:user) { create(:user, :confirmed, :admin_terms_accepted, organization:) } + let!(:role) { create(:assembly_user_role, user:, assembly:, role: :admin) } + + it_behaves_like "manage participatory space share tokens" + end +end diff --git a/decidim-assemblies/spec/system/preview_assembly_with_share_token_spec.rb b/decidim-assemblies/spec/system/preview_assembly_with_share_token_spec.rb new file mode 100644 index 0000000000000..323eb2d49378e --- /dev/null +++ b/decidim-assemblies/spec/system/preview_assembly_with_share_token_spec.rb @@ -0,0 +1,11 @@ +# frozen_string_literal: true + +require "spec_helper" + +describe "Preview assembly with share token" do + let(:organization) { create(:organization) } + let!(:participatory_space) { create(:assembly, organization:, published_at: nil) } + let(:resource_path) { decidim_assemblies.assembly_path(participatory_space) } + + it_behaves_like "preview participatory space with a share_token" +end diff --git a/decidim-blogs/lib/decidim/blogs/version.rb b/decidim-blogs/lib/decidim/blogs/version.rb index d8d0e99f13a78..d0bf3a5325795 100644 --- a/decidim-blogs/lib/decidim/blogs/version.rb +++ b/decidim-blogs/lib/decidim/blogs/version.rb @@ -4,7 +4,7 @@ module Decidim # This holds the decidim-pages version. module Blogs def self.version - "0.29.4" + "0.29.6" end end end diff --git a/decidim-blogs/spec/system/preview_blogs_with_share_token_spec.rb b/decidim-blogs/spec/system/preview_blogs_with_share_token_spec.rb index a5ff8c5cc36e5..bc4669f1817df 100644 --- a/decidim-blogs/spec/system/preview_blogs_with_share_token_spec.rb +++ b/decidim-blogs/spec/system/preview_blogs_with_share_token_spec.rb @@ -2,9 +2,9 @@ require "spec_helper" -describe "Preview blogs with share token" do +describe "preview blogs with a share token" do let(:manifest_name) { "blogs" } include_context "with a component" - it_behaves_like "preview component with share_token" + it_behaves_like "preview component with a share_token" end diff --git a/decidim-budgets/config/locales/ar.yml b/decidim-budgets/config/locales/ar.yml index 19457c6f75b26..04697168be4d7 100644 --- a/decidim-budgets/config/locales/ar.yml +++ b/decidim-budgets/config/locales/ar.yml @@ -45,7 +45,7 @@ ar: projects: المشاريع models: budget: - name: الميزانية + name: ميزانية project: name: مشروع projects: diff --git a/decidim-budgets/config/locales/de.yml b/decidim-budgets/config/locales/de.yml index 76719489fdb44..ae51834a0825e 100644 --- a/decidim-budgets/config/locales/de.yml +++ b/decidim-budgets/config/locales/de.yml @@ -366,7 +366,7 @@ de: events: budgets: budget_published: - email_intro: 'Das Budget %{resource_title} ist jetzt für %{participatory_space_title} aktiv. Sie können es auf dieser Seite ansehen:' + email_intro: 'Das Budget %{resource_title} ist jetzt für %{participatory_space_title} aktiv. Sehen Sie es sich auf dieser Seite an:' email_outro: Sie haben diese Benachrichtigung erhalten, weil Sie %{participatory_space_title} folgen. Falls Sie keine solchen Benachrichtigungen mehr erhalten möchten, besuchen Sie den obigen Link. email_subject: Das Budget %{resource_title} ist jetzt für %{participatory_space_title} aktiv. notification_title: Das Budget %{resource_title} ist jetzt aktiv für %{participatory_space_title}. diff --git a/decidim-budgets/config/locales/eu.yml b/decidim-budgets/config/locales/eu.yml index 7a02a04325d89..886639ca26405 100644 --- a/decidim-budgets/config/locales/eu.yml +++ b/decidim-budgets/config/locales/eu.yml @@ -170,7 +170,7 @@ eu: update: "%{user_name} parte-hartzaileak %{resource_name} proiektua %{space_name} espazioan sortu da" budget_information_modal: back_to: Itzuli %{component_name} osagaira - close_modal: Itxi modala + close_modal: Itxi leihoa continue: Jarraitu more_information: Informazio gehiago aurrekontuari buruz budgets_list: @@ -331,7 +331,7 @@ eu: budget_voting_rule_required: Bozketarako arau bat behar da. geocoding_enabled: Geokodifikazioa gaitua landing_page_content: Aurrekontuen hasierako orria - more_information_modal: '"Informazio gehiago"ren modala' + more_information_modal: '"Informazio gehiago" leihoa' projects_per_page: Orrialde bakoitzeko proiektuak resources_permissions_enabled: Ekintza-baimenak ezarri ahal dira proiektu bakoitzerako scope_id: Eremua @@ -355,7 +355,7 @@ eu: highlighted_heading: Goiburu nabarmendua landing_page_content: Aurrekontuen hasierako orrialdea list_heading: Zerrendaren izenburua - more_information_modal: '"Informazio gehiago"ren modala' + more_information_modal: '"Informazio gehiago" leihoa' show_votes: Erakutsi babesak title: Izenburua votes: Bozketa diff --git a/decidim-budgets/config/locales/id-ID.yml b/decidim-budgets/config/locales/id-ID.yml index 7625a087f2a0b..5d5685f70f005 100644 --- a/decidim-budgets/config/locales/id-ID.yml +++ b/decidim-budgets/config/locales/id-ID.yml @@ -23,6 +23,8 @@ id: title: Tindakan admin: models: + budget: + name: Anggaran project: name: Proyek projects: diff --git a/decidim-budgets/config/locales/is-IS.yml b/decidim-budgets/config/locales/is-IS.yml index e4a04b1369d7a..e2a21902b3a81 100644 --- a/decidim-budgets/config/locales/is-IS.yml +++ b/decidim-budgets/config/locales/is-IS.yml @@ -17,6 +17,8 @@ is: title: Aðgerðir admin: models: + budget: + name: Fjárhagsáætlun project: name: Verkefni projects: diff --git a/decidim-budgets/config/locales/lb.yml b/decidim-budgets/config/locales/lb.yml index 96a7b00367abd..132eda0b76434 100644 --- a/decidim-budgets/config/locales/lb.yml +++ b/decidim-budgets/config/locales/lb.yml @@ -43,7 +43,7 @@ lb: projects: Projekte models: budget: - name: Bugdet + name: Budget project: name: Projekt projects: diff --git a/decidim-budgets/config/locales/lv.yml b/decidim-budgets/config/locales/lv.yml index 7d26742ca8fed..bc660440fcc7b 100644 --- a/decidim-budgets/config/locales/lv.yml +++ b/decidim-budgets/config/locales/lv.yml @@ -25,6 +25,8 @@ lv: title: Darbības admin: models: + budget: + name: Budžets project: name: Projekts projects: diff --git a/decidim-budgets/config/locales/nl.yml b/decidim-budgets/config/locales/nl.yml index 8102e8a3b1496..7cb5f318254b4 100644 --- a/decidim-budgets/config/locales/nl.yml +++ b/decidim-budgets/config/locales/nl.yml @@ -65,7 +65,7 @@ nl: projects: Projecten models: budget: - name: Budget + name: Begroting project: name: Project projects: diff --git a/decidim-budgets/config/locales/ru.yml b/decidim-budgets/config/locales/ru.yml index b0ef416e53696..201081ef652de 100644 --- a/decidim-budgets/config/locales/ru.yml +++ b/decidim-budgets/config/locales/ru.yml @@ -26,6 +26,8 @@ ru: title: Действия admin: models: + budget: + name: Бюджет project: name: Проект projects: diff --git a/decidim-budgets/config/locales/sk.yml b/decidim-budgets/config/locales/sk.yml index 386cd62b77830..79860407ab59e 100644 --- a/decidim-budgets/config/locales/sk.yml +++ b/decidim-budgets/config/locales/sk.yml @@ -26,6 +26,8 @@ sk: title: Akcie admin: models: + budget: + name: Rozpočet project: name: Projekt projects: diff --git a/decidim-budgets/config/locales/uk.yml b/decidim-budgets/config/locales/uk.yml index 96263922cfcf3..7dff50c1d26b6 100644 --- a/decidim-budgets/config/locales/uk.yml +++ b/decidim-budgets/config/locales/uk.yml @@ -26,6 +26,8 @@ uk: title: Дії admin: models: + budget: + name: Бюджет project: name: Проект projects: diff --git a/decidim-budgets/lib/decidim/budgets/version.rb b/decidim-budgets/lib/decidim/budgets/version.rb index a260bacc19ef3..7d16b6a6d0ec7 100644 --- a/decidim-budgets/lib/decidim/budgets/version.rb +++ b/decidim-budgets/lib/decidim/budgets/version.rb @@ -4,7 +4,7 @@ module Decidim # This holds the decidim-budgets version. module Budgets def self.version - "0.29.4" + "0.29.6" end end end diff --git a/decidim-budgets/spec/system/preview_budgets_with_share_token_spec.rb b/decidim-budgets/spec/system/preview_budgets_with_share_token_spec.rb index e76e3bdd615b5..dab5e601e5297 100644 --- a/decidim-budgets/spec/system/preview_budgets_with_share_token_spec.rb +++ b/decidim-budgets/spec/system/preview_budgets_with_share_token_spec.rb @@ -2,9 +2,9 @@ require "spec_helper" -describe "Preview budgets with share token" do +describe "preview budgets with a share token" do let(:manifest_name) { "budgets" } include_context "with a component" - it_behaves_like "preview component with share_token" + it_behaves_like "preview component with a share_token" end diff --git a/decidim-comments/config/locales/de.yml b/decidim-comments/config/locales/de.yml index b6f7a51e8951c..a433d80d16178 100644 --- a/decidim-comments/config/locales/de.yml +++ b/decidim-comments/config/locales/de.yml @@ -65,7 +65,7 @@ de: comment: alignment: against: Gegen - in_favor: Zugunsten + in_favor: Dafür cancel_reply: Antwort abbrechen comment_label: Kommentar %{comment_id} comment_label_reply: Kommentar %{comment_id} (Antwort auf Kommentar %{parent_comment_id}) @@ -115,6 +115,9 @@ de: one: "%{count} Kommentar" other: "%{count} Kommentare" down_vote_button: + label: + one: Button «Nicht unterstützen». %{count} unterstützt nicht + other: Button «Nicht unterstützen». %{count} unterstützen nicht text: Ich bin mit diesem Kommentar nicht einverstanden edit_comment_modal_form: close: Schliessen @@ -125,6 +128,9 @@ de: submit: Senden title: Kommentar bearbeiten up_vote_button: + label: + one: Button «Unterstützen». %{count} Unterstützung + other: Button «Unterstützen». %{count} Unterstützungen text: Ich stimme diesem Kommentar zu events: comments: diff --git a/decidim-comments/lib/decidim/comments/version.rb b/decidim-comments/lib/decidim/comments/version.rb index dccf62142255d..9ffbc6aeead71 100644 --- a/decidim-comments/lib/decidim/comments/version.rb +++ b/decidim-comments/lib/decidim/comments/version.rb @@ -4,7 +4,7 @@ module Decidim # This holds the decidim-comments version. module Comments def self.version - "0.29.4" + "0.29.6" end end end diff --git a/decidim-conferences/app/controllers/decidim/conferences/admin/component_share_tokens_controller.rb b/decidim-conferences/app/controllers/decidim/conferences/admin/component_share_tokens_controller.rb new file mode 100644 index 0000000000000..af15a8a3ad9ca --- /dev/null +++ b/decidim-conferences/app/controllers/decidim/conferences/admin/component_share_tokens_controller.rb @@ -0,0 +1,18 @@ +# frozen_string_literal: true + +module Decidim + module Conferences + module Admin + # This controller allows sharing unpublished things. + # It is targeted for customizations for sharing unpublished things that lives under + # an conference. + class ComponentShareTokensController < Decidim::Admin::ShareTokensController + include Concerns::ConferenceAdmin + + def resource + @resource ||= current_participatory_space.components.find(params[:component_id]) + end + end + end + end +end diff --git a/decidim-conferences/app/controllers/decidim/conferences/admin/conference_share_tokens_controller.rb b/decidim-conferences/app/controllers/decidim/conferences/admin/conference_share_tokens_controller.rb new file mode 100644 index 0000000000000..f57398263240c --- /dev/null +++ b/decidim-conferences/app/controllers/decidim/conferences/admin/conference_share_tokens_controller.rb @@ -0,0 +1,18 @@ +# frozen_string_literal: true + +module Decidim + module Conferences + module Admin + # This controller allows sharing unpublished things. + # It is targeted for customizations for sharing unpublished things that lives under + # an conference. + class ConferenceShareTokensController < Decidim::Admin::ShareTokensController + include Concerns::ConferenceAdmin + + def resource + current_conference + end + end + end + end +end diff --git a/decidim-conferences/app/models/decidim/conference.rb b/decidim-conferences/app/models/decidim/conference.rb index 936ceefa7262a..e262b8b406015 100644 --- a/decidim-conferences/app/models/decidim/conference.rb +++ b/decidim-conferences/app/models/decidim/conference.rb @@ -20,6 +20,7 @@ class Conference < ApplicationRecord include Decidim::HasUploadValidations include Decidim::TranslatableResource include Decidim::FilterableResource + include Decidim::ShareableWithToken translatable_fields :title, :slogan, :short_description, :description, :objectives, :registration_terms @@ -146,6 +147,10 @@ def attachment_context :admin end + def shareable_url(share_token) + EngineRouter.main_proxy(self).conference_url(self, share_token: share_token.token) + end + # Allow ransacker to search for a key in a hstore column (`title`.`en`) ransacker_i18n :title end diff --git a/decidim-conferences/app/permissions/decidim/conferences/permissions.rb b/decidim-conferences/app/permissions/decidim/conferences/permissions.rb index f3c29b02d3852..bb6e4e8237e56 100644 --- a/decidim-conferences/app/permissions/decidim/conferences/permissions.rb +++ b/decidim-conferences/app/permissions/decidim/conferences/permissions.rb @@ -128,6 +128,7 @@ def public_read_conference_action? return allow! if user&.admin? return allow! if conference.published? + return allow! if user_can_preview_space? toggle_allow(can_manage_conference?) end @@ -277,7 +278,8 @@ def conference_admin_action? :partner, :media_link, :registration_type, - :conference_invite + :conference_invite, + :share_tokens ].include?(permission_action.subject) allow! if is_allowed end @@ -300,11 +302,18 @@ def org_admin_action? :partner, :registration_type, :read_conference_registrations, - :export_conference_registrations + :export_conference_registrations, + :share_tokens ].include?(permission_action.subject) allow! if is_allowed end + def user_can_preview_space? + context[:share_token].present? && Decidim::ShareToken.use!(token_for: conference, token: context[:share_token], user:) + rescue ActiveRecord::RecordNotFound, StandardError + nil + end + # Checks if the permission_action is to read the admin conferences list or # not. def read_conference_list_permission_action? diff --git a/decidim-conferences/app/views/decidim/conferences/admin/conferences/index.html.erb b/decidim-conferences/app/views/decidim/conferences/admin/conferences/index.html.erb index 66a678c1ddb13..992f1ef070927 100644 --- a/decidim-conferences/app/views/decidim/conferences/admin/conferences/index.html.erb +++ b/decidim-conferences/app/views/decidim/conferences/admin/conferences/index.html.erb @@ -38,6 +38,11 @@ <% end %> + <% if allowed_to? :read, :share_tokens, current_participatory_space: conference %> + <%= icon_link_to "share-line", decidim_admin_conferences.conference_share_tokens_path(conference), t("actions.share_tokens", scope: "decidim.admin"), class: "action-icon--new" %> + <% else %> + + <% end %> <% if allowed_to? :update, :conference, conference: conference %> <%= icon_link_to "pencil-line", edit_conference_path(conference), t("actions.configure", scope: "decidim.admin"), class: "action-icon--new" %> <% end %> diff --git a/decidim-conferences/config/locales/ar.yml b/decidim-conferences/config/locales/ar.yml index 12ed33c5110da..dbc7ae0b98a61 100644 --- a/decidim-conferences/config/locales/ar.yml +++ b/decidim-conferences/config/locales/ar.yml @@ -98,8 +98,6 @@ ar: conference_copies: new: copy: نسخ - select: حدد البيانات التي ترغب في تكرارها - title: مؤتمر مكرر conference_publications: create: error: كانت هناك مشكلة في نشر هذا المؤتمر. @@ -157,10 +155,6 @@ ar: update: error: حدثت مشكلة أثناء تحديث هذا المؤتمر. success: تم تحديث المؤتمر بنجاح. - conferences_copies: - create: - error: كانت هناك مشكلة في تكرار هذا المؤتمر. - success: تم تكرار المؤتمر بنجاح. media_links: create: error: حدثت مشكلة أثناء إنشاء رابط وسائط جديد. diff --git a/decidim-conferences/config/locales/bg.yml b/decidim-conferences/config/locales/bg.yml index 15baa1d9ca5dc..72437280fa1c2 100644 --- a/decidim-conferences/config/locales/bg.yml +++ b/decidim-conferences/config/locales/bg.yml @@ -100,8 +100,6 @@ bg: conference_copies: new: copy: Копиране - select: Изберете кои данни искате да дублирате - title: Дублиране на конференцията conference_publications: create: error: Възникна проблем при публикуването на тази конференция. @@ -168,10 +166,6 @@ bg: update: error: Възникна проблем при актуализирането на тази конференция. success: Конференцията беше актуализирана успешно. - conferences_copies: - create: - error: Възникна проблем при дублирането на тази конференция. - success: Конференцията беше дублирана успешно. media_links: create: error: Възникна проблем при създаването на нов медия линк. diff --git a/decidim-conferences/config/locales/ca-IT.yml b/decidim-conferences/config/locales/ca-IT.yml index b64699a475e37..987116b4bf331 100644 --- a/decidim-conferences/config/locales/ca-IT.yml +++ b/decidim-conferences/config/locales/ca-IT.yml @@ -103,7 +103,7 @@ ca-IT: new: copy: Copiar select: Selecciona quines dades vols duplicar - title: Jornada duplicada + title: Duplicar la jornada conference_publications: create: error: S'ha produït un error en publicar aquesta jornada. diff --git a/decidim-conferences/config/locales/ca.yml b/decidim-conferences/config/locales/ca.yml index cc9862843d9aa..81affcbe75653 100644 --- a/decidim-conferences/config/locales/ca.yml +++ b/decidim-conferences/config/locales/ca.yml @@ -103,7 +103,7 @@ ca: new: copy: Copiar select: Selecciona quines dades vols duplicar - title: Jornada duplicada + title: Duplicar la jornada conference_publications: create: error: S'ha produït un error en publicar aquesta jornada. diff --git a/decidim-conferences/config/locales/de.yml b/decidim-conferences/config/locales/de.yml index f7dfdfd3f902d..4f66f989417f2 100644 --- a/decidim-conferences/config/locales/de.yml +++ b/decidim-conferences/config/locales/de.yml @@ -21,7 +21,7 @@ de: promoted: Gefördert published_at: Veröffentlicht am registration_terms: Registrierungsbedingungen - registrations_enabled: Registrierungen aktiviert + registrations_enabled: Anmeldungen aktiviert scope_id: Umfang scopes_enabled: Bereiche aktiviert short_description: Kurze Beschreibung @@ -102,8 +102,8 @@ de: conference_copies: new: copy: Kopieren - select: Wählen Sie die Daten aus, die Sie duplizieren möchten - title: Doppelte Konferenz + select: Zu duplizierende Daten auswählen + title: Konferenz duplizieren conference_publications: create: error: Beim Veröffentlichen dieser Konferenz ist ein Fehler aufgetreten. @@ -344,7 +344,7 @@ de: admin: conference_copies: form: - slug_help_html: 'URL-Slugs werden zum Generieren der URLs verwendet, die auf diese Konferenz verweisen. Akzeptiert werden nur Buchstaben, Zahlen und Bindestriche und es muss mit einem Buchstaben beginnen. Beispiel: %{url}' + slug_help_html: 'URL-Slugs werden verwendet, um URLs zu generieren, die auf diese Konferenz verweisen. Akzeptiert nur Buchstaben, Zahlen und Bindestriche und muss mit einem Buchstaben beginnen. Beispiel: %{url}' conference_invites: create: error: Beim Einladen des Benutzers zur Teilnahme an der Konferenz ist ein Problem aufgetreten. @@ -403,7 +403,7 @@ de: title: Registrierungsarten send_conference_diploma_mailer: diploma: - diploma_html: Die Teilnahmebescheinigung für die Konferenz %{title} finden Sie in den Anhängen. + diploma_html: Die Teilnahmebestätigung für die Konferenz %{title} finden Sie in den Anhängen. diploma_user: attendance_verified_by: Anwesenheit überprüft durch certificate_of_attendance: Teilnahmebestätigung @@ -545,10 +545,10 @@ de: email_subject: Die Konferenz "%{resource_title}" wurde aktualisiert notification_title: Die Konferenz %{resource_title} wurde aktualisiert. registrations_enabled: - email_intro: 'Die Konferenz "%{resource_title}" hat Registrierungen aktiviert. Sie können sich auf der Konferenz-Seite registrieren:' - email_outro: Sie haben diese Benachrichtigung erhalten, weil Sie der Konferenz "%{resource_title}" folgen. Falls Sie keine solchen Benachrichtigungen mehr erhalten möchten, besuchen Sie den obigen Link. - email_subject: Die Konferenz "%{resource_title}" hat Registrierungen aktiviert. - notification_title: Die Konferenz %{resource_title} hat Registrierungen aktiviert. + email_intro: 'Für die Konferenz "%{resource_title}" wurde die Anmeldung aktiviert. Sie können sich auf dieser Seite anmelden:' + email_outro: Sie haben diese Benachrichtigung erhalten, weil Sie der Konferenz "%{resource_title}" folgen. Falls Sie keine solchen Benachrichtigungen mehr erhalten möchten, besuchen Sie den angegebenen Link. + email_subject: Die Konferenz "%{resource_title}" hat die Anmeldung aktiviert. + notification_title: Die Konferenz %{resource_title} hat die Anmeldung aktiviert. role_assigned: email_intro: Sie wurden als %{role} für die Konferenz "%{resource_title}" ausgewählt. email_outro: Sie haben diese Benachrichtigung erhalten, weil Sie ein %{role} der Konferenz "%{resource_title}" sind. diff --git a/decidim-conferences/config/locales/el.yml b/decidim-conferences/config/locales/el.yml index 0f30fc4f28aea..b586793ec130e 100644 --- a/decidim-conferences/config/locales/el.yml +++ b/decidim-conferences/config/locales/el.yml @@ -93,8 +93,6 @@ el: conference_copies: new: copy: Αντιγραφή - select: Επιλέξτε ποια δεδομένα θέλετε να αντιγράψετε - title: Αντιγραφή διάσκεψης conference_publications: create: error: Υπήρξε ένα πρόβλημα κατά τη δημοσίευση αυτής της διάσκεψης. @@ -154,10 +152,6 @@ el: update: error: Υπήρξε ένα πρόβλημα κατά την ενημέρωση αυτής της διάσκεψης. success: Η διάσκεψη ενημερώθηκε με επιτυχία. - conferences_copies: - create: - error: Υπήρξε ένα πρόβλημα κατά την αντιγραφή αυτής της διάσκεψης. - success: Η διάσκεψη αντιγράφτηκε με επιτυχία. media_links: create: error: Υπήρξε ένα πρόβλημα κατά τη δημιουργία ενός νέου συνδέσμου πολυμέσων. diff --git a/decidim-conferences/config/locales/es-MX.yml b/decidim-conferences/config/locales/es-MX.yml index 2a40015d103b8..a0c84bb533c0a 100644 --- a/decidim-conferences/config/locales/es-MX.yml +++ b/decidim-conferences/config/locales/es-MX.yml @@ -103,7 +103,7 @@ es-MX: new: copy: Copiar select: Selecciona qué datos quieres duplicar - title: Conferencia duplicada + title: Duplicar la jornada conference_publications: create: error: Hubo un error al publicar esta conferencia. @@ -176,8 +176,8 @@ es-MX: success: Conferencia actualizada con éxito. conferences_copies: create: - error: Hubo un error al duplicar esta conferencia. - success: Conferencia duplicada con éxito. + error: Se ha producido un error al duplicar esta jornada. + success: La jornada se ha duplicado correctamente. media_links: create: error: Se ha producido un error al crear un nuevo enlace multimedia. diff --git a/decidim-conferences/config/locales/es-PY.yml b/decidim-conferences/config/locales/es-PY.yml index a9206dcc3fe5b..636b75cb1ea6b 100644 --- a/decidim-conferences/config/locales/es-PY.yml +++ b/decidim-conferences/config/locales/es-PY.yml @@ -102,8 +102,8 @@ es-PY: conference_copies: new: copy: Dupdo - select: Seleccione qué datos quiere duplicar - title: Conferencia duplicada + select: Selecciona qué datos quieres duplicar + title: Duplicar la jornada conference_publications: create: error: Hubo un error al publicar esta conferencia. @@ -176,8 +176,8 @@ es-PY: success: Conferencia actualizada con éxito conferences_copies: create: - error: Hubo un error al duplicar esta conferencia. - success: Conferencia duplicada con éxito. + error: Se ha producido un error al duplicar esta jornada. + success: La jornada se ha duplicado correctamente. media_links: create: error: Se ha producido un error al crear un nuevo enlace de medios. diff --git a/decidim-conferences/config/locales/es.yml b/decidim-conferences/config/locales/es.yml index ff675862f0f1f..77bf58edf09e5 100644 --- a/decidim-conferences/config/locales/es.yml +++ b/decidim-conferences/config/locales/es.yml @@ -103,7 +103,7 @@ es: new: copy: Copiar select: Selecciona qué datos quieres duplicar - title: Jornada duplicada + title: Duplicar la jornada conference_publications: create: error: Se ha producido un error al publicar esta jornada. @@ -177,7 +177,7 @@ es: conferences_copies: create: error: Se ha producido un error al duplicar esta jornada. - success: Jornada duplicada correctamente. + success: La jornada se ha duplicado correctamente. media_links: create: error: Se ha producido un error al crear un nuevo enlace multimedia. diff --git a/decidim-conferences/config/locales/eu.yml b/decidim-conferences/config/locales/eu.yml index 23615dfa60147..7ee9b4512fd46 100644 --- a/decidim-conferences/config/locales/eu.yml +++ b/decidim-conferences/config/locales/eu.yml @@ -103,7 +103,7 @@ eu: new: copy: Kopiatu select: Hautatu zein datu bikoiztu nahi dituzun - title: Bikoiztu jardunaldia + title: Jardunaldia bikoiztu conference_publications: create: error: Arazo bat egon da jardunaldi hau argitaratzean. @@ -177,7 +177,7 @@ eu: conferences_copies: create: error: Arazo bat egon da jardunaldi hau bikoiztean. - success: Jardunaldia zuzen eguneratua. + success: Jardunaldia zuzen bikoiztua. media_links: create: error: Arazo bat egon da beste komunikazio-esteka bat sortzean. @@ -429,7 +429,7 @@ eu: details_2: Jardunaldiaren xehetasunak eranskinean aurkituko dituzu. pending_validation: confirmation_pending: Berrespena jasoko duzu laster - details: 'To You erregistratu %{registration_type} motako kostua batekin %{price} eta ondorengo gertaerak joateko daiteke:' + details: '%{registration_type} motako %{price} tasan erregistratu zara, eta gertaera hauei erantzun diezaiekezu:' pending_html: %{title} jardunaldirako zure izen-ematea zain dago berresteko. conference_registrations: create: @@ -493,7 +493,7 @@ eu: models: conference_invite: fields: - email: Helbide elektronkoa + email: Helbide elektronikoa name: izena registration_type: Izen-emate mota sent_at: Bidalita diff --git a/decidim-conferences/config/locales/fi-plain.yml b/decidim-conferences/config/locales/fi-plain.yml index bbe9bbf4bfb7d..b5c5563684834 100644 --- a/decidim-conferences/config/locales/fi-plain.yml +++ b/decidim-conferences/config/locales/fi-plain.yml @@ -176,8 +176,8 @@ fi-pl: success: Konferenssi päivitetty onnistuneesti. conferences_copies: create: - error: Virhe kopioitaessa konferenssia. - success: Konferenssi kopioitu onnistuneesti. + error: Konferenssin kopioiminen epäonnistui. + success: Konferenssin kopioiminen onnistui. media_links: create: error: Luotaessa uutta medialinkkiä tapahtui virhe. diff --git a/decidim-conferences/config/locales/fi.yml b/decidim-conferences/config/locales/fi.yml index d5dc40a5f865f..4a49e36243ee0 100644 --- a/decidim-conferences/config/locales/fi.yml +++ b/decidim-conferences/config/locales/fi.yml @@ -176,8 +176,8 @@ fi: success: Konferenssin päivitys onnistui. conferences_copies: create: - error: Konferenssin kopiointi epäonnistui. - success: Konferenssin kopiointi onnistui. + error: Konferenssin kopioiminen epäonnistui. + success: Konferenssin kopioiminen onnistui. media_links: create: error: Uuden medialinkin luonti epäonnistui. diff --git a/decidim-conferences/config/locales/fr-CA.yml b/decidim-conferences/config/locales/fr-CA.yml index bb46e29cab961..37ed9ef4f94c8 100644 --- a/decidim-conferences/config/locales/fr-CA.yml +++ b/decidim-conferences/config/locales/fr-CA.yml @@ -176,7 +176,7 @@ fr-CA: success: Conférence mise à jour avec succès. conferences_copies: create: - error: Une erreur s'est produite lors de la duplication de cette conférence. + error: Un problème est survenu lors de la duplication de cette conférence. success: Conférence dupliquée avec succès. media_links: create: diff --git a/decidim-conferences/config/locales/fr.yml b/decidim-conferences/config/locales/fr.yml index 424582b5da7bf..ee27f42c615c4 100644 --- a/decidim-conferences/config/locales/fr.yml +++ b/decidim-conferences/config/locales/fr.yml @@ -176,7 +176,7 @@ fr: success: Conférence mise à jour avec succès. conferences_copies: create: - error: Une erreur s'est produite lors de la duplication de cette conférence. + error: Un problème est survenu lors de la duplication de cette conférence. success: Conférence dupliquée avec succès. media_links: create: diff --git a/decidim-conferences/config/locales/gl.yml b/decidim-conferences/config/locales/gl.yml index 9880f3fe1aaac..ddaf656198515 100644 --- a/decidim-conferences/config/locales/gl.yml +++ b/decidim-conferences/config/locales/gl.yml @@ -80,8 +80,6 @@ gl: conference_copies: new: copy: Copiar - select: Seleccione os datos que desexa duplicar - title: Conferencia duplicada conference_publications: create: error: Produciuse un erro ao publicar esta conferencia. @@ -139,10 +137,6 @@ gl: update: error: Houbo un erro ao actualizar esta conferencia. success: A conferencia actualizouse con éxito. - conferences_copies: - create: - error: Produciuse un erro ao duplicar esta conferencia. - success: A conferencia duplicouse con éxito. media_links: create: error: Produciuse un erro ao crear unha nova ligazón multimedia. diff --git a/decidim-conferences/config/locales/hu.yml b/decidim-conferences/config/locales/hu.yml index 2b9b5130e6d5b..a2dac2f588fc9 100644 --- a/decidim-conferences/config/locales/hu.yml +++ b/decidim-conferences/config/locales/hu.yml @@ -99,8 +99,6 @@ hu: conference_copies: new: copy: Másolat - select: Válassza ki, mely adatokat szeretné megismételni - title: Duplikált konferencia conference_publications: create: error: Hiba történt a konferencia közzétételében. @@ -161,10 +159,6 @@ hu: update: error: Hiba történt a konferencia frissítésekor. success: A konferencia sikeresen frissült. - conferences_copies: - create: - error: Hiba történt a konferencia másolása során. - success: A konferencia sikeresen megismétlődött. media_links: create: error: Hiba történt új média link létrehozása közben. diff --git a/decidim-conferences/config/locales/id-ID.yml b/decidim-conferences/config/locales/id-ID.yml index 9f3584e78627e..8231a40fcb777 100644 --- a/decidim-conferences/config/locales/id-ID.yml +++ b/decidim-conferences/config/locales/id-ID.yml @@ -44,8 +44,6 @@ id: conference_copies: new: copy: Salinan - select: Pilih data mana yang ingin Anda gandakan - title: Konferensi duplikat conference_publications: create: error: Terjadi kesalahan saat mempublikasikan konferensi ini. @@ -103,10 +101,6 @@ id: update: error: Ada kesalahan saat memperbarui konferensi ini. success: Konferensi berhasil diperbarui. - conferences_copies: - create: - error: Ada kesalahan saat menduplikasi konferensi ini. - success: Konferensi berhasil digandakan. media_links: create: error: Terjadi kesalahan saat membuat tautan media baru. diff --git a/decidim-conferences/config/locales/it.yml b/decidim-conferences/config/locales/it.yml index ab13403cf2f92..61b6fc8cc589f 100644 --- a/decidim-conferences/config/locales/it.yml +++ b/decidim-conferences/config/locales/it.yml @@ -80,8 +80,6 @@ it: conference_copies: new: copy: Copia - select: Seleziona i dati che desideri duplicare - title: Duplica Conferenza conference_publications: create: error: Si è verificato un errore durante la pubblicazione di questa conferenza. @@ -140,10 +138,6 @@ it: update: error: Si è verificato un errore durante l'aggiornamento di questa conferenza. success: Conferenza aggiornata con successo. - conferences_copies: - create: - error: Si è verificato un errore durante la duplicazione di questa conferenza. - success: Conferenza duplicata con successo. media_links: create: error: Si è verificato un errore durante la creazione di un nuovo collegamento multimediale. diff --git a/decidim-conferences/config/locales/ja.yml b/decidim-conferences/config/locales/ja.yml index ec9c8ab318752..bb7d39ca5a305 100644 --- a/decidim-conferences/config/locales/ja.yml +++ b/decidim-conferences/config/locales/ja.yml @@ -99,7 +99,7 @@ ja: conference_copies: new: copy: コピー - select: 複製したいデータを選択してください + select: title: カンファレンスを複製 conference_publications: create: diff --git a/decidim-conferences/config/locales/lb.yml b/decidim-conferences/config/locales/lb.yml index 9d33212764581..1d87906082c43 100644 --- a/decidim-conferences/config/locales/lb.yml +++ b/decidim-conferences/config/locales/lb.yml @@ -77,10 +77,6 @@ lb: update: error: Beim Aktualisieren dieser Konferenz ist ein Fehler aufgetreten. success: Konferenz wurde erfolgreich aktualisiert. - conferences_copies: - create: - error: Beim Duplizieren dieser Konferenz ist ein Fehler aufgetreten. - success: Konferenz wurde erfolgreich dupliziert. media_links: create: error: Beim Erstellen einer neuen Medienverknüpfung ist ein Fehler aufgetreten. diff --git a/decidim-conferences/config/locales/lt.yml b/decidim-conferences/config/locales/lt.yml index ccf36ec3bc386..f2349c6631db4 100644 --- a/decidim-conferences/config/locales/lt.yml +++ b/decidim-conferences/config/locales/lt.yml @@ -99,8 +99,6 @@ lt: conference_copies: new: copy: Kopijuoti - select: Pasirinkite, kuriuos duomenis norėtumėte dubliuoti - title: Dubliuoti konferenciją conference_publications: create: error: Publikuojant šią konferenciją iškilo problema. @@ -160,10 +158,6 @@ lt: update: error: Atnaujinant šią konferenciją iškilo problema. success: Konferencija atnaujinta. - conferences_copies: - create: - error: Dubliuojant šią konferenciją iškilo problema. - success: Konferencija dubliuota. media_links: create: error: Kuriant naują multimedijos nuorodą iškilo problema. diff --git a/decidim-conferences/config/locales/lv.yml b/decidim-conferences/config/locales/lv.yml index 2df097c1406cb..a976342ea5e3c 100644 --- a/decidim-conferences/config/locales/lv.yml +++ b/decidim-conferences/config/locales/lv.yml @@ -50,8 +50,6 @@ lv: conference_copies: new: copy: Kopēt - select: Atlasiet, kurus datus vēlaties dublēt - title: Dublēt konferenci conference_publications: create: error: Konferences publicēšanas laikā radās problēma. @@ -109,10 +107,6 @@ lv: update: error: Šīs konferences atjaunināšanas laikā radās problēma. success: Konference ir veiksmīgi atjaunināta. - conferences_copies: - create: - error: Radās problēma ar šīs konferences dublēšanu. - success: Konference ir veiksmīgi dublēta. media_links: create: error: Jaunas mediju saites izveides laikā radās problēma. diff --git a/decidim-conferences/config/locales/nl.yml b/decidim-conferences/config/locales/nl.yml index a53eccb1a19f8..81c75d92fd060 100644 --- a/decidim-conferences/config/locales/nl.yml +++ b/decidim-conferences/config/locales/nl.yml @@ -80,8 +80,6 @@ nl: conference_copies: new: copy: Kopiëren - select: Selecteer welke gegevens u wilt dupliceren - title: Dubbele conferentie conference_publications: create: error: Er is een fout opgetreden bij het publiceren van deze conferentie. @@ -139,10 +137,6 @@ nl: update: error: Er is een probleem opgetreden bij het bijwerken van deze conferentie. success: Conferentie succesvol bijgewerkt. - conferences_copies: - create: - error: Er was een probleem bij het dupliceren van deze conferentie. - success: Conferentie succesvol gedupliceerd. media_links: create: error: Er is een probleem opgetreden bij het maken van een nieuwe mediakoppeling. diff --git a/decidim-conferences/config/locales/no.yml b/decidim-conferences/config/locales/no.yml index c6e9e70758b87..cfe1f38b646f4 100644 --- a/decidim-conferences/config/locales/no.yml +++ b/decidim-conferences/config/locales/no.yml @@ -80,8 +80,6 @@ conference_copies: new: copy: Kopier - select: Velg hvilke data du vil duplisere - title: Duplisert konferanse conference_publications: create: error: Det oppstod et problem med å publisere denne konferansen. @@ -139,10 +137,6 @@ update: error: Det oppstod et problem med å oppdatere denne konferansen. success: Konferansen ble oppdatert. - conferences_copies: - create: - error: Det oppstod et problem med å duplisere denne konferansen. - success: Konferansen ble duplisert. media_links: create: error: Det oppstod et problem med å opprette en ny media lenke. diff --git a/decidim-conferences/config/locales/pl.yml b/decidim-conferences/config/locales/pl.yml index bd338afa0617c..29d91594f7f39 100644 --- a/decidim-conferences/config/locales/pl.yml +++ b/decidim-conferences/config/locales/pl.yml @@ -106,8 +106,6 @@ pl: conference_copies: new: copy: Kopiuj - select: Wybierz dane, które chcesz zduplikować - title: Zduplikuj konferencję conference_publications: create: error: Wystąpił błąd podczas publikowania tej konferencji. @@ -174,10 +172,6 @@ pl: update: error: Wystąpił błąd podczas aktualizowania konferencji. success: Konferencja została zaktualizowana pomyślnie. - conferences_copies: - create: - error: Wystąpił błąd podczas duplikowania konferencji. - success: Konferencja zduplikowana pomyślnie. media_links: create: error: Podczas tworzenia nowego linku do multimediów wystąpił błąd. diff --git a/decidim-conferences/config/locales/pt-BR.yml b/decidim-conferences/config/locales/pt-BR.yml index a5f29eb142912..0ca8edfa71ec2 100644 --- a/decidim-conferences/config/locales/pt-BR.yml +++ b/decidim-conferences/config/locales/pt-BR.yml @@ -99,8 +99,6 @@ pt-BR: conference_copies: new: copy: cópia de - select: Selecione quais dados você gostaria de duplicar - title: Conferência duplicada conference_publications: create: error: Ocorreu um erro ao publicar esta conferência. @@ -167,10 +165,6 @@ pt-BR: update: error: Houve um erro ao atualizar esta conferência. success: Conferência atualizada com sucesso. - conferences_copies: - create: - error: Houve um erro ao duplicar esta conferência. - success: Conferência duplicada com sucesso. media_links: create: error: Ocorreu um erro ao criar um novo link de mídia. @@ -321,7 +315,7 @@ pt-BR: admin: conference_copies: form: - slug_help_html: 'Os slugs de URL são usados ​​para gerar as URLs que apontam para esta conferência. Aceita apenas letras, números e traços e deve começar com uma letra. Exemplo: %{url}' + slug_help_html: 'Os slugs de URL são usados para gerar as URLs que apontam para esta conferência. Aceita apenas letras, números e traços e deve começar com uma letra. Exemplo: %{url}' conference_invites: create: error: Houve um problema ao convidar o usuário para participar da conferência. diff --git a/decidim-conferences/config/locales/pt.yml b/decidim-conferences/config/locales/pt.yml index d275d983265b8..08579b96ace9a 100644 --- a/decidim-conferences/config/locales/pt.yml +++ b/decidim-conferences/config/locales/pt.yml @@ -80,8 +80,6 @@ pt: conference_copies: new: copy: Copiar - select: Selecione os dados que pretende duplicar - title: Conferência duplicada conference_publications: create: error: Ocorreu um problema ao publicar esta conferência. @@ -139,10 +137,6 @@ pt: update: error: Ocorreu um problema ao atualizar esta conferência. success: Conferência atualizada corretamente. - conferences_copies: - create: - error: Ocorreu um problema ao duplicar esta conferência. - success: Conferência duplicada com sucesso. media_links: create: error: Ocorreu um problema ao criar uma nova hiperligação de multimédia. diff --git a/decidim-conferences/config/locales/ro-RO.yml b/decidim-conferences/config/locales/ro-RO.yml index 872cc47a36c57..0277993ea443a 100644 --- a/decidim-conferences/config/locales/ro-RO.yml +++ b/decidim-conferences/config/locales/ro-RO.yml @@ -98,8 +98,6 @@ ro: conference_copies: new: copy: Copiază - select: Selectați datele pe care doriți să le duplicați - title: Duplică conferinţa conference_publications: create: error: A apărut o problemă la publicarea acestei conferinţe. @@ -163,10 +161,6 @@ ro: update: error: A apărut o eroare la actualizarea conferinței. success: Conferință actualizată cu succes. - conferences_copies: - create: - error: A apărut o problemă la duplicarea acestei conferinţe. - success: Conferință duplicată cu succes. media_links: create: error: A apărut o problemă la crearea unei noi legături media. diff --git a/decidim-conferences/config/locales/sk.yml b/decidim-conferences/config/locales/sk.yml index 631e000d0f195..2c5e0ae42d6e3 100644 --- a/decidim-conferences/config/locales/sk.yml +++ b/decidim-conferences/config/locales/sk.yml @@ -53,8 +53,6 @@ sk: conference_copies: new: copy: Kopírovať - select: Označte údaje, ktoré by ste chceli duplikovať - title: Duplikovať konferenciu conference_publications: create: error: Vyskytol sa problém s publikovaním konferencie. @@ -112,10 +110,6 @@ sk: update: error: Vyskytol sa problém s aktualizáciou tejto konferencie. success: Konferencia úspešne aktualizovaná. - conferences_copies: - create: - error: Vyskytol sa problém s duplikáciou tejto konferencie. - success: Konferencia úspešne duplikovaná. media_links: create: error: Pri tvorbe mediálneho odkazu nastala chyba. diff --git a/decidim-conferences/config/locales/sv.yml b/decidim-conferences/config/locales/sv.yml index 4185b085246ae..b2dd17c1d53ed 100644 --- a/decidim-conferences/config/locales/sv.yml +++ b/decidim-conferences/config/locales/sv.yml @@ -102,8 +102,6 @@ sv: conference_copies: new: copy: Kopiera - select: Välj vilka data som du vill duplicera - title: Duplicera konferens conference_publications: create: error: Det gick inte att publicera konferensen. @@ -174,10 +172,6 @@ sv: update: error: Det gick inte att uppdatera konferensen. success: Konferensen har uppdaterats. - conferences_copies: - create: - error: Det gick inte att duplicera konferensen. - success: Konferensen har duplicerats. media_links: create: error: Det gick inte att skapa en ny medialänk. diff --git a/decidim-conferences/config/locales/tr-TR.yml b/decidim-conferences/config/locales/tr-TR.yml index d2d3d878b4223..f856afc592c10 100644 --- a/decidim-conferences/config/locales/tr-TR.yml +++ b/decidim-conferences/config/locales/tr-TR.yml @@ -53,8 +53,6 @@ tr: conference_copies: new: copy: Kopyala - select: Çoğaltmak istediğiniz verileri seçin - title: Konferansı çoğalt conference_publications: create: error: Bu konferansı yayınlarken bir sorun oluştu. @@ -112,10 +110,6 @@ tr: update: error: Bu konferans güncellenirken bir hata oluştu. success: Konferans başarıyla güncellendi. - conferences_copies: - create: - error: Bu konferansı çoğaltırken bir hata oluştu. - success: Konferans başarıyla kopyalandı. media_links: create: error: Yeni bir medya bağlantısı oluştururken bir hata oluştu. diff --git a/decidim-conferences/config/locales/zh-CN.yml b/decidim-conferences/config/locales/zh-CN.yml index d0ff1297f5dbf..d5997deda0ebf 100644 --- a/decidim-conferences/config/locales/zh-CN.yml +++ b/decidim-conferences/config/locales/zh-CN.yml @@ -44,8 +44,6 @@ zh-CN: conference_copies: new: copy: 复制 - select: 选择要重复的数据 - title: 复制会议 conference_publications: create: error: 发布此会议时出现问题。 @@ -103,10 +101,6 @@ zh-CN: update: error: 更新此会议时出现问题。 success: 会议已成功更新。 - conferences_copies: - create: - error: 复制此会议时出现问题。 - success: 会议成功重复。 media_links: create: error: 创建新媒体链接时出现问题。 diff --git a/decidim-conferences/config/locales/zh-TW.yml b/decidim-conferences/config/locales/zh-TW.yml index 147b5784554da..506fab10c03d6 100644 --- a/decidim-conferences/config/locales/zh-TW.yml +++ b/decidim-conferences/config/locales/zh-TW.yml @@ -90,8 +90,6 @@ zh-TW: conference_copies: new: copy: 複製 - select: 請選擇您想要複製的資料 - title: 複製研討會 conference_publications: create: error: 發布此研討會時出現問題。 @@ -151,10 +149,6 @@ zh-TW: update: error: 更新此研討會時發生問題。 success: 研討會更新成功。 - conferences_copies: - create: - error: 複製此研討會時發生問題。 - success: 研討會複製成功。 media_links: create: error: 創建新的媒體連結時出現問題。 diff --git a/decidim-conferences/lib/decidim/conferences/admin_engine.rb b/decidim-conferences/lib/decidim/conferences/admin_engine.rb index 7e3ffb0a2832e..a6ab648ff7111 100644 --- a/decidim-conferences/lib/decidim/conferences/admin_engine.rb +++ b/decidim-conferences/lib/decidim/conferences/admin_engine.rb @@ -66,6 +66,7 @@ class AdminEngine < ::Rails::Engine put :unpublish get :share end + resources :component_share_tokens, except: [:show], path: "share_tokens", as: "share_tokens" resources :exports, only: :create resources :imports, only: [:new, :create] do get :example, on: :collection @@ -81,6 +82,8 @@ class AdminEngine < ::Rails::Engine end resources :reports, controller: "moderations/reports", only: [:index, :show] end + + resources :conference_share_tokens, except: [:show], path: "share_tokens" end scope "/conferences/:conference_slug/components/:component_id/manage" do diff --git a/decidim-conferences/lib/decidim/conferences/menu.rb b/decidim-conferences/lib/decidim/conferences/menu.rb index a99250eda1b05..4fe7756cf0a4d 100644 --- a/decidim-conferences/lib/decidim/conferences/menu.rb +++ b/decidim-conferences/lib/decidim/conferences/menu.rb @@ -48,6 +48,7 @@ def self.register_admin_conferences_components_menu! active: is_active_link?(manage_component_path(component)) || is_active_link?(decidim_admin_conferences.edit_component_path(current_participatory_space, component)) || is_active_link?(decidim_admin_conferences.edit_component_permissions_path(current_participatory_space, component)) || + is_active_link?(decidim_admin_conferences.component_share_tokens_path(current_participatory_space, component)) || participatory_space_active_link?(component), if: component.manifest.admin_engine && user_role_config.component_is_accessible?(component.manifest_name) end @@ -172,6 +173,13 @@ def self.register_conferences_admin_menu! decidim_admin_conferences.moderations_path(current_participatory_space), icon_name: "flag-line", if: allowed_to?(:read, :moderation, conference: current_participatory_space) + + menu.add_item :conference_share_tokens, + I18n.t("menu.share_tokens", scope: "decidim.admin"), + decidim_admin_conferences.conference_share_tokens_path(current_participatory_space), + active: is_active_link?(decidim_admin_conferences.conference_share_tokens_path(current_participatory_space)), + icon_name: "share-line", + if: allowed_to?(:read, :share_tokens, current_participatory_space:) end end diff --git a/decidim-conferences/lib/decidim/conferences/version.rb b/decidim-conferences/lib/decidim/conferences/version.rb index a673874dc1e17..3bcabdb5f8d59 100644 --- a/decidim-conferences/lib/decidim/conferences/version.rb +++ b/decidim-conferences/lib/decidim/conferences/version.rb @@ -4,7 +4,7 @@ module Decidim # This holds the decidim-conferences version. module Conferences def self.version - "0.29.4" + "0.29.6" end end end diff --git a/decidim-conferences/spec/shared/manage_conference_components_examples.rb b/decidim-conferences/spec/shared/manage_conference_components_examples.rb index 984657311f43c..873eea4c69fe5 100644 --- a/decidim-conferences/spec/shared/manage_conference_components_examples.rb +++ b/decidim-conferences/spec/shared/manage_conference_components_examples.rb @@ -209,8 +209,6 @@ } )) end - - it_behaves_like "manage component share tokens" end context "when the component is published" do diff --git a/decidim-conferences/spec/system/admin/admin_manages_conference_component_share_tokens_spec.rb b/decidim-conferences/spec/system/admin/admin_manages_conference_component_share_tokens_spec.rb new file mode 100644 index 0000000000000..faa819ab0fd9c --- /dev/null +++ b/decidim-conferences/spec/system/admin/admin_manages_conference_component_share_tokens_spec.rb @@ -0,0 +1,12 @@ +# frozen_string_literal: true + +require "spec_helper" + +describe "Admin manages conference component share tokens" do + include_context "when admin administrating a conference" + + it_behaves_like "manage component share tokens" do + let(:participatory_space) { conference } + let(:participatory_space_engine) { decidim_admin_conferences } + end +end diff --git a/decidim-conferences/spec/system/admin/admin_manages_conference_share_tokens_spec.rb b/decidim-conferences/spec/system/admin/admin_manages_conference_share_tokens_spec.rb new file mode 100644 index 0000000000000..827e50a37b565 --- /dev/null +++ b/decidim-conferences/spec/system/admin/admin_manages_conference_share_tokens_spec.rb @@ -0,0 +1,19 @@ +# frozen_string_literal: true + +require "spec_helper" + +describe "Admin manages conference share tokens" do + include_context "when admin administrating a conference" + let(:participatory_space) { conference } + let(:participatory_space_path) { decidim_admin_conferences.edit_conference_path(conference) } + let(:participatory_spaces_path) { decidim_admin_conferences.conferences_path } + + it_behaves_like "manage participatory space share tokens" + + context "when the user is a conference admin" do + let(:user) { create(:user, :confirmed, :admin_terms_accepted, organization:) } + let!(:role) { create(:conference_user_role, user:, conference:, role: :admin) } + + it_behaves_like "manage participatory space share tokens" + end +end diff --git a/decidim-conferences/spec/system/preview_conference_with_share_token_spec.rb b/decidim-conferences/spec/system/preview_conference_with_share_token_spec.rb new file mode 100644 index 0000000000000..714c761d7f5aa --- /dev/null +++ b/decidim-conferences/spec/system/preview_conference_with_share_token_spec.rb @@ -0,0 +1,11 @@ +# frozen_string_literal: true + +require "spec_helper" + +describe "Preview conference with share token" do + let(:organization) { create(:organization) } + let!(:participatory_space) { create(:conference, organization:, published_at: nil) } + let(:resource_path) { decidim_conferences.conference_path(participatory_space) } + + it_behaves_like "preview participatory space with a share_token" +end diff --git a/decidim-core/app/cells/decidim/activity/show.erb b/decidim-core/app/cells/decidim/activity/show.erb index c54f28f42a809..dea32ff9a758e 100644 --- a/decidim-core/app/cells/decidim/activity/show.erb +++ b/decidim-core/app/cells/decidim/activity/show.erb @@ -1,19 +1,19 @@
-
+

<%= created_at %> -

+

- +
<% if title.present? %> - +

<%= title_icon %> <%= title %> - +

<% end %> <%= html_truncate decidim_sanitize(resource_link_text, strip_tags: true), length: 80 %> -
+
<% unless hide_participatory_space? %> <%= participatory_space_link %> diff --git a/decidim-core/app/cells/decidim/address/show.erb b/decidim-core/app/cells/decidim/address/show.erb index 88addae009898..eac160580f2cf 100644 --- a/decidim-core/app/cells/decidim/address/show.erb +++ b/decidim-core/app/cells/decidim/address/show.erb @@ -24,6 +24,7 @@ <%= start_and_end_time %>
+ <% end %> diff --git a/decidim-core/app/cells/decidim/address_cell.rb b/decidim-core/app/cells/decidim/address_cell.rb index 718f134de1f47..591af10c75228 100644 --- a/decidim-core/app/cells/decidim/address_cell.rb +++ b/decidim-core/app/cells/decidim/address_cell.rb @@ -24,11 +24,17 @@ def location_hints end def location + return pending_location_text if model.respond_to?(:pending_location?) && model.pending_location? + decidim_sanitize_translated(model.location) end def address - decidim_sanitize_translated(model.address) + decidim_sanitize_translated(model.address) if model.respond_to?(:address) && model.address.present? + end + + def pending_location_text + t("show.pending_address", scope: "decidim.meetings.meetings") end def display_start_and_end_time? diff --git a/decidim-core/app/cells/decidim/author/badge.erb b/decidim-core/app/cells/decidim/author/badge.erb new file mode 100644 index 0000000000000..ca63f9f807c37 --- /dev/null +++ b/decidim-core/app/cells/decidim/author/badge.erb @@ -0,0 +1,6 @@ +<% if show_badge? %> + + <%= icon "star-s-fill" %> + <%= officialization_text %> + +<% end %> diff --git a/decidim-core/app/cells/decidim/author/show.erb b/decidim-core/app/cells/decidim/author/show.erb index 1a8f3a05032b8..f17422a7119cc 100644 --- a/decidim-core/app/cells/decidim/author/show.erb +++ b/decidim-core/app/cells/decidim/author/show.erb @@ -1,10 +1,15 @@ +<%# If the options hash has the demo key it means we are in the decidim-design engine, so it is not a real-world scenario with actual users %> +<% tooltip = options.has_key?(:demo) ? { tooltip: render(:profile_minicard).html_safe } : nil %> <%= content_tag(:p, class: :author, data: ) do %> - <%= content_tag :span, class: "author__container#{" is-compact" if layout == :compact}" do %> + <%= content_tag :span, class: "author__container#{" is-compact" if layout == :compact}", data: tooltip do %> <% if layout == :compact %> <%= render :avatar %> - <%= render :name %> + + <%= render :name %> + <%= render :badge %> + <% context_actions.each do |action| %> <%= render action %> @@ -15,6 +20,7 @@ <% else %> <%= render :avatar %> <%= render :name %> + <%= render :badge %> <% end %> <% end %> diff --git a/decidim-core/app/cells/decidim/author_cell.rb b/decidim-core/app/cells/decidim/author_cell.rb index b412595ba332a..d5b871806607e 100644 --- a/decidim-core/app/cells/decidim/author_cell.rb +++ b/decidim-core/app/cells/decidim/author_cell.rb @@ -186,5 +186,15 @@ def has_tooltip? model.has_tooltip? end + + def show_badge? + return false unless model.respond_to? :officialized? + + model.officialized? + end + + def officialization_text + translated_attribute(model.officialized_as).presence || t("decidim.profiles.show.officialized") + end end end diff --git a/decidim-core/app/cells/decidim/footer_topics/show.erb b/decidim-core/app/cells/decidim/footer_topics/show.erb index 2e548d6331334..be65c6c713a63 100644 --- a/decidim-core/app/cells/decidim/footer_topics/show.erb +++ b/decidim-core/app/cells/decidim/footer_topics/show.erb @@ -1,5 +1,5 @@ -