-
Notifications
You must be signed in to change notification settings - Fork 814
Umbraco Commerce v15.1.0-rc release notes #6859
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 3 commits
b928ed7
35880f9
96a8d1e
fecd43c
c1e8b51
11121cb
be6425a
9070e35
90235cb
1a1a4a2
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,44 @@ | ||
| --- | ||
| description: Learn how to configure a cart cleanup routine. | ||
| --- | ||
|
|
||
| # Configuring Cart Cleanup | ||
|
|
||
| {% hint style="info" %} | ||
| Available from Umbraco Commerce 15.1.0 | ||
| {% endhint %} | ||
|
|
||
| By default Umbraco Commerce will keep all created carts indefinately. Over time this can obviously become an issue. To assist with this is it possible to configure a cart cleanup routine to delete carts older than a pre-configured time interval. | ||
|
Check warning on line 11 in 15/umbraco-commerce/how-to-guides/configuring-cart-cleanup.md
|
||
|
|
||
| This service can be enabled and configured in the `appSettings.json` | ||
|
|
||
| ```json | ||
| { | ||
| "Umbraco" : { | ||
| "Commerce": { | ||
| "CartCleanupPolicy": { | ||
| "EnableCleanup": true, | ||
| "KeepCartsForDays": 800, | ||
| // Below settings are optional | ||
| "FirstRunTime": string; the time to first run the scheduled cleanup task, in crontab format | ||
| "Period": string; how often to run the task, in timespan format | ||
| // Configure diffrent policies per store | ||
mattbrailsford marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| "PerStorePolicies": { | ||
| "StoreAlias": { | ||
| "KeepCartsForDays": 800, | ||
| } | ||
| } | ||
| } | ||
| } | ||
| } | ||
| } | ||
| ``` | ||
|
|
||
| ## Cart Conversion Rates Widget | ||
|
|
||
| When enabling the cart cleanup service, it's important to know that this can affect the cart conversion rates widget in the analytics section. If the widget is configured to show a time period that exceeds the cleanup policies time frame then a warning will be displayed. | ||
|
|
||
|  | ||
|
|
||
|
|
||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,82 @@ | ||
| --- | ||
| description: Order Line Actions UI Extension for Umbraco Commerce | ||
| --- | ||
|
|
||
| # Order Line Actions | ||
|
|
||
| {% hint style="info" %} | ||
| Available from Umbraco Commerce 15.1.0 | ||
| {% endhint %} | ||
|
|
||
| Order Line Actions allow you to display buttons against each order line of a cart / order allowing you to perform custom actions per order line. | ||
mattbrailsford marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
|  | ||
|
|
||
| ## Registering an Order Line Action | ||
|
|
||
| ```typescript | ||
| import { UcManifestOrderLineAction } from "@umbraco-commerce/backoffice"; | ||
|
|
||
| export const manifests : UcManifestOrderLineAction[] = [ | ||
| { | ||
| type: 'ucOrderLineAction', | ||
| kind: 'default', | ||
| alias: 'My.OrderLineAction.MyOrderLineAction', | ||
| name: 'My Order Line Action', | ||
| weight: 300, | ||
| forEntityTypes: [ 'uc:cart', 'uc:order' ], | ||
| api: () => import('./my-order-line-action.api.js'), | ||
| meta: { | ||
| label: "#orderLineActions_myOrderLineAction", | ||
| icon: 'icon-star' | ||
| } | ||
| } | ||
| ]; | ||
|
|
||
| extensionRegistry.register(manifests); | ||
| ``` | ||
|
|
||
| Each entry must have a type of `ucOrderLineAction` along with a unique `alias` and `name`. Unless you wish to override the button, the `kind` key should be set to `default`. An `api` key should be defined that imports the implementation of the `UcOrderLineActionApi` interface. | ||
mattbrailsford marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| A `meta` entry provides configuration options for order line actions: | ||
|
|
||
| | Name | Description | | ||
| | -- | -- | | ||
| | `label` | A label for this action (supports the `#` prefix localization string syntax) | | ||
| | `icon` | In icon to display for the action | | ||
|
|
||
| ## The Order Line Action API | ||
|
|
||
| In order to define the logic to perform when an order line action button is clicked, you'll need to implement the `UcOrderLineActionApi` interface. This interface is defined as | ||
|
|
||
| ```typescript | ||
| export interface UcOrderLineActionApi extends UmbApi { | ||
| manifest: UcManifestOrderLineAction; | ||
| storeId: string; | ||
| orderId: string; | ||
| orderLineId: string; | ||
| execute(): Promise<void>; | ||
| } | ||
| ``` | ||
|
|
||
| This provides order line action implementations with access to the defined `manifest` and contextual information via the `storeId`, `orderId` and `orderLineId` properties and expects the implementation of an `execute` method to act. | ||
|
Check warning on line 62 in 15/umbraco-commerce/key-concepts/ui-extensions/order-line-actions.md
|
||
mattbrailsford marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| An example implementation would be | ||
|
|
||
| ```typescript | ||
| // my-order-line-action.api.js | ||
|
|
||
| import { UcOrderLineActionApi, UcManifestOrderLineAction } from "@umbraco-commerce/backoffice"; | ||
| import { UmbControllerBase } from "@umbraco-cms/backoffice/class-api"; | ||
|
|
||
| export default class MyOrderLineActionApi extends UmbControllerBase implements UcOrderLineActionApi { | ||
| manifest!: UcManifestOrderLineAction; | ||
| storeId!: string; | ||
| orderId!: string; | ||
| orderLineId!: string; | ||
| async execute() { | ||
| console.log(`You clicked ${this.manifest!.meta.label} for order line ${this.orderLineId}`); | ||
| return Promise.resolve(); | ||
| } | ||
| } | ||
| ``` | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,43 @@ | ||
| --- | ||
| description: Umbraco Commerce v15.1.0-RC release notes. | ||
| --- | ||
|
|
||
| # v15.1.0-RC | ||
|
|
||
| ## Key Takeaways | ||
|
|
||
| * [Cart Cleanup Service](v15.1.0-rc.md#cart-cleanup-service). | ||
| * [Order Line Actions](v15.1.0-rc.md#order-line-actions) | ||
|
|
||
| ## Cart Cleanup Service | ||
|
|
||
| The cart cleanup service is a new background service that periodically cleans up old abandoned carts. This service is off by default, but can be enabled via app settings. | ||
|
|
||
| ```json | ||
| { | ||
| "Umbraco" : { | ||
| "Commerce": { | ||
| "CartCleanupPolicy": { | ||
| "EnableCleanup": true, | ||
| "KeepCartsForDays": 800 | ||
| } | ||
| } | ||
| } | ||
| } | ||
| ``` | ||
|
|
||
| See the [Configuring Cart Cleanup guide](../how-to-guides/configuring-cart-cleanup.md) for more details. | ||
|
|
||
| ## Order Line Actions | ||
|
|
||
| Order line actions are a new UI extension point that lets you register custom buttons to display against each order line of a cart / order. | ||
mattbrailsford marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
|  | ||
|
|
||
| See the [Order Line Actions docs](../key-concepts/ui-extensions/order-line-actions.md) for more details. | ||
|
Check warning on line 37 in 15/umbraco-commerce/release-notes/v15.1.0-rc.md
|
||
mattbrailsford marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| ## What to Test and How to Give Feedback | ||
|
|
||
| We welcome any feedback on installation or upgrade issues, as well as any bugs found in the sections mentioned above. | ||
|
|
||
| Issues can be raised on the Umbraco Commerce issue tracker at [https://github.com/umbraco/Umbraco.Commerce.Issues/issues](https://github.com/umbraco/Umbraco.Commerce.Issues/issues). | ||
Uh oh!
There was an error while loading. Please reload this page.