1 <?xml version=
"1.0" encoding=
"iso-8859-1" ?>
4 <base>CRM/Financial
</base>
5 <class>FinancialTrxn
</class>
6 <name>civicrm_financial_trxn
</name>
11 <type>int unsigned
</type>
12 <required>true
</required>
17 <autoincrement>true
</autoincrement>
20 <name>from_account_id
</name>
21 <type>int unsigned
</type>
22 <comment>FK to financial_account table.
</comment>
27 <name>from_account_id
</name>
28 <table>civicrm_financial_account
</table>
34 <name>to_account_id
</name>
35 <type>int unsigned
</type>
36 <comment>FK to financial_account table.
</comment>
41 <name>to_account_id
</name>
42 <table>civicrm_financial_account
</table>
48 <name>from_financial_account_id
</name>
49 <type>int unsigned
</type>
50 <comment>FK to financial_account table.
</comment>
53 <table>civicrm_financial_account
</table>
54 <keyColumn>id
</keyColumn>
55 <labelColumn>name
</labelColumn>
62 <name>from_financial_account_id
</name>
63 <table>civicrm_financial_account
</table>
68 <name>to_financial_account_id
</name>
69 <type>int unsigned
</type>
70 <comment>FK to financial_financial_account table.
</comment>
73 <table>civicrm_financial_account
</table>
74 <keyColumn>id
</keyColumn>
75 <labelColumn>name
</labelColumn>
82 <name>to_financial_account_id
</name>
83 <table>civicrm_financial_account
</table>
88 <name>trxn_date
</name>
90 <default>NULL
</default>
91 <comment>date transaction occurred
</comment>
95 <name>trxn_type
</name>
97 <values>Debit,Credit
</values>
98 <required>true
</required>
103 <name>total_amount
</name>
105 <required>true
</required>
106 <comment>amount of transaction
</comment>
110 <name>fee_amount
</name>
112 <comment>actual processor fee if known - may be
0.
</comment>
116 <name>net_amount
</name>
118 <comment>actual funds transfer amount. total less fees. if processor does not report actual fee during transaction, this is set to total_amount.
</comment>
122 <name>currency
</name>
125 <default>NULL
</default>
126 <import>true
</import>
127 <headerPattern>/cur(rency)?/i
</headerPattern>
128 <dataPattern>/^[A-Z]{
3}$/
</dataPattern>
129 <comment>3 character string, value from config setting or input via user.
</comment>
132 <table>civicrm_currency
</table>
133 <keyColumn>name
</keyColumn>
134 <labelColumn>full_name
</labelColumn>
135 <nameColumn>numeric_code
</nameColumn>
142 <name>payment_processor
</name>
145 <required>true
</required>
146 <comment>derived from Processor setting in civicrm.settings.php.
</comment>
154 <comment>user-specified unique processor transaction id, bank id + trans id,... depending on payment_method
</comment>
158 <name>trxn_result_code
</name>
161 <comment>processor result code
</comment>
165 <name>status_id
</name>
166 <title>Financial Transaction Status Id
</title>
167 <type>int unsigned
</type>
168 <import>true
</import>
169 <export>true
</export>
170 <comment>pseudo FK to civicrm_option_value of financial_item status option_group
</comment>
171 <headerPattern>/status/i
</headerPattern>
175 <name>payment_processor_id
</name>
176 <type>int unsigned
</type>
177 <comment>Payment Processor for this financial transaction
</comment>
181 <name>payment_processor_id
</name>
182 <table>civicrm_payment_processor
</table>
184 <onDelete>SET NULL
</onDelete>
188 <name>payment_instrument_id
</name>
189 <uniqueName>financial_trxn_payment_instrument_id
</uniqueName>
190 <title>Payment Instrument
</title>
191 <type>int unsigned
</type>
192 <comment>FK to payment_instrument option group values
</comment>
194 <optionGroupName>payment_instrument
</optionGroupName>
202 <name>UI_ftrxn_payment_instrument_id
</name>
203 <fieldName>payment_instrument_id
</fieldName>
207 <name>check_number
</name>
208 <uniqueName>financial_trxn_check_number
</uniqueName>
209 <title>Check Number
</title>
210 <comment>Check number
</comment>
220 <name>UI_ftrxn_check_number
</name>
221 <fieldName>check_number
</fieldName>