Skip to content

Commit

Permalink
Document the removal of PopulateSettings in 1.9 release notes
Browse files Browse the repository at this point in the history
Fix #15397
  • Loading branch information
MikeAlhayek committed Mar 28, 2024
1 parent 1e3874d commit 50729e6
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions src/docs/releases/1.9.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,29 @@ services.AddJsonDerivedTypeInfo<UrlCondition, Condition>();

In particular, any type introduced in custom modules inheriting from `MenuItem`, `AdminNode`, `Condition`, `ConditionOperator`, `Query`, `SitemapType` will have to use this method.

- The extension `PopulateSettings<T>(model)` was removed from `PartFieldDefinition`. If you are using this method in your code, you'll have to get the settings using the `Settings` object directly. For instance, if you have this code,

```csharp
public override IDisplayResult Edit(ContentPartFieldDefinition partFieldDefinition)
{
return Initialize<NumericFieldSettings>("NumericFieldSettings_Edit", model => partFieldDefinition.PopulateSettings(model));
}
```

You'll change it to the following:

```csharp
public override IDisplayResult Edit(ContentPartFieldDefinition partFieldDefinition)
{
return Initialize<NumericFieldSettings>("NumericFieldSettings_Edit", model =>
{
var settings = partFieldDefinition.Settings.ToObject<NumericFieldSettings>();
model.Hint = settings.Hint;
// ...
});
}
```

### Media Indexing

Previously, `.pdf` files were automatically indexed in the search providers (Elasticsearch, Lucene or Azure AI Search). Now, if you want to continue to index `.PDF` file you'll need to enable the `OrchardCore.Media.Indexing.Pdf` feature.
Expand Down

0 comments on commit 50729e6

Please sign in to comment.