SAP Spartacus OccEndpointsService调用getBaseEndpoint的一些场景
生活随笔
收集整理的這篇文章主要介紹了
SAP Spartacus OccEndpointsService调用getBaseEndpoint的一些场景
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
加上兩處打印信息:
BaseEndpoint由三處信息組成:
一些常見的使用場景:
user-details.effect.ts里獲取id為current的用戶明細
user-token.interceptor.ts: HTTP請求的攔截器
AnonymousConsentsInterceptor
site-context.interceptor.ts
用得最多的就是加載CMS page:
languages.effect.ts
取site language:
currencies.effect.ts
取site currency:
cart.effect.ts
根據購物車id加載購物車數據:
cms-component.connector.ts:
由此可見,OccEndpointsService的直接和間接類的消費者,最多的就是effect和connector.
這個anonymousConsentTemplates被觸發的次數非常非常多:
要獲取更多Jerry的原創文章,請關注公眾號"汪子熙":
總結
以上是生活随笔為你收集整理的SAP Spartacus OccEndpointsService调用getBaseEndpoint的一些场景的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: js如何实现页面跳转_js当前页面跳转
- 下一篇: SAP Spartacus HTTP请求