Our blog contains the activity stream of Orchard Dojo: general news, new resources or tutorials are announced here.

Featured tags

IIS
API
SMS
SEO
All tags >

User Notifications Improvements, introduce AddUsers extension method - This week in Orchard (06/01/2023)

Happy New Year everyone! Let's start this year with the improvements of the User Notifications feature, new Orchard Core sites, and of course, the latest fixes and improvements for Orchard Core. Check out our post for the details! Orchard Core updates Move role creation into the recipe instead of feature activation Features should not decide which roles are created but only the recipes. Features can decide what are the default permissions for a named role if the role exists. So, here is a summary of the enhancements this brings: We can now use recipe steps to explicitly list the roles we want to use for the site. We are no longer forced to use the default roles. If a role is deleted, it won't come back at some point after installing new features. Currently, even if we delete a role, it could come back after installing more features. If the Roles feature is disabled and re-enabled later, we keep track of permissions history to automatically assign any permission that would not have been assigned previously while the Roles feature is disabled. If an enabled feature introduces new permissions, it'll now get assigned to the proper roles by default "if these roles exist". Introduce the AddUsers extension method This change is about refactoring the logic that adds the specified user-related services to the collection. This is handy if we use OrchardCore.Users outside Orchard Core, something similar to AddPortableObjectLocalization, which registers the required services. Demos User Notifications Improvements The goal of the User Notifications module is to push notifications to the user, meaning notify the user somehow. There are many ways you can notify a user, one of them being a web notification, you can do SMS, you can do push to a mobile application, etc. We wrote about this new feature a few weeks ago in this post. If you head to Configuration -> Features and enable the Email Notifications and Notifications features, you will have a way to notify users and send email notifications to them. You can send notifications using workflows, but you can send them from code of course. The following workflow notifies the owner of the blog post when a blog post is published or deleted. It also notifies the user if the account of the given user is enabled, for example. You can see a bell icon near the Dark mode icon at the top right. If you click on that icon, you will see a list that shows you all of the notifications you have right now. You can click on them to mark them as read, or you can click on All Notifications at the bottom, which will redirect you to the page where you can see all of your notifications. And that's not everything! If you would like to know more, don't forget to check out this recording on YouTube! And if you want to try out this feature for yourself, now you can find the Notifications feature in the preview build of Orchard Core! News from the community New websites using Orchard Core: the site of the game called Transformers: Reactivate and the careers site of Splash Damage Transformers: Reactivate is a 1-4 player online action game developed by Splash Damage, coming to PC & consoles. Splash Damage worked on some of the biggest franchises in the world, with the likes of Batman, Halo, Gears of War, and now Transformers getting the Splash Damage treatment. Check out their careers site here! If you are interested in more websites using Orchard and Orchard Core, don't forget to visit Show Orchard. Show Orchard is a website for showing representative Orchard CMS (and now Orchard Core) websites all around the internet. It was started by Ryan Drew Burnett, but since he doesn't work with Orchard anymore, as announced earlier, it is now maintained by our team at Lombiq Technologies. Orchard Harvest 2023 For those too young to remember, we had Orchard conferences, called Orchard Harvest. And the conference website was available under orchardharvest.org, but unfortunately, it's not anymore. The last one was in 2017 in New York. So, having another get-together is very much overdue. If you would like to see or get a feeling of how this looked like before, we have a couple of mood videos on the Orchard YouTube channel, like this one from the first conference. The point is that we should really think about organizing the next one, and we at Lombiq can take part in that or provide an organizing role with anybody who wants to take part. If you have any feedback or are looking forward to having a Harvest again, please share your opinion by filling out this survey about the upcoming Orchard Harvest! Orchard Dojo Newsletter Lombiq's Orchard Dojo Newsletter has 394 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! If you are interested in more news about Orchard and the details of the topics above, don't forget to check out the recording of this Orchard meeting!

Fluid.Core 2.3.0, add Content Field handlers to enforce validation in the content API - This week in Orchard (23/12/2022)

