SAP Commerce開發之如何找到某個頁面對應的JSP實現頁面

i042416發表於2020-09-28

For example here below is the product detail page of Hybris Storefront. The requirement is to figure out which JSP page has implemented this UI.


SAP Commerce開發之如何找到某個頁面對應的JSP實現頁面


In some other SAP product it is quite straightforward to achieve. For example in CRM WebClient UI, simply press F2 and we can find the technical name of UI component which implements the current displayed UI.


SAP Commerce開發之如何找到某個頁面對應的JSP實現頁面


In ABAP Webdynpro use “Technical Help” from context menu:


SAP Commerce開發之如何找到某個頁面對應的JSP實現頁面


In SAP Cloud for Customer there is so called “Client Inspector” to fulfill the technical data inspection requirement.


SAP Commerce開發之如何找到某個頁面對應的JSP實現頁面


In Hybris Commerce you can use the following approach to find the implementation JSP file. I still use product detail page as example, based on Hybris 6.5.

(1) logon WCMS cockpit via url: https://localhost:9002/cmscockpit/index.zul Search by keyword “product”, and double click on the search result with name “Product Details”.


SAP Commerce開發之如何找到某個頁面對應的JSP實現頁面


(2) In template detail editor area, write down the name of page template: Product Details Page Template. Also note down the Created Date and Modified Date.


SAP Commerce開發之如何找到某個頁面對應的JSP實現頁面


(3) fire the following flexible search in Hybris Administration Console:

select * from {PageTemplate} where {name} = 'Product Details Page Template'


SAP Commerce開發之如何找到某個頁面對應的JSP實現頁面


In my installation there are more than one page found. Use Created Date and Modified Date I can tell that the last one is what I am looking for.


SAP Commerce開發之如何找到某個頁面對應的JSP實現頁面


then I find the JSP file name here: product/productLayout2Page


SAP Commerce開發之如何找到某個頁面對應的JSP實現頁面


Its fullpath in my laptop:

“C:\Hybris\6.5.0.0.23546\hybris\bin\ext-template\yacceleratorstorefront\web\webroot\WEB-INF\views\responsive\pages\product\productLayout2Page.jsp“


SAP Commerce開發之如何找到某個頁面對應的JSP實現頁面


Or you can also search all cms-content.impex by keyword “Product Details Page Template”:


SAP Commerce開發之如何找到某個頁面對應的JSP實現頁面


As described in the comment, the field frontendTemplateName represents the JSP file name.

要獲取更多Jerry的原創文章,請關注公眾號"汪子熙":

SAP Commerce開發之如何找到某個頁面對應的JSP實現頁面


來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/24475491/viewspace-2724666/,如需轉載,請註明出處,否則將追究法律責任。

相關文章