Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Remove Participation module #3909

Merged
merged 16 commits into from
Oct 16, 2021
Prev Previous commit
Next Next commit
restore fixtures archive
  • Loading branch information
stbnrivas authored and entantoencuanto committed Oct 5, 2021
commit d79ca1b5be87685cd4db89aa5e891c658bc00ec3
113 changes: 1 addition & 112 deletions test/fixtures/gobierto_cms/pages.yml
Original file line number Diff line number Diff line change
@@ -1,115 +1,4 @@
<%#= ERB.new(IO.read(Rails.root.join "test/fixtures_archive/gobierto_cms/pages/madrid/other.yml")).result %>

page_gobierto_cms_with_section:
title_translations: <%= { 'en' => 'CMS Page', 'es' => 'Página del CMS' }.to_json %>
body_translations: <%= { 'en' => 'body of page', 'es' => 'cuerpo de la pagina' }.to_json %>
body_source_translations: <%= { 'en' => 'body source page', 'es' => 'cuerpo fuente de la pagina' }.to_json %>
slug: 'cms-page'
visibility_level: <%= GobiertoCms::Page.visibility_levels[:active] %>
site: madrid
collection: site_news
published_on: <%= Date.current %>
template:

site_news_1:
title_translations: <%= { 'en' => 'Site news 1', 'es' => 'Noticias sitio 1' }.to_json %>
body_translations: <%= { 'en' => 'body site news 1', 'es' => 'cuerpo noticias sitio 1' }.to_json %>
body_source_translations: <%= { 'en' => 'body source site news 1', 'es' => 'cuerpo fuente noticias sitio 1' }.to_json %>
slug: 'site-news-1'
visibility_level: <%= GobiertoCms::Page.visibility_levels[:active] %>
site: madrid
collection: site_news
published_on: <%= Date.current %>
template:

consultation_faq:
title_translations: <%= { 'en' => 'Consultation page FAQ', 'es' => 'FAQ consultas' }.to_json %>
body_translations: <%= { 'en' => 'This is the <strong>body</strong> of the page', 'es' => 'Cuerpo <strong>página</strong> consultas' }.to_json %>
body_source_translations: <%= { 'en' => 'This is the <strong>body</strong> of the page', 'es' => 'Cuerpo <strong>página</strong> consultas' }.to_json %>
slug: 'consultation-faq'
visibility_level: <%= GobiertoCms::Page.visibility_levels[:active] %>
site: madrid
collection: site_pages
published_on: <%= Date.current %>
template:

privacy:
title_translations: <%= {'en' => 'Privacy', 'es' => 'Privacidad' }.to_json %>
body_translations: <%= {'en' => 'These are the privacy terms', 'es' => 'Privacidad' }.to_json %>
body_source_translations: <%= {'en' => 'These are the privacy terms', 'es' => 'Privacidad' }.to_json %>
slug: 'privacy'
visibility_level: <%= GobiertoCms::Page.visibility_levels[:active] %>
site: madrid
collection: site_pages
published_on: <%= Date.current %>
template:

cookies_page:
title_translations: <%= {'en' => 'Cookies', 'es' => 'Cookies' }.to_json %>
body_translations: <%= {'en' => 'These are the cookies terms', 'es' => 'Estas son las condiciones de las cookies' }.to_json %>
body_source_translations: <%= {'en' => 'These are the cookies terms', 'es' => 'Estas son las condiciones de las cookies' }.to_json %>
slug: 'cookies'
visibility_level: <%= GobiertoCms::Page.visibility_levels[:draft] %>
site: madrid
collection: cookies_collection
published_on: <%= Date.current %>
template:

