SAP Commerce Cloud CMS page 和 page template 的概念
CMS pages are laid out according to their page template.
CMS 页面根据其template被布局。
在 SAP Commerce Accelerator项目里,一个page template包含下列内容:
A list of content slots predefined for the template. Template里预定义的content slot列表。
A FrontendTemplateName that corresponds to the name of a JSP that drives the layout of the page. 一个FrontendTemplateName,对应了一个同名的JSP文件,该文件负责定义页面的内容。
A list of PageTypes that the template is restricted to.
比如下图的含义,landing page 1 template只允许包含Content Page和Category Page.
- A VelocityTemplate to specify the layout in SmartEdit.
如何定义一个新的page template
首先定义page template本身:
INSERT_UPDATE PageTemplate;$contentCV[unique=true];uid[unique=true];name;frontendTemplateName;restrictedPageTypes(code);active[default=true]
;;ContentPage2Template;Content Page 2 Template;layout/contentLayout2Page;ContentPage
然后定义content slot:
INSERT_UPDATE ContentSlotName;name[unique=true];template(uid,$contentCV)[unique=true][default='ContentPage2Template'];validComponentTypes(code)
;SiteLogo;;CMSImageComponent,BannerComponent
;HeaderLinks;;CMSLinkComponent,CMSParagraphComponent
;MiniCart;;MiniCartComponent
;NavigationBar;;NavigationComponent
;Section1;;$wideContent
;Section2;;$wideContent
;Section3;;$narrowContent
;Footer;;CMSLinkComponent,CMSParagraphComponent,FooterNavigationComponent
在impex的value区域我们并没有提供template信息,而是使用了默认的ContentPage2Template.
每个content slot都不是能够显示任何类型的Component,而是通过做了指定。比如,SiteLogo contentslot,只允许放置CMSImageComponent和BannerComponent.
Contentslot和page template的从属关系:
INSERT_UPDATE ContentSlotForTemplate;$contentCV;uid[unique=true];position[unique=true];pageTemplate(uid,$contentCV)[unique=true][default='ContentPage2Template'];contentSlot(uid,$contentCV)[unique=true];allowOverwrite
;;SiteLogo-ContentPage2;SiteLogo;;SiteLogoSlot;true
;;HomepageLink-ContentPage2;HomepageNavLink;;HomepageNavLinkSlot;true
;;NavigationBar-ContentPage2;NavigationBar;;NavigationBarSlot;true
;;MiniCart-ContentPage2;MiniCart;;MiniCartSlot;true
;;Footer-ContentPage2;Footer;;FooterSlot;true
;;HeaderLinks-ContentPage2;HeaderLinks;;HeaderLinksSlot;true
这个从属关系也能在Backoffice查看:
更多Jerry的原创文章,尽在:“汪子熙”:
SAP Commerce Cloud CMS page 和 page template 的概念相关推荐
- SAP Commerce Cloud CMS 里的一些元素类型
Content Slots 内容槽是组件的容器.为了在店面中显示组件,您必须将其添加到内容槽中. 共有三种类型的内容槽: 页面内容槽:页面内容槽,也简称为槽,属于它所在的页面,即属于那个页面实例.向槽 ...
- 选择 SAP Spartacus 作为 SAP Commerce Cloud Storefront 实现框架的五个理由
原文:Five Reasons to Move to a Project Spartacus JavaScript Storefront 如果您已经阅读了 SAP Commerce Cloud Pro ...
- 什么是 SAP Commerce Cloud 的 Content Catalog 概念
SAP Commerce Cloud的Content Catalog是一个核心概念,用于管理和组织网站内容.Content Catalog是一个包含页面.组件和其他相关资源的容器,它允许您以结构化和可 ...
- SAP Commerce Cloud SmartEdit 学习笔记
官方文档 SmartEdit 是一个可插拔的 JavaScript 框架,附带一个 UI,使开发人员能够管理现有的网页. SmartEdit 生态系统由共同提供 SmartEdit 产品的 modul ...
- 将您的基于 Accelerator 的 SAP Commerce Cloud Storefront 迁移到 Spartacus Storefront
原文:Migrate Your Accelerator-based Storefront to Project Spartacus 如果您已阅读过"迁移到 Spartacus javascr ...
- 如何安装 SAP Commerce Cloud,以便让 SAP Spartacus 使用
官网链接:https://sap.github.io/spartacus-docs/installing-sap-commerce-cloud-2011/ 分别下载SAP Commerce Cloud ...
- SAP Commerce Cloud Spartacus UI 的购物车 Cart 功能
此功能是在 TUA Spartacus 库的 1.0 版中引入的. 购物车在 TUA Spartacus 与核心 Commerce Spartacus 中的工作方式不同,需要支持产品供应以及复杂的定价 ...
- 关于 Hybris (SAP Commerce Cloud)产品的客户群
下列文字来自百度百科: hybris software成立于1997年,2013年与SAP整合,成为SAP旗下的一份子,提供全渠道客户互动与商务解决方案,该解决方案能够为各机构提供客户的实时背景,借此 ...
- SAP Commerce Cloud ( 电商云 ) 路由路径的自定义配置与开发
这是Jerry 2021年的第 24 篇文章,也是汪子熙公众号总共第 295 篇原创文章. 最近看到 SAP天天事 公众号发布的一篇文章: 基于 SAP Commerce Cloud,老娘舅构建的餐饮 ...
最新文章
- 亚洲最大的元宇宙平台,体验在豪宅里开party
- 不得不爱,Visual Studio Code十大超酷特性
- Intel Realsense C/C++ 转 python rs-align 使用深度颜色映射介绍空间流对齐的概念(转不起来,缺少信息)
- 三维坐标系带偏航角俯仰角_浅谈三维旋转的三种方法及差异
- Cannot subclass final class class com.sun.proxy.$Proxy16
- 比ISA更简单的监管利器,谈谈关于公司上网监管的一点事儿
- 实验3-5 查询水果价格 (15 分)
- C#多线程编程实战(二)
- 数据结构之王道视频中留下的问题
- springboot 整合 mvc 配置外部静态资源
- iOS开发之isa、superclass(课程总结)
- NfcA/NfcB/NfcF/NfcV/IsoDep/Ndef/Mifare/Felica/Pboc/ISOxxxx 标签格式及标准
- linux推流软件推荐,Linux直播推流
- 团队管理,领导的“无为”就是最大“有为”
- ruby on rails中的分页插件Kaminari
- 我的世界电脑版 v1.14.0.68012
- 1《小学数学教材解读策略研究》课题研究方案
- 新的深度学习优化器Ranger: RAdam + LookAhead的协同组合,两者兼得。
- 《计算机网络与因特网》复习纲要
- Bootstrap系列之纵向对齐(Vertical alignment)