You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: 13/umbraco-commerce/how-to-guides/add-item.md
+28-28Lines changed: 28 additions & 28 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,7 @@ description: How-To Guide to add an item to your cart.
4
4
5
5
# Add item to Cart
6
6
7
-
To add an item to the cart, configure Umbraco with a store and add the necessary properties for interaction. Learn more by following the [Getting started with Umbraco Commerce: The Backoffice tutorial](../tutorials/getting-started-with-commerce).
7
+
To add an item to the cart, configure Umbraco with a store and add the necessary properties for interaction. Learn more by following the [Getting started with Umbraco Commerce](../getting-started/umbraco-configuration.md).
8
8
9
9
You will need the front end to be set up to allow an item to be added to the cart. This can be done by adding a button to the front end to call the Action to add the item to the cart.
10
10
@@ -30,30 +30,30 @@ var price = product.TryCalculatePrice().ResultOrThrow("Unable to calculate produ
30
30
31
31
The code above does the following:
32
32
33
-
- You need to access the store to access the relevant properties for your product, such as price. The store has a fallback property allowing you to traverse the tree to find the store.
34
-
- You retrieve the product based on the store and a reference for the product. The 'productReference' comes from the Model which is a single product.
35
-
- The Product is returned as a ProductSnapshot which is Umbraco Commerce obtaining the page ID and carrying out necessary processes to bring in the data for further processing.
36
-
- Finally, you need to calculate the price which is then displayed without VAT. This can also be displayed with VAT.
33
+
* You need to access the store to access the relevant properties for your product, such as price. The store has a fallback property allowing you to traverse the tree to find the store.
34
+
* You retrieve the product based on the store and a reference for the product. The 'productReference' comes from the Model which is a single product.
35
+
* The Product is returned as a ProductSnapshot which is Umbraco Commerce obtaining the page ID and carrying out necessary processes to bring in the data for further processing.
36
+
* Finally, you need to calculate the price which is then displayed without VAT. This can also be displayed with VAT.
37
37
38
38
To display this you need to add some markup or at least amend it to include a button to add an item. Add the following to the same file:
@@ -166,12 +166,12 @@ public IActionResult AddToBasket(CartDto cart)
166
166
167
167
The code above does the following:
168
168
169
-
- The `store` variable is used to access the store to get the store ID.
170
-
- A try-catch block captures any errors that may occur when adding the item to the cart, including any validation errors.
171
-
-`order` is used to retrieve the current order if one exists or create a new order against the store found. In the Commerce API, everything is read-only for performance so you need to make it writable to add the product.
172
-
-`AddProduct` is called and `productReference` is passed along with the quantity.
173
-
-`SaveOrder` is called to save the order.
174
-
-`TempData` stores a message to be displayed to the user if the product has been added to the cart.
169
+
* The `store` variable is used to access the store to get the store ID.
170
+
* A try-catch block captures any errors that may occur when adding the item to the cart, including any validation errors.
171
+
*`order` is used to retrieve the current order if one exists or create a new order against the store found. In the Commerce API, everything is read-only for performance so you need to make it writable to add the product.
172
+
*`AddProduct` is called and `productReference` is passed along with the quantity.
173
+
*`SaveOrder` is called to save the order.
174
+
*`TempData` stores a message to be displayed to the user if the product has been added to the cart.
175
175
176
176
{% hint style="warning" %}
177
177
Umbraco Commerce uses the Unit of Work pattern to complete saving the item (`uow.Complete`). When retrieving or saving data ideally you would want the entire transaction to be committed. However, if there is an error nothing is changed on the database.
@@ -187,12 +187,12 @@ Create a new partial view called `Feedback.cshtml`.
187
187
@Html.ValidationSummary(true, "", new { @class="danger" })
Copy file name to clipboardExpand all lines: 13/umbraco-commerce/how-to-guides/overview.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,5 +8,5 @@ In this section, we will provide a series of How-To Guides, showcasing how to pe
8
8
9
9
## Available guides
10
10
11
-
<tabledata-card-size="large"data-view="cards"><thead><tr><thalign="center"></th><thdata-hiddendata-card-targetdata-type="content-ref"></th></tr></thead><tbody><tr><tdalign="center">Migrate from Vendr to Umbraco Commerce</td><td><ahref="migrate-from-vendr-to-umbraco-commerce/">migrate-from-vendr-to-umbraco-commerce</a></td></tr><tr><tdalign="center">Configure SQLite support</td><td><ahref="configure-sqlite-support.md">configure-sqlite-support.md</a></td></tr><tr><tdalign="center">Add item to Cart</td><td><ahref="add-item.md">add-item.md</a></td></tr><tr><tdalign="center">Update Cart</td><td><ahref="update-cart.md">update-cart.md</a></td></tr>
11
+
<tabledata-card-size="large"data-view="cards"><thead><tr><thalign="center"></th><thdata-hiddendata-card-targetdata-type="content-ref"></th></tr></thead><tbody><tr><tdalign="center">Migrate from Vendr to Umbraco Commerce</td><td><ahref="../upgrading/migrate-from-vendr-to-umbraco-commerce/README.md">migrate-from-vendr-to-umbraco-commerce</a></td></tr><tr><tdalign="center">Configure SQLite support</td><td><ahref="configure-sqlite-support.md">configure-sqlite-support.md</a></td></tr><tr><tdalign="center">Add item to Cart</td><td><ahref="add-item.md">add-item.md</a></td></tr><tr><tdalign="center">Update Cart</td><td><ahref="update-cart.md">update-cart.md</a></td></tr>
12
12
<tr><tdalign="center">Delete item from Cart</td><td><ahref="delete-item.md">delete-item.md</a></td></tr><tr><tdalign="center">Limit Order Line Quantity</td><td><ahref="limit-orderline-quantity.md">limit-orderline-quantity.md</a></td></tr><tr><tdalign="center">Use an alternative database for Umbraco Commerce tables</td><td><ahref="use-an-alternative-database-for-umbraco-commerce-tables.md">use-an-alternative-database-for-umbraco-commerce-tables.md</a></td></tr></tbody></table>
Copy file name to clipboardExpand all lines: 13/umbraco-commerce/key-concepts/product-bundles.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -42,4 +42,4 @@ By adding sub-products to a bundle, Umbraco Commerce knows to automatically sum
42
42
43
43
As you can imagine, product bundles could get rather large making it a little difficult to display them in the backoffice. Umbraco Commerce bundles order lines together in a collapsible user interface. This gives you a clear view of your orders whilst still being able to drill into the detail of the items purchased.
44
44
45
-

45
+

Copy file name to clipboardExpand all lines: 13/umbraco-commerce/reference/stores/README.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -79,7 +79,7 @@ Further store configuration can be achieved by setting up different categories o
79
79
80
80
The available configuration options are:
81
81
82
-
***Locations** - Defines different locations for a store. See [Locations reference documentation](broken-reference) for more details.
82
+
***Locations** - Defines different locations for a store.
83
83
***Order Statuses** - Defines the order statuses to be used by a store.
84
84
***Shipping Methods** - Defines the different shipping options available in the store. See [Shipping reference documentation](../shipping/) for more details.
85
85
***Payment Methods** - Defines the different payment options available in the store.
Copy file name to clipboardExpand all lines: 13/umbraco-commerce/release-notes/README.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,7 +9,7 @@ In this section, we have summarized the changes to Umbraco Commerce that were re
9
9
If there are any breaking changes or other issues to be aware of when upgrading they are also noted here.
10
10
11
11
{% hint style="info" %}
12
-
If you are upgrading to a new major version, check the breaking changes in the [Version Specific Upgrade Notes](upgrading/version-specific-upgrades.md) article.
12
+
If you are upgrading to a new major version, check the breaking changes in the [Version Specific Upgrade Notes](../upgrading/version-specific-upgrades.md) article.
Copy file name to clipboardExpand all lines: 13/umbraco-commerce/upgrading/version-specific-upgrades.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,7 +8,7 @@ description: >-
8
8
This page covers specific upgrade documentation for when migrating to major 13 of Umbraco Commerce.
9
9
10
10
{% hint style="info" %}
11
-
If you are upgrading to a new minor or patch version, you can find information about the breaking changes in the [Release Notes](../release-notes.md) article.
11
+
If you are upgrading to a new minor or patch version, you can find information about the breaking changes in the [Release Notes](../release-notes/README.md) article.
0 commit comments