当前位置:网站首页>Introduction to the extension implementation of SAP Spartacus checkout process
Introduction to the extension implementation of SAP Spartacus checkout process
2022-07-07 05:56:00 【Wang Zixi】
Spartacus Medium checkout Characteristic is CMS Driven , It means checkout Every page in the stream is based on CMS page 、slots and Component. therefore , Development can change the content of each page 、 Add new components 、 take checkout Convert to single step checkout , Or you can create a very complex multi-step application with only a small amount of configuration in the storefront Application checkout workflow .
stay checkout In the process , There are usually links from one step to another , This is to put each checkout The page is registered as semantic page
Why .
checkout The default routing configuration of is as follows :
provideConfig({
routing: {
routes: {
checkout: {
paths: ['checkout'],
},
checkoutShippingAddress: {
paths: ['checkout/shipping-address']
},
checkoutDeliveryMode: {
paths: ['checkout/delivery-mode']
},
checkoutPaymentDetails: {
paths: ['checkout/payment-details']
},
checkoutReviewOrder: {
paths: ['checkout/review-order']
}
},
},
}),
Location of the above code :default-routing-config.ts
Although the default checkout There are four steps , But the default configuration defines five semantic pages . This additional page has a general checkout route , It links to each that should be redirected to checkout The components of . From this routine checkout page ,Spartacus Redirect to Specific and correct
Of checkout step step .
If you want to link to checkout, Then whatever your checkout How is the process specifically designed , Point to this general checkout page . such as , For multi-step checkout, have access to CheckoutGuard To redirect to the correct checkout step .
Through one step checkout, You can set all components on this checkout route , And delete from the component configuration CheckoutGuard.
In addition to routing configuration , You can also define the responsibilities of each step 、 The route to the page and the sequence of steps are configured checkout. The default configuration is as follows :
id Attribute should have a unique value . When a specific step in the configuration needs to be identified , have access to id.
stay
CheckoutProgress
Used in components name Property to indicate which checkout steps have been completed . This name is also used as a translation key .routeName Attribute specifies the semantic page for each step .
type Attribute from
checkout guards
Use .
边栏推荐
- 上海字节面试问题及薪资福利
- Go 语言的 Context 详解
- PTA ladder game exercise set l2-004 search tree judgment
- mac版php装xdebug环境(m1版)
- Flinksql 读写pgsql
- Flask1.1.4 Werkzeug1.0.1 源码分析:启动流程
- Dynamic memory management
- 目标检测中的损失函数与正负样本分配:RetinaNet与Focal loss
- [cloud native] what is the microservice architecture?
- MySQL performance_ Schema common performance diagnosis query
猜你喜欢
Hcip seventh operation
Differences and introduction of cluster, distributed and microservice
话说SQLyog欺骗了我!
Dynamic memory management
苹果cms V10模板/MXone Pro自适应影视电影网站模板
集群、分布式、微服務的區別和介紹
上海字节面试问题及薪资福利
Digital IC interview summary (interview experience sharing of large manufacturers)
力扣102题:二叉树的层序遍历
How to improve website weight
随机推荐
Type de texte de commutation d'entrée et de mot de passe de l'applet natif
毕业之后才知道的——知网查重原理以及降重举例
SQLSTATE[HY000][1130] Host ‘host. docker. internal‘ is not allowed to connect to this MySQL server
数字IC面试总结(大厂面试经验分享)
pytorch_ 01 automatic derivation mechanism
【FPGA教程案例14】基于vivado核的FIR滤波器设计与实现
mac版php装xdebug环境(m1版)
Pytorch builds neural network to predict temperature
得物客服一站式工作台卡顿优化之路
SAP ABAP BDC (batch data communication) -018
PTA ladder game exercise set l2-002 linked list de duplication
async / await
What is message queuing?
Flask1.1.4 werkzeug1.0.1 source code analysis: start the process
How much do you know about clothing ERP?
STM32按键状态机2——状态简化与增加长按功能
目标检测中的损失函数与正负样本分配:RetinaNet与Focal loss
C. colonne Swapping [tri + Simulation]
Polynomial locus of order 5
Question 102: sequence traversal of binary tree