From a2bb1266d34f50adc48f0fa548e077b0dc34d1c0 Mon Sep 17 00:00:00 2001 From: Robin Steiner Date: Mon, 13 May 2024 11:10:50 +0200 Subject: [PATCH] Upgrade Decidim to 0.27.6 --- Gemfile | 2 +- Gemfile.lock | 380 +++++++++--------- app/views/static/api/docs/index.html | 1 + .../interface/componentinterface/index.html | 1 - .../static/api/docs/object/result/index.html | 33 +- ...nter_cache_to_comments.decidim_comments.rb | 22 + ...m_proposals_proposals.decidim_proposals.rb | 17 + db/schema.rb | 5 +- 8 files changed, 245 insertions(+), 216 deletions(-) create mode 100644 db/migrate/20240513090932_add_comment_vote_counter_cache_to_comments.decidim_comments.rb create mode 100644 db/migrate/20240513090933_add_valuation_assignments_count_to_decidim_proposals_proposals.decidim_proposals.rb diff --git a/Gemfile b/Gemfile index fb02048c..ee9f3676 100644 --- a/Gemfile +++ b/Gemfile @@ -2,7 +2,7 @@ source 'https://rubygems.org' -DECIDIM_VERSION = '0.27.5' +DECIDIM_VERSION = '0.27.6' ruby RUBY_VERSION diff --git a/Gemfile.lock b/Gemfile.lock index 2bbc2f5a..cae232e7 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -99,40 +99,40 @@ GIT GEM remote: https://rubygems.org/ specs: - actioncable (6.1.7.6) - actionpack (= 6.1.7.6) - activesupport (= 6.1.7.6) + actioncable (6.1.7.7) + actionpack (= 6.1.7.7) + activesupport (= 6.1.7.7) nio4r (~> 2.0) websocket-driver (>= 0.6.1) - actionmailbox (6.1.7.6) - actionpack (= 6.1.7.6) - activejob (= 6.1.7.6) - activerecord (= 6.1.7.6) - activestorage (= 6.1.7.6) - activesupport (= 6.1.7.6) + actionmailbox (6.1.7.7) + actionpack (= 6.1.7.7) + activejob (= 6.1.7.7) + activerecord (= 6.1.7.7) + activestorage (= 6.1.7.7) + activesupport (= 6.1.7.7) mail (>= 2.7.1) - actionmailer (6.1.7.6) - actionpack (= 6.1.7.6) - actionview (= 6.1.7.6) - activejob (= 6.1.7.6) - activesupport (= 6.1.7.6) + actionmailer (6.1.7.7) + actionpack (= 6.1.7.7) + actionview (= 6.1.7.7) + activejob (= 6.1.7.7) + activesupport (= 6.1.7.7) mail (~> 2.5, >= 2.5.4) rails-dom-testing (~> 2.0) - actionpack (6.1.7.6) - actionview (= 6.1.7.6) - activesupport (= 6.1.7.6) + actionpack (6.1.7.7) + actionview (= 6.1.7.7) + activesupport (= 6.1.7.7) rack (~> 2.0, >= 2.0.9) rack-test (>= 0.6.3) rails-dom-testing (~> 2.0) rails-html-sanitizer (~> 1.0, >= 1.2.0) - actiontext (6.1.7.6) - actionpack (= 6.1.7.6) - activerecord (= 6.1.7.6) - activestorage (= 6.1.7.6) - activesupport (= 6.1.7.6) + actiontext (6.1.7.7) + actionpack (= 6.1.7.7) + activerecord (= 6.1.7.7) + activestorage (= 6.1.7.7) + activesupport (= 6.1.7.7) nokogiri (>= 1.8.5) - actionview (6.1.7.6) - activesupport (= 6.1.7.6) + actionview (6.1.7.7) + activesupport (= 6.1.7.7) builder (~> 3.1) erubi (~> 1.4) rails-dom-testing (~> 2.0) @@ -140,25 +140,25 @@ GEM active_link_to (1.0.5) actionpack addressable - activejob (6.1.7.6) - activesupport (= 6.1.7.6) + activejob (6.1.7.7) + activesupport (= 6.1.7.7) globalid (>= 0.3.6) - activemodel (6.1.7.6) - activesupport (= 6.1.7.6) - activerecord (6.1.7.6) - activemodel (= 6.1.7.6) - activesupport (= 6.1.7.6) + activemodel (6.1.7.7) + activesupport (= 6.1.7.7) + activerecord (6.1.7.7) + activemodel (= 6.1.7.7) + activesupport (= 6.1.7.7) activerecord-postgis-adapter (7.1.1) activerecord (~> 6.1) rgeo-activerecord (~> 7.0.0) - activestorage (6.1.7.6) - actionpack (= 6.1.7.6) - activejob (= 6.1.7.6) - activerecord (= 6.1.7.6) - activesupport (= 6.1.7.6) + activestorage (6.1.7.7) + actionpack (= 6.1.7.7) + activejob (= 6.1.7.7) + activerecord (= 6.1.7.7) + activesupport (= 6.1.7.7) marcel (~> 1.0) mini_mime (>= 1.1.0) - activesupport (6.1.7.6) + activesupport (6.1.7.7) concurrent-ruby (~> 1.0, >= 1.0.2) i18n (>= 1.6, < 2) minitest (>= 5.1) @@ -188,7 +188,7 @@ GEM aws-sigv4 (~> 1.6) aws-sigv4 (1.6.0) aws-eventstream (~> 1, >= 1.0.2) - axe-core-api (4.8.1) + axe-core-api (4.9.0) dumb_delegator virtus axe-core-rspec (4.1.0) @@ -214,7 +214,7 @@ GEM html_tokenizer (~> 0.0.6) parser (>= 2.4) smart_properties - bigdecimal (3.1.6) + bigdecimal (3.1.8) bindata (2.4.15) bindex (0.8.1) binding_of_caller (1.0.0) @@ -234,7 +234,7 @@ GEM rack-test (>= 0.6.3) regexp_parser (>= 1.5, < 3.0) xpath (~> 3.2) - carrierwave (2.2.5) + carrierwave (2.2.6) activemodel (>= 5.0.0) activesupport (>= 5.0.0) addressable (~> 2.6) @@ -254,7 +254,7 @@ GEM actionpack (>= 5.0) cells (>= 4.1.6, < 5.0.0) charlock_holmes (0.7.7) - chef-utils (18.4.2) + chef-utils (18.4.12) concurrent-ruby childprocess (4.1.0) clamby (1.6.10) @@ -270,11 +270,11 @@ GEM coffee-script-source (1.12.2) commonmarker (0.23.10) concurrent-ruby (1.2.3) - crack (0.4.6) + crack (1.0.0) bigdecimal rexml crass (1.0.6) - css_parser (1.16.0) + css_parser (1.17.1) addressable csv (3.3.0) dalli (3.2.5) @@ -288,68 +288,68 @@ GEM dbf (4.3.2) csv debug_inspector (1.1.0) - decidim (0.27.5) - decidim-accountability (= 0.27.5) - decidim-admin (= 0.27.5) - decidim-api (= 0.27.5) - decidim-assemblies (= 0.27.5) - decidim-blogs (= 0.27.5) - decidim-budgets (= 0.27.5) - decidim-comments (= 0.27.5) - decidim-core (= 0.27.5) - decidim-debates (= 0.27.5) - decidim-forms (= 0.27.5) - decidim-generators (= 0.27.5) - decidim-meetings (= 0.27.5) - decidim-pages (= 0.27.5) - decidim-participatory_processes (= 0.27.5) - decidim-proposals (= 0.27.5) - decidim-sortitions (= 0.27.5) - decidim-surveys (= 0.27.5) - decidim-system (= 0.27.5) - decidim-templates (= 0.27.5) - decidim-verifications (= 0.27.5) - decidim-accountability (0.27.5) - decidim-comments (= 0.27.5) - decidim-core (= 0.27.5) - decidim-admin (0.27.5) + decidim (0.27.6) + decidim-accountability (= 0.27.6) + decidim-admin (= 0.27.6) + decidim-api (= 0.27.6) + decidim-assemblies (= 0.27.6) + decidim-blogs (= 0.27.6) + decidim-budgets (= 0.27.6) + decidim-comments (= 0.27.6) + decidim-core (= 0.27.6) + decidim-debates (= 0.27.6) + decidim-forms (= 0.27.6) + decidim-generators (= 0.27.6) + decidim-meetings (= 0.27.6) + decidim-pages (= 0.27.6) + decidim-participatory_processes (= 0.27.6) + decidim-proposals (= 0.27.6) + decidim-sortitions (= 0.27.6) + decidim-surveys (= 0.27.6) + decidim-system (= 0.27.6) + decidim-templates (= 0.27.6) + decidim-verifications (= 0.27.6) + decidim-accountability (0.27.6) + decidim-comments (= 0.27.6) + decidim-core (= 0.27.6) + decidim-admin (0.27.6) active_link_to (~> 1.0) - decidim-core (= 0.27.5) + decidim-core (= 0.27.6) devise (~> 4.7) devise-i18n (~> 1.2) devise_invitable (~> 2.0, >= 2.0.9) - decidim-api (0.27.5) + decidim-api (0.27.6) + decidim-core (= 0.27.6) graphql (~> 1.12, < 1.13) graphql-docs (~> 2.1.0) rack-cors (~> 1.0) - decidim-assemblies (0.27.5) - decidim-core (= 0.27.5) - decidim-blogs (0.27.5) - decidim-admin (= 0.27.5) - decidim-comments (= 0.27.5) - decidim-core (= 0.27.5) - decidim-budgets (0.27.5) - decidim-comments (= 0.27.5) - decidim-core (= 0.27.5) - decidim-comments (0.27.5) - decidim-core (= 0.27.5) + decidim-assemblies (0.27.6) + decidim-core (= 0.27.6) + decidim-blogs (0.27.6) + decidim-admin (= 0.27.6) + decidim-comments (= 0.27.6) + decidim-core (= 0.27.6) + decidim-budgets (0.27.6) + decidim-comments (= 0.27.6) + decidim-core (= 0.27.6) + decidim-comments (0.27.6) + decidim-core (= 0.27.6) redcarpet (~> 3.5, >= 3.5.1) - decidim-conferences (0.27.5) - decidim-core (= 0.27.5) - decidim-meetings (= 0.27.5) + decidim-conferences (0.27.6) + decidim-core (= 0.27.6) + decidim-meetings (= 0.27.6) wicked_pdf (~> 2.1) wkhtmltopdf-binary (~> 0.12) - decidim-core (0.27.5) + decidim-core (0.27.6) active_link_to (~> 1.0) acts_as_list (~> 0.9) batch-loader (~> 1.2) browser (~> 2.7) - carrierwave (~> 2.2.1) + carrierwave (~> 2.2.5, >= 2.2.5) cells-erb (~> 0.1.0) cells-rails (~> 0.1.3) charlock_holmes (~> 0.7) date_validator (~> 0.12.0) - decidim-api (= 0.27.5) devise (~> 4.7) devise-i18n (~> 1.2) diffy (~> 3.3) @@ -365,7 +365,6 @@ GEM loofah (~> 2.19.0) mime-types (>= 1.16, < 4.0) mini_magick (~> 4.9) - mustache (~> 1.1.0) omniauth (~> 2.0) omniauth-facebook (~> 5.0) omniauth-google-oauth2 (~> 1.0) @@ -390,15 +389,15 @@ GEM webpacker (= 6.0.0.rc.5) webpush (~> 1.1) wisper (~> 2.0) - decidim-debates (0.27.5) - decidim-comments (= 0.27.5) - decidim-core (= 0.27.5) - decidim-dev (0.27.5) + decidim-debates (0.27.6) + decidim-comments (= 0.27.6) + decidim-core (= 0.27.6) + decidim-dev (0.27.6) axe-core-rspec (~> 4.1.0) byebug (~> 11.0) capybara (~> 3.24) db-query-matchers (~> 0.10.0) - decidim (= 0.27.5) + decidim (= 0.27.6) erb_lint (~> 0.0.35) factory_bot_rails (~> 4.8) i18n-tasks (~> 0.9.18) @@ -421,50 +420,49 @@ GEM w3c_rspec_validators (~> 0.3.0) webmock (~> 3.6) wisper-rspec (~> 1.0) - decidim-forms (0.27.5) - decidim-core (= 0.27.5) + decidim-forms (0.27.6) + decidim-core (= 0.27.6) wicked_pdf (~> 2.1) wkhtmltopdf-binary (~> 0.12) - decidim-generators (0.27.5) - decidim-core (= 0.27.5) - decidim-meetings (0.27.5) - decidim-core (= 0.27.5) - decidim-forms (= 0.27.5) + decidim-generators (0.27.6) + decidim-core (= 0.27.6) + decidim-meetings (0.27.6) + decidim-core (= 0.27.6) + decidim-forms (= 0.27.6) icalendar (~> 2.5) - decidim-pages (0.27.5) - decidim-core (= 0.27.5) - decidim-participatory_processes (0.27.5) - decidim-core (= 0.27.5) - decidim-proposals (0.27.5) - decidim-comments (= 0.27.5) - decidim-core (= 0.27.5) + decidim-pages (0.27.6) + decidim-core (= 0.27.6) + decidim-participatory_processes (0.27.6) + decidim-core (= 0.27.6) + decidim-proposals (0.27.6) + decidim-comments (= 0.27.6) + decidim-core (= 0.27.6) doc2text (~> 0.4.5) redcarpet (~> 3.5, >= 3.5.1) - decidim-sortitions (0.27.5) - decidim-admin (= 0.27.5) - decidim-comments (= 0.27.5) - decidim-core (= 0.27.5) - decidim-proposals (= 0.27.5) + decidim-sortitions (0.27.6) + decidim-admin (= 0.27.6) + decidim-comments (= 0.27.6) + decidim-core (= 0.27.6) + decidim-proposals (= 0.27.6) decidim-survey_multiple_answers (0.26.2) decidim-admin (>= 0.26.0, < 0.28.0) decidim-core (>= 0.26.0, < 0.28.0) decidim-forms (>= 0.26.0, < 0.28.0) decidim-surveys (>= 0.26.0, < 0.28.0) - decidim-surveys (0.27.5) - decidim-core (= 0.27.5) - decidim-forms (= 0.27.5) - decidim-templates (= 0.27.5) - decidim-system (0.27.5) + decidim-surveys (0.27.6) + decidim-core (= 0.27.6) + decidim-forms (= 0.27.6) + decidim-system (0.27.6) active_link_to (~> 1.0) - decidim-core (= 0.27.5) + decidim-core (= 0.27.6) devise (~> 4.7) devise-i18n (~> 1.2) devise_invitable (~> 2.0, >= 2.0.9) - decidim-templates (0.27.5) - decidim-core (= 0.27.5) - decidim-forms (= 0.27.5) - decidim-verifications (0.27.5) - decidim-core (= 0.27.5) + decidim-templates (0.27.6) + decidim-core (= 0.27.6) + decidim-forms (= 0.27.6) + decidim-verifications (0.27.6) + decidim-core (= 0.27.6) declarative-builder (0.1.0) declarative-option (< 0.2.0) declarative-option (0.1.0) @@ -483,7 +481,7 @@ GEM delayed_job (>= 3.0, < 5) descendants_tracker (0.0.4) thread_safe (~> 0.3, >= 0.3.1) - devise (4.9.3) + devise (4.9.4) bcrypt (~> 3.0) orm_adapter (~> 0.1) railties (>= 4.1.0) @@ -496,11 +494,11 @@ GEM devise (>= 4.6) diff-lcs (1.5.1) diffy (3.4.2) - doc2text (0.4.6) - nokogiri (>= 1.13.2, < 1.15.0) + doc2text (0.4.7) + nokogiri (>= 1.13.2, < 1.17.0) rubyzip (~> 2.3.0) docile (1.4.0) - doorkeeper (5.6.8) + doorkeeper (5.7.0) railties (>= 5) doorkeeper-i18n (4.0.1) dumb_delegator (1.0.0) @@ -519,7 +517,7 @@ GEM escape_utils (1.3.0) et-orbi (1.2.7) tzinfo - excon (0.109.0) + excon (0.110.0) execjs (2.9.1) extended-markdown-filter (0.7.0) html-pipeline (~> 2.9) @@ -559,7 +557,9 @@ GEM et-orbi (~> 1, >= 1.2.7) raabro (~> 1.4) gemoji (3.0.1) - geocoder (1.8.2) + geocoder (1.8.3) + base64 (>= 0.1.0) + csv (>= 3.0.0) globalid (1.2.1) activesupport (>= 6.1) graphql (1.12.24) @@ -578,10 +578,10 @@ GEM html-pipeline (2.14.3) activesupport (>= 2) nokogiri (>= 1.4) - html_tokenizer (0.0.7) + html_tokenizer (0.0.8) htmlentities (4.3.4) httpclient (2.8.3) - i18n (1.14.1) + i18n (1.14.5) concurrent-ruby (~> 1.0) i18n-tasks (0.9.37) activesupport (>= 4.0.2) @@ -603,14 +603,15 @@ GEM invisible_captcha (0.13.0) rails (>= 3.2.0) jmespath (1.6.2) - json (2.7.1) + json (2.7.2) json-jwt (1.16.3) activesupport (>= 4.2) aes_key_wrap bindata faraday (~> 2.0) faraday-follow_redirects - jwt (2.7.1) + jwt (2.8.1) + base64 kaminari (1.2.2) activesupport (>= 4.1.0) kaminari-actionview (= 1.2.2) @@ -643,7 +644,7 @@ GEM net-imap net-pop net-smtp - marcel (1.0.2) + marcel (1.0.4) matrix (0.4.2) mdl (0.13.0) kramdown (~> 2.3) @@ -651,13 +652,13 @@ GEM mixlib-cli (~> 2.1, >= 2.1.1) mixlib-config (>= 2.2.1, < 4) mixlib-shellout - method_source (1.0.0) + method_source (1.1.0) mime-types (3.5.2) mime-types-data (~> 3.2015) - mime-types-data (3.2023.1205) + mime-types-data (3.2024.0507) mini_magick (4.12.0) mini_mime (1.1.5) - minitest (5.21.2) + minitest (5.22.3) mixlib-cli (2.1.8) mixlib-config (3.0.27) tomlrb @@ -665,20 +666,19 @@ GEM chef-utils msgpack (1.7.2) multi_xml (0.6.0) - mustache (1.1.1) net-http (0.4.1) uri - net-imap (0.4.9.1) + net-imap (0.4.11) date net-protocol net-pop (0.1.2) net-protocol net-protocol (0.2.2) timeout - net-smtp (0.4.0.1) + net-smtp (0.5.0) net-protocol - nio4r (2.7.0) - nokogiri (1.14.5-x86_64-linux) + nio4r (2.7.3) + nokogiri (1.16.4-x86_64-linux) racc (~> 1.4) oauth (1.1.0) oauth-tty (~> 1.0, >= 1.0.1) @@ -699,18 +699,18 @@ GEM rack-protection omniauth-facebook (5.0.0) omniauth-oauth2 (~> 1.2) - omniauth-google-oauth2 (1.1.1) + omniauth-google-oauth2 (1.1.2) jwt (>= 2.0) - oauth2 (~> 2.0.6) + oauth2 (~> 2.0) omniauth (~> 2.0) - omniauth-oauth2 (~> 1.8.0) + omniauth-oauth2 (~> 1.8) omniauth-oauth (1.2.0) oauth omniauth (>= 1.0, < 3) omniauth-oauth2 (1.8.0) oauth2 (>= 1.4, < 3) omniauth (~> 2.0) - omniauth-rails_csrf_protection (1.0.1) + omniauth-rails_csrf_protection (1.0.2) actionpack (>= 4.2) omniauth (~> 2.0) omniauth-twitter (1.4.0) @@ -745,7 +745,7 @@ GEM activerecord (>= 5.2) activesupport (>= 5.2) polyglot (0.3.5) - premailer (1.22.0) + premailer (1.23.0) addressable css_parser (>= 1.12.0) htmlentities (>= 4.0.0) @@ -763,12 +763,12 @@ GEM pry (>= 0.13, < 0.15) pry-rails (0.3.9) pry (>= 0.10.4) - public_suffix (5.0.4) + public_suffix (5.0.5) puma (5.6.7) nio4r (~> 2.0) raabro (1.4.0) racc (1.7.3) - rack (2.2.8) + rack (2.2.9) rack-attack (6.7.0) rack (>= 1.0, < 4) rack-cors (1.1.1) @@ -786,20 +786,20 @@ GEM rack rack-test (2.1.0) rack (>= 1.3) - rails (6.1.7.6) - actioncable (= 6.1.7.6) - actionmailbox (= 6.1.7.6) - actionmailer (= 6.1.7.6) - actionpack (= 6.1.7.6) - actiontext (= 6.1.7.6) - actionview (= 6.1.7.6) - activejob (= 6.1.7.6) - activemodel (= 6.1.7.6) - activerecord (= 6.1.7.6) - activestorage (= 6.1.7.6) - activesupport (= 6.1.7.6) + rails (6.1.7.7) + actioncable (= 6.1.7.7) + actionmailbox (= 6.1.7.7) + actionmailer (= 6.1.7.7) + actionpack (= 6.1.7.7) + actiontext (= 6.1.7.7) + actionview (= 6.1.7.7) + activejob (= 6.1.7.7) + activemodel (= 6.1.7.7) + activerecord (= 6.1.7.7) + activestorage (= 6.1.7.7) + activesupport (= 6.1.7.7) bundler (>= 1.15.0) - railties (= 6.1.7.6) + railties (= 6.1.7.7) sprockets-rails (>= 2.0.0) rails-controller-testing (1.0.5) actionpack (>= 5.0.1.rc1) @@ -814,14 +814,14 @@ GEM rails-i18n (6.0.0) i18n (>= 0.7, < 2) railties (>= 6.0.0, < 7) - railties (6.1.7.6) - actionpack (= 6.1.7.6) - activesupport (= 6.1.7.6) + railties (6.1.7.7) + actionpack (= 6.1.7.7) + activesupport (= 6.1.7.7) method_source rake (>= 12.2) thor (~> 1.0) rainbow (3.1.1) - rake (13.1.0) + rake (13.2.1) ransack (2.4.2) activerecord (>= 5.2.4) activesupport (>= 5.2.4) @@ -859,24 +859,24 @@ GEM dbf (~> 4.0) rgeo (>= 1.0) rouge (4.1.3) - rspec (3.12.0) - rspec-core (~> 3.12.0) - rspec-expectations (~> 3.12.0) - rspec-mocks (~> 3.12.0) + rspec (3.13.0) + rspec-core (~> 3.13.0) + rspec-expectations (~> 3.13.0) + rspec-mocks (~> 3.13.0) rspec-cells (0.3.9) cells (>= 4.0.0, < 6.0.0) rspec-rails (>= 3.0.0, < 6.2.0) - rspec-core (3.12.2) - rspec-support (~> 3.12.0) - rspec-expectations (3.12.3) + rspec-core (3.13.0) + rspec-support (~> 3.13.0) + rspec-expectations (3.13.0) diff-lcs (>= 1.2.0, < 2.0) - rspec-support (~> 3.12.0) + rspec-support (~> 3.13.0) rspec-html-matchers (0.9.4) nokogiri (~> 1) rspec (>= 3.0.0.a, < 4) - rspec-mocks (3.12.6) + rspec-mocks (3.13.1) diff-lcs (>= 1.2.0, < 2.0) - rspec-support (~> 3.12.0) + rspec-support (~> 3.13.0) rspec-rails (4.1.2) actionpack (>= 4.2) activesupport (>= 4.2) @@ -887,7 +887,7 @@ GEM rspec-support (~> 3.10) rspec-retry (0.6.2) rspec-core (> 3.3) - rspec-support (3.12.1) + rspec-support (3.13.1) rspec_junit_formatter (0.3.0) rspec-core (>= 2, < 4, != 2.12.0) rubocop (1.28.2) @@ -908,9 +908,9 @@ GEM rubocop-rspec (2.11.1) rubocop (~> 1.19) ruby-progressbar (1.13.0) - ruby-vips (2.2.0) + ruby-vips (2.2.1) ffi (~> 1.12) - rubyXL (3.4.25) + rubyXL (3.4.27) nokogiri (>= 1.10.8) rubyzip (>= 1.3.0) rubyzip (2.3.2) @@ -963,7 +963,7 @@ GEM temple (0.10.3) terminal-table (3.0.2) unicode-display_width (>= 1.1.1, < 3) - thor (1.3.0) + thor (1.3.1) thread_safe (0.3.6) tilt (2.3.0) timeout (0.4.1) @@ -984,7 +984,7 @@ GEM validate_url (1.0.15) activemodel (>= 3.0.0) public_suffix - version_gem (1.1.3) + version_gem (1.1.4) virtus (1.0.5) axiom-types (~> 0.1) coercible (~> 1.0) @@ -1008,7 +1008,7 @@ GEM webfinger (1.2.0) activesupport httpclient (>= 2.4) - webmock (3.19.1) + webmock (3.23.0) addressable (>= 2.8.0) crack (>= 0.3.2) hashdiff (>= 0.4.0, < 2.0.0) @@ -1024,14 +1024,14 @@ GEM websocket-driver (0.7.6) websocket-extensions (>= 0.1.0) websocket-extensions (0.1.5) - wicked_pdf (2.7.0) + wicked_pdf (2.8.0) activesupport wisper (2.0.1) wisper-rspec (1.1.0) - wkhtmltopdf-binary (0.12.6.6) + wkhtmltopdf-binary (0.12.6.7) xpath (3.2.0) nokogiri (~> 1.8) - zeitwerk (2.6.12) + zeitwerk (2.6.13) PLATFORMS x86_64-linux @@ -1045,20 +1045,20 @@ DEPENDENCIES bootsnap byebug dalli - decidim (= 0.27.5) + decidim (= 0.27.6) decidim-anonymous_codes! decidim-anonymous_proposals! decidim-antivirus! decidim-cleaner! - decidim-conferences (= 0.27.5) + decidim-conferences (= 0.27.6) decidim-decidim_awesome! decidim-decidim_geo! - decidim-dev (= 0.27.5) + decidim-dev (= 0.27.6) decidim-participatory_documents! - decidim-proposals (= 0.27.5) + decidim-proposals (= 0.27.6) decidim-question_captcha! decidim-survey_multiple_answers (~> 0.26.2) - decidim-templates (= 0.27.5) + decidim-templates (= 0.27.6) decidim-term_customizer! delayed_cron_job delayed_job_active_record diff --git a/app/views/static/api/docs/index.html b/app/views/static/api/docs/index.html index e611e0cf..2eca637b 100644 --- a/app/views/static/api/docs/index.html +++ b/app/views/static/api/docs/index.html @@ -14,6 +14,7 @@

