(OFBIZ-9390) Thanks Renuka Srishti for the report and patch. git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-plugins/trunk@1798029 13f79535-47bb-0310-9956-ffa450edef68
114 lines
5.2 KiB
XML
114 lines
5.2 KiB
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
<!--
|
|
Licensed to the Apache Software Foundation (ASF) under one
|
|
or more contributor license agreements. See the NOTICE file
|
|
distributed with this work for additional information
|
|
regarding copyright ownership. The ASF licenses this file
|
|
to you under the Apache License, Version 2.0 (the
|
|
"License"); you may not use this file except in compliance
|
|
with the License. You may obtain a copy of the License at
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
Unless required by applicable law or agreed to in writing,
|
|
software distributed under the License is distributed on an
|
|
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
KIND, either express or implied. See the License for the
|
|
specific language governing permissions and limitations
|
|
under the License.
|
|
-->
|
|
|
|
<entitymodel xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/entitymodel.xsd">
|
|
<title>Entity of Passport Component</title>
|
|
<description>Data Model Enhancements For Passport</description>
|
|
<version>1.0</version>
|
|
|
|
<entity entity-name="ThirdPartyLogin"
|
|
package-name="org.apache.ofbiz.passport"
|
|
title="Third party logins for a specific product store">
|
|
<field name="productStoreId" type="id"></field>
|
|
<field name="loginMethTypeId" type="id"></field><!-- i.e. OAuth2 -->
|
|
<field name="loginProviderId" type="id"></field><!-- i.e. GitHub -->
|
|
<field name="fromDate" type="date-time"></field>
|
|
<field name="thruDate" type="date-time"></field>
|
|
<field name="sequenceNum" type="numeric"></field>
|
|
<prim-key field="productStoreId"/>
|
|
<prim-key field="loginMethTypeId"/>
|
|
<prim-key field="loginProviderId"/>
|
|
<prim-key field="fromDate"/>
|
|
<relation type="one" fk-name="PROD_STORE_LOGINS" rel-entity-name="ProductStore">
|
|
<key-map field-name="productStoreId"/>
|
|
</relation>
|
|
<relation type="many" rel-entity-name="EnumerationType">
|
|
<key-map field-name="loginMethTypeId" rel-field-name="enumTypeId"/>
|
|
<key-map field-name="loginProviderId" rel-field-name="enumTypeId"/>
|
|
</relation>
|
|
</entity>
|
|
|
|
<!-- GitHub OAuth -->
|
|
<entity entity-name="OAuth2GitHub"
|
|
package-name="org.apache.ofbiz.passport"
|
|
title="GitHub OAuth Login Config">
|
|
<field name="productStoreId" type="id"></field>
|
|
<field name="clientId" type="short-varchar"></field>
|
|
<field name="clientSecret" type="short-varchar"></field>
|
|
<field name="returnUrl" type="value"></field>
|
|
<field name="localRedirectUri" type="short-varchar"></field>
|
|
<field name="iconUrl" type="url"></field>
|
|
<field name="fromDate" type="date-time"></field>
|
|
<field name="thruDate" type="date-time"></field>
|
|
<prim-key field="productStoreId"/>
|
|
<prim-key field="fromDate"/>
|
|
<relation type="one" fk-name="STORE_OAUTH_GITHUB" rel-entity-name="ProductStore">
|
|
<key-map field-name="productStoreId"/>
|
|
</relation>
|
|
</entity>
|
|
|
|
<entity entity-name="GitHubUser"
|
|
package-name="org.apache.ofbiz.passport"
|
|
title="Store GitHub access token for user">
|
|
<field name="gitHubUserId" type="id-vlong"></field>
|
|
<field name="productStoreId" type="id-ne"></field>
|
|
<field name="envPrefix" type="short-varchar"></field>
|
|
<field name="tokenType" type="short-varchar"></field>
|
|
<field name="accessToken" type="value"></field>
|
|
<prim-key field="gitHubUserId"/>
|
|
<relation type="one" fk-name="GITHUB_USER_STORE" rel-entity-name="ProductStore">
|
|
<key-map field-name="productStoreId"/>
|
|
</relation>
|
|
</entity>
|
|
|
|
<!-- LinkedIn OAuth -->
|
|
<entity entity-name="OAuth2LinkedIn"
|
|
package-name="org.apache.ofbiz.passport"
|
|
title="LinkedIn OAuth Login Config">
|
|
<field name="productStoreId" type="id"></field>
|
|
<field name="apiKey" type="short-varchar"></field>
|
|
<field name="secretKey" type="short-varchar"></field>
|
|
<field name="liveReturnUrl" type="value"></field>
|
|
<field name="testReturnUrl" type="value"></field>
|
|
<field name="localRedirectUri" type="short-varchar"></field>
|
|
<field name="iconUrl" type="url"></field>
|
|
<field name="fromDate" type="date-time"></field>
|
|
<field name="thruDate" type="date-time"></field>
|
|
<prim-key field="productStoreId"/>
|
|
<prim-key field="fromDate"/>
|
|
<relation type="one" fk-name="OAUTH2_LINKEDIN" rel-entity-name="ProductStore">
|
|
<key-map field-name="productStoreId"/>
|
|
</relation>
|
|
</entity>
|
|
|
|
<entity entity-name="LinkedInUser"
|
|
package-name="org.apache.ofbiz.passport"
|
|
title="Store LinkedIn access token for user">
|
|
<field name="linkedInUserId" type="id-vlong"></field>
|
|
<field name="productStoreId" type="id-ne"></field>
|
|
<field name="envPrefix" type="short-varchar"></field>
|
|
<field name="accessToken" type="value"></field>
|
|
<prim-key field="linkedInUserId"/>
|
|
<relation type="one" fk-name="LINKEDIN_USER" rel-entity-name="ProductStore">
|
|
<key-map field-name="productStoreId"/>
|
|
</relation>
|
|
</entity>
|
|
|
|
</entitymodel> |