put obj or product id in the cart?
– cw use obj
– obj is big to transfer
. much smaller compare with cw obj
– not convenient if operate with product id, ie. need to parse them again
– what if the product changed? at least the price
– to keep all the obj info or just part of it?
. comments are not needed
. detail description not needed
. just header / attribute /…
– how to save the obj?
. use json?
– save storage space
– what people did is just select the product, select the attribute, select the amount,
– so better to parse the info.
how to address the shipping fee?
– shipping fee can be reduced for the same store when purchase multiple items
– leave notes to store
– multiple store purchase in 1 cart
– can leave notes to the order?
. who will be the person to take care of it?
. so just notes to each store
– how to address the discount for each store?
– how to use the credit?
– how to address anonymous user?
. keep all the info in client only?
. update to server once the user registered?
is cart mandatory?
– cw use cart
– anonymous user?
– everybody can purchase, mean everybody has cart, so no need to create it
how about the ds?
– just make it store level?
– what needed by the server side?
about the purchase now
– add2cart and then move to the shopping cart page for next step
– ie. move to the on ui
about the shopping cart page
– what does it do?
– user review the item in the cart
– user do adjustment, ie. change the amount, remove items, leave comments
– recalculate the price
– recalculate the shipping fee
– ready to move to next step
– shipping in the same page?
. it’s related with the items over there
. it’s linked to the address, ie. address change, the fee will be changed
. enter the address and then calculate the shipping fee
. 2 things: address & fee
. need to consider the separate package for the same store?
. shipping is calcualted automatically, need the info from the shipping company
. auto detect the address?
– do shipping together or do the ON first and then do shipping?
. do ON first to simplify the work
– for the ON ui, get it from db or from file?
. db is good for people to modify, does people need to modify them frequently?
– no, this part is not customizable
=> use template for ON ui
– ds from the server
storeId, storeName, storeLogo
productId, productName, productImage, price, amount, shipping fee
total price, total shipping fee
– how to add property to the object?
. add it directly
– how to add it via each iteration?
. create another object and copy
– too much
. use another obj for extra info
– not good for iteration in client side
. can use index
– next step of shopping cart
. change of the amount will go to server or after click confirm?
. delete icon for the page
. what if people change icon and then go to other place?
– use local storage?
– update server each time?
. too many update
-> there won’t be too many as the change is
– will delete update server?
. better to do it this way
– how to determine which warehouse is the right one?
. by distance?
– normally for sure by 就近原则
– also depends, for example at the border of country
. by priority?
. own rule
– is it too heavy to calculate the shipping price?
. check all warehouse to get the to_address
. check sku-> warehouse -> store -> warehouse to get the from address
. check store for ship company
. check shipping company with (from, to, weight, size, shipCompany) to get the price
any other good idea?
– do it at the shipping/cart ui
– click to get shipping fee
– rough shipping fee
– use city instead of specific warehouse address
– do it in client?
. client to get it for product page
. anyhow the product need to retrieve product & store info
. server to handle it in shipping/cart ui
– anything can be cached?
– calculate the total shipping fee
. if all product use the same warehouse, then can go with this,
. otherwise, need to group them by the warehouse, and then do pricing
. if there is only 1 prod for the store, then no need to recalculate
. if each product are from different warehouse, then no need to recalculate
. is it too complicated for the single warehouse and single city?
=> leave it to later phase
– how to handle the weight unit?
. to be simple, use the same weight unit, ie. g for weight, cm for length
. do it later if need to have individual weight unit,