Using the GraphQL APi

The GraphQL format is a JSON formatted text that is specified in a query. Response is a JSON object as well. For details about specification check the official GraphQL site.

+

Exercise caution when utilizing the output of this API, as it may include HTML that has not been escaped. Take particular care in handling this data, specially if you intend to render it on a webpage.

For instance, you can check the version of a Decidim installation by using curl in the terminal:

curl -sSH "Content-Type: application/json" \
 -d '{"query": "{ decidim { version } }"}' \
diff --git a/app/views/static/api/docs/interface/componentinterface/index.html b/app/views/static/api/docs/interface/componentinterface/index.html
index 1741cf9b..58d5ed9c 100644
--- a/app/views/static/api/docs/interface/componentinterface/index.html
+++ b/app/views/static/api/docs/interface/componentinterface/index.html
@@ -12,7 +12,6 @@ 

  • Meetings
  • Pages
  • Proposals
  • -
  • Result
  • Sortitions
  • Surveys
  • diff --git a/app/views/static/api/docs/object/result/index.html b/app/views/static/api/docs/object/result/index.html index eed6c50e..31e22ca7 100644 --- a/app/views/static/api/docs/object/result/index.html +++ b/app/views/static/api/docs/object/result/index.html @@ -6,39 +6,20 @@

    Fields

    - id (ID!) -
    -

    The internal ID for this result

    -
    -
    -
    - name (TranslatedField!) -
    -

    The name of this component.

    -
    -
    -
    - weight (Int!) -
    -

    The order of this result

    -
    -
    -
    - participatorySpace (ParticipatorySpace!) + category (Category)
    -

    The participatory space in which this component belongs to.

    +

    The object's category

    - category (Category) + id (ID!)
    -

    The object's category

    +

    The internal ID for this result

    @@ -177,6 +158,12 @@

    The number of children results

    +
    + weight (Int!) +
    +

    The order of this result

    +
    +
    externalId (String)
    diff --git a/db/migrate/20240513090932_add_comment_vote_counter_cache_to_comments.decidim_comments.rb b/db/migrate/20240513090932_add_comment_vote_counter_cache_to_comments.decidim_comments.rb new file mode 100644 index 00000000..e4c0f576 --- /dev/null +++ b/db/migrate/20240513090932_add_comment_vote_counter_cache_to_comments.decidim_comments.rb @@ -0,0 +1,22 @@ +# frozen_string_literal: true +# This migration comes from decidim_comments (originally 20240304092558) + +class AddCommentVoteCounterCacheToComments < ActiveRecord::Migration[6.1] + def change + add_column :decidim_comments_comments, :up_votes_count, :integer, null: false, default: 0, index: true + add_column :decidim_comments_comments, :down_votes_count, :integer, null: false, default: 0, index: true + + # We cannot use the reset_counters as up_votes and down_votes are scoped associationws + reversible do |dir| + dir.up do + Decidim::Comments::Comment.reset_column_information + Decidim::Comments::Comment.find_each do |record| + # rubocop:disable Rails/SkipsModelValidations + record.class.update_counters(record.id, up_votes_count: record.up_votes.length) + record.class.update_counters(record.id, down_votes_count: record.down_votes.length) + # rubocop:enable Rails/SkipsModelValidations + end + end + end + end +end diff --git a/db/migrate/20240513090933_add_valuation_assignments_count_to_decidim_proposals_proposals.decidim_proposals.rb b/db/migrate/20240513090933_add_valuation_assignments_count_to_decidim_proposals_proposals.decidim_proposals.rb new file mode 100644 index 00000000..97a16744 --- /dev/null +++ b/db/migrate/20240513090933_add_valuation_assignments_count_to_decidim_proposals_proposals.decidim_proposals.rb @@ -0,0 +1,17 @@ +# frozen_string_literal: true +# This migration comes from decidim_proposals (originally 20240404202756) + +class AddValuationAssignmentsCountToDecidimProposalsProposals < ActiveRecord::Migration[6.1] + def change + add_column :decidim_proposals_proposals, :valuation_assignments_count, :integer, default: 0 + + reversible do |dir| + dir.up do + Decidim::Proposals::Proposal.reset_column_information + Decidim::Proposals::Proposal.find_each do |record| + Decidim::Proposals::Proposal.reset_counters(record.id, :valuation_assignments) + end + end + end + end +end diff --git a/db/schema.rb b/db/schema.rb index 4a239be9..bd87640d 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -10,7 +10,7 @@ # # It's strongly recommended that you check this file into your version control system. -ActiveRecord::Schema.define(version: 2024_05_13_084816) do +ActiveRecord::Schema.define(version: 2024_05_13_090933) do # These are extensions that must be enabled in order to support this database enable_extension "ltree" @@ -490,6 +490,8 @@ t.string "decidim_participatory_space_type" t.integer "decidim_participatory_space_id" t.datetime "deleted_at" + t.integer "up_votes_count", default: 0, null: false + t.integer "down_votes_count", default: 0, null: false t.index ["created_at"], name: "index_decidim_comments_comments_on_created_at" t.index ["decidim_author_id", "decidim_author_type"], name: "index_decidim_comments_comments_on_decidim_author" t.index ["decidim_author_id"], name: "decidim_comments_comment_author" @@ -1585,6 +1587,7 @@ t.jsonb "body" t.integer "comments_count", default: 0, null: false t.integer "follows_count", default: 0, null: false + t.integer "valuation_assignments_count", default: 0 t.index "md5((body)::text)", name: "decidim_proposals_proposal_body_search" t.index "md5((title)::text)", name: "decidim_proposals_proposal_title_search" t.index ["created_at"], name: "index_decidim_proposals_proposals_on_created_at"