VbzCart/docs/pieces/checkout/page 3: Difference between revisions
Jump to navigation
Jump to search
imported>Woozle (Created page with "This shows the general layout of the Order Confirmation page: File:2019-08-29.screenshot.VBZ checkout page 3.png") |
imported>Woozle No edit summary |
||
Line 1: | Line 1: | ||
==About== | |||
This process takes place in <code>/lib/page/ckout/content.php</code>. I've gone back and forth between two possible confirmation processes: | |||
* Render the confirmation from the Cart data; if approved, convert the Cart data into an Order and submit. | |||
** '''Advantages''': creates fewer junk Order records | |||
** '''Disadvantages''': If there's a bug in the order conversion, we might receive different order data than was approved by the user. Also, slightly harder to debug in that the problem shows up a step later | |||
* Convert the Cart data into an order, then render the confirmation page from the Order data. | |||
** '''Advantages''': ensures data integrity between what the customer approves and what we receive | |||
** '''Disadvantages''': creates more junk Order records | |||
Given this, I decided to keep both versions available and make it easy to switch between them. It may be that once the code is more mature/reliable, we will want to switch to the first method (confirm-from-Cart) -- but for now, it seems like the reliability of the second method is needed. Functions: | |||
* <code>RenderConfirm_fromCart()</code> - confirm then convert | |||
* <code>RenderConfirm_fromOrder()</code> - convert then confirm | |||
* <code>RenderConfirm()</code> - dispatcher | |||
==Screenshot== | |||
This shows the general layout of the Order Confirmation page: | This shows the general layout of the Order Confirmation page: | ||
[[File:2019-08-29.screenshot.VBZ checkout page 3.png]] | [[File:2019-08-29.screenshot.VBZ checkout page 3.png]] |
Revision as of 00:56, 21 October 2019
About
This process takes place in /lib/page/ckout/content.php
. I've gone back and forth between two possible confirmation processes:
- Render the confirmation from the Cart data; if approved, convert the Cart data into an Order and submit.
- Advantages: creates fewer junk Order records
- Disadvantages: If there's a bug in the order conversion, we might receive different order data than was approved by the user. Also, slightly harder to debug in that the problem shows up a step later
- Convert the Cart data into an order, then render the confirmation page from the Order data.
- Advantages: ensures data integrity between what the customer approves and what we receive
- Disadvantages: creates more junk Order records
Given this, I decided to keep both versions available and make it easy to switch between them. It may be that once the code is more mature/reliable, we will want to switch to the first method (confirm-from-Cart) -- but for now, it seems like the reliability of the second method is needed. Functions:
RenderConfirm_fromCart()
- confirm then convertRenderConfirm_fromOrder()
- convert then confirmRenderConfirm()
- dispatcher
Screenshot
This shows the general layout of the Order Confirmation page: