Skip to content

Commit 678b14c

Browse files
committed
Merge branch 'refs/heads/master' into v15/feature/api-users-and-external-access
# Conflicts: # 15/umbraco-cms/SUMMARY.md
2 parents bc11a6a + 2e613eb commit 678b14c

File tree

34 files changed

+806
-243
lines changed

34 files changed

+806
-243
lines changed

13/umbraco-engage/developers/headless/README.md

Lines changed: 15 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -42,27 +42,24 @@ To install the Umbraco Engage Headless API, follow these steps:
4242
dotnet add package Umbraco.Engage.Headless
4343
```
4444

45-
## Updating Startup.cs
45+
## Updating Program.cs
4646

47-
To update the Startup.cs file, follow these steps:
47+
To update the Program.cs file, follow these steps:
4848

49-
1. Open your `Startup.cs` file.
50-
2. Locate the **ConfigureServices** method.
51-
3. Add the line `.AddMarketingApiDocumentation()` after `.AddDeliveryApi()`. Your ConfigureServices method should look like this:
49+
1. Open your `Program.cs` file.
50+
2. Add the line `.AddEngageApiDocumentation()` after `.AddDeliveryApi()`. Your `CreateUmbracoBuilder` method should look like this:
5251

5352
```cs
54-
public void ConfigureServices(IServiceCollection services)
55-
{
56-
services.AddUmbraco(_env, _config)
57-
.AddBackOffice()
58-
.AddWebsite()
59-
.AddDeliveryApi()
60-
.AddMarketingApiDocumentation()
61-
.AddComposers()
62-
.Build();
63-
}
53+
builder.CreateUmbracoBuilder()
54+
.AddBackOffice()
55+
.AddWebsite()
56+
.AddDeliveryApi()
57+
.AddEngageApiDocumentation()
58+
.AddComposers()
59+
.Build();
60+
6461
```
6562

66-
4. Rebuild and run your site.
67-
5. Navigate to **/umbraco/swagger** in your browser.
68-
6. From the top right definition dropdown, check for the **Umbraco Engage Marketing API.**
63+
3. Rebuild and run your site.
64+
4. Navigate to **/umbraco/swagger** in your browser.
65+
5. From the top right definition dropdown, check for the **Umbraco Engage Marketing API.**

13/umbraco-engage/upgrading/migrate-from-umarketingsuite.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,10 @@ Run this script to migrate all the Umbraco data.
261261

262262
1. Delete any `obj`/`bin` folders in your projects to ensure a clean build.
263263
2. Recompile all projects and ensure all dependencies are restored correctly.
264-
3. Add your new Umbraco Engage [license](../installation/licensing.md) key to the `appSettings.json` file:
264+
3. Contact Umbraco Support for a license key.
265+
1. Look for the speech bubble in the bottom right corner of your screen at [umbraco.com](https://umbraco.com).
266+
2. Click it, and you can open a new support request.
267+
4. Add your new Umbraco Engage [license](../installation/licensing.md) key to the `appSettings.json` file:
265268

266269
```json
267270
"Umbraco": {

14/umbraco-cms/tutorials/add-microsoft-entra-id-authentication.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,12 @@ description: >-
99
This tutorial takes you through configuring Microsoft Entra ID (Azure Active Directory/Azure AD) for the member login on your Umbraco CMS website.
1010

1111
{% hint style="warning" %}
12-
Entra ID conflicts with Umbraco ID which is the main authentication method used on all Umbraco Cloud projects.
12+
Microsoft Entra ID conflicts with Umbraco ID when used for backoffice user logins on Umbraco Cloud projects. This does not affect member logins.
1313

14-
Due to this, we **highly recommend not using Azure AD for backoffice authentication on your Umbraco Cloud projects**.
14+
**We strongly recommend against using Entra ID for backoffice authentication on Umbraco Cloud projects**.
15+
16+
For member authentication, other [External Login Providers](../reference/security/external-login-providers.md), such as Google Auth and OpenIdConnect, are still supported and compatible with Umbraco Cloud.
1517

16-
It is still possible to use other [External Login Providers](../reference/security/external-login-providers.md) like Google Auth and OpenIdConnect, with Umbraco Cloud.
1718
{% endhint %}
1819

1920
## Prerequisites

15/umbraco-cms/.gitbook.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,3 +104,5 @@ redirects:
104104
extending/backoffice-tours: extending/README.md
105105
tutorials/creating-a-backoffice-tour: tutorials/overview.md
106106
extending/packages/types-of-packages: extending/packages/README.md
107+
reference/configuration/nucachesettings: reference/configuration/cache-settings.md
108+
fundamentals/backoffice/property-editors/built-in-umbraco-property-editors/listview: fundamentals/backoffice/property-editors/built-in-umbraco-property-editors/collection.md

15/umbraco-cms/SUMMARY.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@
3030
* [Property Editors](fundamentals/backoffice/property-editors/README.md)
3131
* [Built-in Property Editors](fundamentals/backoffice/property-editors/built-in-umbraco-property-editors/README.md)
3232
* [Image Cropper](fundamentals/backoffice/property-editors/built-in-umbraco-property-editors/image-cropper.md)
33+
* [Block Editors](fundamentals/backoffice/property-editors/built-in-umbraco-property-editors/block-editor/README.md)
34+
* [Block Grid](fundamentals/backoffice/property-editors/built-in-umbraco-property-editors/block-editor/block-grid-editor.md)
3335
* [Data](fundamentals/data/README.md)
3436
* [Users](fundamentals/data/users/README.md)
3537
* [API Users](fundamentals/data/users/api-users.md)
@@ -50,6 +52,7 @@
5052
* [Health Check Guides](extending/health-check/guides/README.md)
5153
* [Content Content Security Policy (CSP)](extending/health-check/guides/contentsecuritypolicy.md)
5254
* [Creating a Custom Database Table](extending/database.md)
55+
* [Creating a Custom Seed Key Provider](extending/creating-custom-seed-key-provider.md)
5356

5457
## Reference
5558

@@ -73,7 +76,7 @@
7376
* [Logging settings](reference/configuration/loggingsettings.md)
7477
* [Maximum Upload Size Settings](reference/configuration/maximumuploadsizesettings.md)
7578
* [Models builder settings](reference/configuration/modelsbuildersettings.md)
76-
* [NuCache Settings](reference/configuration/nucachesettings.md)
79+
* [Cache Settings](reference/configuration/cache-settings.md)
7780
* [Package Migration](reference/configuration/packagemigrationsettings.md)
7881
* [Plugins settings](reference/configuration/pluginssettings.md)
7982
* [Request handler settings](reference/configuration/requesthandlersettings.md)
@@ -85,6 +88,7 @@
8588
* [Web routing](reference/configuration/webroutingsettings.md)
8689
* [Querying & Models](reference/querying/README.md)
8790
* [ITagQuery](reference/querying/itagquery.md)
91+
* [UmbracoContext helper](reference/querying/umbraco-context.md)
8892
* [Routing & Controllers](reference/routing/README.md)
8993
* [Routing in Umbraco](reference/routing/request-pipeline/README.md)
9094
* [IContentFinder](reference/routing/request-pipeline/icontentfinder.md)
@@ -97,6 +101,7 @@
97101
* [Management API](reference/management-api/README.md)
98102
* [External Access](reference/management-api/external-access.md)
99103
* [Cache & Distributed Cache](reference/cache/README.md)
104+
* [Cache Seeding](reference/cache/cache-seeding.md)
100105
* [Examples](reference/cache/examples/README.md)
101106
* [Working with caching](reference/cache/examples/tags.md)
102107

Lines changed: 115 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,115 @@
1+
---
2+
description: A guide to creating a custom seed key provider for Umbraco
3+
---
4+
5+
# Creating a Custom Seed Key Provider
6+
7+
Umbraco uses a lazy loaded cache, which means that content is loaded into the cache on an as-needed basis. However, you may need specific content to always be in the cache. To achieve this you can implement your own custom seed key providers.
8+
9+
There are two types of seed key providers: `IDocumentSeedKeyProvider` for documents and `IMediaSeedKeyProvider` for media. As these interfaces are identical only `IDocumentSeedKeyProvider` is demonstrated in this article.
10+
11+
{% hint style="warning" %}
12+
Seed keys are cached and calculated once. Any documents created after the site has started will not be included in the seed keys until after a server restart.
13+
{% endhint %}
14+
15+
## Implementation
16+
17+
This example implements a `IDocumentSeedKeyProvider` which seeds all the children of a node, in this case blog posts.
18+
19+
1. Create a new class called `BlogSeedKeyProvider` that implements `IDocumentSeedKeyProvider`.
20+
21+
```csharp
22+
using Umbraco.Cms.Infrastructure.HybridCache;
23+
24+
namespace MySite.SeedKeyProviders;
25+
26+
public class BlogSeedKeyProvider : IDocumentSeedKeyProvider
27+
{
28+
public ISet<Guid> GetSeedKeys()
29+
{
30+
}
31+
}
32+
```
33+
34+
Next we'll inject the `IDocumentNavigationQueryService` in order to get the children of the blog node.
35+
36+
```csharp
37+
using Umbraco.Cms.Core.Services.Navigation;
38+
using Umbraco.Cms.Infrastructure.HybridCache;
39+
40+
namespace MySite.SeedKeyProviders;
41+
42+
public class BlogSeedKeyProvider : IDocumentSeedKeyProvider
43+
{
44+
private readonly IDocumentNavigationQueryService _documentNavigationQueryService;
45+
46+
public BlogSeedKeyProvider(IDocumentNavigationQueryService documentNavigationQueryService)
47+
=> _documentNavigationQueryService = documentNavigationQueryService;
48+
49+
{...}
50+
```
51+
52+
3. Parse a hardcoded string to a GUID.
53+
4. Use the `IDocumentNavigationQueryService` to get the children of the blog node.
54+
5. Return their keys as a `HashSet`.
55+
56+
```csharp
57+
public ISet<Guid> GetSeedKeys()
58+
{
59+
var blogRoot = Guid.Parse("a5fdb22d-b7f2-4a59-8c4e-46ed86bde56c");
60+
61+
if (_documentNavigationQueryService.TryGetChildrenKeys(blogRoot, out IEnumerable<Guid> blogPostKeys))
62+
{
63+
return new HashSet<Guid>(blogPostKeys);
64+
}
65+
66+
return new HashSet<Guid>();
67+
}
68+
```
69+
Since this returns it as a set, and all the sets get unioned, we do not have to worry about duplicates.
70+
71+
The final class looks like this:
72+
73+
```csharp
74+
using Umbraco.Cms.Core.Services.Navigation;
75+
using Umbraco.Cms.Infrastructure.HybridCache;
76+
77+
namespace MySite.SeedKeyProviders;
78+
79+
public class BlogSeedKeyProvider : IDocumentSeedKeyProvider
80+
{
81+
private readonly IDocumentNavigationQueryService _documentNavigationQueryService;
82+
83+
public BlogSeedKeyProvider(IDocumentNavigationQueryService documentNavigationQueryService)
84+
=> _documentNavigationQueryService = documentNavigationQueryService;
85+
86+
public ISet<Guid> GetSeedKeys()
87+
{
88+
var blogRoot = Guid.Parse("a5fdb22d-b7f2-4a59-8c4e-46ed86bde56c");
89+
90+
if (_documentNavigationQueryService.TryGetChildrenKeys(blogRoot, out IEnumerable<Guid> blogPostKeys))
91+
{
92+
return new HashSet<Guid>(blogPostKeys);
93+
}
94+
95+
return new HashSet<Guid>();
96+
}
97+
}
98+
```
99+
100+
### Registering the Seed Key Provider
101+
102+
Now that the `BlogSeedKeyProvider` is implemented, it must be registered in the `Startup` class.
103+
104+
```csharp
105+
using MySite.SeedKeyProviders;
106+
using Umbraco.Cms.Infrastructure.DependencyInjection;
107+
using Umbraco.Cms.Infrastructure.HybridCache;
108+
109+
WebApplicationBuilder builder = WebApplication.CreateBuilder(args);
110+
111+
builder.Services.AddSingleton<IDocumentSeedKeyProvider, BlogSeedKeyProvider>();
112+
{...}
113+
```
114+
115+
All blogpost will now be seeded into the cache on startup, and will always be present in the cache.

15/umbraco-cms/fundamentals/backoffice/property-editors/built-in-umbraco-property-editors/block-editor/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ Umbraco CMS currently ships with two Block Editors: the Block List and the Block
1414

1515
## Customizing Block Editors
1616

17-
### [Build custom views for blocks](build-custom-view-for-blocks.md)
17+
### [Creating custom views for blocks](../../../../../tutorials/creating-custom-views-for-blocklist.md)
1818

1919
Learn how to create custom views for the blocks used in your Block Grid or Block List property editors.
2020

Lines changed: 110 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,110 @@
1+
# Collection
2+
3+
`Alias: Umbraco.ListView`
4+
5+
`Returns: IEnumerable<IPublishedContent>`
6+
7+
**Collection** displays a collection of categories when it is enabled on a Document Type with children.
8+
9+
![Collection example](../../../../../../10/umbraco-cms/fundamentals/backoffice/property-editors/built-in-property-editors/images/listview.png)
10+
11+
## Enable collection
12+
13+
If enabled, editors will be able to see multiple children from a collection on a content node that has children. When not enabled, no collection will be shown and all children will be shown in the Content Tree.
14+
15+
![Enable Collection example](../../../../../../10/umbraco-cms/fundamentals/backoffice/property-editors/built-in-property-editors/images/enable-listview.png)
16+
17+
## Settings
18+
19+
![Collection settings example](/14/umbraco-cms/fundamentals/backoffice/property-editors/built-in-umbraco-property-editors/images/list-view-settings.png)
20+
21+
22+
### Page Size
23+
24+
Defines how many child content nodes you want to see per page. This will limit how many content items you will see in your collection. If you set it to 5, then only 5 content items will be shown in the collection.
25+
26+
### Order By
27+
28+
Will sort your collection by the selection you choose in the dropdown. By default it selects "Last edited" and you get the following three columns:
29+
30+
* **Last edited** - When the content node was last edited and saved.
31+
* **Name** - Name of the content node(s).
32+
* **Created by** - This is the user who the content node was created by.
33+
34+
You can add more sorting to this collection by adding more datatypes to the columns in the "Columns Displayed" section.
35+
36+
### Order Direction
37+
38+
You can select order of the content nodes displayed, "Acsending" or "Descending". The order is affected by the "Order By" selection.
39+
40+
### Columns Displayed
41+
42+
It is possible to add more columns to the collection, via adding the properties through the dropdown. These properties are based on the Data Types which are used by the Document Type. It will show up in the dropdown by its alias and not the name on the property.
43+
44+
![Collection property example](../../../../../../10/umbraco-cms/fundamentals/backoffice/property-editors/built-in-property-editors/images/listview-property.png) ![Collection property example](../../../../../../10/umbraco-cms/fundamentals/backoffice/property-editors/built-in-property-editors/images/listview-property-dropdown.png)
45+
46+
Once you have selected a column you want to display, define what its name should be and what kind of value it should display. You can also move the headers around, re-ordering how they should look. This is done by the move icon on the left side of the alias.
47+
48+
The template section is where you define what kind of value you want to display. The value of the column is in the `value` variable.
49+
50+
### Layouts
51+
52+
Collection comes with two layouts by default. A list and a grid view. These views can be disabled if you are not interested in any of them.
53+
54+
{% hint style="info" %}
55+
A minimum of one layout needs to be enabled for Collection to work.
56+
{% endhint %}
57+
58+
You can also make your own layout and add it to the settings. For example, if you wanted to change the width or length of the grid, you will be able to do so.
59+
60+
### Bulk Action Permissions
61+
62+
Select what kind of action is available on the collection.
63+
64+
* **Allow bulk publish** - content only
65+
* **Allow bulk unpublish** - content only
66+
* **Allow bulk copy** - content only
67+
* **Allow bulk move**
68+
* **Allow bulk delete**
69+
70+
### Workspace View icon
71+
72+
Changes the icon in the backoffice of the collection. By default it will look like the image below.
73+
74+
![Collection icon example](../../../../../../10/umbraco-cms/fundamentals/backoffice/property-editors/built-in-property-editors/images/list-icon.png)
75+
76+
### Workspace View name
77+
78+
You can change the name of the collection itself. Default if empty: 'Child Items'.
79+
80+
### Show Content Workspace View First
81+
82+
Enable this to show the Content Workspace View by default instead of the collection's.
83+
84+
## Content Example
85+
86+
### Generic field value
87+
88+
This example uses a generic field on a child item and displays it in the collection. ![Collection content example email](../../../../../../10/umbraco-cms/fundamentals/backoffice/property-editors/built-in-property-editors/images/listview-content-example-email-settings.png)
89+
90+
The `{{ value }}` will take the value of the Email property and display it in the collection, as shown on the image below.
91+
92+
![Collection content example email](../../../../../../10/umbraco-cms/fundamentals/backoffice/property-editors/built-in-property-editors/images/listview-content-example-email.png)
93+
94+
### Member name
95+
96+
First, a Member Picker property needs to be present on the content item. In this example, the `child item` has gotten a Member Picker Data Type with the alias of `isAuthor`.
97+
98+
![Collection member picker](../../../../../../10/umbraco-cms/fundamentals/backoffice/property-editors/built-in-property-editors/images/member-picker.png)
99+
100+
The child item has a member and the value that should be displayed is the name of the picked value. The next step is to reconfigure the template value in the collection setting.
101+
102+
![Collection member picker](../../../../../../10/umbraco-cms/fundamentals/backoffice/property-editors/built-in-property-editors/images/member-picker-settings.png)
103+
104+
This will take the value picked up by the member picker. ![Collection member picker](../../../../../../10/umbraco-cms/fundamentals/backoffice/property-editors/built-in-property-editors/images/picked-member.png)
105+
106+
And display it in the collection. Shown in the example below: ![Collection member picker](../../../../../../10/umbraco-cms/fundamentals/backoffice/property-editors/built-in-property-editors/images/list-member-picked.png)
107+
108+
### Other examples
109+
110+
![Collection other examples](../../../../../../10/umbraco-cms/fundamentals/backoffice/property-editors/built-in-property-editors/images/others.png) ![Collection other examples](../../../../../../10/umbraco-cms/fundamentals/backoffice/property-editors/built-in-property-editors/images/others-result.png)

0 commit comments

Comments
 (0)