From ef3d735113bf5b65b02cc146481844e31393e86c Mon Sep 17 00:00:00 2001 From: Shahed Nasser Date: Mon, 9 Oct 2023 17:31:32 +0300 Subject: [PATCH] docs: update price list's user guide (#5323) * docs: update price list's user guide * remove import links * hide import prices docs * add double quotes * fix build error * removed import prices section * remove text about import --- www/apps/docs/content/modules/overview.mdx | 12 +- .../{import-prices.mdx => _import-prices.mdx} | 0 .../content/modules/price-lists/overview.mdx | 36 ----- www/apps/docs/content/recipes/b2b.mdx | 20 +-- .../price-lists/{import.mdx => _import.mdx} | 2 +- .../content/user-guide/price-lists/index.md | 1 - .../content/user-guide/price-lists/manage.mdx | 129 ++++++++---------- .../content/user-guide/products/manage.mdx | 17 +-- .../content/user-guide/tips/_category_.json | 9 ++ .../content/user-guide/tips/bulk-editor.mdx | 59 ++++++++ .../content/user-guide/{ => tips}/lists.mdx | 1 - www/apps/docs/sidebars.js | 5 - www/apps/docs/vercel.json | 4 + 13 files changed, 134 insertions(+), 161 deletions(-) rename www/apps/docs/content/modules/price-lists/admin/{import-prices.mdx => _import-prices.mdx} (100%) rename www/apps/docs/content/user-guide/price-lists/{import.mdx => _import.mdx} (98%) create mode 100644 www/apps/docs/content/user-guide/tips/_category_.json create mode 100644 www/apps/docs/content/user-guide/tips/bulk-editor.mdx rename www/apps/docs/content/user-guide/{ => tips}/lists.mdx (99%) diff --git a/www/apps/docs/content/modules/overview.mdx b/www/apps/docs/content/modules/overview.mdx index 9a63f3ca55..62af4b4ffb 100644 --- a/www/apps/docs/content/modules/overview.mdx +++ b/www/apps/docs/content/modules/overview.mdx @@ -141,7 +141,6 @@ Medusa's products configuration allows managing products of different types incl - Create discounts and deals with advanced conditions and rules such as minimum cart quantity or specific products. - Offer free shipping, fixed discount, or percentage discount. - Override product prices using price lists and set special conditions such as specific customer groups. -- Import prices into a price list from a CSV file. @@ -237,7 +236,7 @@ If you have any questions about Medusa, its features, and development with it, f }, ]} /> - -### Import Prices - -Admins can import prices into a price list from CSV files. - -Developers can import the prices from CSV files using the Admin APIs. They can also customize the import strategy. - - - --- ## Understand the Architecture diff --git a/www/apps/docs/content/recipes/b2b.mdx b/www/apps/docs/content/recipes/b2b.mdx index 2128f0117d..4156cfa111 100644 --- a/www/apps/docs/content/recipes/b2b.mdx +++ b/www/apps/docs/content/recipes/b2b.mdx @@ -194,7 +194,7 @@ A price list allows you to set different prices on a set of products for various You can use price lists to set the same price for all B2B customers or different prices for different B2B customers if you’ve organized them into separate customer groups. -You can create a price list through the Medusa admin or Admin REST APIs. You can also import prices into your price list after creating it. +You can create a price list through the Medusa admin or Admin REST APIs. --- diff --git a/www/apps/docs/content/user-guide/price-lists/import.mdx b/www/apps/docs/content/user-guide/price-lists/_import.mdx similarity index 98% rename from www/apps/docs/content/user-guide/price-lists/import.mdx rename to www/apps/docs/content/user-guide/price-lists/_import.mdx index 5e5503a93e..188e2b63b9 100644 --- a/www/apps/docs/content/user-guide/price-lists/import.mdx +++ b/www/apps/docs/content/user-guide/price-lists/_import.mdx @@ -16,7 +16,7 @@ To import prices, you must have the prices in a CSV file. You can see a template :::note -For a list of accepted columns, refer to [this guide](../../modules/price-lists/admin/import-prices.mdx#csv-file). +For a list of accepted columns, refer to [this guide](../../modules/price-lists/admin/_import-prices.mdx#csv-file). ::: diff --git a/www/apps/docs/content/user-guide/price-lists/index.md b/www/apps/docs/content/user-guide/price-lists/index.md index 1a0dbf386e..8d914b3881 100644 --- a/www/apps/docs/content/user-guide/price-lists/index.md +++ b/www/apps/docs/content/user-guide/price-lists/index.md @@ -28,4 +28,3 @@ In the list, you can see price list details such as the name, description, and s ## Learn More About Price Lists - [Manage a Price List](./manage.mdx) -- [Import Prices](./import.mdx) diff --git a/www/apps/docs/content/user-guide/price-lists/manage.mdx b/www/apps/docs/content/user-guide/price-lists/manage.mdx index 92a7c45769..4f64a45b8d 100644 --- a/www/apps/docs/content/user-guide/price-lists/manage.mdx +++ b/www/apps/docs/content/user-guide/price-lists/manage.mdx @@ -15,66 +15,50 @@ In this document, you’ll learn how to create, update, and delete price lists a To create a price list: 1. Go to the Pricing page. -2. Click on the “Add price list” button at the top right. +2. Click on the “Create New” button at the top right. -This opens the form to create the price list in a new window. The form is split into different sections. +This opens the form to create the price list in a new window. The form is split into different steps. -### Price List Type +### Step 1: Create Price List -In this section, choose the type of the price list. It can be either a Sale or an Override. +In this step, enter the price list's general information: -### General - -In this section, enter the name and description of the price list. Both fields are required. - -### Configuration - -In this section, you can choose some optional configurations that determine how the price list will be applied: - -1. To specify the start or end dates: - 1. Toggle the “Price overrides has a start date” or “Price overrides has an expiry date” fields. - 2. Choose the date and time. -2. To specify customer groups that this price list will be applied for: +1. Under the Type section, choose the type of the price list. It can be either Sale or Override. +2. Under the General section, enter the name and description of the price list. +3. To specify a start date for the price list: + 1. Toggle the "Price list has a start date?" field. + 2. A "Start date" field will show. Choose a start date using it. +4. To specify an expiry or end date for the price list: + 1. Toggle the "Price list has an expiry date?" field. + 2. A "End date" field will show. Choose a start date using it. +5. To limit the price list to specific customer groups: 1. Toggle the “Customer availability” field. - 2. In the Customer Groups field, choose at least one customer group. + 2. A table is shown where you can select the customer groups that the price list is applied to. -### Prices +Once you're done, click the Continue button at the top right. -In this section, you must choose at least one product and specify the prices you want to apply to at least one of its variants. +### Step 2: Choose Products -1. To add product prices: - 1. Click on the “Add Products Manually” button. - 2. Choose at least one product from the list. - 3. Click the Save button. The products will then be seen under the Prices section. - 4. For each product you added: - 1. Click on the icon at its right. - 2. To add the same price for all variants: - 1. Click on the icon next to any of the variants. - 2. Choose “Edit Prices” from the dropdown. - 3. In the new window, choose the “Apply on all variants” option. - 4. Enter the price for each currency. - 5. Click on the “Save and close” button. - 3. To add a price for each variant: - 1. Click on the icon next to a variant. - 2. Choose “Edit Prices” from the dropdown. - 3. In the new window, choose the “Apply overrides on selected variants” option. - 4. Choose the variants that you want to apply the current pricing to. - 5. Enter the price for each currency. - 6. Click on the “Save and close” button. - 4. To remove a variant from the price list: - 1. Click on the icon next to the variant. - 2. Click on "Remove from List" from the dropdown. -2. To remove products from the prices list: - 1. Click on the “Add Products Manually” button. - 2. Uncheck the products you previously added and want to remove. - 3. Click on the Save button. +In this step, choose the products that you want to adjust their pricing using this price list. You can choose a product by ticking the box at the left of its row. You can also search through products using the search box at the top right. + +Once you're done, click the Continue button at the top right. + +### Step 3: Edit Prices + +In this step, you can change the prices of each variant of the products you chose in the second step. To do that: + +1. Click on the "Add prices button" at the right side of a product. +2. This will open the bulk editor to edit the prices of the product's variant. Learn more about tips to using the bulk editor in [this guide](../tips/bulk-editor.mdx). +3. For each variant, you can specify a price per currency or region. +4. Once you're done, click on the "Save Prices" button at the top right. +5. Keep repeating the process for all products in the price list. ### Save the Price List -To save the price list you can either: +After editing the prices of all products in the price list, you can save the price list by either: -1. Click the “Save as draft” button to save the price list without publishing it; -2. Or click the “Publish price list” button to save and publish the price list. +1. Clicking the “Save as Draft” button at the top right button to save the price list without publishing it; +2. Or clicking the “Save and Publish” button to save and publish the price list. --- @@ -99,48 +83,48 @@ To change a price list’s status: 1. Go to the Pricing page. 2. Click on the icon next to the price list. -3. Based on the current status, click on the Unpublish or Publish links in the dropdown to change the status. +3. If the price list is a draft, click on "Mark as active" in the dropdown to publish it. Otherwise, if the price list is active or published, click on the "Mark as draft" in the dropdown to unpublish it. --- -## Edit Price List’s Configurations +## Edit Price List’s Details -To edit a price list’s information and configurations: +To edit a price list’s details: 1. Go to the price list’s details page. 2. Click on the icon in the first section. -3. Choose “Edit price list details”. -4. This opens a form in a new window that has the [same sections as the Create Price List form](#create-a-price-list), except for the Prices section. You can edit the price list’s general information, customer groups, and start and end dates. -5. Once you’re done making changes, click on the Save changes button. +3. Choose “Edit details” from the dropdown. +4. This opens a form as a side window. The form has the same fields explained in [step one of creating a price list](#step-1-create-a-price-list). +5. Make the necessary edits to the price list's details. +6. Once you’re done , click on the Save button. --- ## Manage Prices -### Add Product Prices +### Add Products -To add new product prices: +To add new products to the price list: 1. Go to the price list’s details page. 2. In the Prices section, click on the icon. -3. Click on “Edit manually” in the dropdown. -4. This opens a new window with a form similar to the [Prices section in the Create form](#prices). You can search for or manually add products. -5. Once you’re done, click on the “Save changes” button. +3. Click on “Add products" in the dropdown. +4. This opens a new window with the same form as [step two of creating a price list](#step-2-choose-products). +5. Choose products you want to ad to the price list, then click the Continue button at the top right. +6. The next step has the same fields explained in [step three of creating a price list](#step-3-edit-prices). +7. Make changes to the prices of the variants of the new product(s). +8. Once you’re done, click on the "Submit and Close" button. ### Edit a Product’s Prices To edit the prices in the price list: 1. Go to the price list’s details page. -2. Find the product you want to edit in the Prices section. -3. Click on the icon next to it. -4. Choose “Edit prices” from the dropdown. -5. In the new window: - 1. Click on the icon next to the product’s name to expand the list of variants. - 2. Click on the icon next to the variant you want to edit. - 3. Edit the prices of the variant for each currency. - 4. Once you’re done, click on the “Save and close” button. -6. Once you’re done editing the product’s prices, click on the Save button. +2. In the Prices section, click on the icon. +3. Click on “Edit prices in the dropdown. +4. This opens a new window with the same form as [step three of creating a price list](#step-3-edit-prices). +5. Make changes to the prices of any product's variants in the price list. +6. Once you’re done, click on the “Save changes” button. ### Delete a Product’s Prices @@ -150,12 +134,13 @@ Deleting a product’s prices in a price list cannot be undone. ::: -To delete all the prices of a product in a price list: +To delete a product from a price list and remove the pricing changes as well: 1. Go to the price list’s details page. -2. Find the product you want to edit in the Prices section. +2. Find the product you want to delete in the Prices section. 3. Click on the icon next to it. -4. Click on “Remove product” in the dropdown. +4. Click on “Delete prices” in the dropdown. +5. Confirm deleting the product's prices by clicking the “Confirm” button in the pop-up. --- @@ -172,4 +157,4 @@ To delete a price list: 1. Go to the Pricing page. 2. Click on the icon next to the price list you want to delete. 3. Click on Delete in the dropdown. -4. Confirm deleting the price list by clicking the “Yes, confirm” button in the pop-up. \ No newline at end of file +4. Confirm deleting the price list by entering the price list's name, then clicking the "Confirm" button. diff --git a/www/apps/docs/content/user-guide/products/manage.mdx b/www/apps/docs/content/user-guide/products/manage.mdx index 3c2089dd04..54f207df09 100644 --- a/www/apps/docs/content/user-guide/products/manage.mdx +++ b/www/apps/docs/content/user-guide/products/manage.mdx @@ -5,7 +5,6 @@ addHowToData: true --- import UiIcon from '@site/src/components/UiIcon'; -import getOsShortcut from '@site/src/utils/get-os-shortcut' # Manage Products @@ -244,7 +243,7 @@ To delete a variant: --- -## Edit Product Prices with Bulk Editor +## Edit Product Prices The prices bulk editor allows you to edit the prices of a product's variants using a spreadsheet interface. @@ -254,19 +253,7 @@ To open the prices bulk editor: 2. Click on the icon at the top right of the Variants section. 3. Click on Edit Prices from the dropdown. -This opens the prices bulk editor in a pop-up. Some tips on how to use the bulk editor: - -- To view or hide currencies or regions from the editor: - 1. Click on the View button. - 2. Check or uncheck a currency/region by clicking on it in the dropdown. -- To edit a cell's value, there are two ways: - 1. To edit the value without replacing the existing one, double-click the cell, then enter your new value. - 2. To edit the value by replacing the existing one, click on the cell and start typing your new value. -- After editing a cell's value, you can persist it by either clicking outside the cell or pressing tab -- To delete a value, select the cell then press backspace -- To delete the value of multiple adjacent cells in a column, click on a cell, then drag either up or down to other cells in the same column. Once you've selected all cells you want to delete their values, press backspace -- To apply a value of a cell to other adjacent cells in a column, click on a cell, then drag the blue dot at the corner of that cell either up or down to other cells you want to apply the value to. -- To undo a change you made in the currently selected cell(s), press + Z +This opens the prices bulk editor in a pop-up. You can refer to the [Bulk Editor](../tips/bulk-editor.mdx) user guide to learn tips about how to use the bulk editor. Once you're done making changes, you can save your changes by clicking the "Save and close" button. Then, in the pop-up that opens: diff --git a/www/apps/docs/content/user-guide/tips/_category_.json b/www/apps/docs/content/user-guide/tips/_category_.json new file mode 100644 index 0000000000..cc0cad291b --- /dev/null +++ b/www/apps/docs/content/user-guide/tips/_category_.json @@ -0,0 +1,9 @@ +{ + "position": 2, + "collapsed": false, + "link": null, + "label": "Tips", + "customProps": { + "sidebar_is_group_headline": true + } +} \ No newline at end of file diff --git a/www/apps/docs/content/user-guide/tips/bulk-editor.mdx b/www/apps/docs/content/user-guide/tips/bulk-editor.mdx new file mode 100644 index 0000000000..5a0b037a92 --- /dev/null +++ b/www/apps/docs/content/user-guide/tips/bulk-editor.mdx @@ -0,0 +1,59 @@ +--- +description: "Learn how to use the bulk editor in the Medusa admin and its shortcuts. The bulk editor is available in different areas, including the product details page and the Create Price List form." +--- + +import getOsShortcut from '@site/src/utils/get-os-shortcut' + +# Bulk Editor + +In this document, you'll learn about different tips and shortcuts to using the bulk editor. + +## Overview + +The bulk editor allows you to edit prices or values using a spreadsheet-interface. It simplifies the editing process when working with a large number of data, and provides you with an intuitive user experience. + +The bulk editor is used in different areas of the Medusa admin, including the [Edit Product Prices](../products/manage.mdx#edit-product-prices) form or the [Create Price List](../price-lists/manage.mdx#step-3-edit-prices) form. + +--- + +## Toggle Columns View + +As the bulk editor may include a large number of columns, such as the different currencies supported in your store, you can toggle the columns' visibility to focus on a subset of columns. + +To do that: + +1. Click on the "View" button at the top left. +2. Check or uncheck a column by clicking on it in the dropdown. + +--- + +## Selecting Cells + +You can select multiple cells to apply an action on them. To do that: + +1. Click and hold the mouse on a cell +2. Drag the mouse in the direction of the other cells you want to select. +3. Once you're done selecting, release the hold. + +--- + +## Editing Cells + +There are multiple ways you can edit cells in a bulk editor: + +1. To edit the value without replacing the existing one, double-click the cell, then enter your new value. +2. To edit the value by replacing the existing one, click on the cell and start typing your new value. +3. To apply a value of a cell to other adjacent cells: + 1. Click on a cell + 2. Hold and Drag the blue dot at the corner of that cell to adjacent cells you want to apply the value to. + 3. Once you're done, release the hold on the blue dot. + +--- + +## Shortcuts + +You can use the following shortcuts while working with the bulk editor: + +- tab: Persist the current cell's value and move focus to the next cell. +- backspace: Delete the value of the selected cell(s). +- + Z: Undo a change you made in the currently selected cell(s). \ No newline at end of file diff --git a/www/apps/docs/content/user-guide/lists.mdx b/www/apps/docs/content/user-guide/tips/lists.mdx similarity index 99% rename from www/apps/docs/content/user-guide/lists.mdx rename to www/apps/docs/content/user-guide/tips/lists.mdx index e931712605..716e277505 100644 --- a/www/apps/docs/content/user-guide/lists.mdx +++ b/www/apps/docs/content/user-guide/tips/lists.mdx @@ -1,5 +1,4 @@ --- -sidebar_position: 2 description: 'Learn how to use utility features in the Medusa Admin including lists, quick and advanced filters, pagination, and search functionalities. You can also customize quick features.' --- diff --git a/www/apps/docs/sidebars.js b/www/apps/docs/sidebars.js index aa5950df19..b391905306 100644 --- a/www/apps/docs/sidebars.js +++ b/www/apps/docs/sidebars.js @@ -1148,11 +1148,6 @@ module.exports = { id: "modules/price-lists/admin/manage-price-lists", label: "Admin: Manage Price Lists", }, - { - type: "doc", - id: "modules/price-lists/admin/import-prices", - label: "Admin: Import Prices", - }, ], }, { diff --git a/www/apps/docs/vercel.json b/www/apps/docs/vercel.json index 94f3f13da7..e043a63d65 100644 --- a/www/apps/docs/vercel.json +++ b/www/apps/docs/vercel.json @@ -480,6 +480,10 @@ { "source": "/contribution-guidelines", "destination": "/contribution/docs" + }, + { + "source": "/user-guide/price-lists/import", + "destination": "/user-guide/price-lists" } ], "framework": "docusaurus-2",