且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

SAP Spartacus的Component 请求

更新时间:2022-09-09 20:21:03

请求的url:


https://spartacus-dev0.eastus.cloudapp.azure.com:9002/occ/v2/electronics-spa/cms/components?fields=DEFAULT¤tPage=0&pageSize=26&componentIds=AllBrandsCategoryLink%2CCanonBrandCategoryLink%2CSonyBrandCategoryLink%2CKodakBrandCategoryLink%2CSamsungBrandCategoryLink%2CToshibaBrandCategoryLink%2CFujifilmBrandCategoryLink%2CKingstonBrandCategoryLink%2CIciduBrandCategoryLink%2CTDKBrandCategoryLink%2CSweexBrandCategoryLink%2CDigitalCamerasCategoryLink%2CDigitalCompactsCategoryLink%2CDigitalSLRCategoryLink%2CFilmCamerasCategoryLink%2CHandheldCamcordersCategoryLink%2CWebcamsCategoryLink%2CCameraAccessoriesCategoryLink%2CCamerasFlashesCategoryLink%2CTripodsCategoryLink%2CCameraLensesCategoryLink%2CFlashMemoryCategoryLink%2CPowerSuppliesCategoryLink%2CColourFilmsCategoryLink%2CBlackAndWhiteFilmsCategoryLink%2CBlankVideotapesCategoryLink&lang=en&curr=USD


url decode之后如下:

https://spartacus-dev0.eastus.cloudapp.azure.com:9002/occ/v2/electronics-spa/cms/components?fields=DEFAULT¤tPage=0&pageSize=26&componentIds=AllBrandsCategoryLink,CanonBrandCategoryLink,SonyBrandCategoryLink,KodakBrandCategoryLink,SamsungBrandCategoryLink,ToshibaBrandCategoryLink,FujifilmBrandCategoryLink,KingstonBrandCategoryLink,IciduBrandCategoryLink,TDKBrandCategoryLink,SweexBrandCategoryLink,DigitalCamerasCategoryLink,DigitalCompactsCategoryLink,DigitalSLRCategoryLink,FilmCamerasCategoryLink,HandheldCamcordersCategoryLink,WebcamsCategoryLink,CameraAccessoriesCategoryLink,CamerasFlashesCategoryLink,TripodsCategoryLink,CameraLensesCategoryLink,FlashMemoryCategoryLink,PowerSuppliesCategoryLink,ColourFilmsCategoryLink,BlackAndWhiteFilmsCategoryLink,BlankVideotapesCategoryLink&lang=en&curr=USD


componentIds参数之后,罗列了所有的Component id:SAP Spartacus的Component 请求返回的响应里,包含26个Component的明细数据:SAP Spartacus的Component 请求SAP Spartacus的Component 请求Component 1的name:All Brands Link

url:/Brands/all/c/brands

typecode:CMSLinkComponent

这个Component对应的url如下图所示:SAP Spartacus的Component 请求第二个All Brands Link Component:SAP Spartacus的Component 请求对应的Component url如下图所示:SAP Spartacus的Component 请求第三个Component:SAP Spartacus的Component 请求SAP Spartacus的Component 请求后面的逻辑类似,不一一重复了