Fluid.Core 2.3.0, add Content Field handlers to enforce validation in the content API, and please help the community to decide whether to merge the Responsive Admin Theme or not. Check out our last post for this year! Orchard Core updates Fluid.Core 2.3.0 The 2.3.0 version of Fluid.Core is here and merged into Orchard Core. Let's see some of the important changes in this version! The first one is adding support for TimeSpan. Now, if you have a C# TimeSpan object that you pass in a model, it's converted to a DateTime starting from 1970. The second one is adding replace_last and remove_last filters. These are standard Liquid filters that can now be used in Fluid as well. Fluid now targets .NET 7.0. When you go to NuGet.org and search for the Fluid.Core package, you will see that the latest version of this package now also targets .NET 7.0. Let's continue with the one about fixing the case/when tag multi-statements evaluation. In Shopify Liquid a case will return multiple expressions if multiple conditions are met. This can happen because a when can contain multiple values. In Fluid the first condition that is true will return the expression and then exit the case in the same manner that a SQL "case" works. If you check out this screenshot, you can see the Liquid behavior on the Shopify API. Now Fluid supports this behavior. Add Content Field handlers to enforce validation in the content API When creating content using the Contents API, the content is stored as the user sends it without any kind of validation. For example, if you create a type with a required TitlePart, and post a new item with no title, the content item gets created with no title. Here the goal was to implement the ValidatingAsync method in every part/field handler so that way, each part/field is validated against its own settings. Also, add field handlers to be called so we can validate fields. So, to summarize this addition, this is about adding a way to attach handlers for fields. For example: services.AddContentField<TextField>() .UseDisplayDriver<TextFieldDisplayDriver>() .AddHandler<TextFieldHandler>(); // this was added TitlePartHandler was modified to validate the part against the TitlePartSettings. New handlers were added: TextFieldHandler to validate a text field. One handler for each part/field will be added "if it does not exist" which would implement that ValidatingAsync(...) event. This would be part of a follow-up PR to ensure the team is in agreement with the approach and to reduce the code change. News from the community Help the community decide whether to merge the Responsive Admin Theme or not Last month you could see a demo of the Responsive Admin Theme where one can change the look of the forms. Now we need to decide whether we want to merge this PR or not for the reasons explained in the meeting where the feature was demoed (and also in the meeting on 12/20/2022). To vote please use reactions for this comment (not on a new comment please, but you can still comment on the PR on top of it). The limit for the vote will be January 3rd, 2023. Thank you! Christmas in Lombiq Sometimes we do stuff. Together. Not (just) in front of computer screens. These are some usual events in Lombiq that are all announced and arranged in advance. We periodically have an event called RnDay: this is a few hour-long event where we share with each other what we recently worked on and what we plan to do. E.g., If we recently finished a project, then the project's team members demo what they've done. We had our last RnDay for this year in the Aranytíz Budapest, which is an event space where we held this event. And at the end of the day, we visited a nearby restaurant to have dinner together. We would like to thank you all for reading our posts and making the Orchard community stronger together with us! We hope that we can give you valuable news and demos about the happenings around Orchard and Orchard Core from time to time by reading our posts and of course the This week in Orchard newsletter. We would like to wish everyone a Merry Christmas and a Happy New Year with some photos of our latest event! Orchard Harvest 2023 For those who are too young to remember, we had Orchard conferences, called Orchard Harvest. And the conference website was available under orchardharvest.org, but unfortunately, it's not anymore. The last one was in 2017 in New York. So, having another get-together is very much overdue. If you would like to see or get a feeling of how this looked like before, we have a couple of mood videos on the Orchard YouTube channel, like this one from the first conference. The point is that we should really think about organizing the next one, and we at Lombiq can take part in that or provide an organizing role with anybody who wants to take part. If you have any feedback or you are looking forward to having a Harvest again, please share your opinion with us by filling out this survey about the upcoming Orchard Harvest! Orchard Dojo Newsletter Lombiq's Orchard Dojo Newsletter has 379 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 you think would like to read our weekly articles? Tell them to subscribe here! If you are interested in more news about Orchard and the details of the topics above, don't forget to check out the recording of this Orchard meeting!

Fix content types fields dependency, Orchard Core in MS Tech Summit - This week in Orchard (25/11/2022)

Fix content types fields dependency, implement ITicketStore for large cookies, fix OC version used in templates, and an upcoming talk from Lombiq about Orchard Core at the MS Tech Summit conference next week! Check out our post for the details! Orchard Core updates Fix content types fields dependency When we enable the OrchardCore.ContentTypes feature but not enable any feature that composes fields like OrchardCore.ContentFields, the Fields section shows up. Here we should remove the Add Field button when there are no field definitions. Also, if a currently attached field has no definition, we should not be able to edit it, but we should be able to remove it. This can happen if a field was attached to a content type/part while the field definition is available, but then the feature that provides the definition was disabled. Moreover, we should remove the Fields section from the UI if the current content type has no fields and also there are no field definitions. Let's say that we have a site installed with the Blog recipe. This recipe defines a content type called Blog Post which has several content fields attached. These fields are defined by the following modules: Content Fields, Markdown, Media, Taxonomies, etc. So, if we disable all of these features and navigate to Content -> Content Definition -> Content Types -> Blog Post and check out the Fields section, you will see that you can only remove the attached fields and not edit them, furthermore the Add Field button is missing because we have no content field definitions in our site, so, there is no need to display this button because it would only show you an empty list. Implement ITicketStore for large cookies You have the option as an admin user to create a custom role with lots of content types and provide custom permissions to the user. But it could mean that the logged-in user having custom permissions cannot access the admin section as authentication cookie size increases and some web servers have a limit on header sizes (e.g., IIS 16kb, Kestrel 32kb). This introduces the implementation of ITicketStore as an optional feature, when enabled, it will store all claims for the logged-in user on the server's in-memory cache or distributed cache instead of a cookie. Fix OC version used in templates The template default settings are generated on the build. These templates have an OrchardVersion argument that has a default value defined in an MSBuild script to be replaced with the Version property. In the release pipeline, this value will have the VersionSuffix applied to it, like the preview. This fix forces the value of the Version property to be the one in the tag which will prevent preview from being added. This will also fix the templates' default value for OrchardVersion. The pack command uses the Version property only for the packages, and at that point, the template JSON files are already built with the wrong version. News from the community Orchard Core at MS Tech Summit Are you involved in any area (from development to DevOps and cloud to architecture) related to Microsoft technologies? If so, the MS Tech Summit is the event created for you. Close to 50 keynotes, 25 Microsoft MVP award-winning speakers, expo, live streaming, and VoD, all free of charge. Zoltán Lehóczky from Lombiq will give a talk too, about building websites with Orchard Core. Check out the free online conference coming on 2 December to see his talk too! Orchard Harvest 2023 For those who are too young to remember, we had Orchard conferences, called Orchard Harvest. And the conference website was available under orchardharvest.org, but unfortunately, it's not anymore. The last one was in 2017 in New York. So, having another get-together is very much overdue. If you would like to see or get a feeling of how this looked like before, we have a couple of mood videos on the Orchard YouTube channel, like this one from the first conference. The point is that we should really think about organizing the next one, and we at Lombiq can take part in that or provide an organizing role with anybody who wants to take part. If you have any feedback or you are looking forward to having a Harvest again, please share your opinion with us by filling out this survey about the upcoming Orchard Harvest! Orchard Dojo Newsletter Lombiq's Orchard Dojo Newsletter has 379 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 you think would like to read our weekly articles? Tell them to subscribe here! If you are interested in more news around Orchard and the details of the topics above, don't forget to check out the recording of this Orchard meeting!