about_site:
title_translations: <%= { 'es' => 'Sobre el sitio', 'en' => 'About site' }.to_json %>
body_translations: <%= {
"en" => "This is the <strong>body</strong> of the page that contains an image:<br><img src='#{Rails.application.routes.url_helpers.gobierto_attachments_attachment_url(ActiveRecord::FixtureSet.identify(:png_attachment_uploaded), host: 'madrid.gobierto.test')}' alt='The image'> and a <a href='#{Rails.application.routes.url_helpers.gobierto_attachments_attachment_url(ActiveRecord::FixtureSet.identify(:pdf_attachment_uploaded), host: 'madrid.gobierto.test')}'>link to a doc</a>.",
"es" => "Esto es el <strong>cuerpo</strong> de la página que contiene una imagen:<br><img src='#{Rails.application.routes.url_helpers.gobierto_attachments_attachment_url(ActiveRecord::FixtureSet.identify(:png_attachment_uploaded), host: 'madrid.gobierto.test')}' alt='La imagen'> y un <a href='#{Rails.application.routes.url_helpers.gobierto_attachments_attachment_url(ActiveRecord::FixtureSet.identify(:pdf_attachment_uploaded), host: 'madrid.gobierto.test')}'>enlace a un doc</a>."
}.to_json %>
body_source_translations: <%= {
"en" => "This is the **body** of a page that contains an image:\r\n\r\n![The image](#{Rails.application.routes.url_helpers.gobierto_attachments_attachment_url(ActiveRecord::FixtureSet.identify(:png_attachment_uploaded), host: 'madrid.gobierto.test')})\r\n\r\n and a [link to a doc](#{Rails.application.routes.url_helpers.gobierto_attachments_attachment_url(ActiveRecord::FixtureSet.identify(:pdf_attachment_uploaded), host: 'madrid.gobierto.test')}).",
"es" => "Esto es el **cuerpo** de la página que contiene una imagen:\r\n\r\n![La imagen](#{Rails.application.routes.url_helpers.gobierto_attachments_attachment_url(ActiveRecord::FixtureSet.identify(:png_attachment_uploaded), host: 'madrid.gobierto.test')})\r\n\r\n y un [enlace a un doc](#{Rails.application.routes.url_helpers.gobierto_attachments_attachment_url(ActiveRecord::FixtureSet.identify(:pdf_attachment_uploaded), host: 'madrid.gobierto.test')})."
}.to_json %>
slug: 'about-site'
visibility_level: <%= GobiertoCms::Page.visibility_levels[:active] %>
site: madrid
collection: site_pages
published_on: <%= Date.current %>
template:

about_site_draft:
title_translations: <%= { 'es' => 'Sobre el sitio Borrador', 'en' => 'About site Draft' }.to_json %>
body_translations: <%= {
"en" => "This is the <strong>body</strong> of the page that contains an image:<br><img src='#{Rails.application.routes.url_helpers.gobierto_attachments_attachment_url(ActiveRecord::FixtureSet.identify(:png_attachment_uploaded), host: 'madrid.gobierto.test')}' alt='The image'> and a <a href='#{Rails.application.routes.url_helpers.gobierto_attachments_attachment_url(ActiveRecord::FixtureSet.identify(:pdf_attachment_uploaded), host: 'madrid.gobierto.test')}'>link to a doc</a>.",
"es" => "Esto es el <strong>cuerpo</strong> de la página que contiene una imagen:<br><img src='#{Rails.application.routes.url_helpers.gobierto_attachments_attachment_url(ActiveRecord::FixtureSet.identify(:png_attachment_uploaded), host: 'madrid.gobierto.test')}' alt='La imagen'> y un <a href='#{Rails.application.routes.url_helpers.gobierto_attachments_attachment_url(ActiveRecord::FixtureSet.identify(:pdf_attachment_uploaded), host: 'madrid.gobierto.test')}'>enlace a un doc</a>."
}.to_json %>
body_source_translations: <%= {
"en" => "This is the **body** of a page that contains an image:\r\n\r\n![The image](#{Rails.application.routes.url_helpers.gobierto_attachments_attachment_url(ActiveRecord::FixtureSet.identify(:png_attachment_uploaded), host: 'madrid.gobierto.test')})\r\n\r\n and a [link to a doc](#{Rails.application.routes.url_helpers.gobierto_attachments_attachment_url(ActiveRecord::FixtureSet.identify(:pdf_attachment_uploaded), host: 'madrid.gobierto.test')}).",
"es" => "Esto es el **cuerpo** de la página que contiene una imagen:\r\n\r\n![La imagen](#{Rails.application.routes.url_helpers.gobierto_attachments_attachment_url(ActiveRecord::FixtureSet.identify(:png_attachment_uploaded), host: 'madrid.gobierto.test')})\r\n\r\n y un [enlace a un doc](#{Rails.application.routes.url_helpers.gobierto_attachments_attachment_url(ActiveRecord::FixtureSet.identify(:pdf_attachment_uploaded), host: 'madrid.gobierto.test')})."
}.to_json %>
slug: 'about-site-draft'
visibility_level: <%= GobiertoCms::Page.visibility_levels[:draft] %>
site: madrid
collection: site_pages
published_on: <%= Date.current %>
template:

