我正在迁移经典ui对话框以触摸ui对话框,我迁移了父组件对话框,我观察到AEM也显示了子组件中的父对话框选项卡和属性.在现有的经典ui对话框中,它不会继承父属性,而在触摸ui中则不会.
我们如何通过阻止对话继承来实现触摸ui中相同的经典ui行为.
如果有人有关于此问题的信息,请分享详细信息.
我在模板中添加了一个段落系统组件,试图模拟Geometrixx的contentPage.一切都很好,但我不能将任何组件拖入系统,因为没有要添加.我能错过什么?
更多信息:
<cq:include path="par" resourceType="foundation/components/parsys"/>
在Adobe AEM(以前称为CQ5)中,基础组件parsys的design_dialog允许用户设置"Cell Padding".无论在文本字段中输入什么值,都会显示在设计css中.
例如:
鉴于当前页面正在使用/ etc/designs/my-design,页面输出将包含对/etc/designs/my-design.css样式表虚拟路径的引用.
如果用户将parsys cell padding配置为30px,那么my-design.css文件将包含以下内容:
.page_full .par div.section {
padding: 30px;
}
Run Code Online (Sandbox Code Playgroud)
字符串"30px"存储在名为div.padding的jcr:content/page/par/section属性中,但是,我无法弄清楚parsys.jsp如何将其注入my-design.css.
编辑:
要清楚,currentDesign.writeCssIncludes(pageContext);基础页面headlibs.jsp中的调用是设置css包含的代码,如下所示:
<link href="/etc/designs/my-design/static.css" rel="stylesheet" type="text/css"/>
<link href="/etc/designs/my-design.css" rel="stylesheet" type="text/css"/>
Run Code Online (Sandbox Code Playgroud)
但是,目前尚不清楚如何将自己的CSS包含在/etc/designs/my-design.css请求的响应主体中.
我通过为每个添加_rep_policy.xml文件向/ home/groups和/ home/users添加了一些额外的ACL,但似乎无法让它们部署.我将以下行添加到我的vault filter.xml中
<filter root="/home/users/rep:policy" mode="replace"/>
<filter root="/home/groups/rep:policy" mode="replace"/>
Run Code Online (Sandbox Code Playgroud)
两者都有这样的内容:
<?xml version="1.0" encoding="UTF-8"?>
<jcr:root xmlns:jcr="http://www.jcp.org/jcr/1.0" xmlns:rep="internal"
jcr:primaryType="rep:ACL">
<allow
jcr:primaryType="rep:GrantACE"
rep:principalName="everyone"
rep:privileges="{Name}[jcr:read]"/>
</jcr:root>
Run Code Online (Sandbox Code Playgroud)
但是当我运行maven时,我可以看到它们周围的一切都被部署,但不是这两个.如果我尝试直接通过包管理器安装包,它只有在我将访问控制处理设置为"替换"时才有效.我不知道如何在maven中配置它.
我想知道是否有一种方法可以在CQ5中获取页面节点的呈现HTML输出,而无需点击实际的URL.我有页面节点,我想在java中以编程方式获取该页面节点的呈现HTML输出,并将其存储在字符串中,而不会访问页面URL.
任何帮助表示赞赏,提前谢谢!
我知道AEM在成功验证后如何创建名为"login-token"的cookie.
我的问题是AEM如何在每个请求中验证此cookie?是否有任何过滤器可用于拦截请求然后验证cookie?如果没有,那么AEM如何再次调用吊索认证处理程序?
我在这里找不到http:// host:port/system/console/status-slingfilter
请帮我澄清一下
这是我的第一个AEM项目,我在一个正在工作的组件中上传图像,如果我打开组件的设置来更改图像,预览不起作用,如下图所示.
如果我尝试打开图像,/content/xxxDetails/xxx/_jcr_content/par/banner/bannerImage我可以访问图像.
我如何解决预览问题,我认为这是基本问题,但请帮助我,因为这是我的第一个项目.
编辑:cq:对话框
<?xml version="1.0" encoding="UTF-8"?>
<jcr:root xmlns:sling="http://sling.apache.org/jcr/sling/1.0" xmlns:cq="http://www.day.com/jcr/cq/1.0" xmlns:jcr="http://www.jcp.org/jcr/1.0" xmlns:nt="http://www.jcp.org/jcr/nt/1.0"
jcr:primaryType="nt:unstructured"
jcr:title="Properties"
sling:resourceType="cq/gui/components/authoring/dialog">
<content
jcr:primaryType="nt:unstructured"
sling:resourceType="granite/ui/components/foundation/container">
<layout
jcr:primaryType="nt:unstructured"
sling:resourceType="granite/ui/components/foundation/layouts/tabs"
type="nav"/>
<items jcr:primaryType="nt:unstructured">
<banner
jcr:primaryType="nt:unstructured"
jcr:title="Banner Properties"
sling:resourceType="granite/ui/components/foundation/section">
<layout
jcr:primaryType="nt:unstructured"
sling:resourceType="granite/ui/components/foundation/layouts/fixedcolumns"/>
<items jcr:primaryType="nt:unstructured">
<columns
jcr:primaryType="nt:unstructured"
sling:resourceType="granite/ui/components/foundation/container">
<items jcr:primaryType="nt:unstructured">
<headerText
jcr:primaryType="nt:unstructured"
sling:resourceType="granite/ui/components/foundation/form/textfield"
fieldLabel="Heading Text"
name="./header"/>
<SubText
jcr:primaryType="nt:unstructured"
sling:resourceType="granite/ui/components/foundation/form/textarea"
fieldLabel="SubHeading"
name="./subtext"/>
<bannerImage
jcr:primaryType="nt:unstructured"
sling:resourceType="granite/ui/components/foundation/form/fileupload"
autoStart="{Boolean}false"
class="cq-droptarget"
fieldLabel="Banner"
fileNameParameter="./bannerImgName"
fileReferenceParameter="./bannerImgRef"
mimeTypes="[image]"
multiple="{Boolean}false"
name="./bannerImage"
title="Upload Image"
uploadUrl="${suffix.path}"
useHTML5="{Boolean}true"/>
</items>
</columns>
</items>
</banner>
</items>
</content>
</jcr:root>
Run Code Online (Sandbox Code Playgroud)
错误日志
09.05.2017 18:29:15.949 *ERROR* [0:0:0:0:0:0:0:1 …Run Code Online (Sandbox Code Playgroud) 我是Apache Sling,CQ5等的新手.
在我们的代码库中,我们有一个类似于此的代码段:
void perform(SlingHttpServletRequest request, SlingHttpServletResponse response) {
ResourceResolver resourceResolver = request.getResourceResolver();
Session session = resourceResolver.adaptTo(Session.class);
PageManager pageManager = resourceResolver.adaptTo(PageManager.class);
}
Run Code Online (Sandbox Code Playgroud)
什么adapTo在这里做什么?
还有一个很好的文档/用户手册我可以阅读开始使用Sling,CQ5等?
我在作者模式的编辑视图中有一个带有删除按钮的CQ5组件.现在有两种方法可以在页面中包含此组件:
如何在分析中显示组件时,如何将CQ5.5配置为仅显示编辑栏中的删除按钮.当组件通过cq静态包含时:include不应显示删除按钮,因为在这种情况下无法从页面中删除组件.
有任何想法吗?
我只发现了以下CQ5文档,如何从编辑栏中删除删除按钮:http://dev.day.com/docs/en/cq/5-5/developing/components/edit_config.html#cq :actions
如果我不使用布局编辑栏,也会正确显示和隐藏删除按钮:/
我有一个具有如下属性的组件.
@Component(immediate = true, metatype = true, label = "Conf Details")
@Service(value = { LocationConfigurationUtil.class })
@Properties({
@Property(label = "location blueprint", name = "locationPath", value = "", description = "..."),
@Property(label = "location page template", name = "locationTemplate", value = "", description = "..."),
@Property(label = "basepath live copies", name = "liveCopyRoot", value = "/content/WebRoot", description = "...") })
public class LocationConfigurationUtil {
@Activate
protected void activate(Map<String, Object> mapCreated) {
// some code
}
}
Run Code Online (Sandbox Code Playgroud)
为了使它成为jcr节点中的可编辑属性,我使用了非标准方法.我sling:OsgiConfig在路径/apps/system/config中创建了具有在java代码中声明的属性,它工作正常. …