Add a feature to allow the user to manage tenants, integrating UI testing into Orchard Core - This week in Orchard (18/11/2022)

Let's continue checking out the newest features and editions of the 1.5.0 release of Orchard Core and see a demo about integrating UI testing into Orchard Core! Oh, and did you know that Orchard Core was presented at this year's .NET Conf too? Orchard Core updates Add a feature to allow the user to manage tenants Let's say you have an Orchard Core site set up with the Software as a Service recipe. This recipe allows you to easily create multiple tenants by enabling the necessary features. Here you can see that we have already created two additional tenants called Agency and Blog. We still need to set up the Agency one, but the Blog tenant is ready to go. And here you may notice a new button near the Blog tenant, called Features. By clicking on this button, you will be redirected to a page that allows you to manage the feature of the tenant called Blog. So, if you have a SaaS environment now, you can manage the tenant's features from the host by allowing to accept {tenant?} in the route. This tenant value is only evaluated if the request is running on the host. When a tenant value is present, we'll execute the code in the scope of the given tenant. SqlParser & SqlGrammar subquery support The issue was that the SQL parser did not allow subqueries in the FROM clause. Try to run the following SQL Query, which can be done via Search -> Queries -> Run SQL Query on the admin page of Orchard Core. SELECT Id FROM ( SELECT Id FROM Document) AS Temp The query should run, but instead of that, you encountered an error: Syntax error, expected: id_simple at line:0, col:15. And this has been fixed in Orchard Core 1.5. So, if you run the query with the latest release, you will see that the query was executed successfully. Update YesSql to 3.2.0 A new version of YesSql comes with the latest release of Orchard Core. YesSql now has version number 3.2.0, which provides several improvements and fixes since the latest version shipped with Orchard Core 1.4. Don't forget to take a look at the changes! Demos Integrating UI testing into Orchard Core We would like to show some updates related to integrating UI testing into Orchard Core. This was not the first time, we already talked about this a while ago in this post. And now it's taking shape, so we would like to have some feedback and finish it up together! In this demo, we will talk about this pull request which introduces UI testing to Orchard Core in .NET with Selenium with our library called UI Testing Toolbox. There's already UI testing in Orchard Core with Cypress, this is a bit different, these are not written in JavaScript but in .NET. They use other underlying libraries for browser automation and what will be tested here is a little bit different as well. We implemented everything that was in Cypress before, and there's a lot more now. If you are interested in the progress, you can find it in the PR as well. Now let's see the current progress of the integration! There's a new folder in the Orchard Core solution called OrchardCore.Tests.UI and also an OrchardCore.Tests.UI.Mvc. The Mvc one is just testing an MVC launch, there is no CMS functionality or anything like that and the Tests.UI tests the whole of the Orchard Core feature set. The main goal was to have some decent coverage. So, we are not waiting for an hour to wait for all the UI tests to finish but still, we can be fairly confident that if these pass, then we haven't messed up anything too badly. For example, we have tests for all the built-in recipes (AgencyRecipeTests.cs, BlogRecipeTests.cs, HeadlessRecipeTests.cs, etc.). The most complete one is under the BlogRecipeTests, which runs the whole setup and checks out the basic features of Orchard Core, like login, logout, registration, basic content operations, turning features on and off, etc. If you are interested in how to run these tests or what these tests actually do in action, check out this recording on YouTube! News from the community Orchard Core at .NET Conf 2022 .NET Conf is the biggest .NET virtual event and this year we were celebrating the release of .NET 7. And there was a talk called Build websites with a modern ASP.NET Core CMS – Orchard Core by Zoltán Lehóczky from Lombiq Technologies. In this session, we'll do a quick dive into working with the modern ASP.NET Core framework and web content management system (CMS) Orchard Core. We'll see what Orchard can provide you, how it goes beyond simple content management, and why you'd want to join such a cutting-edge open-source community. You can check out the recording of this session on YouTube! Orchard Harvest 2023 For those who are too young to remember, we had Orchard conferences, called Orchard Harvest. And the conference website was available under orchardharvest.org, but unfortunately, it's not anymore. The last one was in 2017 in New York. So, having another get-together is very much overdue. If you would like to see or get a feeling of how this looked like before, we have a couple of mood videos on the Orchard YouTube channel, like this one from the first conference. The point is that we should really think about organizing the next one, and we at Lombiq can take part in that or provide an organizing role with anybody who wants to take part. If you have any feedback or you are looking forward to having a Harvest again, please share your opinion with us by filling out this survey about the upcoming Orchard Harvest! Orchard Dojo Newsletter Lombiq's Orchard Dojo Newsletter has 381 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 you think would like to read our weekly articles? Tell them to subscribe here! If you are interested in more news around Orchard and the details of the topics above, don't forget to check out the recording of this Orchard meeting!

