Merge pull request #19291 from eileenmcnaughton/prof
[civicrm-core.git] / xml / schema / Contribute / ContributionProduct.xml
1 <?xml version="1.0" encoding="iso-8859-1" ?>
2
3 <table>
4 <base>CRM/Contribute</base>
5 <class>ContributionProduct</class>
6 <name>civicrm_contribution_product</name>
7 <add>1.4</add>
8 <log>true</log>
9 <component>CiviContribute</component>
10 <field>
11 <name>id</name>
12 <title>Contribution Product ID</title>
13 <type>int unsigned</type>
14 <required>true</required>
15 <add>1.4</add>
16 </field>
17 <primaryKey>
18 <name>id</name>
19 <autoincrement>true</autoincrement>
20 </primaryKey>
21 <field>
22 <name>product_id</name>
23 <title>Product ID</title>
24 <type>int unsigned</type>
25 <required>true</required>
26 <add>1.4</add>
27 </field>
28 <field>
29 <name>contribution_id</name>
30 <title>Contribution ID</title>
31 <type>int unsigned</type>
32 <required>true</required>
33 <add>1.4</add>
34 </field>
35 <foreignKey>
36 <name>contribution_id</name>
37 <table>civicrm_contribution</table>
38 <key>id</key>
39 <add>1.4</add>
40 <onDelete>CASCADE</onDelete>
41 </foreignKey>
42 <field>
43 <name>product_option</name>
44 <title>Product Option</title>
45 <type>varchar</type>
46 <length>255</length>
47 <export>true</export>
48 <comment>Option value selected if applicable - e.g. color, size etc.</comment>
49 <add>1.4</add>
50 </field>
51 <field>
52 <name>quantity</name>
53 <title>Quantity</title>
54 <type>int</type>
55 <export>true</export>
56 <comment></comment>
57 <add>1.4</add>
58 </field>
59 <field>
60 <name>fulfilled_date</name>
61 <type>date</type>
62 <title>Fulfilled Date</title>
63 <export>true</export>
64 <comment>Optional. Can be used to record the date this product was fulfilled or shipped.</comment>
65 <add>1.4</add>
66 <html>
67 <type>Select Date</type>
68 <formatType>activityDate</formatType>
69 </html>
70 </field>
71 <field>
72 <name>start_date</name>
73 <uniqueName>contribution_start_date</uniqueName>
74 <title>Start date for premium</title>
75 <type>date</type>
76 <export>true</export>
77 <comment>Actual start date for a time-delimited premium (subscription, service or membership)</comment>
78 <add>1.4</add>
79 </field>
80 <field>
81 <name>end_date</name>
82 <uniqueName>contribution_end_date</uniqueName>
83 <type>date</type>
84 <title>End date for premium</title>
85 <export>true</export>
86 <comment>Actual end date for a time-delimited premium (subscription, service or membership)</comment>
87 <add>1.4</add>
88 </field>
89 <field>
90 <name>comment</name>
91 <title>Premium comment</title>
92 <type>text</type>
93 <add>1.4</add>
94 </field>
95 <field>
96 <name>financial_type_id</name>
97 <title>Financial Type</title>
98 <type>int unsigned</type>
99 <default>NULL</default>
100 <pseudoconstant>
101 <table>civicrm_financial_type</table>
102 <keyColumn>id</keyColumn>
103 <labelColumn>name</labelColumn>
104 </pseudoconstant>
105 <comment>FK to Financial Type(for membership price sets only).</comment>
106 <add>4.3</add>
107 </field>
108 <foreignKey>
109 <name>financial_type_id</name>
110 <table>civicrm_financial_type</table>
111 <key>id</key>
112 <onDelete>SET NULL</onDelete>
113 <add>4.3</add>
114 </foreignKey>
115 </table>