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

Dev to main #684

Merged
merged 29 commits into from
Aug 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
a704a9b
UHF-10469: Change news archive fallback and rss views to use drupal d…
teroelonen Aug 19, 2024
a6c6cca
UHF-10469: Add correct machine names and configuration to news archiv…
teroelonen Aug 19, 2024
eebd1d0
UHF-10469: Add translations for news archive view
teroelonen Aug 19, 2024
a3b1da8
UHF-10469: Update documentation to reflect the changes made to news a…
teroelonen Aug 19, 2024
43ba971
UHF-10469: Attach the feed icon to the news archive
teroelonen Aug 19, 2024
794e38c
Merge pull request #683 from City-of-Helsinki/UHF-10469
teroelonen Aug 20, 2024
e1b26a8
Update configuration
hel-platta-automation Aug 20, 2024
6c95387
Merge pull request #682 from City-of-Helsinki/update-configuration
teroelonen Aug 20, 2024
055e16f
UHF-10469: Add news articles to rss feed and fallback listing of news…
teroelonen Aug 21, 2024
a7d7d56
Merge pull request #685 from City-of-Helsinki/UHF-10469_news_articles…
teroelonen Aug 22, 2024
0f9bce3
UHF-10296: disable old recommendations block, enable new
rpnykanen Aug 22, 2024
0ec7a5e
UHF-10296: leave the old block enabled for other than main languages
rpnykanen Aug 22, 2024
4a5aeec
UHF-10296: annif keyword entity reference is not translatable any more
rpnykanen Aug 23, 2024
739ed42
UHF-10296: fix the en and sv translation recommendations
rpnykanen Aug 23, 2024
ec9fe92
UHF-10485: alter didn't trigger for articles because of wrong view id
rpnykanen Aug 23, 2024
77a69d8
UHF-10485: mentioned orderable news feeds in site specific documentation
rpnykanen Aug 23, 2024
f543789
Merge pull request #687 from City-of-Helsinki/UHF-10296
rpnykanen Aug 23, 2024
f82a5df
UHF-10485: Updated the documentation a bit
teroelonen Aug 23, 2024
fcd3adf
Merge pull request #688 from City-of-Helsinki/UHF-10485
rpnykanen Aug 23, 2024
2c19301
UHF-10452: Change the front page latest news blocks news archive base…
teroelonen Aug 23, 2024
ff8de16
Updated node modules based on npm audit fix
actions-bot Aug 25, 2024
9d28c4b
Update configuration
hel-platta-automation Aug 27, 2024
84c18dc
Merge pull request #686 from City-of-Helsinki/update-configuration
hyrsky Aug 27, 2024
46f95ce
Update configuration
hel-platta-automation Aug 27, 2024
0627475
Merge pull request #691 from City-of-Helsinki/update-configuration
teroelonen Aug 27, 2024
c329694
Merge pull request #689 from City-of-Helsinki/UHF-10452
teroelonen Aug 27, 2024
ba6148a
Update configuration
hel-platta-automation Aug 27, 2024
56214a2
Merge pull request #690 from City-of-Helsinki/automation/npm-audit
rpnykanen Aug 27, 2024
9888a19
Merge pull request #692 from City-of-Helsinki/update-configuration
rpnykanen Aug 28, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 18 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -96,13 +96,17 @@ selection of what to show is determined by the `field_listing_type`, and the par
#### News archive (news_archive)

The _news_archive_ paragraph provides the news archive search that can be added to landing pages. The news archive is
a React search that uses views listing (`news_archive_index`) as a fallback when JavaScript is not enabled. All React
a React search that uses views listing (`news_archive`) as a fallback when JavaScript is not enabled. All React
searches are in the `hdbt` theme, so most of the related logic is also found there. The _news_archive_ paragraph has an
editable title and description.
- React search code can be found under the `hdbt` theme [here](https://github.com/City-of-Helsinki/drupal-hdbt/tree/main/src/js/react/apps/news-archive).
- Additional configuration for the React app is under the `hdbt_subtheme` theme function
`hdbt_subtheme_preprocess_paragraph` [here](https://github.com/City-of-Helsinki/drupal-helfi-etusivu/blob/dev/public/themes/custom/hdbt_subtheme/hdbt_subtheme.theme)
- Fallback view when JavaScript is not enabled can be found in the `/conf/cim` folder [here](https://github.com/City-of-Helsinki/drupal-helfi-etusivu/blob/dev/conf/cmi/views.view.news_archive_index.yml).
- Fallback view when JavaScript is not enabled can be found in the `/conf/cim` folder [here](https://github.com/City-of-Helsinki/drupal-helfi-etusivu/blob/dev/conf/cmi/views.view.news_archive.yml).
- **NOTICE:** The fallback view and RSS view retrieve data from the regular database, while the React application queries
the Elasticsearch index. This is because switching the view to use the Elasticsearch index as the data source limits
its ability to filter using URL queries, compared to the regular view. For example, queries in the format
`?tags%5b%5d=375` would no longer work out of the box, and the contextual filters would need to be added separately.

### Custom roles

Expand Down Expand Up @@ -146,3 +150,15 @@ each paragraph that support the alternative languages. For example `paragraphs.p

Regarding this alternative language support there is a custom module called `helfi_alt_lang_fallback` that provides
menu and block fallbacks for the alternative languages. See more from the module itself [here](https://github.com/City-of-Helsinki/drupal-helfi-etusivu/tree/dev/public/modules/custom/helfi_alt_lang_fallback).

### News and article feed reordering with drupal/draggableviews

Drupal/draggableviews -module is used to allow content creators to reorder the `main news feed` and `main articles feed`
located in the front page. Adding content to the front page news feed can be done from node edit page by enabling
`Publish the news article in the top news articles flow` selection.

Draggableviews-module doesn't support translations out of the box and some patching has been done to get it working.
The initial feed ordering view was done in [this PR](https://github.com/City-of-Helsinki/drupal-helfi-etusivu/pull/103/files#diff-eac9bb841152af0a402bf0d14621ac75c98ff734db71f6a34a7156b9812346df)
- `langcode` column was added to draggableviews -database table.
- Query alter was created for views utilizing draggableviews to filter out content by language.
- Page preprocess was included to add custom styling to the admin interface of the view used to organize the items.
Loading