Orchard Core 1.5.0, adding Feature Profiles support to Auto Setup - This week in Orchard (11/11/2022)

We are thrilled to announce that Orchard Core 1.5.0 is now available! Check out this post to know everything about the latest release of Orchard Core! Now let's see the newest features and editions of the current release that we will continue the whole month! Let's get started! Orchard Core updates CultureInfo should not depend on local computer settings When the library sets the culture using the new CultureInfo(culture), you can get unexpected results if this is also the system's culture and data formats were customized. This could be a problem if the server wants one data format for internal administrative use that's different from the culture's canonical format. For example, you have an en-US server with a date format set to ISO 8601. Then if you want to display a date in Orchard Core with the site set to American locale, it will display it using ISO 8601, which is not what you'd expect. The site's internationalization should not depend on the local format settings. This repro assumes you have Windows 10 with en-US region settings: Steps to reproduce the behavior on Windows: Go to /Admin/Settings/Localization and make sure your site is en-US. Create a new view that contains @T["Date: {0:d}", new DateTime(2022, 02, 21, 12, 0)]. Navigate to it, you will see Date: 2/21/2022. Go to Start Menu > Settings > Time & Language > Region > Change data formats. Change the Short date to "2017-04-05". Restart the server. Visit the same page again, you will see Date: 2022-02-21. And as you may guess, the expected behavior is that you should still see: 2/21/2022. This means that from now on, you can use a new option coming from appsettings.json (IgnoreSystemSettings under the OrchardCore_Localization_CultureOptions section), which is about setting whether to ignore the system culture settings or not. Adding Feature Profiles support to Auto Setup The issue here was that the Auto Setup doesn't support Feature Profiles. The Feature Profiles feature allows the Default tenant to create Feature Profiles which can restrict the features available to a tenant with Feature Rules. Let's say you want to use Auto Setup to set up tenants automatically. You set the FeatureProfile property (like for ShellName, SiteName... "FeatureProfile": "standard-tenant") for a tenant as, it is used by Feature Profiles in Shell Settings. The feature profile is not used for tenant settings, only if you manually configure it from the Default tenant's admin, but the Auto Setup should apply the configuration. If you check out the documentation of the Auto Setup feature, you can see that now you can optionally pass the name of the feature profile used by default. Note, it's only applicable if the Feature Profiles feature is used. Add styles for common ASP.NET validation classes Currently, when we are using common HTML for validation the styles are not applied correctly. Here is an example of code: <div class="mb-3" asp-validation-class-for="DisplayName"> <label asp-for="DisplayName">@T["Display Name"]</label> <input asp-for="DisplayName" class="form-control w-md-25" autofocus /> <span class="hint">@T["Name of the type as it will be displayed on screens."]</span> <span asp-validation-for="DisplayName"></span></div> The <span asp-validation-for="DisplayName"></span> text should be displayed in red. This is because we are missing class styles for field-validation-error. Also, the <div class="mb-3" asp-validation-class-for="DisplayName"> doesn't have any visual distinction. This is maybe because we don't have any class styles for has-validation-error. We should at least provide default styling for these even though it might look "different". Also, at the same time, we should probably make sure that we are consistent in the way that we are implementing these validations throughout the entire Orchard Core admin forms at least. And here, you can see a screen with the updated styles: News from the community Orchard Core 1.5.0 Orchard Core 1.5.0 is now available! If you open up nuget.org and search for the OrchardCore.Application.Cms.Targets package, you will find the updated version of Orchard Core! There is a new page in the documentation with the breaking changes. Upgrade your solution to 1.5.0 now! Feel free to drop on the dedicated Gitter chat and ask questions or use GitHub Discussions! Orchard Harvest 2023 For those who are too young to remember, we had Orchard conferences, called Orchard Harvest. And the conference website was available under orchardharvest.org, but unfortunately, it's not anymore. The last one was in 2017 in New York. So, having another get-together is very much overdue. If you would like to see or get a feeling of how this looked like before, we have a couple of mood videos on the Orchard YouTube channel, like this one from the first conference. The point is that we should really think about organizing the next one, and we at Lombiq can take part in that or provide an organizing role with anybody who wants to take part. If you have any feedback or you are looking forward to having a Harvest again, please share your opinion with us by filling out this survey about the upcoming Orchard Harvest! Orchard Dojo Newsletter Lombiq's Orchard Dojo Newsletter has 383 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 you think would like to read our weekly articles? Tell them to subscribe here! If you are interested in more news around Orchard and the details of the topics above, don't forget to check out the recording of this Orchard meeting!

