summaryrefslogtreecommitdiff
path: root/design-documents
diff options
context:
space:
mode:
Diffstat (limited to 'design-documents')
-rw-r--r--design-documents/016-backoffice-order-management.rst130
-rw-r--r--design-documents/017-backoffice-inventory-management.rst3
2 files changed, 86 insertions, 47 deletions
diff --git a/design-documents/016-backoffice-order-management.rst b/design-documents/016-backoffice-order-management.rst
index d53a23a9..1facccd3 100644
--- a/design-documents/016-backoffice-order-management.rst
+++ b/design-documents/016-backoffice-order-management.rst
@@ -67,47 +67,90 @@ An infinity scroll is propose instead of a pagination, reasons:
Create orders
-------------
+this form is divided into 4 sections
+* ``product``: where the merchant can add inventory product and non-inventory
+ product.
-* ``product``: optional, collapsed by default
+* ``price``: where the merchant can override the total price (if product was
+ added) or set the order price and summary.
- * ``name``: search box to select product by description field. if not found it
- will be a 'create new' option leading to the create product without loosing
- context
- * ``quantity``: mandatory
- * ``price``: taken from the product, but it can be overridden.
- * ``add button``: will add the product to the list and calculate the total price
+* ``payment``: where some default of the payment processing can be changed
+* ``extra``: where the merchant can add extra information in JSON format
+
+
+Create order: Product section
+.............................
-* ``amount``: default to the total price of product, but can be overridden. If
- overridden, show a message with the discount in %
+This section has two parts:
-* ``summary``: order description
+The first part will add/remove product from the current stock.
-* ``fulfillment url``: url where the user will land after buying the product
+* ``name``: search box to select product by description field. if not found it
+ will be a 'create new' option leading to the create product without loosing
+ context
-* ``payment``: all values should have default from instance configuration
+* ``quantity``: mandatory
- * ``exchanges``: default value from the instance, new exchanges will be added
- using the url and public key will be taken from querying the url
+The second part will add non inventory product. To add a product a :ref:`create
+product <backoffice-create-product>` form will be shown. The product in the list
+can be edited or deleted from the list.
- * ``auditors``: default value from the instance, new auditors will be added using
- the url and name/pub_key will be taken from querying the url
+In both cases, the total unit and price of the products will be calculated and
+shown in the bottom of the section. If the merchant collapse one of the product
+list a line with a resume of the total price and units will be shown.
+
+.. image:: ../backoffice-order-create.product-section.svg
+ :width: 800
- * ``wire method``: it should select one of supported from exchanges
- * ``refund deadline``: calendar type of input
- * ``pay deadline``: calendar type of input
- * ``auto refund deadline``: calendar type of input
- * ``max fee``: default value from the instance
+Create order: Price section
+...........................
- * ``max wire fee``: default value from the instance
+This section scenarios.
- * ``wire_fee_amortization``: default value from the instance
+The fist one is without products being added: the ``order price`` and
+``summary`` inputs will be shown.
-There were field not considered for this form, check Alternatives for more
-information.
+If there is at least one product added, the ``total products price`` as the sum
+of all products prices will be shown. The ``order price`` will default to
+``total products price``. The ``products taxes`` and ``profit`` will be shown
+since ``order price`` cannot be less that ``product taxes``.
-.. image:: ../backoffice-order-create.svg
+.. image:: ../backoffice-order-create.price-section.svg
+ :width: 800
+
+Create order: Payment section
+.............................
+
+This section show optional values that can be overwritten by the merchant
+
+* ``refund deadline``: calendar type of input. default from instance
+
+* ``pay deadline``: calendar type of input. default from instance
+
+* ``auto refund deadline``: calendar type of input. default empty, optional.
+
+* ``delivery date``: calendar type of input. default empty, optional.
+
+* ``delivery location``: location section similar to instance jurisdiction or
+ instance address. optional
+
+* ``max fee``: default value from the instance
+
+* ``max wire fee``: default value from the instance
+
+* ``wire_fee_amortization``: default value from the instance
+
+.. image:: ../backoffice-order-create.payment-section.svg
+ :width: 800
+
+Create order: all section expanded
+.............................
+
+An example of how all section in a page will be shown.
+
+.. image:: ../backoffice-order-create.all-expanded.svg
:width: 800
@@ -228,20 +271,21 @@ collapsed as default. show disabled if unpaid
refund popup
---------------
+------------
If there is any refund:
* show total refund from ``refund_amount``
-* a + sign to show more information
-* if expanded show a timeline vertically showing amount a reason
- ``refund_details``
+* a (down arrow) to show more information
+* if expanded show table with date, amount and reason
Warn if there is a pending refund when ``refund_pending`` is true
Ask for:
-* amount
+* amount: default 0, show max amount refundable (order amount - already
+ refunded)
+
* reason: concatenation of the next values
* drop down options: duplicated, requested by customer, other
@@ -257,6 +301,7 @@ Example of details by status
----------------------------
+
.. image:: ../backoffice-order-details.paid.svg
:width: 800
@@ -306,17 +351,16 @@ Discussion / Q&A
* Shall we show merchant information from the ContractTerm in the order detail?
-* Order creation was first thought as out of scope but should be useful for
- testing purpose or when frontend is not yet integrated with taler merchant
- backend. Shall we skip it?
-
* Do we have the date and time of when the order goes from these states?
- * claimed => paid (maybe last wire_details.execution_time with confirmed = true )
+ * null => unpaid (using contractTerm.timestamp from now but may not be correct)
+
* unpaid => claimed (maybe contractTerm.timestamp)
-* Refund button is being show if "not refunded" and "time < refund deadline".
- should we consider partial refund?
+ * claimed => paid (maybe last wire_details.execution_time with confirmed = true )
+
+* Refund button is being show if "refund_amount < contract_terms.amount" and "time < refund deadline".
+ Is there any other case? Is this taking into account auto_refund?
* Field left out in the order creation:
@@ -326,12 +370,4 @@ Discussion / Q&A
* contractTerm.merchant_pub: filled by the backend
* contractTerm.merchant_base_url: filled by the backend
* contractTerm.h_wire: defined by the backend
- * contractTerm.delivery_location: not used
- * contractTerm.delivery_date: not used
- * contractTerm.nonce: not used
- * contractTerm.products[].description: defined by product_id
- * contractTerm.products[].description_i18n: defined by product_id
- * contractTerm.products[].unit: defined by product_id
- * contractTerm.products[].image: defined by product_id
- * contractTerm.products[].delivery_date: not used
- * contractTerm.products[].taxes: defined by product_id
+ * contractTerm.nonce: not used \ No newline at end of file
diff --git a/design-documents/017-backoffice-inventory-management.rst b/design-documents/017-backoffice-inventory-management.rst
index e8c1a333..5513dd8b 100644
--- a/design-documents/017-backoffice-inventory-management.rst
+++ b/design-documents/017-backoffice-inventory-management.rst
@@ -49,6 +49,9 @@ Actions will be
* modify
* delete: with a confirm popup, it may fail if have some locked
+
+.. _backoffice-create-product:
+
Create and Update Product form
------------------------------