11841 Commits

Author SHA1 Message Date
Benedek Farkas
0063c18f7f Testing windows-2025 runners on 1.10.x (#8843)
* Testing compile workflow on windows-2025 runners

* Wording [skip ci]

* Compile workflow: Switch shell to cmd where pwsh is not needed
2025-09-19 09:57:27 +02:00
Benedek Farkas
51400833e8 Merge branch '1.10.x' into 1.10.x-to-dev 2025-09-18 23:48:39 +02:00
Benedek Farkas
0de919d36f Fix gulp pipeline installation and error detection (#8841)
Some checks failed
Compile / Compile .NET solution (push) Has been cancelled
Compile / Compile Client-side Assets (push) Has been cancelled
* Fine-tuning the compile-node job in the compile workflow

* Temporarily disabling the compile job

* Splitting up steps in the compile-node job of the compile workflow

* Revert "Temporarily disabling the compile job"

This reverts commit c130566943.
2025-09-18 23:48:02 +02:00
Benedek Farkas
1819e91a61 Revert "Experimental compile workflow changes for better error detection"
This reverts commit 4e18292616.
2025-09-18 23:28:21 +02:00
Benedek Farkas
4e18292616 Experimental compile workflow changes for better error detection 2025-09-18 23:15:56 +02:00
Benedek Farkas
1925ec3541 Fixing indentation in TheAdmin/Styles/site.css 2025-09-18 22:41:32 +02:00
Benedek Farkas
673d782d82 Merge branch '1.10.x' into 1.10.x-to-dev
# Conflicts:
#	src/Orchard.Web/Core/Contents/Controllers/AdminController.cs
#	src/Orchard.Web/Core/Contents/Drivers/ContentsDriver.cs
#	src/Orchard.Web/Core/Contents/Placement.info
#	src/Orchard.Web/Modules/Orchard.Fields/Orchard.Fields.csproj
#	src/Orchard.Web/Themes/TheAdmin/Styles/site.css
#	src/Orchard/Orchard.Framework.csproj
2025-09-18 22:35:24 +02:00
Benedek Farkas
9b7b561869 Merge branch 'dev' into 1.10.x-to-dev 2025-09-18 22:13:32 +02:00
Andrea Piovanelli
b14c29503b #8565: Delete and Unpublish buttons in backoffice content edit (#8566)
Some checks failed
Compile / Compile .NET solution (push) Has been cancelled
Compile / Compile Client-side Assets (push) Has been cancelled
* Added publish and delete buttons to backoffice content edit.

* Corrected condition for content unpublishing.
Managed unpublish and delete button for blogs and widgets.

* Some little code refactoring

* Added css classes for unpublish-button.
Condition for delete button visibility now checks for contentItem.Id > 0 instead of IsNew() function

* Removed UnpublishButton from Widget Editor.

* Removed Widget_DeleteButton to use the generic Content_DeleteButton shape and avoid its duplication or confusing management via Placement.info.

* Removed Widget_UnpublishButton shape

* Removed unpublish button show/hide logic from driver.
Added comments to clarify how new Unpublish and Delete actions work.

* EOL fix to Orchard.Widgets.csproj.

* Added unpublish button to edit widget (shown if widget is draftable only)

* Hide Content edit delete button at frontend

* ContentsDriver: removed AdminFilter check to display delete button and checked the content is published before showing the unpublish button.

* Applied some of the proposed formatting changes

* Several refactoring operations

* Autoformatting.

* Stylesheet refactoring and reorganization to properly position backoffice buttons

* Autoformatting

---------

Co-authored-by: Alessandro Agostini <alessandro.agostini@laser-group.com>
Co-authored-by: Matteo Piovanelli <matteo.piovanelli@laser-group.com>
2025-06-13 16:17:11 +02:00
Marek Dzikiewicz
d310fb56e1 #8832: Add LazyLoadConvention (#8833)
Some checks failed
Compile / Compile .NET solution (push) Has been cancelled
Compile / Compile Client-side Assets (push) Has been cancelled
2025-04-17 10:03:42 -07:00
Marek Dzikiewicz
4c463287ca #8828: Expose Redis API to clear multiple keys using wildcard syntax (#8829)
* #8828: Expose Redis API to clear multiple keys using wildcard syntax

* #8828: Rename IRedisCacheStorageProvider to ICacheStorageProviderWithKeyPrefix

* Moving ICacheStorageProviderWithKeyPrefix to Orchard.Caching

---------

Co-authored-by: Benedek Farkas <benedek.farkas@lombiq.com>
2025-04-16 14:28:43 +02:00
Andrea Piovanelli
3561be6e37 Moved embed video import to a dedicated service. (#8827)
Some checks failed
Compile / Compile .NET solution (push) Has been cancelled
Compile / Compile Client-side Assets (push) Has been cancelled
2025-02-04 12:55:39 +01:00
Benedek Farkas
5c3d045aa1 #8800: Reverting breaking changes to Enumeration Fields caused by #8789 (#8824)
Some checks failed
Compile / Compile .NET solution (push) Has been cancelled
Compile / Compile Client-side Assets (push) Has been cancelled
* Revert "#8640: Fixing consistency between different Enumeration Field flavors' data storage (#8789)"

This reverts commit fdbb06ba8d.

* Re-adding change to fix that changing the ListMode of an EnumerationField from a multi-select to a single-select flavor shouldn't break the editor

* Code styling in Fields/Enumeration.Edit.cshtml
2025-01-23 11:59:24 +01:00
Benedek Farkas
c38c9bf398 Merge branch '1.10.x-to-dev' into dev
Some checks failed
Compile / Compile .NET solution (push) Has been cancelled
Compile / Compile Client-side Assets (push) Has been cancelled
SpecFlow tests / SpecFlow tests (1.10.x) (push) Has been cancelled
SpecFlow tests / SpecFlow tests (dev) (push) Has been cancelled
Build Crowdin Translation Packages / build-crowdin-translation-packages (push) Has been cancelled
2025-01-17 19:55:39 +01:00
Benedek Farkas
d2e91853e1 Merge branch '1.10.x' into 1.10.x-to-dev
# Conflicts:
#	src/Orchard.Specs/App.Config
#	src/Orchard.Web.Tests/app.config
#	src/Orchard.Web/Modules/Orchard.Projections/Services/ProjectionManager.cs
#	src/Orchard.Web/Orchard.Web.csproj
#	src/Orchard.Web/Web.config
#	src/Orchard.Web/packages.config
2025-01-17 19:39:55 +01:00
Benedek Farkas
e405f48cad Merge branch 'dev' into 1.10.x-to-dev 2025-01-17 19:27:36 +01:00
Benedek Farkas
32c5f1e821 #8822: Upgrading MailKit to 4.9.0 and consolidating all NuGet packages (#8823)
Some checks failed
Compile / Compile .NET solution (push) Has been cancelled
Compile / Compile Client-side Assets (push) Has been cancelled
* Upgrading MailKit to 4.8.0 and consolidating all NuGet packages

* Upgrading MailKit to 4.9.0 and consolidating dependency package versions
2025-01-17 19:22:19 +01:00
Benedek Farkas
d26e8e47f1 #8232: Adding warnings when a Projection Query has an empty Filter Group (#8813)
Some checks failed
Compile / Compile .NET solution (push) Has been cancelled
Compile / Compile Client-side Assets (push) Has been cancelled
* Projections: Returning empty list of content items instead of every content item when the query has no filters

* Better solution to skip processing empty filter groups, instead of returning nothing when there's an empty filter group

* Code styling and comments

* Code styling in ProjectionPartDriver, QueryPartDriver and ProjectionManager

* Reverting functional change to ignore empty filter groups

* Code styling in AdminController, ProjectionPartDriver and QueryPartDriver

* Adding notification when saving a Query or a ProjectionPart to warn about the effect of an empty filter group

* Fixing that upgrading Newtonsoft.Json 13.x broke the SpecFlow test execution app
2025-01-14 17:22:02 +01:00
Benedek Farkas
6466c3884b Merge branch '1.10.x' into dev
Some checks failed
Compile / Compile .NET solution (push) Has been cancelled
Compile / Compile Client-side Assets (push) Has been cancelled
# Conflicts:
#	src/Orchard.Specs/Hosting/Orchard.Web/Web.config
#	src/Orchard.Web/Core/Orchard.Core.csproj
2024-12-10 09:38:09 +01:00
Benedek Farkas
1c40b8ba93 #8808: Fixing Container admin navigation (#8809)
* Fixing that Core.Containers "Show on admin menu" functionality shouldn't depend on the Orchard.Lists feature

* Moving menu.list.png admin menu icon from Orchard.Lists to Core.Containers as menu.container.png

to fix that Containers should have a default admin menu icon

* Fixing conflict between lists and container admin navicon by applying the unused menu.list-definition.png to lists

* Code styling and removing duplicate code
2024-12-10 09:30:58 +01:00
Benedek Farkas
c35bdb2389 Merge branch '1.10.x-to-dev' into dev 2024-12-08 20:22:22 +01:00
Benedek Farkas
20de85e5b6 Simplifying LinkFieldDriver validation of URL and fragment 2024-12-08 20:19:49 +01:00
Benedek Farkas
7dbc8110fa Fixing notification types in the Navigation AdminController for Save, Publish, Unpublish 2024-12-08 19:37:53 +01:00
Benedek Farkas
1aec856831 Code and comment styling in MainMenuService and LinkFieldDriver 2024-12-08 19:37:09 +01:00
Benedek Farkas
e68d25e46d Fixing merge and consolidating NuGet packages 2024-12-08 13:58:44 +01:00
Benedek Farkas
aa44765825 Merge branch '1.10.x' into 1.10.x-to-dev 2024-12-08 13:31:27 +01:00
Benedek Farkas
c3b98ba3c4 #8819: Compile workflow should run at least one of the SpecFlow tests (#8820)
* Using Title Casing in the Compile workflow's step names

* Adding step to run the Setup with SpecFlow

* Fixing typo

* Fixing that upgrading Newtonsoft.Json to 13.x broke the SpecFlow test execution app
2024-12-07 20:48:21 +01:00
Benedek Farkas
d01c331a9e Fixing that upgrading NHibernate broke the SpecFlow test execution app 2024-12-07 17:56:17 +01:00
Benedek Farkas
18ce08f379 #6986: Media Processing Html Filter (improved) (#8806)
* #6986 Created feature Media Processing Html Filter

* Fixing HtmlAgilityPack and upgrading FW and package version to match Orchard.Specs

* Adapting MediaProcessingHtmlFilter to IHtmlFilter breaking change

* Fixing that Orchard.MediaProcessingHtmlFilter should depend on Orchard.MediaProcessing

* Code styling

* Using regexes instead of HtmlAgilityPack, thanks GHCP

* Updating comments and code styling

* Code styling

* Reworking ProcessContent to use StringBuilder instead of replaces

* Fixing that GetAttributeRegex should find attributes with empty value

* Code styling

* Fixing that detecting the extension works regardless of casing

but it still works with Azure Blob Storage (which is case-sensitive) too

* Optimizing image tag regex

* Caching attribute regexes

* Caching attribute values of img tags

* Simplifying attribute value cache

---------

Co-authored-by: Arjan Noordende <arjan@zumey.com>
2024-12-07 11:59:46 +01:00
Benedek Farkas
5c57a30907 Setting fail-fast to false in the Specflow workflow's strategy
https://docs.github.com/en/actions/writing-workflows/workflow-syntax-for-github-actions#jobsjob_idstrategyfail-fast
2024-12-07 11:10:35 +01:00
Benedek Farkas
ebae790f15 #8276: Updating Npgsql to 4.0.17 and fixing setup with PostgreSQL (#8810)
* Updating Npgsql to version 4.0.17 (the latest minor version of the closest major version that isn't vulnerable)

https://github.com/OrchardCMS/Orchard/security/dependabot/54

* Fixing that Projection Migrations created indexes with the same name in different tables, which is not supported by PostgreSQL
2024-12-06 14:14:57 +01:00
Benedek Farkas
79f66cebf6 #8752: Publish/unpublish Menu Items in the Menu editor (#8807)
* Cleaning up Core/Navigation/Controllers/AdminController

* Extending Core/Navigation/Controllers/AdminController to be able to publish/unpublish menuitems

* Redirecting to menu when saving a menu item and using the menu item text in the notification

* Fixing that saving a menu item shouldn't publish it if it's unpublished

* Using the menu item text in the notification when publishing and unpublishing too
2024-12-06 10:09:52 +01:00
Benedek Farkas
0d93cb1d8d #8816: Compilation workflow should test the setup and code generation (#8817)
* Updating Compile workflow with setup and code generation steps

* Updating NHibernate reference and OrchardBasicCorrectness.ruleset path in ModuleTestsCsProj code generation template

* Ignoring CS2008 warning when recompiling with generated modules, because the theme and test projects don't have .cs files

* Generating a test project should also include packages.config

* Fixing the relative path of Orchard.Core and Orchard.Framework in the generated test project

* A bit of code styling in the Compile workflow

* Updating Readme

* Revert "A bit of code styling in the Compile workflow"

This reverts commit 7b01ebbad0.
2024-12-06 09:59:15 +01:00
Benedek Farkas
8425b4ad76 #8811: Update vulnerable NuGet packages and consolidate them (#8812)
* Updating System.IdentityModel.Tokens.Jwt and its dependencies in Orchard.Azure.MediaServices

* Using System.IO.Compression instead of DotNetZip

* Upgrading Newtonsoft.Json from 12.0.3 (vulnerable) to 13.0.3

* Updating ModuleRootWebConfig.txt codegen template according to the new Newtonsoft.Json version
2024-12-06 09:49:45 +01:00
Benedek Farkas
53f3a19ece #8814: Upgrading NHibernate to 5.5.2 (#8815)
* Upgrading NHibernate to 5.5.2

* Adapting SchemaCommandGenerator to obsolete NHibernate code

* Adapting unit tests to NHibernate breaking change

https://github.com/nhibernate/nhibernate-core/issues/1106
https://github.com/nhibernate/nhibernate-core/issues/1095

* Updating ModuleRootWebConfig.txt codegen template according to the new Newtonsoft.Json and NHibernate version
2024-12-06 09:49:25 +01:00
aaronamm
32e7d862f9 Add AutorouteSettings.AllowSetAsHomePage to control whether user can set a content to display on a home page (#8424)
* Add AutorouteSettings.AllowSetAsHomePage to control whether user can set a content to display on a home page

* Extending the description of the AllowSetAsHomePage setting

* Updating setting label

---------

Co-authored-by: Benedek Farkas <benedek.farkas@lombiq.com>
2024-11-14 17:36:34 +01:00
Andrea Piovanelli
81570fab35 Internal page links validation for LinkField (#8805)
Some checks failed
Compile / Compile .NET solution (push) Has been cancelled
Compile / Compile client-side assets (push) Has been cancelled
* Added page internal references management in LinkField valid urls (e.g. field.Value = "#someId")

* Code refactoring to check LinkField value.
2024-10-29 09:14:13 +01:00
Andrea Piovanelli
6e4fefd873 Content Item published before Custom Form submit event triggers (#8795)
* Moved content item publish before triggering form submit events.
Refreshed the content item passed in the context of rules manager and workflow manager.

* Added version to content manager get call after conditionally publishing the content item.
2024-05-17 09:33:45 +02:00
Andrea Piovanelli
fc8b681b4e Ambiguity in LocalizedTaxonomyController action names (#8785)
* Removed ambiguity to LocalizedTaxonomyController actions.

* Properly added ApplyPreRequest to the action.

* Code refactoring

* Code autoformatting

* Sorting using

* Overriding GetTaxonomy action

* Calling base GetTaxonomy action

* Removing ApplyPreRequest function

* Removed ApplyPreRequest function

* Added virtual keyword to GetTaxonomy action in LocalizedTaxonomyController

---------

Co-authored-by: Benedek Farkas <benedek.farkas@lombiq.com>
2024-05-16 17:16:43 +02:00
Benedek Farkas
86bcf413e7 Merge remote-tracking branch 'origin/1.10.x' into dev 2024-05-03 15:33:22 +02:00
Benedek Farkas
0d9fccb624 Fixing WebDownloaderTests 2024-05-03 15:33:07 +02:00
Benedek Farkas
62038ed1bb #6981: Normalized image profile path hash and added profile purging (#8788)
* #6981 Normalized image profile path hash and added profile purging

* Profile purge functions rather belong in IImageProfileService

* Deleting an Image Profile now also removes all its files too

* Comment formatting

* Caching the value of the "Orchard.MediaProcessing.NormalizePath" app setting in ImageProfileManager

* Code styling in ImageProfileManager

* Formatting and code styling ImageProfileManager

---------

Co-authored-by: Arjan Noordende <arjan@zumey.com>
2024-05-03 15:19:20 +02:00
Benedek Farkas
6eab0a1260 Merge branch '1.10.x' into 'dev' through the 'issue/8791' integration branch (the previous commit was a squash merge by mistake) 2024-04-19 16:50:55 +02:00
Benedek Farkas
e60a845359 #8791: Merge 1.10.x into dev (#8792)
* 6748: Stricter file and folder name validation (#6792)

* Media Library: More strict file and folder name validation, fixes #6748

* Resetting MediaLibraryService changes to 1.10.x

* Code styling in FileSystemStorageProvider

* Adding string file and folder name validation to FileSystemStorageProvider, so that MediaLibrary components don't need to do it separately

* Applying the same file and folder name validation to AzureFileSystem too

* Code styling and fixes in AzureFileSystem, MediaLibrary and IStorageProvider

* Simplifying invalid character detection

* Code styling

* Adding InvalidNameCharacterException to be able to handle invalid characters precisely at various user-facing components

* Updating MediaLibrary not to log an error when a file can't be uploaded due to invalid characters

---------

Co-authored-by: Lombiq <github@lombiq.com>

* #6793: Adding a content-independent culture selector shape for the front-end (#8784)

* Adds a new CultureSelector shape for front-end

* fixed query string culture change

* Moving NameValueCollectionExtensions from Orchard.DynamicForms and Orchard.Localization to Orchard.Framework

* Code styling

* Simplifying UserCultureSelectorController and removing the addition of the culture to the query string

* EOF empty lines and code styling

* Fixing that the main Orchard.Localization should depend on Orchard.Autoroute

* Code styling in LocalizationService

* Updating LocalizationService to not have to use IEnumerable.Single

* Matching culture name matching in LocalizationService culture- and casing-invariant

---------

Co-authored-by: Sergio Navarro <jersio@hotmail.com>
Co-authored-by: psp589 <pablosanchez589@gmail.com>

* #8640: Fixing consistency between different Enumeration Field flavors' data storage (#8789)

* Reworking EnumerationField's logic to store/retrieve its (selected) values

* Fixing exception when creating new item with CheckboxList flavor, adding more nullchecks and compactness

* Code styling in EnumerationFieldDriver

* Code styling in EnumerationField editor template

* Fixing that EnumerationFieldDriver and the EnumerationField editor template should read SelectedValues instead of Values directly

---------

Co-authored-by: Matteo Piovanelli <MatteoPiovanelli-Laser@users.noreply.github.com>

* Fixing merge

---------

Co-authored-by: Lombiq <github@lombiq.com>
Co-authored-by: Sergio Navarro <jersio@hotmail.com>
Co-authored-by: psp589 <pablosanchez589@gmail.com>
Co-authored-by: Matteo Piovanelli <MatteoPiovanelli-Laser@users.noreply.github.com>
2024-04-19 15:48:17 +02:00
Benedek Farkas
23fb9dff92 Fixing merge 2024-04-19 15:34:59 +02:00
Benedek Farkas
0bce8e634b Merge branch '1.10.x' into issue/8791
# Conflicts:
#	src/Orchard.Web/Modules/Orchard.Azure/Services/FileSystems/AzureFileSystem.cs
#	src/Orchard.Web/Modules/Orchard.Localization/Module.txt
#	src/Orchard.Web/Modules/Orchard.Localization/Orchard.Localization.csproj
#	src/Orchard.Web/Modules/Orchard.Localization/Services/LocalizationService.cs
#	src/Orchard.Web/Modules/Orchard.MediaLibrary/Controllers/ClientStorageController.cs
2024-04-19 12:38:53 +02:00
Benedek Farkas
0faf196f74 #6193: IHtmlFilter and TokenFilter improvements and bugfixes (fixing auto-merge) (#8790) 2024-04-19 11:59:21 +02:00
Sipke Schoorstra
cf4335e5ba #6193: IHtmlFilter and TokenFilter improvements and bugfixes (#6938)
* IHtmlFilter and TokenFilter improvements and bugfixes.

This changeset unifies the two separate TokenFilter implementations (one for BodyPart, TextField, etc and another one for certain elements such as Html).
It also fixes a bug with the TokenFilter when executing for HtmlWidget, where the wrong content item is being recorded by the handler (the original implementation).
Thirdly, it removes awkward code repetition by moving filter execution into a dedicated HtmlFilterRunner service.

* Renaming IHtmlFilterRunner to IHtmlFilterProcessor (and its references)

* Applying IHtmlFilterProcessor to HtmlMenuItems too + code styling in BodyPartDriver

* Fixing FeedControllerTests.CorePartValuesAreExtracted

* Code styling

---------

Co-authored-by: Jean-Thierry Kéchichian <jean-thierry.kechichian@wanadoo.fr>
Co-authored-by: Sipke Schoorstra <sipke@ideliverable.com>
Co-authored-by: Benedek Farkas <benedek.farkas@lombiq.com>
2024-04-19 11:20:32 +02:00
Benedek Farkas
fdbb06ba8d #8640: Fixing consistency between different Enumeration Field flavors' data storage (#8789)
* Reworking EnumerationField's logic to store/retrieve its (selected) values

* Fixing exception when creating new item with CheckboxList flavor, adding more nullchecks and compactness

* Code styling in EnumerationFieldDriver

* Code styling in EnumerationField editor template

* Fixing that EnumerationFieldDriver and the EnumerationField editor template should read SelectedValues instead of Values directly

---------

Co-authored-by: Matteo Piovanelli <MatteoPiovanelli-Laser@users.noreply.github.com>
2024-04-19 11:11:47 +02:00
Benedek Farkas
15cad85d1e #6793: Adding a content-independent culture selector shape for the front-end (#8784)
* Adds a new CultureSelector shape for front-end

* fixed query string culture change

* Moving NameValueCollectionExtensions from Orchard.DynamicForms and Orchard.Localization to Orchard.Framework

* Code styling

* Simplifying UserCultureSelectorController and removing the addition of the culture to the query string

* EOF empty lines and code styling

* Fixing that the main Orchard.Localization should depend on Orchard.Autoroute

* Code styling in LocalizationService

* Updating LocalizationService to not have to use IEnumerable.Single

* Matching culture name matching in LocalizationService culture- and casing-invariant

---------

Co-authored-by: Sergio Navarro <jersio@hotmail.com>
Co-authored-by: psp589 <pablosanchez589@gmail.com>
2024-04-18 23:35:48 +02:00