Orchard Harvest 2023, User Notifications - This week in Orchard (28/10/2022)

Adding default form templates for the Default Theme, adding wrapper element for all content fields, demo about the User Notifications module and don't forget to fill out a survey about the next Orchard Harvest conference! Orchard Core updates Adding default form templates for the Default Theme Currently, all of the form widgets are rendered using Widget.cshtml which renders too much HTML without any added value. The goal here is to create default Widget-Form, Widget-Input, Widget-Label, Widget-Select, Widget-TextArea, Widget-Validation, and Widget-ValidationSummary templates. It means that now, you will find these default form templates if you open up the Default Theme. Adding a wrapper element for all content fields There is no easy way to hide/show content fields "label and input as a group" using JavaScript event because there is no wrapper element to select. The goal here is to add a wrapper element to all of the content fields to allow the user to easily hide/show the entire field block using JavaScript. Here you can see the editor of the Text Field where the wrapper has now new classes with ones that you can easily use to distinguish the same kinds of Text Fields from each other. For example, the Text Field called Subtitle of the built-in Blog Post content type has the following HTML structure. Here you can see that the third class and the ID contain the technical name of the Text Field, which makes targeting the given field easier. Adding GetPageSize method to account for MaxPageSize throughout the code Now we have a new GetPageSize method in the PagerOptions class that returns the maximum number of the allowed page size based on the values of the default and maximum page size numbers. And we are using the value coming from this method for every occurrence, where we are constructing the Pager by passing it as the second parameter. Which is the default page size in this case. Demos User Notifications The goal of the User Notifications module is to push notifications to the user, meaning notify the user somehow. There are many ways you can notify a user, one of them being a web notification, you can do SMS, you can do push to a mobile application, etc. In Orchard Core right now, there is no way to send notifications, but there is a way to send emails. Let's navigate to Configuration -> Features and enable the Notifications module. This will provide a way to notify users. After you enable this module, you will see a new bell icon near the Dark mode icon at the top right. If you click on that icon, you will see a list that shows you all of the notifications that you have right now. You can click on them to mark them as read, or you can click on All Notifications at the bottom, which will redirect you to the page where you can see all of your notifications. Here you can see a list of all of the notifications available. You can use the search here, and filter them only to see the read or the unread notifications. You can sort by recently created, or by previously created. You can also mark the unread notifications as read, mark the read notifications as unread or you can delete the notifications as well. You can also hit the Mark All As Read button to mark everything as read. Now let's see how you can generate notifications! Notifications can be generated via code by injecting INotificationManager. But you can also generate notifications via Workflows. Here you can see we have a workflow called Notify Content Owner, which contains the custom activities provided by the Notifications module. Here we put two events, one for when the Blog Post content item is published and one for when the Article is deleted. And here, you can also see the two new Notify content's owner activities as well. Let's check out the content of the first Notify content's owner activity! Here you can see we have proper Liquid support to customize the summary, and the body of our notification. If we open up the editor of the second Notify content's owner activity, you can see here we have some HTML code in the body as well. To be able to render the HTML properly, don't forget to put a tick in the "The body contains HTML" checkbox. And that's not everything! If you would like to know don't forget to check out this recording on YouTube! And if you want to try out this feature for yourself, you can find the code in this PR! News from the community Orchard Harvest 2023 For those who are too young to remember, we had Orchard conferences, called Orchard Harvest. And the conference website was available under orchardharvest.org, but unfortunately, it's not anymore. The last one was in 2017 in New York. So, having another get-together is very much overdue. If you would like to see or get a feeling of how this looked like before, we have a couple of mood videos on the Orchard YouTube channel, like this one from the first conference. The point is that we should really think about organizing the next one, and we at Lombiq can take part in that or provide an organizing role with anybody who wants to take part. If you have any feedback or are you looking forward to having a Harvest again, please share your opinion with us by filling out this survey about the upcoming Orchard Harvest! Orchard Dojo Newsletter Lombiq's Orchard Dojo Newsletter has 381 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 you think would like to read our weekly articles? Tell them to subscribe here! If you are interested in more news around Orchard and the details of the topics above, don't forget to check out the recording of this Orchard meeting!

New AddDataMigration extension, show the container's header for List Part - This week in Orchard (13/10/2022)