generic_site_page:
title_translations: <%= {
'en' => 'Generic page',
'es' => 'Página genérica'
}.to_json %>
body_translations: <%= {
'en' => 'Generic page',
'es' => 'Página genérica'
}.to_json %>
body_source_translations: <%= {
'en' => 'Generic page',
'es' => 'Página genérica'
}.to_json %>
slug: 'generic-page'
visibility_level: <%= GobiertoCms::Page.visibility_levels[:active] %>
site: madrid
published_on: <%= Date.current %>
template:



<%= ERB.new(IO.read(Rails.root.join "test/fixtures_archive/gobierto_cms/pages/madrid/other.yml")).result %>
<%= ERB.new(IO.read(Rails.root.join "test/fixtures_archive/gobierto_cms/pages/santander/other.yml")).result %>
<%= ERB.new(IO.read(Rails.root.join "test/fixtures_archive/gobierto_cms/pages/santander/first_level.yml")).result %>
<%= ERB.new(IO.read(Rails.root.join "test/fixtures_archive/gobierto_cms/pages/santander/second_level.yml")).result %>
26 changes: 1 addition & 25 deletions test/fixtures/gobierto_cms/section_items.yml
Original file line number Diff line number Diff line change
@@ -1,26 +1,2 @@
<%#= ERB.new(IO.read(Rails.root.join "test/fixtures_archive/gobierto_cms/section_items/madrid/other.yml")).result %>

cms_section_madrid_1_item_a:
item: site_pages (GobiertoCms::Page)
position: 0
parent_id: nil
section: cms_section_madrid_1
level: 0

cms_section_madrid_1_item_b:
item: about_site (GobiertoCms::Page)
position: 0
parent_id: nil
section: cms_section_madrid_1
level: 0


cms_section_madrid_1_item_b:
item: about_site (GobiertoCms::Page)
position: 0
parent_id: nil
section: cookies_section
item_id: cookies_page
level: 0

<%= ERB.new(IO.read(Rails.root.join "test/fixtures_archive/gobierto_cms/section_items/madrid/other.yml")).result %>
<%= ERB.new(IO.read(Rails.root.join "test/fixtures_archive/gobierto_cms/section_items/santander/other.yml")).result %>
155 changes: 2 additions & 153 deletions test/fixtures/gobierto_common/collection_items.yml
Original file line number Diff line number Diff line change
@@ -1,155 +1,4 @@
<%= ERB.new(IO.read(Rails.root.join "test/fixtures_archive/gobierto_common/collection_items/madrid/attachments.yml")).result %>
<%= ERB.new(IO.read(Rails.root.join "test/fixtures_archive/gobierto_common/collection_items/madrid/events.yml")).result %>

