Add stereotype as a filter for the contents UI, fix OpenID Configuration initialization and our Open-Source Orchard Core Extensions solution is updated to Orchard Core 1.6! Check out our post for the details!
Orchard Core updates
Add stereotype as a filter for the contents UI
In some cases, we want to create a menu item that would allow the user to manage content items of a specific stereotype. Currently, we only support single content the type but not the stereotype. The goal of this change was to add a query parameter stereotype that would allow us to manage only content items that share the same given stereotype.
To try this out, we have to have some content where the stereotype is defined. We will go the lazy way and edit the existing content definitions of the built-in content types defined by the Blog recipe. We can do that under Content -> Content Definition -> Content Types. We edited the definition of the Blog and the Article content type and set the stereotype value to Test. Now to be able to filter all the content items with the Test stereotype, let's navigate to Content -> Content Items and add the following query string to the URL: stereotype=Test, so the full URL in our case will be the following https://localhost:44300/Admin/Contents/ContentItems?stereotype=Test&admin=-327987887
And as you can see, Orchard Core shows us the content items of the content types where we set the stereotype to "Test". You can read more about this feature in the release notes of the 1.7 release of Orchard Core.
Fix OpenId Configuration initialization
When using the OpenId Server feature along with OpenId Validation and using a custom Authority value, the following exception was thrown:
InvalidOperationException: The issuer attached to the static configuration must be the same as the one configured in the validation options.
You can reproduce the issue by following these steps:
- Enable the OpenId Server and the Validation features.
- Set a new value in the Authority settings in server settings.
- The site becomes useless, and you'll get the above exception.
And as you can see, the fix for this issue is quite interesting. But why would it work by applying these changes? Well, it's due to the fact the issuer comes from potentially multiple places:
- The issuer configured in the validation options (options.Issuer).
- The issuer attached to a static configuration (options.Configuration.Issuer).
- The issuer attached to a dynamic configuration, retrieved using OIDC discovery (accessed via options.ConfigurationManager).
Recent versions of OpenIddict use options.Issuer as the source of truth and now require that the issuer attached to a static configuration - which is the case when you target a "local" server - match the global value, options.Issuer.
News from the community
Updated Lombiq's Open-Source Orchard Core Extensions
This is an Orchard Core Visual Studio solution that contains most of Lombiq's open-source Orchard modules and themes, as well as related utilities and libraries. Please keep in mind that only those extensions included that use the latest released version of Orchard (i.e., the very cutting-edge ones depending on a nightly build are not yet here). And now, this solution has been updated to the latest and greatest 1.6 Orchard Core version. Check them out here, and install them from NuGet or from the source!
Orchard Dojo Newsletter
Lombiq's Orchard Dojo Newsletter has 468 subscribers! We have started this newsletter to inform the community around Orchard of the latest news about the platform. By subscribing to this newsletter, you will get an e-mail whenever a new post is published to Orchard Dojo, including This week in Orchard of course.
Do you know of other Orchard enthusiasts who would like to read our weekly articles? Tell them to subscribe here!