Add notes in the documents on how to configure YesSql, and show Bag Part content when the post request generates errors in the Bag Part. New AddDataMigration extension method, demo about showing the container's header for List Part, and many more are waiting for you in our current post! Orchard Core updates Add notes in the documents on how to configure YesSql We have a page in the Orchard Core documentation that describes how you can run SQL queries by creating a DbConnection instance and obtaining a custom ISqlDialect from IStore from the YesSql namespace in the YesSql.Abstractions package. Or how you can handle prefixed tables. Now this page has been updated with a new section that describes how you can configure YesSql by configuring YesSqlOptions. Show Bag Part content when the post request generates errors in the Bag Part Assume we have a content type (ex., Product) with a Bag Part attached. The user creates new or edits existing products and provides invalid data for items within the Bag Part. The post request fails validation which is great! However, the Bag Part will be rendered in a collapsed state. So, the user is left wondering where the error is until the user uncollapses the Bag Part and sees the highlighted error. The solution here is when rendering the Bag Part, we should uncollapse the Bag Part if there is an error in any of its contents. We can try this one out easily. Let's say we have a site set up with the Agency recipe (that recipe contains the Landing Page content type which has several Bag Parts attached) and edit the content definition of the Service content type. Here we edit the Icon Class Text Field and make it required. Now it's time to edit the predefined Landing Page content item and remove the value of the Icon Class from one of the attached Services. And as you can see here, the Service content type is uncollapsed, making it easier to identify where the error comes from. New AddDataMigration extension The goal of the new AddDataMigration extension is to shorten code like services.AddScoped<IDataMigration, CustomMigrations>(); to services.AddDataMigration<CustomMigrations>();. And if you open up a given Startup.cs file (in our case the one that sits in the AdminDashboard module), you will see the usage of this new extension. Demos Show the container's header for List Part There is a need to extend the look of the default List Part. This would mean that the buttons that allow you to edit the container content item itself and to add contained content items now will be placed in a new line on the top to make the search text box wider. These navigation buttons now appear on every page where List Part or Contained Part are used for easier navigation. Here you can see the updated page of the predefined Blog content item. And if you would like to edit the given Blog content item or create a new Blog Post, you will see these new buttons there as well on the top. But now let's edit the content definition of the Blog content type and hit edit near the attached List Part to edit the List Part itself. Here you can find a new checkbox with a hint "Check this option to show a header for the owning content." Let's put a tick in this checkbox and see what will happen when we navigate back to the list item's view. As you can see, now we have a new line here that shows the header for the owning content, meaning the header of the Blog content item, which just shows "Blog" in this case. This new line is also available on the page where you edit the blog content item itself and on the page where you create a new blog post. But let's do some tricks now! Let's say that we edit the definition of the Blog content type and add a new Media Field to it, called Logo. After we can edit our predefined blog content item and upload an image using our new Media Field. The header is simple by default, but we can override it easily using shapes! Let's say that we want to display that logo in this new line! To do that, we needed to create a new shape template called Content-Blog.Header.cshtml (we are using Razor and the technical name of this content type is Blog). Here you can see that this row contains two columns, and we would like to display the image that is selected by our Media Field called Logo in the first column. And now, the only thing to do is to navigate back to the admin UI of Orchard Core and check out the brand-new look of our Blog! If you want to try this out right now, you will find the code in this pull request. And as always, if you want to see a recording about this feature, this will be your video on YouTube! News from the community Orchard Core Commerce is now available on all DotNest sites Orchard Core Commerce is now available on all DotNest sites! A few weeks ago, we mentioned the current state of the Orchard Core Commerce module and one of the hugest improvements of adding Stripe Payment to the solution. And now you can start building your e-commerce site on DotNest! Check out our announcement for details here. Orchard Dojo Newsletter Lombiq's Orchard Dojo Newsletter has 355 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 you think would like to read our weekly articles? Tell them to subscribe here! If you are interested in more news around Orchard and the details of the topics above, don't forget to check out the recording of this Orchard meeting!

Smithsonian Folkways Recordings now upgraded to Orchard Core - This week in Orchard (06/10/2022)

