public interface ISrCart
Service that retrieve/create buyer's shopping cart, make cart totals after any line action, etc. This is shared non-transactional service.
| Modifier and Type | Method and Description |
|---|---|
void |
delLine(Map<String,Object> pRvs,
CartLn pCartLn,
TxDst pTxRules)
Deletes cart line.
|
void |
emptyCart(Map<String,Object> pRvs,
Buyer pBuyr)
Empties Cart.
|
Cart |
getCart(Map<String,Object> pRvs,
org.beigesoft.mdl.IReqDt pRqDt,
boolean pIsNeedToCreate,
boolean pIsBuAuth)
Get/Create Cart.
|
void |
hndCartChg(Map<String,Object> pRvs,
Cart pCart,
TxDst pTxRules)
Handle event cart delivering or line changed.
|
void |
hndCurrChg(Map<String,Object> pRvs,
Cart pCart,
AcStg pAs,
TrdStg pTs)
Handle event cart currency changed.
|
void |
mkCartTots(Map<String,Object> pRvs,
TrdStg pTs,
CartLn pCartLn,
AcStg pAs,
TxDst pTxRules)
Refresh cart totals by seller cause line inserted/changed/deleted.
|
void |
mkLine(Map<String,Object> pRvs,
CartLn pCartLn,
AcStg pAs,
TrdStg pTs,
TxDst pTxRules,
boolean pRedoPr,
boolean pRedoTxc)
Makes cart line.
|
AItmPri<?,?> |
revItmPri(Map<String,Object> pRvs,
TrdStg pTs,
Buyer pBuyer,
EItmTy pItType,
Long pItId)
Reveals item's price descriptor.
|
TxDst |
revTxRules(Map<String,Object> pRvs,
Cart pCart,
AcStg pAs)
Reveal shared tax rules for cart.
|
void emptyCart(Map<String,Object> pRvs, Buyer pBuyr) throws Exception
Empties Cart.
pRvs - request scoped varspBuyr - buyerException - - an exceptionCart getCart(Map<String,Object> pRvs, org.beigesoft.mdl.IReqDt pRqDt, boolean pIsNeedToCreate, boolean pIsBuAuth) throws Exception
Get/Create Cart.
pRvs - request scoped varspRqDt - Request DatapIsNeedToCreate - if need to create, e.g. "NO" for deleting item from
cart, "YES" for adding one.pIsBuAuth - buyer must be authorizedException - - an exceptionvoid mkCartTots(Map<String,Object> pRvs, TrdStg pTs, CartLn pCartLn, AcStg pAs, TxDst pTxRules) throws Exception
Refresh cart totals by seller cause line inserted/changed/deleted.
pRvs - request scoped varspTs - TrdStgpCartLn - affected cart linepAs - Accounting SettingspTxRules - NULL if not taxableException - - an exception.TxDst revTxRules(Map<String,Object> pRvs, Cart pCart, AcStg pAs) throws Exception
Reveal shared tax rules for cart. It also makes buyer-regCustomer.
pRvs - request scoped varspCart - cartpAs - Accounting SettingsException - - an exception.void hndCurrChg(Map<String,Object> pRvs, Cart pCart, AcStg pAs, TrdStg pTs) throws Exception
Handle event cart currency changed.
pRvs - request scoped varspCart - cartpAs - Accounting SettingspTs - TrdStgException - - an exception.void hndCartChg(Map<String,Object> pRvs, Cart pCart, TxDst pTxRules) throws Exception
Handle event cart delivering or line changed.
pRvs - request scoped varspCart - cartpTxRules - Tax RulesException - - an exception.void delLine(Map<String,Object> pRvs, CartLn pCartLn, TxDst pTxRules) throws Exception
Deletes cart line.
pRvs - request scoped varspCartLn - cart linepTxRules - Tax RulesException - - an exception.void mkLine(Map<String,Object> pRvs, CartLn pCartLn, AcStg pAs, TrdStg pTs, TxDst pTxRules, boolean pRedoPr, boolean pRedoTxc) throws Exception
Makes cart line. Tax category, price, seller are already done.
pRvs - request scoped varspCartLn - cart linepAs - Accounting SettingspTs - TrdStgpTxRules - NULL if not taxablepRedoPr - redo pricepRedoTxc - redo tax categoryException - - an exception.AItmPri<?,?> revItmPri(Map<String,Object> pRvs, TrdStg pTs, Buyer pBuyer, EItmTy pItType, Long pItId) throws Exception
Reveals item's price descriptor.
pRvs - request scoped varspTs - TrdStgpBuyer - BuyerpItType - Item TypepItId - Item IDException - - an exceptionCopyright © 2019. All rights reserved.