cm:content 和 sys:base 有什么区别

发布于 2024-11-27 04:41:16 字数 291 浏览 3 评论 0原文

我创建了一个新的内容模型,并将其继承与 cm:content 关联,以将节点保存为特定文件夹下的内容。

但是,如果我想将内容模型与 sys:base 相关联作为示例怎么办?节点将保存在哪里?如何为节点创建容器?

人员和其他内容不继承自 cm:content,并且我不希望用户从其他位置管理节点,我想确保用户将管理从来自创建的对话框和页面的新内容模型旨在提供类似的服务。

非常感谢您的所有回复

Mohammed Amr 高级系统开发人员 数字系列公司

I create a new content model, and i made its inheritance to be associated with cm:content to save the nodes as content under specific folder.

But, What if i want to associate the content model with sys:base as example ? Where the nodes will be saved ? How to create a container for the nodes ?

Person and other content does not inherit from cm:content, and i don't want the user to manage the nodes from something else where, i want to ensure that the user will manage the nodes created from the new content model from created dialogs and pages designed to serve something like this.

all of your replies is highly appreciated

Mohammed Amr
Senior System Developer
Digital Series Co.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

℉服软 2024-12-04 04:41:16

sys:base 定义于 systemModel.xml 如下(此处显示最后的 HEAD 修订版):

  <type name="sys:base">
     <title>Base</title>
     <mandatory-aspects>
        <aspect>sys:referenceable</aspect>
        <aspect>sys:localized</aspect>
     </mandatory-aspects>
  </type>

通过 systemModel 了解以下两个方面:对于此类强制 类型。 cm:content 间接继承自 sys:base,正如您在 contentModel.xml,通过cm:object 这会带来一些限制并且将仙粉索引到其上。

contentModel 中,您还可以看到 cm:folder 公开了一个名为 cm:contains 的新关联,该关联的目标是 sys:base< /代码> 对象。这意味着在 cm:folder(和子类型)中,您可以存储由 sys:base 启动的层次结构分支中的每种类型,包括 cm:object代码>和<代码>cm:内容。

这应该足以向您展示如何:

  • 创建允许特定子类型的容器,
  • 在存储方面,cm:contentsys:base 之间没有太大区别cm:folder 类型中的此类类型
  • 位于继承层次结构中,因此,您可以根据其属性以及与存储库中其他实体的关系来选择要继承的类型(
  • 如果需要),您可以继承来自 sys:base 而不是cm:contentcm:object,但是您会错过那些更高级类型引入的所有功能

我不明白为什么内容类型应该改变或影响用户访问内容的方式,尤其是当您有自己的页面向用户显示内容时。

附带说明一下,usr:user 也继承自 sys:base,正如您在 userModel.xml

sys:base is defined in systemModel.xml as follows (last HEAD revision showed here):

  <type name="sys:base">
     <title>Base</title>
     <mandatory-aspects>
        <aspect>sys:referenceable</aspect>
        <aspect>sys:localized</aspect>
     </mandatory-aspects>
  </type>

Go through the systemModel to learn about the two aspects that are mandatory for such type. cm:content inherits indirectly from sys:base, as you can see in the contentModel.xml, passing through cm:object that puts some constraints and indexing fairy powder onto it.

In the contentModel, you can also see that cm:folder exposes a new association named cm:contains that target sys:base objects. This means that within a cm:folder (and subtypes) you can store every type in the hierarchy branch started by sys:base, including cm:object and cm:content.

This should be already enough to show you how:

  • to create containers that allow for specific child types
  • there's no big difference between cm:content and sys:base when it comes to storing such types in a cm:folder
  • types are in a inheritance hierarchy, and as such you choose which type to inherit from depending on its properties and relationships with other entities in the repository
  • if you want, you could inherit from sys:base instead of cm:content or cm:object, but then you'll miss all of the features introduced by those more high level types

I can't see why content types should change or affect the way users access content, especially if you have your own pages to show content to users.

As a side note, also usr:user inherits from sys:base, as you can see in the userModel.xml

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文