Provide IConfiguration extensions to configure certain modules, replace StatusCode() when possible, demo about migrating Smithsonian Folkways Recordings to Orchard Core, and many more are waiting for you in our current post! Orchard Core updates GraphQL 4 Now Orchard Core uses GraphQL 4 instead of 2.4.0. The next step would be to update to GraphQL to 7.1.1, which is the latest release currently. Provide IConfiguration extensions to configure certain modules Several modules expose their configuration via IOptions<T> but only include site settings IConfigureOptions<T> for it: Email, Facebook, GitHub, Google, and Reverse Proxy Configuration. These could also provide extension methods like OrchardCore.Shells.Azure does with AddAzureShellsConfiguration() so the configuration can be easily provided by e.g., the appsettings.json file. And now we have these extension methods. If you check out the ConfigureEmailSettings extension method, you can see a sample for that which reads the settings from the appsettings.json file. This means the OrchardCore.Email module allows the user to use configuration values to override the settings configured from the admin area by calling the ConfigureEmailSettings extension method on OrchardCoreBuilder when initializing the app. Replace StatusCode() when possible We have some helper methods that can be used instead of returning StatusCode(). And there is also a new extension method called InternalServerError that produces an InternalServerError response. Demos Smithsonian Folkways Recordings Orchard Core migration For those who are unfamiliar with the Smithsonian Folkways Recordings site, the primary purpose is to showcase music and its cultural impact, as well as to provide related educational content. The news from the world of music is also available in the form of articles, and users can digitally purchase albums and other content as well. Additionally, users can also request licenses to use music for their purposes. The site was recently migrated from Orchard 1.x to Orchard Core and its process includes recreating and reimplementing everything present in the previous application as well as adding some important new features like UI tests. The home page serves navigation purposes for the most part. It shows the latest available content on the site, including new releases, artists, vinyl reissues, news, etc. You can also browse the site by filtering by genre, location, artists, or record labels. Users can use the License request form to request licensed music for their personal uses. You can navigate between the editor groups using the top navigation bar or you can also use the Back and Continue buttons. The data that the user enters is always saved when you click the Continue button, which is by design. There is a song search feature too that can be used to find the song which they would like to license. The registered users of the site can use the LDAP server and NetSuite login options as well for authentication so they don't necessarily need an Orchard Core user account to log in. One of the largest parts of the migration process is data migration which was handled by Jean-Thierry Kéchichian. If you are interested in how he did that or some other technical details, check out this recording on YouTube for more! News from the community Smithsonian Folkways Recordings now upgraded to Orchard Core As you can read, the Smithsonian Folkways Recordings now upgraded to Orchard Core, migrated from Orchard 1.x, and we worked a lot on it too! Here you can check out the case study about the migration process. Orchard Dojo Newsletter Lombiq's Orchard Dojo Newsletter has 356 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 you think would like to read our weekly articles? Tell them to subscribe here! If you are interested in more news around Orchard and the details of the topics above, don't forget to check out the recording of this Orchard meeting!

Orchard Core 1.4.0, Lombiq Base Theme for Orchard Core overview - This week in Orchard (03/06/2022)

We are thrilled to announce that Orchard Core 1.4.0 is now available! Check out this post to know everything about the latest release of Orchard Core! Now let's see the newest features and additions of the current release that we will continue next week too! Let's get started! Orchard Core updates Remove form tag from allowed tags during sanitization Now we explicitly remove the form tag when we do sanitization. The default HtmlSanitizerService doesn't do that, but for security reasons, the community decided to do it. The documentation has been updated as well, so if you want to be able to render the form tags, then you need to configure it. Set security stamp when the user is disabled Disabling a user should invalidate the user's security stamp. When the security stamp validator revalidates the cookie, the user will then be expired. Here you can see the new UserDisabledEventHandler, which calls the UpdateSecurityStampAsync method, to update the security stamp for the user who needs to be disabled. Ignore IUpdateModel and BuildPartDisplayContext in console_log The console_log on FlowPart shape returned logs of C# Runtime objects. To reproduce the bug, you had to follow these steps: Use {{ Model.Content | console_log }} or @Orchard.ConsoleLog((object)Model). Log model containing FlowPart. See the browser's log and find C# Runtime properties logged. The expected behavior would be to just log the shape-related properties and ignore IUpdateModel and BuildPartDisplayContext properties in console_log for shape JSON. Now you can see that the view models for editing and displaying the BagParts and FlowParts gets the IgnoreDataMember, and BindNever attributes to do not log these properties. Demos Lombiq Base Theme for Orchard Core A few weeks ago, we mentioned that our Base Theme for Orchard Core is officially released. After that, we showed how you can use the Resource Management feature to include assets based on different conditions easily and how to construct your home page menu structure using the main navigation name in the Base Theme. Our goal with this Base Theme for Orchard Core is to have all the common things that you usually do when making a theme, like setting up the layout and the zones, setting up variables and mixins, and so on. We hope this makes the whole theme development easier and faster for you. This time we just want to give you a short overview of the other useful features that you can get if you build your own custom Orchard Core theme by using our Base Theme for Orchard Core. The theme has some built-in zones (you have to run the Lombiq Orchard Core Base Theme - Layers and Zones recipe that creates these zones), which could be familiar to you if you used Orchard 1.x in the past because it has the same names as you faced with the default theme of the previous version of Orchard. The theme by default uses a front-end menu which is the same as the admin menu just uses the Main name instead of admin. The Layout.cshtml file of the theme automatically sets up the normal things like the viewport, language, etc, injects the Header, and injects the latest Bootstrap, so it actually overrides the one coming from Orchard Core with the one that you set up in your theme via npm. This is good if you need some features that are newer than the one in the release. You can also find a very tiny JavaScript helper that lets you have a ready event. It makes the library a little bit slimmer. If you would like to know more about this theme, head to YouTube for a demo! News from the community Orchard Core 1.4.0 Orchard Core 1.4.0 is now available! If you open up nuget.org and search for the OrchardCore.Application.Cms.Targets package, you will find the updated version of Orchard Core! There is a new page in the documentation with the breaking changes and the new features. Upgrade your solution to 1.4.0 now! Feel free to drop on the dedicated Gitter chat and ask questions or use GitHub Discussions! Orchard Core Commerce MVP planning and survey A few weeks ago, you could see a nice demo about the Orchard Core Commerce module. And in that blog post, we also mentioned that Lombiq provides stewardship for this module. That actually means that we will do code reviews and work on features and fixes. To have that, Márk Bartha (who is the project leader from our side) started this thread and added this survey. This is about asking the community what the most important features for you would be in an Orchard Core-based e-commerce solution. If you do e-commerce or if you have an opinion about e-commerce, please share your opinion here. The point of this is to try to do not all the things but focus on what is really needed first. Orchard Dojo Newsletter Lombiq's Orchard Dojo Newsletter has 275 subscribers! We have started this newsletter to inform the community around Orchard with 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 you think would like to read our weekly articles? Tell them to subscribe here! If you are interested in more news around Orchard and the details of the topics above, don't forget to check out the recording of this Orchard meeting!

