0
我有一个视图,而且对于视图而不是表本身,我将更容易。在ATG中,我可以将itemdescriptor映射到视图而不是表格吗?有人能为我提供一个例子吗?可以将ItemDescriptor映射到一个视图而不是表
TIA
我有一个视图,而且对于视图而不是表本身,我将更容易。在ATG中,我可以将itemdescriptor映射到视图而不是表格吗?有人能为我提供一个例子吗?可以将ItemDescriptor映射到一个视图而不是表
TIA
是的,它可以。这实际上与设立正常的item-descriptor
没有什么不同。然而大多数意见是read-only
所以你需要确保你的item-descriptor
也是read-only
。这可以通过在item-descriptor
定义上设置writable="false"
属性来实现。视图的名称只是成为table
的名称。
<item-descriptor name="ExampleItemDescriptor" cache-mode="simple" writable="false" query-expire-timeout="60000" item-cache-timeout="60000" item-cache-size="2000" query-cache-size="2000">
<table name="name_of_view" type="primary" id-column-names="multiple,columns">
<property name="aproperty" column-name="column" data-type="string" />
</table>
</item-descriptor>
感谢您的解释。有效! – user3465554