Merge pull request #22941 from sunilpawar/batch_copy_radio_clear_value
[civicrm-core.git] / xml / schema / Core / Tag.xml
1 <?xml version="1.0" encoding="iso-8859-1" ?>
2
3 <table>
4 <base>CRM/Core</base>
5 <class>Tag</class>
6 <name>civicrm_tag</name>
7 <comment>Provides support for flat or hierarchical classification of various types of entities (contacts, groups, actions...).</comment>
8 <add>1.1</add>
9 <log>true</log>
10 <icon>fa-tag</icon>
11 <labelField>name</labelField>
12 <field>
13 <name>id</name>
14 <title>Tag ID</title>
15 <type>int unsigned</type>
16 <required>true</required>
17 <comment>Tag ID</comment>
18 <html>
19 <type>Number</type>
20 </html>
21 <add>1.1</add>
22 </field>
23 <primaryKey>
24 <name>id</name>
25 <autoincrement>true</autoincrement>
26 </primaryKey>
27 <field>
28 <name>name</name>
29 <title>Tag Name</title>
30 <type>varchar</type>
31 <required>true</required>
32 <length>64</length>
33 <comment>Name of Tag.</comment>
34 <add>1.1</add>
35 </field>
36 <field>
37 <name>description</name>
38 <title>Description</title>
39 <type>varchar</type>
40 <length>255</length>
41 <comment>Optional verbose description of the tag.</comment>
42 <add>1.1</add>
43 </field>
44 <field>
45 <name>parent_id</name>
46 <title>Parent Tag ID</title>
47 <type>int unsigned</type>
48 <default>NULL</default>
49 <comment>Optional parent id for this tag.</comment>
50 <pseudoconstant>
51 <table>civicrm_tag</table>
52 <keyColumn>id</keyColumn>
53 <labelColumn>name</labelColumn>
54 </pseudoconstant>
55 <html>
56 <label>Parent Tag</label>
57 </html>
58 <add>1.1</add>
59 </field>
60 <field>
61 <name>is_selectable</name>
62 <title>Display Tag?</title>
63 <type>boolean</type>
64 <default>1</default>
65 <required>true</required>
66 <comment>Is this tag selectable / displayed</comment>
67 <add>2.1</add>
68 </field>
69 <foreignKey>
70 <name>parent_id</name>
71 <table>civicrm_tag</table>
72 <key>id</key>
73 <add>1.1</add>
74 </foreignKey>
75 <index>
76 <name>UI_name</name>
77 <fieldName>name</fieldName>
78 <unique>true</unique>
79 <add>2.1</add>
80 </index>
81 <field>
82 <name>is_reserved</name>
83 <title>Reserved</title>
84 <type>boolean</type>
85 <default>0</default>
86 <required>true</required>
87 <add>3.2</add>
88 </field>
89 <field>
90 <name>is_tagset</name>
91 <title>Tagset</title>
92 <type>boolean</type>
93 <default>0</default>
94 <required>true</required>
95 <add>3.2</add>
96 </field>
97 <field>
98 <name>used_for</name>
99 <title>Used For</title>
100 <type>varchar</type>
101 <length>64</length>
102 <default>NULL</default>
103 <html>
104 <type>Select</type>
105 </html>
106 <pseudoconstant>
107 <optionGroupName>tag_used_for</optionGroupName>
108 </pseudoconstant>
109 <serialize>COMMA</serialize>
110 <add>3.2</add>
111 </field>
112 <field>
113 <name>created_id</name>
114 <title>Created By Contact ID</title>
115 <type>int unsigned</type>
116 <comment>FK to civicrm_contact, who created this tag</comment>
117 <html>
118 <label>Created By</label>
119 </html>
120 <add>3.4</add>
121 </field>
122 <field>
123 <name>color</name>
124 <title>Color</title>
125 <type>varchar</type>
126 <length>255</length>
127 <comment>Hex color value e.g. #ffffff</comment>
128 <default>NULL</default>
129 <add>4.7</add>
130 </field>
131 <foreignKey>
132 <name>created_id</name>
133 <table>civicrm_contact</table>
134 <key>id</key>
135 <add>3.4</add>
136 <onDelete>SET NULL</onDelete>
137 </foreignKey>
138 <field>
139 <name>created_date</name>
140 <type>datetime</type>
141 <title>Tag Created Date</title>
142 <comment>Date and time that tag was created.</comment>
143 <add>3.4</add>
144 </field>
145 </table>