Fixing in the ContentPickerFieldIndexProvider, Lombiq Base Theme for Orchard Core - This week in Orchard (13/05/2022)

Fixing that unpublishing and editing content item with uninitialized ContentPickerField breaks, renaming ReverseProxySettings permission to ManageReverseProxySettings, and our Base Theme for Orchard Core is officially released! Check out our current post to read about the details! Orchard Core updates Rename ReverseProxySettings permission to ManageReverseProxySettings The Reverse Proxy Configuration module enables the configuration of hosting scenarios with a reverse proxy, like enabling the forwarding of the HTTP header X-Forwarded-For and so on. You can manage these options under Configuration -> Settings -> Reverse Proxy, but you need to have the proper permission to do that. Now this permission has a new name, called Manage Reverse Proxy Settings, that you can manage for every role under Security -> Roles. Unpublishing and editing the content item with an uninitialized ContentPickerField breaks If you have a custom ContentPart that contains a ContentPickerField and it's not initialized (so null) and you try to unpublish the content type, it will say it was unpublished, but that won't be true. If you try to edit and publish the same content item, you will get "An unhandled exception occurred while processing the request." error. Dávid El-Saig realized this can be avoided by giving the field a default value (public ContentPickerField Related { get; set; } = new();), but it's easy to miss, and the resulting symptoms are not easy to connect with the true problem. Steps to reproduce the behavior: Create a content type via migration. Start and set up the web app. Create a new content item of the content type. Add a part (e.g. public class RelatedPart : ContentPart { public ContentPickerField Related { get; set; } }) via migration update step. Start up the web app again. Try to unpublish or edit the content item created in step 3. Experience the bug described above. The expected behavior would be that the unpublishing or editing should be successful. And the problem was the following: the if (jPart == null) and if (jField == null) will never be true because if the value is JSON null, it will be a JValue type, so the cast on the preceding line will cause the exception as you can see on the screenshot. This can be fixed if type matching is used instead of casting. And as you can see, there is a new GetContentFields extension that uses the GetContentField extension which contains using the type matching instead of casting. News from the community Lombiq Base Theme for Orchard Core is officially released Our Base Theme for Orchard Core is now officially released! It contains all the foundations to build Orchard themes efficiently with included detailed samples. It can contain any shared content that is not specific to a specific project's theme. You can find the sample module with a commented walkthrough in this repository here. If you want to quickly try out this project and see it in action, clone our Open-Source Orchard Core Extensions full Orchard Core solution and also see our other useful Orchard Core-related open-source projects! We will clone the Lombiq's Open-Source Orchard Core Extensions repository for this demo as well. If you remember, two weeks ago, we mentioned that the Lombiq Helpful Libraries contains an abstract class called MainMenuNavigationProviderBase for creating a home page menu structure using the main navigation name. If you use the Lombiq.BaseTheme, it automatically displays the generated menu as a widget in the Navigation zone. Now it's time to see it in action! Just run our Open-Source Orchard Core Extensions solution and set up your site using the Agency recipe, for example. After that, you can navigate to Design -> Themes and enable the Lombiq Base Theme and Lombiq Base Theme - Samples themes. You can also make the Samples one as the current site theme. Now let's enable some features. Our home page menu structure will display as a widget in the Navigation zone. To have the MenuWidget, we need to enable the Lombiq Helpful Extensions - Helpful Widgets feature. The HelpfulLibrariesNavigationProvider sits in the Samples project of Helpful Libraries, so we have to enable the Lombiq Helpful Libraries - Samples feature as well. Now we can navigate to the home page of our site. The styling looks quite awful, but that's not the point here. As you can see, the Helpful Libraries drop-down now appears with the submenu items that we defined in the Build method. You can see the special LINQ to DB label, and the divider as well. And of course, you have the option to navigate to the given actions to test out the LinqToDbSamplesController that provides some examples of querying the database with Lombiq.HelpfulLibraries.LinqToDb and the TypedRouteController. Orchard Dojo Newsletter Lombiq's Orchard Dojo Newsletter has 247 subscribers! We have started this newsletter to inform the community around Orchard with 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 you think would like to read our weekly articles? Tell them to subscribe here! If you are interested in more news around Orchard and the details of the topics above, don't forget to check out the recording of this Orchard meeting!