您好 Liferay 专家,
service.xml
请帮我在 Liferay 中为以下场景创建一个:
我有 2 张桌子
SystemUsed
systemUsedId long name varchar
User_SystemUsed
userId long --> mapped to userId of User_ table systemUsedId long --> mapped to systemUsedId of SystemUsed table.<br>
谢谢
您可以按如下方式创建表:
<entity name="SystemUsed" local-service="true" remote-service="false">
<column name="systemUsedId type="Long" />
<column name="name" type="String"/>
</entity>
<entity name="User_SystemUsed" local-service="true" remote-service="false">
<column name="systemUsedId" type="SystemUsed" entity="SystemUsed" mapping-key="systemUsedId" />
<column name="userId" type="User" entity="User_" mapping-key="userid" />
</entity>
我希望 user_ 表像这样正确映射......