Merge pull request #23082 from agileware/CIVICRM-1958
[civicrm-core.git] / xml / schema / Core / OpenID.xml
1 <?xml version="1.0" encoding="iso-8859-1" ?>
2 <table>
3 <base>CRM/Core</base>
4 <class>OpenID</class>
5 <name>civicrm_openid</name>
6 <comment>OpenID information for a specific location.</comment>
7 <add>2.0</add>
8 <field>
9 <name>id</name>
10 <title>Open ID identifier</title>
11 <type>int unsigned</type>
12 <required>true</required>
13 <comment>Unique OpenID ID</comment>
14 <html>
15 <type>Number</type>
16 </html>
17 <add>2.0</add>
18 </field>
19 <primaryKey>
20 <name>id</name>
21 <autoincrement>true</autoincrement>
22 </primaryKey>
23 <field>
24 <name>contact_id</name>
25 <title>Contact ID</title>
26 <type>int unsigned</type>
27 <comment>FK to Contact ID</comment>
28 <html>
29 <label>Contact</label>
30 </html>
31 <add>2.0</add>
32 </field>
33 <foreignKey>
34 <name>contact_id</name>
35 <table>civicrm_contact</table>
36 <key>id</key>
37 <add>2.0</add>
38 <onDelete>CASCADE</onDelete>
39 </foreignKey>
40 <field>
41 <name>location_type_id</name>
42 <title>OpenID Location Type</title>
43 <type>int unsigned</type>
44 <pseudoconstant>
45 <table>civicrm_location_type</table>
46 <keyColumn>id</keyColumn>
47 <labelColumn>display_name</labelColumn>
48 </pseudoconstant>
49 <comment>Which Location does this email belong to.</comment>
50 <add>2.0</add>
51 </field>
52 <index>
53 <name>index_location_type</name>
54 <fieldName>location_type_id</fieldName>
55 <add>2.0</add>
56 </index>
57 <field>
58 <name>openid</name>
59 <title>OpenID</title>
60 <type>varchar</type>
61 <length>255</length>
62 <import>true</import>
63 <headerPattern>/^Open.?ID|u(niq\w*)?.?ID/i</headerPattern>
64 <dataPattern>/^[\w\/\:\.]+$/</dataPattern>
65 <comment>the OpenID (or OpenID-style http://username.domain/) unique identifier for this contact mainly used for logging in to CiviCRM</comment>
66 <rule>url</rule>
67 <comment>OpenID</comment>
68 <add>2.0</add>
69 </field>
70 <index>
71 <name>UI_openid</name>
72 <fieldName>openid</fieldName>
73 <unique>true</unique>
74 <add>2.0</add>
75 </index>
76 <field>
77 <name>allowed_to_login</name>
78 <title>Allowed to login?</title>
79 <type>boolean</type>
80 <required>true</required>
81 <default>0</default>
82 <comment>Whether or not this user is allowed to login</comment>
83 <add>2.0</add>
84 </field>
85 <field>
86 <name>is_primary</name>
87 <title>Primary ID</title>
88 <type>boolean</type>
89 <default>0</default>
90 <required>true</required>
91 <html>
92 <type>Radio</type>
93 </html>
94 <comment>Is this the primary email for this contact and location.</comment>
95 <add>2.0</add>
96 </field>
97 </table>