1 <?xml version=
"1.0" encoding=
"iso-8859-1" ?>
4 <base>CRM/Contribute
</base>
5 <class>Contribution
</class>
6 <name>civicrm_contribution
</name>
11 <uniqueName>contribution_id
</uniqueName>
12 <type>int unsigned
</type>
13 <required>true
</required>
15 <title>Contribution ID
</title>
16 <comment>Contribution ID
</comment>
21 <autoincrement>true
</autoincrement>
24 <name>contact_id
</name>
25 <uniqueName>contribution_contact_id
</uniqueName>
26 <title>Contact ID
</title>
27 <type>int unsigned
</type>
28 <required>true
</required>
30 <headerPattern>/contact(.?id)?/i
</headerPattern>
31 <dataPattern>/^\d+$/
</dataPattern>
32 <comment>FK to Contact ID
</comment>
36 <name>contact_id
</name>
37 <table>civicrm_contact
</table>
40 <onDelete>CASCADE
</onDelete>
43 <name>solicitor_id
</name>
44 <title>Solicitor ID
</title>
45 <type>int unsigned
</type>
46 <comment>FK to Solicitor ID
</comment>
51 <name>solicitor_id
</name>
52 <table>civicrm_contact
</table>
56 <onDelete>SET NULL
</onDelete>
59 <name>contribution_type_id
</name>
60 <title>Contribution Type
</title>
61 <export>false
</export>
62 <type>int unsigned
</type>
63 <comment>FK to Contribution Type
</comment>
68 <name>contribution_type_id
</name>
69 <table>civicrm_contribution_type
</table>
73 <onDelete>SET NULL
</onDelete>
76 <name>financial_type_id
</name>
77 <title>Financial Type
</title>
78 <export>false
</export>
79 <type>int unsigned
</type>
80 <comment>FK to Financial Type for (total_amount - non_deductible_amount).
</comment>
84 <name>financial_type_id
</name>
85 <table>civicrm_financial_type
</table>
90 <name>contribution_page_id
</name>
91 <title>Contribution Page
</title>
92 <type>int unsigned
</type>
94 <comment>The Contribution Page which triggered this contribution
</comment>
98 <name>contribution_page_id
</name>
99 <table>civicrm_contribution_page
</table>
101 <onDelete>SET NULL
</onDelete>
104 <name>payment_instrument_id
</name>
105 <uniqueName>contribution_payment_instrument_id
</uniqueName>
106 <title>Payment Instrument
</title>
107 <type>int unsigned
</type>
108 <comment>FK to Payment Instrument
</comment>
110 <name>paymentInstrument
</name>
111 <optionGroupName>paymentInstrument
</optionGroupName>
112 <class>CRM_Contribute_PseudoConstant
</class>
117 <name>UI_contrib_payment_instrument_id
</name>
118 <fieldName>payment_instrument_id
</fieldName>
122 <name>receive_date
</name>
123 <type>datetime
</type>
124 <import>true
</import>
125 <headerPattern>/receive(.?date)?/i
</headerPattern>
126 <dataPattern>/^\d{
4}-?\d{
2}-?\d{
2} ?(\d{
2}:?\d{
2}:?(\d{
2})?)?$/
</dataPattern>
127 <comment>when was gift received
</comment>
131 <name>non_deductible_amount
</name>
132 <title>Non-deductible Amount
</title>
135 <import>true
</import>
136 <headerPattern>/non?.?deduct/i
</headerPattern>
137 <dataPattern>/^\d+(\.\d{
2})?$/
</dataPattern>
138 <comment>Portion of total amount which is NOT tax deductible. Equal to total_amount for non-deductible financial types.
</comment>
142 <name>total_amount
</name>
144 <required>true
</required>
145 <import>true
</import>
146 <headerPattern>/^total|(.?^am(ou)?nt)/i
</headerPattern>
147 <dataPattern>/^\d+(\.\d{
2})?$/
</dataPattern>
148 <comment>Total amount of this contribution. Use market value for non-monetary gifts.
</comment>
152 <name>fee_amount
</name>
154 <import>true
</import>
155 <headerPattern>/fee(.?am(ou)?nt)?/i
</headerPattern>
156 <dataPattern>/^\d+(\.\d{
2})?$/
</dataPattern>
157 <comment>actual processor fee if known - may be
0.
</comment>
161 <name>net_amount
</name>
163 <import>true
</import>
164 <headerPattern>/net(.?am(ou)?nt)?/i
</headerPattern>
165 <dataPattern>/^\d+(\.\d{
2})?$/
</dataPattern>
166 <comment>actual funds transfer amount. total less fees. if processor does not report actual fee during transaction, this is set to total_amount.
</comment>
171 <title>Transaction ID
</title>
174 <import>true
</import>
175 <headerPattern>/tr(ansactio|x)n(.?id)?/i
</headerPattern>
176 <comment>unique transaction id. may be processor id, bank id + trans id, or account number + check number... depending on payment_method
</comment>
180 <name>invoice_id
</name>
181 <title>Invoice ID
</title>
184 <import>true
</import>
185 <headerPattern>/invoice(.?id)?/i
</headerPattern>
186 <comment>unique invoice id, system generated or passed in
</comment>
190 <name>currency
</name>
193 <default>NULL
</default>
194 <import>true
</import>
195 <headerPattern>/cur(rency)?/i
</headerPattern>
196 <dataPattern>/^[A-Z]{
3}$/i
</dataPattern>
197 <comment>3 character string, value from config setting or input via user.
</comment>
200 <table>civicrm_currency
</table>
201 <keyColumn>name
</keyColumn>
202 <labelColumn>symbol
</labelColumn>
206 <name>cancel_date
</name>
207 <type>datetime
</type>
208 <import>true
</import>
209 <headerPattern>/cancel(.?date)?/i
</headerPattern>
210 <dataPattern>/^\d{
4}-?\d{
2}-?\d{
2} ?(\d{
2}:?\d{
2}:?(\d{
2})?)?$/
</dataPattern>
211 <comment>when was gift cancelled
</comment>
215 <name>cancel_reason
</name>
217 <import>true
</import>
218 <headerPattern>/(cancel.?)?reason/i
</headerPattern>
222 <name>receipt_date
</name>
223 <type>datetime
</type>
224 <import>true
</import>
225 <headerPattern>/receipt(.?date)?/i
</headerPattern>
226 <dataPattern>/^\d{
4}-?\d{
2}-?\d{
2} ?(\d{
2}:?\d{
2}:?(\d{
2})?)?$/
</dataPattern>
227 <comment>when (if) receipt was sent. populated automatically for online donations w/ automatic receipting
</comment>
231 <name>thankyou_date
</name>
232 <title>Thank-you Date
</title>
233 <type>datetime
</type>
234 <import>true
</import>
235 <headerPattern>/thank(s|(.?you))?(.?date)?/i
</headerPattern>
236 <dataPattern>/^\d{
4}-?\d{
2}-?\d{
2} ?(\d{
2}:?\d{
2}:?(\d{
2})?)?$/
</dataPattern>
237 <comment>when (if) was donor thanked
</comment>
242 <uniqueName>contribution_source
</uniqueName>
243 <title>Contribution Source
</title>
246 <import>true
</import>
247 <headerPattern>/source/i
</headerPattern>
248 <comment>Origin of this Contribution.
</comment>
252 <name>amount_level
</name>
253 <title>Amount Label
</title>
255 <import>true
</import>
261 <comment>Note and/or Comment.
</comment>
262 <htmlType>textarea
</htmlType>
265 <import>true
</import>
266 <headerPattern>/Note|Comment/i
</headerPattern>
267 <dataPattern>//
</dataPattern>
272 <name>UI_contrib_trxn_id
</name>
273 <fieldName>trxn_id
</fieldName>
274 <unique>true
</unique>
278 <name>UI_contrib_invoice_id
</name>
279 <fieldName>invoice_id
</fieldName>
280 <unique>true
</unique>
284 <name>contribution_recur_id
</name>
285 <type>int unsigned
</type>
286 <comment>Conditional foreign key to civicrm_contribution_recur id. Each contribution made in connection with a recurring contribution carries a foreign key to the recurring contribution record. This assumes we can track these processor initiated events.
</comment>
290 <name>contribution_recur_id
</name>
291 <table>civicrm_contribution_recur
</table>
294 <onDelete>SET NULL
</onDelete>
297 <name>honor_contact_id
</name>
298 <title>Honor Contact
</title>
299 <type>int unsigned
</type>
300 <comment>FK to contact ID
</comment>
304 <name>honor_contact_id
</name>
305 <table>civicrm_contact
</table>
308 <onDelete>SET NULL
</onDelete>
315 <import>true
</import>
318 <name>is_pay_later
</name>
319 <title>Is Pay Later
</title>
322 <import>true
</import>
326 <name>contribution_status_id
</name>
327 <title>Contribution Status
</title>
328 <type>int unsigned
</type>
330 <import>true
</import>
331 <export>true
</export>
332 <headerPattern>/status/i
</headerPattern>
336 <name>honor_type_id
</name>
337 <title>Honor Type
</title>
338 <type>int unsigned
</type>
339 <comment>Implicit FK to civicrm_option_value.
</comment>
341 <onDelete>SET NULL
</onDelete>
343 <optionGroupName>honor_type
</optionGroupName>
347 <name>index_contribution_status
</name>
348 <fieldName>contribution_status_id
</fieldName>
352 <name>received_date
</name>
353 <fieldName>receive_date
</fieldName>
357 <name>address_id
</name>
358 <type>int unsigned
</type>
359 <comment>Conditional foreign key to civicrm_address.id. We insert an address record for each contribution when we have associated billing name and address data.
</comment>
363 <name>address_id
</name>
364 <table>civicrm_address
</table>
367 <onDelete>SET NULL
</onDelete>
370 <name>check_number
</name>
371 <title>Check Number
</title>
372 <headerPattern>/check(.?number)?/i
</headerPattern>
376 <import>true
</import>
380 <name>check_number
</name>
381 <fieldName>check_number
</fieldName>
385 <name>campaign_id
</name>
386 <uniqueName>contribution_campaign_id
</uniqueName>
387 <type>int unsigned
</type>
388 <title>Campaign ID
</title>
389 <import>true
</import>
390 <comment>The campaign for which this contribution has been triggered.
</comment>
394 <name>campaign_id
</name>
395 <table>civicrm_campaign
</table>
397 <onDelete>SET NULL
</onDelete>