<%#= ERB.new(IO.read(Rails.root.join "test/fixtures_archive/gobierto_common/collection_items/madrid/pages.yml")).result %>
# consultation_faq
consultation_faq_on_site:
collection: site_pages
item: consultation_faq
item_type: 'GobiertoCms::Page'
container: madrid (Site)

# privacy
privacy_on_site:
collection: site_pages
item: privacy
item_type: 'GobiertoCms::Page'
container: madrid (Site)

# about
about_on_site:
collection: site_pages
item: about_site
item_type: 'GobiertoCms::Page'
container: madrid (Site)

# about
about_draft_on_site:
collection: site_pages
item: about_site_draft
item_type: 'GobiertoCms::Page'
container: madrid (Site)


# site news
site_news_1_on_site:
collection: site_news
item: site_news_1
item_type: 'GobiertoCms::News'
container: madrid (Site)

# cookies
cookies_collection_item:
collection: cookies_collection
item: cookies_page
item_type: 'GobiertoCms::Page'
container: madrid (Site)

# themes

themes_on_process:
collection: news
item: themes
item_type: 'GobiertoCms::News'
container: sport_city_process (GobiertoParticipation::Process)

themes_on_site:
collection: news
item: themes
item_type: 'GobiertoCms::News'
container: madrid (Site)

themes_on_participation:
collection: news
item: themes
item_type: 'GobiertoCms::News'
container_type: GobiertoParticipation

themes_on_issue:
collection: news
item: themes
item_type: 'GobiertoCms::News'
container: culture_term (GobiertoCommon::Term)

themes_on_scope:
collection: news
item: themes
item_type: 'GobiertoCms::News'
container: old_town_term (GobiertoCommon::Term)

# themes_draft

themes_draft_on_process:
collection: news
item: themes_draft
item_type: 'GobiertoCms::News'
container: sport_city_process (GobiertoParticipation::Process)

themes_draft_on_site:
collection: news
item: themes_draft
item_type: 'GobiertoCms::News'
container: madrid (Site)

themes_draft_on_participation:
collection: news
item: themes_draft
item_type: 'GobiertoCms::News'
container_type: GobiertoParticipation

themes_draft_on_issue:
collection: news
item: themes_draft (GobiertoAttachments::Attachment)
item_type: 'GobiertoCms::News'
container: culture_term (GobiertoCommon::Term)

themes_draft_on_scope:
collection: news
item: themes_draft (GobiertoAttachments::Attachment)
item_type: 'GobiertoCms::News'
container: old_town_term (GobiertoCommon::Term)

# notice_1

notice_1_on_site:
collection: site_attachments
item: notice_1
item_type: 'GobiertoCms::News'
container: madrid (Site)

notice_1_on_issue:
collection: site_attachments
item: notice_1
item_type: 'GobiertoCms::News'
container: women_term (GobiertoCommon::Term)

notice_1_on_scope:
collection: site_attachments
item: notice_1
item_type: 'GobiertoCms::News'
container: old_town_term (GobiertoCommon::Term)

# notice_2

notice_2_on_issue:
collection: site_attachments_archived
item: notice_2
item_type: 'GobiertoCms::News'
container: women_term (GobiertoCommon::Term)

notice_2_on_scope:
collection: site_attachments_archived
item: notice_2
item_type: 'GobiertoCms::News'
container: old_town_term (GobiertoCommon::Term)

# about_site

site_page_1:
collection: site_pages
item: about_site
item_type: 'GobiertoCms::Page'
container: madrid (Site)


<%= ERB.new(IO.read(Rails.root.join "test/fixtures_archive/gobierto_common/collection_items/santander/pages.yml")).result %>
<%= ERB.new(IO.read(Rails.root.join "test/fixtures_archive/gobierto_common/collection_items/madrid/pages.yml")).result %>
<%= ERB.new(IO.read(Rails.root.join "test/fixtures_archive/gobierto_common/collection_items/santander/pages.yml")).result %>
Loading