1 <?xml version=
"1.0" encoding=
"iso-8859-1" ?>
4 <base>CRM/Contribute
</base>
5 <class>Contribution
</class>
6 <name>civicrm_contribution
</name>
7 <description>Financial records consisting of transactions, line-items, etc.
</description>
10 <icon>fa-credit-card
</icon>
11 <component>CiviContribute
</component>
13 <add>civicrm/contribute/add?reset=
1&action=add
&context=standalone
</add>
14 <view>civicrm/contact/view/contribution?reset=
1&action=view
&id=[id]
</view>
15 <update>civicrm/contact/view/contribution?reset=
1&action=update
&id=[id]
</update>
16 <delete>civicrm/contact/view/contribution?reset=
1&action=delete
&id=[id]
</delete>
20 <uniqueName>contribution_id
</uniqueName>
21 <type>int unsigned
</type>
22 <required>true
</required>
24 <title>Contribution ID
</title>
25 <comment>Contribution ID
</comment>
33 <autoincrement>true
</autoincrement>
36 <name>contact_id
</name>
37 <uniqueName>contribution_contact_id
</uniqueName>
38 <title>Contact ID
</title>
39 <type>int unsigned
</type>
40 <required>true
</required>
42 <headerPattern>/contact(.?id)?/i
</headerPattern>
43 <dataPattern>/^\d+$/
</dataPattern>
44 <comment>FK to Contact ID
</comment>
46 <type>EntityRef
</type>
47 <label>Contact
</label>
52 <name>contact_id
</name>
53 <table>civicrm_contact
</table>
56 <onDelete>CASCADE
</onDelete>
59 <name>financial_type_id
</name>
60 <title>Financial Type ID
</title>
61 <type>int unsigned
</type>
62 <comment>FK to Financial Type for (total_amount - non_deductible_amount).
</comment>
64 <table>civicrm_financial_type
</table>
65 <keyColumn>id
</keyColumn>
66 <labelColumn>name
</labelColumn>
71 <label>Financial Type
</label>
76 <name>financial_type_id
</name>
77 <table>civicrm_financial_type
</table>
82 <name>contribution_page_id
</name>
83 <title>Contribution Page ID
</title>
84 <type>int unsigned
</type>
86 <comment>The Contribution Page which triggered this contribution
</comment>
88 <table>civicrm_contribution_page
</table>
89 <keyColumn>id
</keyColumn>
90 <labelColumn>title
</labelColumn>
94 <label>Contribution Page
</label>
99 <name>contribution_page_id
</name>
100 <table>civicrm_contribution_page
</table>
102 <onDelete>SET NULL
</onDelete>
105 <name>payment_instrument_id
</name>
106 <uniqueName>payment_instrument_id
</uniqueName>
107 <title>Payment Method ID
</title>
108 <type>int unsigned
</type>
109 <comment>FK to Payment Instrument
</comment>
110 <export>true
</export>
111 <headerPattern>/^payment|(p(ayment\s)?instrument)$/i
</headerPattern>
113 <optionGroupName>payment_instrument
</optionGroupName>
117 <label>Payment Method
</label>
122 <name>UI_contrib_payment_instrument_id
</name>
123 <fieldName>payment_instrument_id
</fieldName>
127 <name>receive_date
</name>
128 <title>Date Received
</title>
129 <type>datetime
</type>
130 <import>true
</import>
131 <headerPattern>/receive(.?date)?/i
</headerPattern>
132 <dataPattern>/^\d{
4}-?\d{
2}-?\d{
2} ?(\d{
2}:?\d{
2}:?(\d{
2})?)?$/
</dataPattern>
133 <comment>Date contribution was received - not necessarily the creation date of the record
</comment>
136 <type>Select Date
</type>
137 <formatType>activityDateTime
</formatType>
141 <name>non_deductible_amount
</name>
142 <title>Non-deductible Amount
</title>
145 <import>true
</import>
146 <headerPattern>/non?.?deduct/i
</headerPattern>
147 <dataPattern>/^\d+(\.\d{
2})?$/
</dataPattern>
148 <comment>Portion of total amount which is NOT tax deductible. Equal to total_amount for non-deductible financial types.
</comment>
155 <name>total_amount
</name>
157 <required>true
</required>
158 <import>true
</import>
159 <headerPattern>/^total|(.?^am(ou)?nt)/i
</headerPattern>
160 <dataPattern>/^\d+(\.\d{
2})?$/
</dataPattern>
161 <comment>Total amount of this contribution. Use market value for non-monetary gifts.
</comment>
165 <label>Total Amount
</label>
169 <name>index_total_amount_receive_date
</name>
170 <fieldName>total_amount
</fieldName>
171 <fieldName>receive_date
</fieldName>
175 <name>fee_amount
</name>
177 <import>true
</import>
178 <headerPattern>/fee(.?am(ou)?nt)?/i
</headerPattern>
179 <dataPattern>/^\d+(\.\d{
2})?$/
</dataPattern>
180 <comment>actual processor fee if known - may be
0.
</comment>
184 <label>Fee Amount
</label>
188 <name>net_amount
</name>
190 <import>true
</import>
191 <headerPattern>/net(.?am(ou)?nt)?/i
</headerPattern>
192 <dataPattern>/^\d+(\.\d{
2})?$/
</dataPattern>
193 <comment>actual funds transfer amount. total less fees. if processor does not report actual fee during transaction, this is set to total_amount.
</comment>
197 <label>Net Amount
</label>
202 <title>Transaction ID
</title>
205 <import>true
</import>
206 <headerPattern>/tr(ansactio|x)n(.?id)?/i
</headerPattern>
207 <comment>unique transaction id. may be processor id, bank id + trans id, or account number + check number... depending on payment_method
</comment>
208 <readonly>true
</readonly>
215 <name>invoice_id
</name>
216 <title>Invoice Reference
</title>
219 <import>true
</import>
220 <headerPattern>/invoice(.?id)?/i
</headerPattern>
221 <comment>unique invoice id, system generated or passed in
</comment>
222 <readonly>true
</readonly>
229 <name>invoice_number
</name>
230 <title>Invoice Number
</title>
233 <import>true
</import>
234 <headerPattern>/invoice(.?number)?/i
</headerPattern>
235 <comment>Human readable invoice number
</comment>
242 <name>currency
</name>
245 <default>NULL
</default>
246 <import>true
</import>
247 <headerPattern>/cur(rency)?/i
</headerPattern>
248 <dataPattern>/^[A-Z]{
3}$/i
</dataPattern>
249 <comment>3 character string, value from config setting or input via user.
</comment>
252 <table>civicrm_currency
</table>
253 <keyColumn>name
</keyColumn>
254 <labelColumn>full_name
</labelColumn>
255 <nameColumn>name
</nameColumn>
256 <abbrColumn>symbol
</abbrColumn>
260 <label>Currency
</label>
264 <name>cancel_date
</name>
265 <title>Cancelled / Refunded Date
</title>
266 <type>datetime
</type>
267 <import>true
</import>
268 <headerPattern>/cancel(.?date)?/i
</headerPattern>
269 <dataPattern>/^\d{
4}-?\d{
2}-?\d{
2} ?(\d{
2}:?\d{
2}:?(\d{
2})?)?$/
</dataPattern>
270 <comment>when was gift cancelled
</comment>
273 <type>Select Date
</type>
274 <formatType>activityDateTime
</formatType>
276 <uniqueName>contribution_cancel_date
</uniqueName>
279 <name>cancel_reason
</name>
281 <title>Cancellation / Refund Reason
</title>
282 <import>true
</import>
283 <export>true
</export>
284 <headerPattern>/(cancel.?)?reason/i
</headerPattern>
292 <name>receipt_date
</name>
293 <type>datetime
</type>
294 <import>true
</import>
295 <headerPattern>/receipt(.?date)?/i
</headerPattern>
296 <dataPattern>/^\d{
4}-?\d{
2}-?\d{
2} ?(\d{
2}:?\d{
2}:?(\d{
2})?)?$/
</dataPattern>
297 <comment>when (if) receipt was sent. populated automatically for online donations w/ automatic receipting
</comment>
299 <type>Select Date
</type>
300 <formatType>activityDateTime
</formatType>
301 <label>Receipt Date
</label>
306 <name>thankyou_date
</name>
307 <title>Thank-you Date
</title>
308 <type>datetime
</type>
309 <import>true
</import>
310 <headerPattern>/thank(s|(.?you))?(.?date)?/i
</headerPattern>
311 <dataPattern>/^\d{
4}-?\d{
2}-?\d{
2} ?(\d{
2}:?\d{
2}:?(\d{
2})?)?$/
</dataPattern>
312 <comment>when (if) was donor thanked
</comment>
315 <type>Select Date
</type>
316 <formatType>activityDateTime
</formatType>
321 <uniqueName>contribution_source
</uniqueName>
322 <title>Contribution Source
</title>
325 <import>true
</import>
326 <headerPattern>/source/i
</headerPattern>
327 <comment>Origin of this Contribution.
</comment>
334 <name>index_source
</name>
335 <fieldName>source
</fieldName>
339 <name>amount_level
</name>
340 <title>Amount Label
</title>
342 <import>true
</import>
349 <name>UI_contrib_trxn_id
</name>
350 <fieldName>trxn_id
</fieldName>
351 <unique>true
</unique>
355 <name>UI_contrib_invoice_id
</name>
356 <fieldName>invoice_id
</fieldName>
357 <unique>true
</unique>
361 <name>contribution_recur_id
</name>
362 <title>Recurring Contribution ID
</title>
363 <type>int unsigned
</type>
364 <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>
365 <export>true
</export>
366 <readonly>true
</readonly>
368 <label>Recurring Contribution
</label>
373 <name>contribution_recur_id
</name>
374 <table>civicrm_contribution_recur
</table>
377 <onDelete>SET NULL
</onDelete>
384 <import>true
</import>
386 <type>CheckBox
</type>
390 <name>is_pay_later
</name>
391 <title>Is Pay Later
</title>
394 <import>true
</import>
397 <type>CheckBox
</type>
401 <name>contribution_status_id
</name>
402 <title>Contribution Status ID
</title>
403 <type>int unsigned
</type>
405 <import>true
</import>
406 <export>true
</export>
407 <headerPattern>/status/i
</headerPattern>
409 <optionGroupName>contribution_status
</optionGroupName>
413 <label>Contribution Status
</label>
418 <name>index_contribution_status
</name>
419 <fieldName>contribution_status_id
</fieldName>
423 <name>received_date
</name>
424 <fieldName>receive_date
</fieldName>
428 <name>address_id
</name>
429 <uniqueName>contribution_address_id
</uniqueName>
430 <title>Address ID
</title>
431 <type>int unsigned
</type>
432 <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>
434 <label>Address
</label>
437 <export>true
</export>
440 <name>address_id
</name>
441 <table>civicrm_address
</table>
444 <onDelete>SET NULL
</onDelete>
447 <name>check_number
</name>
448 <title>Check Number
</title>
449 <uniqueName>contribution_check_number
</uniqueName>
450 <headerPattern>/check(.?number)?/i
</headerPattern>
457 <import>true
</import>
461 <name>check_number
</name>
462 <fieldName>check_number
</fieldName>
466 <name>campaign_id
</name>
467 <component>CiviCampaign
</component>
468 <uniqueName>contribution_campaign_id
</uniqueName>
469 <type>int unsigned
</type>
470 <title>Campaign ID
</title>
471 <import>true
</import>
472 <comment>The campaign for which this contribution has been triggered.
</comment>
475 <table>civicrm_campaign
</table>
476 <keyColumn>id
</keyColumn>
477 <labelColumn>title
</labelColumn>
478 <prefetch>FALSE
</prefetch>
481 <type>EntityRef
</type>
482 <label>Campaign
</label>
486 <name>creditnote_id
</name>
487 <title>Credit Note ID
</title>
490 <import>true
</import>
491 <headerPattern>/creditnote(.?id)?/i
</headerPattern>
492 <comment>unique credit note id, system generated or passed in
</comment>
499 <name>index_creditnote_id
</name>
500 <fieldName>creditnote_id
</fieldName>
504 <name>tax_amount
</name>
505 <title>Tax Amount
</title>
507 <import>true
</import>
508 <headerPattern>/tax(.?am(ou)?nt)?/i
</headerPattern>
509 <dataPattern>/^\d+(\.\d{
2})?$/
</dataPattern>
510 <comment>Total tax amount of this contribution.
</comment>
517 <name>campaign_id
</name>
518 <table>civicrm_campaign
</table>
520 <onDelete>SET NULL
</onDelete>
523 <name>revenue_recognition_date
</name>
524 <type>datetime
</type>
525 <import>true
</import>
526 <headerPattern>/revenue(.?date)?/i
</headerPattern>
527 <dataPattern>/^\d{
4}-?\d{
2}-?\d{
2} ?(\d{
2}:?\d{
2}:?(\d{
2})?)?$/
</dataPattern>
528 <comment>Stores the date when revenue should be recognized.
</comment>
530 <type>Select Date
</type>
531 <formatType>activityDateTime
</formatType>
532 <label>Revenue Recognition Date
</label>
537 <name>is_template
</name>
538 <title>Is a Template Contribution
</title>
541 <import>true
</import>
542 <comment>Shows this is a template for recurring contributions.
</comment>
543 <readonly>true
</readonly>
545 <type>CheckBox
</type>