Commit | Line | Data |
---|---|---|
e501603b | 1 | <?php |
c3fc2621 | 2 | |
e501603b TO |
3 | /** |
4 | * @package CRM | |
6b83d5bd | 5 | * @copyright CiviCRM LLC (c) 2004-2019 |
e501603b TO |
6 | * |
7 | * Generated from xml/schema/CRM/Contribute/ContributionPage.xml | |
8 | * DO NOT EDIT. Generated by CRM_Core_CodeGen | |
74db51d3 | 9 | * (GenCodeChecksum:a0dc506faaceaf3a644d020cd5b0676b) |
e501603b | 10 | */ |
c3fc2621 | 11 | |
f41f0342 | 12 | /** |
c3fc2621 | 13 | * Database access object for the ContributionPage entity. |
f41f0342 | 14 | */ |
e501603b | 15 | class CRM_Contribute_DAO_ContributionPage extends CRM_Core_DAO { |
c3fc2621 | 16 | |
e501603b | 17 | /** |
f41f0342 | 18 | * Static instance to hold the table name. |
e501603b TO |
19 | * |
20 | * @var string | |
21 | */ | |
fa45b5b9 | 22 | public static $_tableName = 'civicrm_contribution_page'; |
c3fc2621 | 23 | |
e501603b | 24 | /** |
f41f0342 | 25 | * Should CiviCRM log any modifications to this table in the civicrm_log table. |
e501603b | 26 | * |
c3fc2621 | 27 | * @var bool |
e501603b | 28 | */ |
fa45b5b9 | 29 | public static $_log = TRUE; |
c3fc2621 | 30 | |
e501603b TO |
31 | /** |
32 | * Contribution Id | |
33 | * | |
e6ca0a57 | 34 | * @var int |
e501603b TO |
35 | */ |
36 | public $id; | |
c3fc2621 | 37 | |
e501603b TO |
38 | /** |
39 | * Contribution Page title. For top of page display | |
40 | * | |
41 | * @var string | |
42 | */ | |
43 | public $title; | |
c3fc2621 | 44 | |
e501603b TO |
45 | /** |
46 | * Text and html allowed. Displayed below title. | |
47 | * | |
48 | * @var text | |
49 | */ | |
50 | public $intro_text; | |
c3fc2621 | 51 | |
e501603b TO |
52 | /** |
53 | * default financial type assigned to contributions submitted via this page, e.g. Contribution, Campaign Contribution | |
54 | * | |
e6ca0a57 | 55 | * @var int |
e501603b TO |
56 | */ |
57 | public $financial_type_id; | |
c3fc2621 | 58 | |
e501603b TO |
59 | /** |
60 | * Payment Processors configured for this contribution Page | |
61 | * | |
62 | * @var string | |
63 | */ | |
64 | public $payment_processor; | |
c3fc2621 | 65 | |
e501603b TO |
66 | /** |
67 | * if true - processing logic must reject transaction at confirmation stage if pay method != credit card | |
68 | * | |
e6ca0a57 | 69 | * @var bool |
e501603b TO |
70 | */ |
71 | public $is_credit_card_only; | |
c3fc2621 | 72 | |
e501603b TO |
73 | /** |
74 | * if true - allows real-time monetary transactions otherwise non-monetary transactions | |
75 | * | |
e6ca0a57 | 76 | * @var bool |
e501603b TO |
77 | */ |
78 | public $is_monetary; | |
c3fc2621 | 79 | |
e501603b TO |
80 | /** |
81 | * if true - allows recurring contributions, valid only for PayPal_Standard | |
82 | * | |
e6ca0a57 | 83 | * @var bool |
e501603b TO |
84 | */ |
85 | public $is_recur; | |
c3fc2621 | 86 | |
e501603b TO |
87 | /** |
88 | * if false, the confirm page in contribution pages gets skipped | |
89 | * | |
e6ca0a57 | 90 | * @var bool |
e501603b TO |
91 | */ |
92 | public $is_confirm_enabled; | |
c3fc2621 | 93 | |
e501603b TO |
94 | /** |
95 | * Supported recurring frequency units. | |
96 | * | |
97 | * @var string | |
98 | */ | |
99 | public $recur_frequency_unit; | |
c3fc2621 | 100 | |
e501603b TO |
101 | /** |
102 | * if true - supports recurring intervals | |
103 | * | |
e6ca0a57 | 104 | * @var bool |
e501603b TO |
105 | */ |
106 | public $is_recur_interval; | |
c3fc2621 | 107 | |
e501603b TO |
108 | /** |
109 | * if true - asks user for recurring installments | |
110 | * | |
e6ca0a57 | 111 | * @var bool |
e501603b TO |
112 | */ |
113 | public $is_recur_installments; | |
c3fc2621 | 114 | |
e501603b TO |
115 | /** |
116 | * if true - user is able to adjust payment start date | |
117 | * | |
e6ca0a57 | 118 | * @var bool |
e501603b TO |
119 | */ |
120 | public $adjust_recur_start_date; | |
c3fc2621 | 121 | |
e501603b TO |
122 | /** |
123 | * if true - allows the user to send payment directly to the org later | |
124 | * | |
e6ca0a57 | 125 | * @var bool |
e501603b TO |
126 | */ |
127 | public $is_pay_later; | |
c3fc2621 | 128 | |
e501603b TO |
129 | /** |
130 | * The text displayed to the user in the main form | |
131 | * | |
132 | * @var text | |
133 | */ | |
134 | public $pay_later_text; | |
c3fc2621 | 135 | |
e501603b TO |
136 | /** |
137 | * The receipt sent to the user instead of the normal receipt text | |
138 | * | |
139 | * @var text | |
140 | */ | |
141 | public $pay_later_receipt; | |
c3fc2621 | 142 | |
e501603b TO |
143 | /** |
144 | * is partial payment enabled for this online contribution page | |
145 | * | |
e6ca0a57 | 146 | * @var bool |
e501603b TO |
147 | */ |
148 | public $is_partial_payment; | |
c3fc2621 | 149 | |
e501603b TO |
150 | /** |
151 | * Initial amount label for partial payment | |
152 | * | |
153 | * @var string | |
154 | */ | |
155 | public $initial_amount_label; | |
c3fc2621 | 156 | |
e501603b TO |
157 | /** |
158 | * Initial amount help text for partial payment | |
159 | * | |
160 | * @var text | |
161 | */ | |
162 | public $initial_amount_help_text; | |
c3fc2621 | 163 | |
e501603b TO |
164 | /** |
165 | * Minimum initial amount for partial payment | |
166 | * | |
167 | * @var float | |
168 | */ | |
169 | public $min_initial_amount; | |
c3fc2621 | 170 | |
e501603b TO |
171 | /** |
172 | * if true, page will include an input text field where user can enter their own amount | |
173 | * | |
e6ca0a57 | 174 | * @var bool |
e501603b TO |
175 | */ |
176 | public $is_allow_other_amount; | |
c3fc2621 | 177 | |
e501603b TO |
178 | /** |
179 | * FK to civicrm_option_value. | |
180 | * | |
e6ca0a57 | 181 | * @var int |
e501603b TO |
182 | */ |
183 | public $default_amount_id; | |
c3fc2621 | 184 | |
e501603b TO |
185 | /** |
186 | * if other amounts allowed, user can configure minimum allowed. | |
187 | * | |
188 | * @var float | |
189 | */ | |
190 | public $min_amount; | |
c3fc2621 | 191 | |
e501603b TO |
192 | /** |
193 | * if other amounts allowed, user can configure maximum allowed. | |
194 | * | |
195 | * @var float | |
196 | */ | |
197 | public $max_amount; | |
c3fc2621 | 198 | |
e501603b TO |
199 | /** |
200 | * The target goal for this page, allows people to build a goal meter | |
201 | * | |
202 | * @var float | |
203 | */ | |
204 | public $goal_amount; | |
c3fc2621 | 205 | |
e501603b TO |
206 | /** |
207 | * Title for Thank-you page (header title tag, and display at the top of the page). | |
208 | * | |
209 | * @var string | |
210 | */ | |
211 | public $thankyou_title; | |
c3fc2621 | 212 | |
e501603b TO |
213 | /** |
214 | * text and html allowed. displayed above result on success page | |
215 | * | |
216 | * @var text | |
217 | */ | |
218 | public $thankyou_text; | |
c3fc2621 | 219 | |
e501603b TO |
220 | /** |
221 | * Text and html allowed. displayed at the bottom of the success page. Common usage is to include link(s) to other pages such as tell-a-friend, etc. | |
222 | * | |
223 | * @var text | |
224 | */ | |
225 | public $thankyou_footer; | |
c3fc2621 | 226 | |
e501603b TO |
227 | /** |
228 | * if true, receipt is automatically emailed to contact on success | |
229 | * | |
e6ca0a57 | 230 | * @var bool |
e501603b TO |
231 | */ |
232 | public $is_email_receipt; | |
c3fc2621 | 233 | |
e501603b TO |
234 | /** |
235 | * FROM email name used for receipts generated by contributions to this contribution page. | |
236 | * | |
237 | * @var string | |
238 | */ | |
239 | public $receipt_from_name; | |
c3fc2621 | 240 | |
e501603b TO |
241 | /** |
242 | * FROM email address used for receipts generated by contributions to this contribution page. | |
243 | * | |
244 | * @var string | |
245 | */ | |
246 | public $receipt_from_email; | |
c3fc2621 | 247 | |
e501603b TO |
248 | /** |
249 | * comma-separated list of email addresses to cc each time a receipt is sent | |
250 | * | |
251 | * @var string | |
252 | */ | |
253 | public $cc_receipt; | |
c3fc2621 | 254 | |
e501603b TO |
255 | /** |
256 | * comma-separated list of email addresses to bcc each time a receipt is sent | |
257 | * | |
258 | * @var string | |
259 | */ | |
260 | public $bcc_receipt; | |
c3fc2621 | 261 | |
e501603b TO |
262 | /** |
263 | * text to include above standard receipt info on receipt email. emails are text-only, so do not allow html for now | |
264 | * | |
265 | * @var text | |
266 | */ | |
267 | public $receipt_text; | |
c3fc2621 | 268 | |
e501603b TO |
269 | /** |
270 | * Is this property active? | |
271 | * | |
e6ca0a57 | 272 | * @var bool |
e501603b TO |
273 | */ |
274 | public $is_active; | |
c3fc2621 | 275 | |
e501603b TO |
276 | /** |
277 | * Text and html allowed. Displayed at the bottom of the first page of the contribution wizard. | |
278 | * | |
279 | * @var text | |
280 | */ | |
281 | public $footer_text; | |
c3fc2621 | 282 | |
e501603b TO |
283 | /** |
284 | * Is this property active? | |
285 | * | |
e6ca0a57 | 286 | * @var bool |
e501603b TO |
287 | */ |
288 | public $amount_block_is_active; | |
c3fc2621 | 289 | |
e501603b TO |
290 | /** |
291 | * Date and time that this page starts. | |
292 | * | |
293 | * @var datetime | |
294 | */ | |
295 | public $start_date; | |
c3fc2621 | 296 | |
e501603b TO |
297 | /** |
298 | * Date and time that this page ends. May be NULL if no defined end date/time | |
299 | * | |
300 | * @var datetime | |
301 | */ | |
302 | public $end_date; | |
c3fc2621 | 303 | |
e501603b TO |
304 | /** |
305 | * FK to civicrm_contact, who created this contribution page | |
306 | * | |
e6ca0a57 | 307 | * @var int |
e501603b TO |
308 | */ |
309 | public $created_id; | |
c3fc2621 | 310 | |
e501603b TO |
311 | /** |
312 | * Date and time that contribution page was created. | |
313 | * | |
314 | * @var datetime | |
315 | */ | |
316 | public $created_date; | |
c3fc2621 | 317 | |
e501603b TO |
318 | /** |
319 | * 3 character string, value from config setting or input via user. | |
320 | * | |
321 | * @var string | |
322 | */ | |
323 | public $currency; | |
c3fc2621 | 324 | |
e501603b TO |
325 | /** |
326 | * The campaign for which we are collecting contributions with this page. | |
327 | * | |
e6ca0a57 | 328 | * @var int |
e501603b TO |
329 | */ |
330 | public $campaign_id; | |
c3fc2621 | 331 | |
e501603b TO |
332 | /** |
333 | * Can people share the contribution page through social media? | |
334 | * | |
e6ca0a57 | 335 | * @var bool |
e501603b TO |
336 | */ |
337 | public $is_share; | |
c3fc2621 | 338 | |
e501603b TO |
339 | /** |
340 | * if true - billing block is required for online contribution page | |
341 | * | |
e6ca0a57 | 342 | * @var bool |
e501603b TO |
343 | */ |
344 | public $is_billing_required; | |
c3fc2621 | 345 | |
e501603b | 346 | /** |
f41f0342 | 347 | * Class constructor. |
e501603b | 348 | */ |
c3fc2621 | 349 | public function __construct() { |
e501603b TO |
350 | $this->__table = 'civicrm_contribution_page'; |
351 | parent::__construct(); | |
352 | } | |
c3fc2621 | 353 | |
e501603b | 354 | /** |
f41f0342 | 355 | * Returns foreign keys and entity references. |
e501603b TO |
356 | * |
357 | * @return array | |
358 | * [CRM_Core_Reference_Interface] | |
359 | */ | |
c3fc2621 | 360 | public static function getReferenceColumns() { |
346aaaba | 361 | if (!isset(Civi::$statics[__CLASS__]['links'])) { |
fa45b5b9 | 362 | Civi::$statics[__CLASS__]['links'] = static::createReferenceColumns(__CLASS__); |
c3fc2621 CW |
363 | Civi::$statics[__CLASS__]['links'][] = new CRM_Core_Reference_Basic(self::getTableName(), 'financial_type_id', 'civicrm_financial_type', 'id'); |
364 | Civi::$statics[__CLASS__]['links'][] = new CRM_Core_Reference_Basic(self::getTableName(), 'created_id', 'civicrm_contact', 'id'); | |
365 | Civi::$statics[__CLASS__]['links'][] = new CRM_Core_Reference_Basic(self::getTableName(), 'campaign_id', 'civicrm_campaign', 'id'); | |
346aaaba | 366 | CRM_Core_DAO_AllCoreTables::invoke(__CLASS__, 'links_callback', Civi::$statics[__CLASS__]['links']); |
e501603b | 367 | } |
346aaaba | 368 | return Civi::$statics[__CLASS__]['links']; |
e501603b | 369 | } |
c3fc2621 | 370 | |
e501603b TO |
371 | /** |
372 | * Returns all the column names of this table | |
373 | * | |
374 | * @return array | |
375 | */ | |
c3fc2621 | 376 | public static function &fields() { |
346aaaba | 377 | if (!isset(Civi::$statics[__CLASS__]['fields'])) { |
c3fc2621 CW |
378 | Civi::$statics[__CLASS__]['fields'] = [ |
379 | 'id' => [ | |
e501603b TO |
380 | 'name' => 'id', |
381 | 'type' => CRM_Utils_Type::T_INT, | |
c3fc2621 | 382 | 'title' => ts('Contribution Page ID'), |
215b423e | 383 | 'description' => ts('Contribution Id'), |
c3fc2621 | 384 | 'required' => TRUE, |
a36434b9 | 385 | 'where' => 'civicrm_contribution_page.id', |
522a26c9 | 386 | 'table_name' => 'civicrm_contribution_page', |
387 | 'entity' => 'ContributionPage', | |
388 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 389 | 'localizable' => 0, |
c3fc2621 CW |
390 | ], |
391 | 'title' => [ | |
e501603b TO |
392 | 'name' => 'title', |
393 | 'type' => CRM_Utils_Type::T_STRING, | |
c3fc2621 | 394 | 'title' => ts('Contribution Page Title'), |
215b423e | 395 | 'description' => ts('Contribution Page title. For top of page display'), |
e501603b TO |
396 | 'maxlength' => 255, |
397 | 'size' => CRM_Utils_Type::HUGE, | |
a36434b9 | 398 | 'where' => 'civicrm_contribution_page.title', |
522a26c9 | 399 | 'table_name' => 'civicrm_contribution_page', |
400 | 'entity' => 'ContributionPage', | |
401 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 402 | 'localizable' => 1, |
c3fc2621 CW |
403 | ], |
404 | 'intro_text' => [ | |
e501603b TO |
405 | 'name' => 'intro_text', |
406 | 'type' => CRM_Utils_Type::T_TEXT, | |
c3fc2621 | 407 | 'title' => ts('Contribution Page Introduction Text'), |
215b423e | 408 | 'description' => ts('Text and html allowed. Displayed below title.'), |
e501603b TO |
409 | 'rows' => 6, |
410 | 'cols' => 50, | |
a36434b9 | 411 | 'where' => 'civicrm_contribution_page.intro_text', |
522a26c9 | 412 | 'table_name' => 'civicrm_contribution_page', |
413 | 'entity' => 'ContributionPage', | |
414 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 415 | 'localizable' => 1, |
c3fc2621 | 416 | 'html' => [ |
e501603b | 417 | 'type' => 'RichTextEditor', |
c3fc2621 CW |
418 | ], |
419 | ], | |
420 | 'financial_type_id' => [ | |
e501603b TO |
421 | 'name' => 'financial_type_id', |
422 | 'type' => CRM_Utils_Type::T_INT, | |
c3fc2621 | 423 | 'title' => ts('Financial Type'), |
215b423e | 424 | 'description' => ts('default financial type assigned to contributions submitted via this page, e.g. Contribution, Campaign Contribution'), |
a36434b9 | 425 | 'where' => 'civicrm_contribution_page.financial_type_id', |
522a26c9 | 426 | 'table_name' => 'civicrm_contribution_page', |
427 | 'entity' => 'ContributionPage', | |
428 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 429 | 'localizable' => 0, |
e501603b | 430 | 'FKClassName' => 'CRM_Financial_DAO_FinancialType', |
c3fc2621 | 431 | 'html' => [ |
e501603b | 432 | 'type' => 'Select', |
c3fc2621 CW |
433 | ], |
434 | 'pseudoconstant' => [ | |
e501603b TO |
435 | 'table' => 'civicrm_financial_type', |
436 | 'keyColumn' => 'id', | |
437 | 'labelColumn' => 'name', | |
e6ca0a57 | 438 | ], |
c3fc2621 CW |
439 | ], |
440 | 'payment_processor' => [ | |
e501603b TO |
441 | 'name' => 'payment_processor', |
442 | 'type' => CRM_Utils_Type::T_STRING, | |
c3fc2621 | 443 | 'title' => ts('Payment Processor'), |
215b423e | 444 | 'description' => ts('Payment Processors configured for this contribution Page'), |
e501603b TO |
445 | 'maxlength' => 128, |
446 | 'size' => CRM_Utils_Type::HUGE, | |
a36434b9 | 447 | 'where' => 'civicrm_contribution_page.payment_processor', |
522a26c9 | 448 | 'table_name' => 'civicrm_contribution_page', |
449 | 'entity' => 'ContributionPage', | |
450 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 451 | 'localizable' => 0, |
c3fc2621 | 452 | 'html' => [ |
e501603b | 453 | 'type' => 'Select', |
c3fc2621 CW |
454 | ], |
455 | 'pseudoconstant' => [ | |
e501603b TO |
456 | 'table' => 'civicrm_payment_processor', |
457 | 'keyColumn' => 'id', | |
458 | 'labelColumn' => 'name', | |
e6ca0a57 | 459 | ], |
c3fc2621 CW |
460 | ], |
461 | 'is_credit_card_only' => [ | |
e501603b TO |
462 | 'name' => 'is_credit_card_only', |
463 | 'type' => CRM_Utils_Type::T_BOOLEAN, | |
c3fc2621 | 464 | 'title' => ts('Is Credit Card Only?'), |
215b423e | 465 | 'description' => ts('if true - processing logic must reject transaction at confirmation stage if pay method != credit card'), |
a36434b9 | 466 | 'where' => 'civicrm_contribution_page.is_credit_card_only', |
45a83e42 | 467 | 'default' => '0', |
522a26c9 | 468 | 'table_name' => 'civicrm_contribution_page', |
469 | 'entity' => 'ContributionPage', | |
470 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 471 | 'localizable' => 0, |
c3fc2621 CW |
472 | ], |
473 | 'is_monetary' => [ | |
e501603b TO |
474 | 'name' => 'is_monetary', |
475 | 'type' => CRM_Utils_Type::T_BOOLEAN, | |
c3fc2621 | 476 | 'title' => ts('Is Monetary'), |
215b423e | 477 | 'description' => ts('if true - allows real-time monetary transactions otherwise non-monetary transactions'), |
a36434b9 | 478 | 'where' => 'civicrm_contribution_page.is_monetary', |
e501603b | 479 | 'default' => '1', |
522a26c9 | 480 | 'table_name' => 'civicrm_contribution_page', |
481 | 'entity' => 'ContributionPage', | |
482 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 483 | 'localizable' => 0, |
c3fc2621 CW |
484 | ], |
485 | 'is_recur' => [ | |
e501603b TO |
486 | 'name' => 'is_recur', |
487 | 'type' => CRM_Utils_Type::T_BOOLEAN, | |
c3fc2621 | 488 | 'title' => ts('Is Recurring'), |
215b423e | 489 | 'description' => ts('if true - allows recurring contributions, valid only for PayPal_Standard'), |
a36434b9 | 490 | 'where' => 'civicrm_contribution_page.is_recur', |
45a83e42 | 491 | 'default' => '0', |
522a26c9 | 492 | 'table_name' => 'civicrm_contribution_page', |
493 | 'entity' => 'ContributionPage', | |
494 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 495 | 'localizable' => 0, |
c3fc2621 CW |
496 | ], |
497 | 'is_confirm_enabled' => [ | |
e501603b TO |
498 | 'name' => 'is_confirm_enabled', |
499 | 'type' => CRM_Utils_Type::T_BOOLEAN, | |
c3fc2621 | 500 | 'title' => ts('Confirmation Page?'), |
215b423e | 501 | 'description' => ts('if false, the confirm page in contribution pages gets skipped'), |
a36434b9 | 502 | 'where' => 'civicrm_contribution_page.is_confirm_enabled', |
e501603b | 503 | 'default' => '1', |
522a26c9 | 504 | 'table_name' => 'civicrm_contribution_page', |
505 | 'entity' => 'ContributionPage', | |
506 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 507 | 'localizable' => 0, |
c3fc2621 CW |
508 | ], |
509 | 'recur_frequency_unit' => [ | |
e501603b TO |
510 | 'name' => 'recur_frequency_unit', |
511 | 'type' => CRM_Utils_Type::T_STRING, | |
c3fc2621 | 512 | 'title' => ts('Recurring Frequency'), |
215b423e | 513 | 'description' => ts('Supported recurring frequency units.'), |
e501603b TO |
514 | 'maxlength' => 128, |
515 | 'size' => CRM_Utils_Type::HUGE, | |
a36434b9 | 516 | 'where' => 'civicrm_contribution_page.recur_frequency_unit', |
522a26c9 | 517 | 'table_name' => 'civicrm_contribution_page', |
518 | 'entity' => 'ContributionPage', | |
519 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 520 | 'localizable' => 0, |
2a5c9b4d | 521 | 'serialize' => self::SERIALIZE_SEPARATOR_TRIMMED, |
c3fc2621 | 522 | 'html' => [ |
2a5c9b4d | 523 | 'type' => 'Select', |
c3fc2621 CW |
524 | ], |
525 | 'pseudoconstant' => [ | |
2a5c9b4d CW |
526 | 'optionGroupName' => 'recur_frequency_units', |
527 | 'keyColumn' => 'name', | |
528 | 'optionEditPath' => 'civicrm/admin/options/recur_frequency_units', | |
e6ca0a57 | 529 | ], |
c3fc2621 CW |
530 | ], |
531 | 'is_recur_interval' => [ | |
e501603b TO |
532 | 'name' => 'is_recur_interval', |
533 | 'type' => CRM_Utils_Type::T_BOOLEAN, | |
c3fc2621 | 534 | 'title' => ts('Support Recurring Intervals'), |
215b423e | 535 | 'description' => ts('if true - supports recurring intervals'), |
a36434b9 | 536 | 'where' => 'civicrm_contribution_page.is_recur_interval', |
45a83e42 | 537 | 'default' => '0', |
522a26c9 | 538 | 'table_name' => 'civicrm_contribution_page', |
539 | 'entity' => 'ContributionPage', | |
540 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 541 | 'localizable' => 0, |
c3fc2621 CW |
542 | ], |
543 | 'is_recur_installments' => [ | |
e501603b TO |
544 | 'name' => 'is_recur_installments', |
545 | 'type' => CRM_Utils_Type::T_BOOLEAN, | |
c3fc2621 | 546 | 'title' => ts('Recurring Installments?'), |
215b423e | 547 | 'description' => ts('if true - asks user for recurring installments'), |
a36434b9 | 548 | 'where' => 'civicrm_contribution_page.is_recur_installments', |
45a83e42 | 549 | 'default' => '0', |
522a26c9 | 550 | 'table_name' => 'civicrm_contribution_page', |
551 | 'entity' => 'ContributionPage', | |
552 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 553 | 'localizable' => 0, |
c3fc2621 CW |
554 | ], |
555 | 'adjust_recur_start_date' => [ | |
e501603b TO |
556 | 'name' => 'adjust_recur_start_date', |
557 | 'type' => CRM_Utils_Type::T_BOOLEAN, | |
c3fc2621 | 558 | 'title' => ts('Adjust Recurring Start Date'), |
215b423e | 559 | 'description' => ts('if true - user is able to adjust payment start date'), |
a36434b9 | 560 | 'where' => 'civicrm_contribution_page.adjust_recur_start_date', |
45a83e42 | 561 | 'default' => '0', |
522a26c9 | 562 | 'table_name' => 'civicrm_contribution_page', |
563 | 'entity' => 'ContributionPage', | |
564 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 565 | 'localizable' => 0, |
c3fc2621 CW |
566 | ], |
567 | 'is_pay_later' => [ | |
e501603b TO |
568 | 'name' => 'is_pay_later', |
569 | 'type' => CRM_Utils_Type::T_BOOLEAN, | |
c3fc2621 | 570 | 'title' => ts('Pay Later'), |
215b423e | 571 | 'description' => ts('if true - allows the user to send payment directly to the org later'), |
a36434b9 | 572 | 'where' => 'civicrm_contribution_page.is_pay_later', |
45a83e42 | 573 | 'default' => '0', |
522a26c9 | 574 | 'table_name' => 'civicrm_contribution_page', |
575 | 'entity' => 'ContributionPage', | |
576 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 577 | 'localizable' => 0, |
c3fc2621 CW |
578 | ], |
579 | 'pay_later_text' => [ | |
e501603b TO |
580 | 'name' => 'pay_later_text', |
581 | 'type' => CRM_Utils_Type::T_TEXT, | |
c3fc2621 | 582 | 'title' => ts('Pay Later Text'), |
215b423e | 583 | 'description' => ts('The text displayed to the user in the main form'), |
a36434b9 | 584 | 'where' => 'civicrm_contribution_page.pay_later_text', |
522a26c9 | 585 | 'table_name' => 'civicrm_contribution_page', |
586 | 'entity' => 'ContributionPage', | |
587 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 588 | 'localizable' => 1, |
c3fc2621 CW |
589 | ], |
590 | 'pay_later_receipt' => [ | |
e501603b TO |
591 | 'name' => 'pay_later_receipt', |
592 | 'type' => CRM_Utils_Type::T_TEXT, | |
c3fc2621 | 593 | 'title' => ts('Pay Later Receipt'), |
215b423e | 594 | 'description' => ts('The receipt sent to the user instead of the normal receipt text'), |
a36434b9 | 595 | 'where' => 'civicrm_contribution_page.pay_later_receipt', |
522a26c9 | 596 | 'table_name' => 'civicrm_contribution_page', |
597 | 'entity' => 'ContributionPage', | |
598 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 599 | 'localizable' => 1, |
c3fc2621 CW |
600 | ], |
601 | 'is_partial_payment' => [ | |
e501603b TO |
602 | 'name' => 'is_partial_payment', |
603 | 'type' => CRM_Utils_Type::T_BOOLEAN, | |
c3fc2621 | 604 | 'title' => ts('Allow Partial Payment'), |
215b423e | 605 | 'description' => ts('is partial payment enabled for this online contribution page'), |
a36434b9 | 606 | 'where' => 'civicrm_contribution_page.is_partial_payment', |
45a83e42 | 607 | 'default' => '0', |
522a26c9 | 608 | 'table_name' => 'civicrm_contribution_page', |
609 | 'entity' => 'ContributionPage', | |
610 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 611 | 'localizable' => 0, |
c3fc2621 CW |
612 | ], |
613 | 'initial_amount_label' => [ | |
e501603b TO |
614 | 'name' => 'initial_amount_label', |
615 | 'type' => CRM_Utils_Type::T_STRING, | |
c3fc2621 | 616 | 'title' => ts('Initial Amount Label'), |
215b423e | 617 | 'description' => ts('Initial amount label for partial payment'), |
e501603b TO |
618 | 'maxlength' => 255, |
619 | 'size' => CRM_Utils_Type::HUGE, | |
a36434b9 | 620 | 'where' => 'civicrm_contribution_page.initial_amount_label', |
522a26c9 | 621 | 'table_name' => 'civicrm_contribution_page', |
622 | 'entity' => 'ContributionPage', | |
623 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 624 | 'localizable' => 1, |
c3fc2621 CW |
625 | ], |
626 | 'initial_amount_help_text' => [ | |
e501603b TO |
627 | 'name' => 'initial_amount_help_text', |
628 | 'type' => CRM_Utils_Type::T_TEXT, | |
c3fc2621 | 629 | 'title' => ts('Initial Amount Help Text'), |
215b423e | 630 | 'description' => ts('Initial amount help text for partial payment'), |
a36434b9 | 631 | 'where' => 'civicrm_contribution_page.initial_amount_help_text', |
522a26c9 | 632 | 'table_name' => 'civicrm_contribution_page', |
633 | 'entity' => 'ContributionPage', | |
634 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 635 | 'localizable' => 1, |
c3fc2621 CW |
636 | ], |
637 | 'min_initial_amount' => [ | |
e501603b TO |
638 | 'name' => 'min_initial_amount', |
639 | 'type' => CRM_Utils_Type::T_MONEY, | |
c3fc2621 | 640 | 'title' => ts('Min Initial Amount'), |
215b423e | 641 | 'description' => ts('Minimum initial amount for partial payment'), |
c3fc2621 | 642 | 'precision' => [ |
e501603b | 643 | 20, |
fb607354 | 644 | 2, |
c3fc2621 | 645 | ], |
a36434b9 | 646 | 'where' => 'civicrm_contribution_page.min_initial_amount', |
522a26c9 | 647 | 'table_name' => 'civicrm_contribution_page', |
648 | 'entity' => 'ContributionPage', | |
649 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 650 | 'localizable' => 0, |
c3fc2621 CW |
651 | ], |
652 | 'is_allow_other_amount' => [ | |
e501603b TO |
653 | 'name' => 'is_allow_other_amount', |
654 | 'type' => CRM_Utils_Type::T_BOOLEAN, | |
c3fc2621 | 655 | 'title' => ts('Allow Other Amounts'), |
215b423e | 656 | 'description' => ts('if true, page will include an input text field where user can enter their own amount'), |
a36434b9 | 657 | 'where' => 'civicrm_contribution_page.is_allow_other_amount', |
45a83e42 | 658 | 'default' => '0', |
522a26c9 | 659 | 'table_name' => 'civicrm_contribution_page', |
660 | 'entity' => 'ContributionPage', | |
661 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 662 | 'localizable' => 0, |
c3fc2621 CW |
663 | ], |
664 | 'default_amount_id' => [ | |
e501603b TO |
665 | 'name' => 'default_amount_id', |
666 | 'type' => CRM_Utils_Type::T_INT, | |
c3fc2621 | 667 | 'title' => ts('Default Amount'), |
215b423e | 668 | 'description' => ts('FK to civicrm_option_value.'), |
a36434b9 | 669 | 'where' => 'civicrm_contribution_page.default_amount_id', |
522a26c9 | 670 | 'table_name' => 'civicrm_contribution_page', |
671 | 'entity' => 'ContributionPage', | |
672 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 673 | 'localizable' => 0, |
c3fc2621 CW |
674 | ], |
675 | 'min_amount' => [ | |
e501603b TO |
676 | 'name' => 'min_amount', |
677 | 'type' => CRM_Utils_Type::T_MONEY, | |
c3fc2621 | 678 | 'title' => ts('Minimum Amount'), |
215b423e | 679 | 'description' => ts('if other amounts allowed, user can configure minimum allowed.'), |
c3fc2621 | 680 | 'precision' => [ |
e501603b | 681 | 20, |
fb607354 | 682 | 2, |
c3fc2621 | 683 | ], |
a36434b9 | 684 | 'where' => 'civicrm_contribution_page.min_amount', |
522a26c9 | 685 | 'table_name' => 'civicrm_contribution_page', |
686 | 'entity' => 'ContributionPage', | |
687 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 688 | 'localizable' => 0, |
c3fc2621 CW |
689 | ], |
690 | 'max_amount' => [ | |
e501603b TO |
691 | 'name' => 'max_amount', |
692 | 'type' => CRM_Utils_Type::T_MONEY, | |
c3fc2621 | 693 | 'title' => ts('Maximum Amount'), |
215b423e | 694 | 'description' => ts('if other amounts allowed, user can configure maximum allowed.'), |
c3fc2621 | 695 | 'precision' => [ |
e501603b | 696 | 20, |
fb607354 | 697 | 2, |
c3fc2621 | 698 | ], |
a36434b9 | 699 | 'where' => 'civicrm_contribution_page.max_amount', |
522a26c9 | 700 | 'table_name' => 'civicrm_contribution_page', |
701 | 'entity' => 'ContributionPage', | |
702 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 703 | 'localizable' => 0, |
c3fc2621 CW |
704 | ], |
705 | 'goal_amount' => [ | |
e501603b TO |
706 | 'name' => 'goal_amount', |
707 | 'type' => CRM_Utils_Type::T_MONEY, | |
c3fc2621 | 708 | 'title' => ts('Goal Amount'), |
215b423e | 709 | 'description' => ts('The target goal for this page, allows people to build a goal meter'), |
c3fc2621 | 710 | 'precision' => [ |
e501603b | 711 | 20, |
fb607354 | 712 | 2, |
c3fc2621 | 713 | ], |
a36434b9 | 714 | 'where' => 'civicrm_contribution_page.goal_amount', |
522a26c9 | 715 | 'table_name' => 'civicrm_contribution_page', |
716 | 'entity' => 'ContributionPage', | |
717 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 718 | 'localizable' => 0, |
c3fc2621 CW |
719 | ], |
720 | 'thankyou_title' => [ | |
e501603b TO |
721 | 'name' => 'thankyou_title', |
722 | 'type' => CRM_Utils_Type::T_STRING, | |
c3fc2621 | 723 | 'title' => ts('Thank-you Title'), |
215b423e | 724 | 'description' => ts('Title for Thank-you page (header title tag, and display at the top of the page).'), |
e501603b TO |
725 | 'maxlength' => 255, |
726 | 'size' => CRM_Utils_Type::HUGE, | |
a36434b9 | 727 | 'where' => 'civicrm_contribution_page.thankyou_title', |
522a26c9 | 728 | 'table_name' => 'civicrm_contribution_page', |
729 | 'entity' => 'ContributionPage', | |
730 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 731 | 'localizable' => 1, |
c3fc2621 CW |
732 | ], |
733 | 'thankyou_text' => [ | |
e501603b TO |
734 | 'name' => 'thankyou_text', |
735 | 'type' => CRM_Utils_Type::T_TEXT, | |
c3fc2621 | 736 | 'title' => ts('Thank-you Text'), |
215b423e | 737 | 'description' => ts('text and html allowed. displayed above result on success page'), |
e501603b TO |
738 | 'rows' => 8, |
739 | 'cols' => 60, | |
a36434b9 | 740 | 'where' => 'civicrm_contribution_page.thankyou_text', |
522a26c9 | 741 | 'table_name' => 'civicrm_contribution_page', |
742 | 'entity' => 'ContributionPage', | |
743 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 744 | 'localizable' => 1, |
c3fc2621 | 745 | 'html' => [ |
e501603b | 746 | 'type' => 'RichTextEditor', |
c3fc2621 CW |
747 | ], |
748 | ], | |
749 | 'thankyou_footer' => [ | |
e501603b TO |
750 | 'name' => 'thankyou_footer', |
751 | 'type' => CRM_Utils_Type::T_TEXT, | |
c3fc2621 | 752 | 'title' => ts('Thank-you Footer'), |
215b423e | 753 | 'description' => ts('Text and html allowed. displayed at the bottom of the success page. Common usage is to include link(s) to other pages such as tell-a-friend, etc.'), |
e501603b TO |
754 | 'rows' => 8, |
755 | 'cols' => 60, | |
a36434b9 | 756 | 'where' => 'civicrm_contribution_page.thankyou_footer', |
522a26c9 | 757 | 'table_name' => 'civicrm_contribution_page', |
758 | 'entity' => 'ContributionPage', | |
759 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 760 | 'localizable' => 1, |
c3fc2621 | 761 | 'html' => [ |
e501603b | 762 | 'type' => 'RichTextEditor', |
c3fc2621 CW |
763 | ], |
764 | ], | |
765 | 'is_email_receipt' => [ | |
e501603b TO |
766 | 'name' => 'is_email_receipt', |
767 | 'type' => CRM_Utils_Type::T_BOOLEAN, | |
c3fc2621 | 768 | 'title' => ts('Send email Receipt'), |
215b423e | 769 | 'description' => ts('if true, receipt is automatically emailed to contact on success'), |
a36434b9 | 770 | 'where' => 'civicrm_contribution_page.is_email_receipt', |
45a83e42 | 771 | 'default' => '0', |
522a26c9 | 772 | 'table_name' => 'civicrm_contribution_page', |
773 | 'entity' => 'ContributionPage', | |
774 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 775 | 'localizable' => 0, |
c3fc2621 CW |
776 | ], |
777 | 'receipt_from_name' => [ | |
e501603b TO |
778 | 'name' => 'receipt_from_name', |
779 | 'type' => CRM_Utils_Type::T_STRING, | |
c3fc2621 | 780 | 'title' => ts('Receipt From'), |
215b423e | 781 | 'description' => ts('FROM email name used for receipts generated by contributions to this contribution page.'), |
e501603b TO |
782 | 'maxlength' => 255, |
783 | 'size' => CRM_Utils_Type::HUGE, | |
a36434b9 | 784 | 'where' => 'civicrm_contribution_page.receipt_from_name', |
522a26c9 | 785 | 'table_name' => 'civicrm_contribution_page', |
786 | 'entity' => 'ContributionPage', | |
787 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 788 | 'localizable' => 1, |
c3fc2621 CW |
789 | ], |
790 | 'receipt_from_email' => [ | |
e501603b TO |
791 | 'name' => 'receipt_from_email', |
792 | 'type' => CRM_Utils_Type::T_STRING, | |
c3fc2621 | 793 | 'title' => ts('Receipt From email'), |
215b423e | 794 | 'description' => ts('FROM email address used for receipts generated by contributions to this contribution page.'), |
e501603b TO |
795 | 'maxlength' => 255, |
796 | 'size' => CRM_Utils_Type::HUGE, | |
a36434b9 | 797 | 'where' => 'civicrm_contribution_page.receipt_from_email', |
522a26c9 | 798 | 'table_name' => 'civicrm_contribution_page', |
799 | 'entity' => 'ContributionPage', | |
800 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 801 | 'localizable' => 0, |
c3fc2621 CW |
802 | ], |
803 | 'cc_receipt' => [ | |
e501603b TO |
804 | 'name' => 'cc_receipt', |
805 | 'type' => CRM_Utils_Type::T_STRING, | |
c3fc2621 | 806 | 'title' => ts('Receipt cc'), |
215b423e | 807 | 'description' => ts('comma-separated list of email addresses to cc each time a receipt is sent'), |
e501603b TO |
808 | 'maxlength' => 255, |
809 | 'size' => CRM_Utils_Type::HUGE, | |
a36434b9 | 810 | 'where' => 'civicrm_contribution_page.cc_receipt', |
522a26c9 | 811 | 'table_name' => 'civicrm_contribution_page', |
812 | 'entity' => 'ContributionPage', | |
813 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 814 | 'localizable' => 0, |
c3fc2621 CW |
815 | ], |
816 | 'bcc_receipt' => [ | |
e501603b TO |
817 | 'name' => 'bcc_receipt', |
818 | 'type' => CRM_Utils_Type::T_STRING, | |
c3fc2621 | 819 | 'title' => ts('Receipt bcc'), |
215b423e | 820 | 'description' => ts('comma-separated list of email addresses to bcc each time a receipt is sent'), |
e501603b TO |
821 | 'maxlength' => 255, |
822 | 'size' => CRM_Utils_Type::HUGE, | |
a36434b9 | 823 | 'where' => 'civicrm_contribution_page.bcc_receipt', |
522a26c9 | 824 | 'table_name' => 'civicrm_contribution_page', |
825 | 'entity' => 'ContributionPage', | |
826 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 827 | 'localizable' => 0, |
c3fc2621 CW |
828 | ], |
829 | 'receipt_text' => [ | |
e501603b TO |
830 | 'name' => 'receipt_text', |
831 | 'type' => CRM_Utils_Type::T_TEXT, | |
c3fc2621 | 832 | 'title' => ts('Receipt Text'), |
215b423e | 833 | 'description' => ts('text to include above standard receipt info on receipt email. emails are text-only, so do not allow html for now'), |
e501603b TO |
834 | 'rows' => 6, |
835 | 'cols' => 50, | |
a36434b9 | 836 | 'where' => 'civicrm_contribution_page.receipt_text', |
522a26c9 | 837 | 'table_name' => 'civicrm_contribution_page', |
838 | 'entity' => 'ContributionPage', | |
839 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 840 | 'localizable' => 1, |
c3fc2621 | 841 | 'html' => [ |
e501603b | 842 | 'type' => 'TextArea', |
c3fc2621 CW |
843 | ], |
844 | ], | |
845 | 'is_active' => [ | |
e501603b TO |
846 | 'name' => 'is_active', |
847 | 'type' => CRM_Utils_Type::T_BOOLEAN, | |
c3fc2621 | 848 | 'title' => ts('Is Page Active?'), |
215b423e | 849 | 'description' => ts('Is this property active?'), |
a36434b9 | 850 | 'where' => 'civicrm_contribution_page.is_active', |
522a26c9 | 851 | 'table_name' => 'civicrm_contribution_page', |
852 | 'entity' => 'ContributionPage', | |
853 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 854 | 'localizable' => 0, |
c3fc2621 CW |
855 | ], |
856 | 'footer_text' => [ | |
e501603b TO |
857 | 'name' => 'footer_text', |
858 | 'type' => CRM_Utils_Type::T_TEXT, | |
c3fc2621 | 859 | 'title' => ts('Footer Text'), |
215b423e | 860 | 'description' => ts('Text and html allowed. Displayed at the bottom of the first page of the contribution wizard.'), |
e501603b TO |
861 | 'rows' => 6, |
862 | 'cols' => 50, | |
a36434b9 | 863 | 'where' => 'civicrm_contribution_page.footer_text', |
522a26c9 | 864 | 'table_name' => 'civicrm_contribution_page', |
865 | 'entity' => 'ContributionPage', | |
866 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 867 | 'localizable' => 1, |
c3fc2621 | 868 | 'html' => [ |
e501603b | 869 | 'type' => 'RichTextEditor', |
c3fc2621 CW |
870 | ], |
871 | ], | |
872 | 'amount_block_is_active' => [ | |
e501603b TO |
873 | 'name' => 'amount_block_is_active', |
874 | 'type' => CRM_Utils_Type::T_BOOLEAN, | |
c3fc2621 | 875 | 'title' => ts('Is Amount Block Active?'), |
215b423e | 876 | 'description' => ts('Is this property active?'), |
a36434b9 | 877 | 'where' => 'civicrm_contribution_page.amount_block_is_active', |
e501603b | 878 | 'default' => '1', |
522a26c9 | 879 | 'table_name' => 'civicrm_contribution_page', |
880 | 'entity' => 'ContributionPage', | |
881 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 882 | 'localizable' => 0, |
c3fc2621 CW |
883 | ], |
884 | 'start_date' => [ | |
e501603b TO |
885 | 'name' => 'start_date', |
886 | 'type' => CRM_Utils_Type::T_DATE + CRM_Utils_Type::T_TIME, | |
c3fc2621 | 887 | 'title' => ts('Contribution Page Start Date'), |
215b423e | 888 | 'description' => ts('Date and time that this page starts.'), |
a36434b9 | 889 | 'where' => 'civicrm_contribution_page.start_date', |
522a26c9 | 890 | 'table_name' => 'civicrm_contribution_page', |
891 | 'entity' => 'ContributionPage', | |
892 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 893 | 'localizable' => 0, |
c3fc2621 CW |
894 | ], |
895 | 'end_date' => [ | |
e501603b TO |
896 | 'name' => 'end_date', |
897 | 'type' => CRM_Utils_Type::T_DATE + CRM_Utils_Type::T_TIME, | |
c3fc2621 | 898 | 'title' => ts('Contribution Page End Date'), |
215b423e | 899 | 'description' => ts('Date and time that this page ends. May be NULL if no defined end date/time'), |
a36434b9 | 900 | 'where' => 'civicrm_contribution_page.end_date', |
522a26c9 | 901 | 'table_name' => 'civicrm_contribution_page', |
902 | 'entity' => 'ContributionPage', | |
903 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 904 | 'localizable' => 0, |
c3fc2621 CW |
905 | ], |
906 | 'created_id' => [ | |
e501603b TO |
907 | 'name' => 'created_id', |
908 | 'type' => CRM_Utils_Type::T_INT, | |
c3fc2621 | 909 | 'title' => ts('Contribution Page Created By'), |
215b423e | 910 | 'description' => ts('FK to civicrm_contact, who created this contribution page'), |
a36434b9 | 911 | 'where' => 'civicrm_contribution_page.created_id', |
522a26c9 | 912 | 'table_name' => 'civicrm_contribution_page', |
913 | 'entity' => 'ContributionPage', | |
914 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 915 | 'localizable' => 0, |
e501603b | 916 | 'FKClassName' => 'CRM_Contact_DAO_Contact', |
c3fc2621 CW |
917 | ], |
918 | 'created_date' => [ | |
e501603b TO |
919 | 'name' => 'created_date', |
920 | 'type' => CRM_Utils_Type::T_DATE + CRM_Utils_Type::T_TIME, | |
c3fc2621 | 921 | 'title' => ts('Contribution Page Created Date'), |
215b423e | 922 | 'description' => ts('Date and time that contribution page was created.'), |
a36434b9 | 923 | 'where' => 'civicrm_contribution_page.created_date', |
522a26c9 | 924 | 'table_name' => 'civicrm_contribution_page', |
925 | 'entity' => 'ContributionPage', | |
926 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 927 | 'localizable' => 0, |
c3fc2621 CW |
928 | ], |
929 | 'currency' => [ | |
e501603b TO |
930 | 'name' => 'currency', |
931 | 'type' => CRM_Utils_Type::T_STRING, | |
c3fc2621 | 932 | 'title' => ts('Contribution Page Currency'), |
215b423e | 933 | 'description' => ts('3 character string, value from config setting or input via user.'), |
e501603b TO |
934 | 'maxlength' => 3, |
935 | 'size' => CRM_Utils_Type::FOUR, | |
a36434b9 | 936 | 'where' => 'civicrm_contribution_page.currency', |
937 | 'headerPattern' => '/cur(rency)?/i', | |
938 | 'dataPattern' => '/^[A-Z]{3}$/i', | |
e501603b | 939 | 'default' => 'NULL', |
522a26c9 | 940 | 'table_name' => 'civicrm_contribution_page', |
941 | 'entity' => 'ContributionPage', | |
942 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 943 | 'localizable' => 0, |
c3fc2621 | 944 | 'html' => [ |
e501603b | 945 | 'type' => 'Select', |
c3fc2621 CW |
946 | ], |
947 | 'pseudoconstant' => [ | |
e501603b TO |
948 | 'table' => 'civicrm_currency', |
949 | 'keyColumn' => 'name', | |
950 | 'labelColumn' => 'full_name', | |
951 | 'nameColumn' => 'name', | |
e6ca0a57 | 952 | ], |
c3fc2621 CW |
953 | ], |
954 | 'campaign_id' => [ | |
e501603b TO |
955 | 'name' => 'campaign_id', |
956 | 'type' => CRM_Utils_Type::T_INT, | |
c3fc2621 | 957 | 'title' => ts('Contribution Page Campaign ID'), |
215b423e | 958 | 'description' => ts('The campaign for which we are collecting contributions with this page.'), |
a36434b9 | 959 | 'where' => 'civicrm_contribution_page.campaign_id', |
522a26c9 | 960 | 'table_name' => 'civicrm_contribution_page', |
961 | 'entity' => 'ContributionPage', | |
962 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 963 | 'localizable' => 0, |
e501603b | 964 | 'FKClassName' => 'CRM_Campaign_DAO_Campaign', |
c3fc2621 | 965 | 'pseudoconstant' => [ |
e501603b TO |
966 | 'table' => 'civicrm_campaign', |
967 | 'keyColumn' => 'id', | |
968 | 'labelColumn' => 'title', | |
e6ca0a57 | 969 | ], |
c3fc2621 CW |
970 | ], |
971 | 'is_share' => [ | |
e501603b TO |
972 | 'name' => 'is_share', |
973 | 'type' => CRM_Utils_Type::T_BOOLEAN, | |
c3fc2621 | 974 | 'title' => ts('Is Contribution Page Shared?'), |
215b423e | 975 | 'description' => ts('Can people share the contribution page through social media?'), |
a36434b9 | 976 | 'where' => 'civicrm_contribution_page.is_share', |
e501603b | 977 | 'default' => '1', |
522a26c9 | 978 | 'table_name' => 'civicrm_contribution_page', |
979 | 'entity' => 'ContributionPage', | |
980 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 981 | 'localizable' => 0, |
c3fc2621 CW |
982 | ], |
983 | 'is_billing_required' => [ | |
e501603b TO |
984 | 'name' => 'is_billing_required', |
985 | 'type' => CRM_Utils_Type::T_BOOLEAN, | |
c3fc2621 | 986 | 'title' => ts('Is billing block required'), |
215b423e | 987 | 'description' => ts('if true - billing block is required for online contribution page'), |
a36434b9 | 988 | 'where' => 'civicrm_contribution_page.is_billing_required', |
45a83e42 | 989 | 'default' => '0', |
522a26c9 | 990 | 'table_name' => 'civicrm_contribution_page', |
991 | 'entity' => 'ContributionPage', | |
992 | 'bao' => 'CRM_Contribute_BAO_ContributionPage', | |
6a7e5e5d | 993 | 'localizable' => 0, |
c3fc2621 CW |
994 | ], |
995 | ]; | |
346aaaba | 996 | CRM_Core_DAO_AllCoreTables::invoke(__CLASS__, 'fields_callback', Civi::$statics[__CLASS__]['fields']); |
e501603b | 997 | } |
346aaaba | 998 | return Civi::$statics[__CLASS__]['fields']; |
e501603b | 999 | } |
c3fc2621 | 1000 | |
e501603b | 1001 | /** |
bd8e0b14 | 1002 | * Return a mapping from field-name to the corresponding key (as used in fields()). |
e501603b TO |
1003 | * |
1004 | * @return array | |
bd8e0b14 | 1005 | * Array(string $name => string $uniqueName). |
e501603b | 1006 | */ |
c3fc2621 | 1007 | public static function &fieldKeys() { |
bd8e0b14 TO |
1008 | if (!isset(Civi::$statics[__CLASS__]['fieldKeys'])) { |
1009 | Civi::$statics[__CLASS__]['fieldKeys'] = array_flip(CRM_Utils_Array::collect('name', self::fields())); | |
e501603b | 1010 | } |
bd8e0b14 | 1011 | return Civi::$statics[__CLASS__]['fieldKeys']; |
e501603b | 1012 | } |
c3fc2621 | 1013 | |
e501603b TO |
1014 | /** |
1015 | * Returns the names of this table | |
1016 | * | |
1017 | * @return string | |
1018 | */ | |
c3fc2621 | 1019 | public static function getTableName() { |
e501603b TO |
1020 | return CRM_Core_DAO::getLocaleTableName(self::$_tableName); |
1021 | } | |
c3fc2621 | 1022 | |
e501603b TO |
1023 | /** |
1024 | * Returns if this table needs to be logged | |
1025 | * | |
c3fc2621 | 1026 | * @return bool |
e501603b | 1027 | */ |
c3fc2621 | 1028 | public function getLog() { |
e501603b TO |
1029 | return self::$_log; |
1030 | } | |
c3fc2621 | 1031 | |
e501603b TO |
1032 | /** |
1033 | * Returns the list of fields that can be imported | |
1034 | * | |
1035 | * @param bool $prefix | |
1036 | * | |
1037 | * @return array | |
1038 | */ | |
c3fc2621 CW |
1039 | public static function &import($prefix = FALSE) { |
1040 | $r = CRM_Core_DAO_AllCoreTables::getImports(__CLASS__, 'contribution_page', $prefix, []); | |
60808919 | 1041 | return $r; |
e501603b | 1042 | } |
c3fc2621 | 1043 | |
e501603b TO |
1044 | /** |
1045 | * Returns the list of fields that can be exported | |
1046 | * | |
1047 | * @param bool $prefix | |
1048 | * | |
1049 | * @return array | |
1050 | */ | |
c3fc2621 CW |
1051 | public static function &export($prefix = FALSE) { |
1052 | $r = CRM_Core_DAO_AllCoreTables::getExports(__CLASS__, 'contribution_page', $prefix, []); | |
60808919 | 1053 | return $r; |
e501603b | 1054 | } |
c3fc2621 | 1055 | |
e7a6b91a AS |
1056 | /** |
1057 | * Returns the list of indices | |
c3fc2621 CW |
1058 | * |
1059 | * @param bool $localize | |
1060 | * | |
1061 | * @return array | |
e7a6b91a AS |
1062 | */ |
1063 | public static function indices($localize = TRUE) { | |
c3fc2621 | 1064 | $indices = []; |
e7a6b91a AS |
1065 | return ($localize && !empty($indices)) ? CRM_Core_DAO_AllCoreTables::multilingualize(__CLASS__, $indices) : $indices; |
1066 | } | |
c3fc2621 | 1067 | |
e501603b | 1068 | } |