Regen DAOs with new import() / export()
[civicrm-core.git] / CRM / Contribute / DAO / ContributionPage.php
1 <?php
2 /*
3 +--------------------------------------------------------------------+
4 | CiviCRM version 4.7 |
5 +--------------------------------------------------------------------+
6 | Copyright CiviCRM LLC (c) 2004-2016 |
7 +--------------------------------------------------------------------+
8 | This file is a part of CiviCRM. |
9 | |
10 | CiviCRM is free software; you can copy, modify, and distribute it |
11 | under the terms of the GNU Affero General Public License |
12 | Version 3, 19 November 2007 and the CiviCRM Licensing Exception. |
13 | |
14 | CiviCRM is distributed in the hope that it will be useful, but |
15 | WITHOUT ANY WARRANTY; without even the implied warranty of |
16 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. |
17 | See the GNU Affero General Public License for more details. |
18 | |
19 | You should have received a copy of the GNU Affero General Public |
20 | License and the CiviCRM Licensing Exception along |
21 | with this program; if not, contact CiviCRM LLC |
22 | at info[AT]civicrm[DOT]org. If you have questions about the |
23 | GNU Affero General Public License or the licensing of CiviCRM, |
24 | see the CiviCRM license FAQ at http://civicrm.org/licensing |
25 +--------------------------------------------------------------------+
26 */
27 /**
28 * @package CRM
29 * @copyright CiviCRM LLC (c) 2004-2016
30 *
31 * Generated from xml/schema/CRM/Contribute/ContributionPage.xml
32 * DO NOT EDIT. Generated by CRM_Core_CodeGen
33 * (GenCodeChecksum:4948188e5ba353c75f5c3fe00e67a5ea)
34 */
35 require_once 'CRM/Core/DAO.php';
36 require_once 'CRM/Utils/Type.php';
37 class CRM_Contribute_DAO_ContributionPage extends CRM_Core_DAO {
38 /**
39 * static instance to hold the table name
40 *
41 * @var string
42 */
43 static $_tableName = 'civicrm_contribution_page';
44 /**
45 * static instance to hold the field values
46 *
47 * @var array
48 */
49 static $_fields = null;
50 /**
51 * static instance to hold the keys used in $_fields for each field.
52 *
53 * @var array
54 */
55 static $_fieldKeys = null;
56 /**
57 * static instance to hold the FK relationships
58 *
59 * @var string
60 */
61 static $_links = null;
62 /**
63 * static value to see if we should log any modifications to
64 * this table in the civicrm_log table
65 *
66 * @var boolean
67 */
68 static $_log = true;
69 /**
70 * Contribution Id
71 *
72 * @var int unsigned
73 */
74 public $id;
75 /**
76 * Contribution Page title. For top of page display
77 *
78 * @var string
79 */
80 public $title;
81 /**
82 * Text and html allowed. Displayed below title.
83 *
84 * @var text
85 */
86 public $intro_text;
87 /**
88 * default financial type assigned to contributions submitted via this page, e.g. Contribution, Campaign Contribution
89 *
90 * @var int unsigned
91 */
92 public $financial_type_id;
93 /**
94 * Payment Processors configured for this contribution Page
95 *
96 * @var string
97 */
98 public $payment_processor;
99 /**
100 * if true - processing logic must reject transaction at confirmation stage if pay method != credit card
101 *
102 * @var boolean
103 */
104 public $is_credit_card_only;
105 /**
106 * if true - allows real-time monetary transactions otherwise non-monetary transactions
107 *
108 * @var boolean
109 */
110 public $is_monetary;
111 /**
112 * if true - allows recurring contributions, valid only for PayPal_Standard
113 *
114 * @var boolean
115 */
116 public $is_recur;
117 /**
118 * if false, the confirm page in contribution pages gets skipped
119 *
120 * @var boolean
121 */
122 public $is_confirm_enabled;
123 /**
124 * Supported recurring frequency units.
125 *
126 * @var string
127 */
128 public $recur_frequency_unit;
129 /**
130 * if true - supports recurring intervals
131 *
132 * @var boolean
133 */
134 public $is_recur_interval;
135 /**
136 * if true - asks user for recurring installments
137 *
138 * @var boolean
139 */
140 public $is_recur_installments;
141 /**
142 * if true - user is able to adjust payment start date
143 *
144 * @var boolean
145 */
146 public $adjust_recur_start_date;
147 /**
148 * if true - allows the user to send payment directly to the org later
149 *
150 * @var boolean
151 */
152 public $is_pay_later;
153 /**
154 * The text displayed to the user in the main form
155 *
156 * @var text
157 */
158 public $pay_later_text;
159 /**
160 * The receipt sent to the user instead of the normal receipt text
161 *
162 * @var text
163 */
164 public $pay_later_receipt;
165 /**
166 * is partial payment enabled for this online contribution page
167 *
168 * @var boolean
169 */
170 public $is_partial_payment;
171 /**
172 * Initial amount label for partial payment
173 *
174 * @var string
175 */
176 public $initial_amount_label;
177 /**
178 * Initial amount help text for partial payment
179 *
180 * @var text
181 */
182 public $initial_amount_help_text;
183 /**
184 * Minimum initial amount for partial payment
185 *
186 * @var float
187 */
188 public $min_initial_amount;
189 /**
190 * if true, page will include an input text field where user can enter their own amount
191 *
192 * @var boolean
193 */
194 public $is_allow_other_amount;
195 /**
196 * FK to civicrm_option_value.
197 *
198 * @var int unsigned
199 */
200 public $default_amount_id;
201 /**
202 * if other amounts allowed, user can configure minimum allowed.
203 *
204 * @var float
205 */
206 public $min_amount;
207 /**
208 * if other amounts allowed, user can configure maximum allowed.
209 *
210 * @var float
211 */
212 public $max_amount;
213 /**
214 * The target goal for this page, allows people to build a goal meter
215 *
216 * @var float
217 */
218 public $goal_amount;
219 /**
220 * Title for Thank-you page (header title tag, and display at the top of the page).
221 *
222 * @var string
223 */
224 public $thankyou_title;
225 /**
226 * text and html allowed. displayed above result on success page
227 *
228 * @var text
229 */
230 public $thankyou_text;
231 /**
232 * 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.
233 *
234 * @var text
235 */
236 public $thankyou_footer;
237 /**
238 * if true, receipt is automatically emailed to contact on success
239 *
240 * @var boolean
241 */
242 public $is_email_receipt;
243 /**
244 * FROM email name used for receipts generated by contributions to this contribution page.
245 *
246 * @var string
247 */
248 public $receipt_from_name;
249 /**
250 * FROM email address used for receipts generated by contributions to this contribution page.
251 *
252 * @var string
253 */
254 public $receipt_from_email;
255 /**
256 * comma-separated list of email addresses to cc each time a receipt is sent
257 *
258 * @var string
259 */
260 public $cc_receipt;
261 /**
262 * comma-separated list of email addresses to bcc each time a receipt is sent
263 *
264 * @var string
265 */
266 public $bcc_receipt;
267 /**
268 * text to include above standard receipt info on receipt email. emails are text-only, so do not allow html for now
269 *
270 * @var text
271 */
272 public $receipt_text;
273 /**
274 * Is this property active?
275 *
276 * @var boolean
277 */
278 public $is_active;
279 /**
280 * Text and html allowed. Displayed at the bottom of the first page of the contribution wizard.
281 *
282 * @var text
283 */
284 public $footer_text;
285 /**
286 * Is this property active?
287 *
288 * @var boolean
289 */
290 public $amount_block_is_active;
291 /**
292 * Date and time that this page starts.
293 *
294 * @var datetime
295 */
296 public $start_date;
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;
303 /**
304 * FK to civicrm_contact, who created this contribution page
305 *
306 * @var int unsigned
307 */
308 public $created_id;
309 /**
310 * Date and time that contribution page was created.
311 *
312 * @var datetime
313 */
314 public $created_date;
315 /**
316 * 3 character string, value from config setting or input via user.
317 *
318 * @var string
319 */
320 public $currency;
321 /**
322 * The campaign for which we are collecting contributions with this page.
323 *
324 * @var int unsigned
325 */
326 public $campaign_id;
327 /**
328 * Can people share the contribution page through social media?
329 *
330 * @var boolean
331 */
332 public $is_share;
333 /**
334 * if true - billing block is required for online contribution page
335 *
336 * @var boolean
337 */
338 public $is_billing_required;
339 /**
340 * class constructor
341 *
342 * @return civicrm_contribution_page
343 */
344 function __construct() {
345 $this->__table = 'civicrm_contribution_page';
346 parent::__construct();
347 }
348 /**
349 * Returns foreign keys and entity references
350 *
351 * @return array
352 * [CRM_Core_Reference_Interface]
353 */
354 static function getReferenceColumns() {
355 if (!self::$_links) {
356 self::$_links = static ::createReferenceColumns(__CLASS__);
357 self::$_links[] = new CRM_Core_Reference_Basic(self::getTableName() , 'financial_type_id', 'civicrm_financial_type', 'id');
358 self::$_links[] = new CRM_Core_Reference_Basic(self::getTableName() , 'created_id', 'civicrm_contact', 'id');
359 self::$_links[] = new CRM_Core_Reference_Basic(self::getTableName() , 'campaign_id', 'civicrm_campaign', 'id');
360 }
361 return self::$_links;
362 }
363 /**
364 * Returns all the column names of this table
365 *
366 * @return array
367 */
368 static function &fields() {
369 if (!(self::$_fields)) {
370 self::$_fields = array(
371 'id' => array(
372 'name' => 'id',
373 'type' => CRM_Utils_Type::T_INT,
374 'title' => ts('Contribution Page ID') ,
375 'description' => 'Contribution Id',
376 'required' => true,
377 ) ,
378 'title' => array(
379 'name' => 'title',
380 'type' => CRM_Utils_Type::T_STRING,
381 'title' => ts('Contribution Page Title') ,
382 'description' => 'Contribution Page title. For top of page display',
383 'maxlength' => 255,
384 'size' => CRM_Utils_Type::HUGE,
385 ) ,
386 'intro_text' => array(
387 'name' => 'intro_text',
388 'type' => CRM_Utils_Type::T_TEXT,
389 'title' => ts('Contribution Page Introduction Text') ,
390 'description' => 'Text and html allowed. Displayed below title.',
391 'rows' => 6,
392 'cols' => 50,
393 'html' => array(
394 'type' => 'RichTextEditor',
395 ) ,
396 ) ,
397 'financial_type_id' => array(
398 'name' => 'financial_type_id',
399 'type' => CRM_Utils_Type::T_INT,
400 'title' => ts('Financial Type') ,
401 'description' => 'default financial type assigned to contributions submitted via this page, e.g. Contribution, Campaign Contribution',
402 'FKClassName' => 'CRM_Financial_DAO_FinancialType',
403 'html' => array(
404 'type' => 'Select',
405 ) ,
406 'pseudoconstant' => array(
407 'table' => 'civicrm_financial_type',
408 'keyColumn' => 'id',
409 'labelColumn' => 'name',
410 )
411 ) ,
412 'payment_processor' => array(
413 'name' => 'payment_processor',
414 'type' => CRM_Utils_Type::T_STRING,
415 'title' => ts('Payment Processor') ,
416 'description' => 'Payment Processors configured for this contribution Page',
417 'maxlength' => 128,
418 'size' => CRM_Utils_Type::HUGE,
419 'html' => array(
420 'type' => 'Select',
421 ) ,
422 'pseudoconstant' => array(
423 'table' => 'civicrm_payment_processor',
424 'keyColumn' => 'id',
425 'labelColumn' => 'name',
426 )
427 ) ,
428 'is_credit_card_only' => array(
429 'name' => 'is_credit_card_only',
430 'type' => CRM_Utils_Type::T_BOOLEAN,
431 'title' => ts('Is Credit Card Only?') ,
432 'description' => 'if true - processing logic must reject transaction at confirmation stage if pay method != credit card',
433 ) ,
434 'is_monetary' => array(
435 'name' => 'is_monetary',
436 'type' => CRM_Utils_Type::T_BOOLEAN,
437 'title' => ts('Is Monetary') ,
438 'description' => 'if true - allows real-time monetary transactions otherwise non-monetary transactions',
439 'default' => '1',
440 ) ,
441 'is_recur' => array(
442 'name' => 'is_recur',
443 'type' => CRM_Utils_Type::T_BOOLEAN,
444 'title' => ts('Is Recurring') ,
445 'description' => 'if true - allows recurring contributions, valid only for PayPal_Standard',
446 ) ,
447 'is_confirm_enabled' => array(
448 'name' => 'is_confirm_enabled',
449 'type' => CRM_Utils_Type::T_BOOLEAN,
450 'title' => ts('Confirmation Page?') ,
451 'description' => 'if false, the confirm page in contribution pages gets skipped',
452 'default' => '1',
453 ) ,
454 'recur_frequency_unit' => array(
455 'name' => 'recur_frequency_unit',
456 'type' => CRM_Utils_Type::T_STRING,
457 'title' => ts('Recurring Frequency') ,
458 'description' => 'Supported recurring frequency units.',
459 'maxlength' => 128,
460 'size' => CRM_Utils_Type::HUGE,
461 ) ,
462 'is_recur_interval' => array(
463 'name' => 'is_recur_interval',
464 'type' => CRM_Utils_Type::T_BOOLEAN,
465 'title' => ts('Support Recurring Intervals') ,
466 'description' => 'if true - supports recurring intervals',
467 ) ,
468 'is_recur_installments' => array(
469 'name' => 'is_recur_installments',
470 'type' => CRM_Utils_Type::T_BOOLEAN,
471 'title' => ts('Recurring Installments?') ,
472 'description' => 'if true - asks user for recurring installments',
473 ) ,
474 'adjust_recur_start_date' => array(
475 'name' => 'adjust_recur_start_date',
476 'type' => CRM_Utils_Type::T_BOOLEAN,
477 'title' => ts('Adjust Recurring Start Date') ,
478 'description' => 'if true - user is able to adjust payment start date',
479 ) ,
480 'is_pay_later' => array(
481 'name' => 'is_pay_later',
482 'type' => CRM_Utils_Type::T_BOOLEAN,
483 'title' => ts('Pay Later') ,
484 'description' => 'if true - allows the user to send payment directly to the org later',
485 ) ,
486 'pay_later_text' => array(
487 'name' => 'pay_later_text',
488 'type' => CRM_Utils_Type::T_TEXT,
489 'title' => ts('Pay Later Text') ,
490 'description' => 'The text displayed to the user in the main form',
491 ) ,
492 'pay_later_receipt' => array(
493 'name' => 'pay_later_receipt',
494 'type' => CRM_Utils_Type::T_TEXT,
495 'title' => ts('Pay Later Receipt') ,
496 'description' => 'The receipt sent to the user instead of the normal receipt text',
497 ) ,
498 'is_partial_payment' => array(
499 'name' => 'is_partial_payment',
500 'type' => CRM_Utils_Type::T_BOOLEAN,
501 'title' => ts('Allow Partial Payment') ,
502 'description' => 'is partial payment enabled for this online contribution page',
503 ) ,
504 'initial_amount_label' => array(
505 'name' => 'initial_amount_label',
506 'type' => CRM_Utils_Type::T_STRING,
507 'title' => ts('Initial Amount Label') ,
508 'description' => 'Initial amount label for partial payment',
509 'maxlength' => 255,
510 'size' => CRM_Utils_Type::HUGE,
511 ) ,
512 'initial_amount_help_text' => array(
513 'name' => 'initial_amount_help_text',
514 'type' => CRM_Utils_Type::T_TEXT,
515 'title' => ts('Initial Amount Help Text') ,
516 'description' => 'Initial amount help text for partial payment',
517 ) ,
518 'min_initial_amount' => array(
519 'name' => 'min_initial_amount',
520 'type' => CRM_Utils_Type::T_MONEY,
521 'title' => ts('Min Initial Amount') ,
522 'description' => 'Minimum initial amount for partial payment',
523 'precision' => array(
524 20,
525 2
526 ) ,
527 ) ,
528 'is_allow_other_amount' => array(
529 'name' => 'is_allow_other_amount',
530 'type' => CRM_Utils_Type::T_BOOLEAN,
531 'title' => ts('Allow Other Amounts') ,
532 'description' => 'if true, page will include an input text field where user can enter their own amount',
533 ) ,
534 'default_amount_id' => array(
535 'name' => 'default_amount_id',
536 'type' => CRM_Utils_Type::T_INT,
537 'title' => ts('Default Amount') ,
538 'description' => 'FK to civicrm_option_value.',
539 ) ,
540 'min_amount' => array(
541 'name' => 'min_amount',
542 'type' => CRM_Utils_Type::T_MONEY,
543 'title' => ts('Minimum Amount') ,
544 'description' => 'if other amounts allowed, user can configure minimum allowed.',
545 'precision' => array(
546 20,
547 2
548 ) ,
549 ) ,
550 'max_amount' => array(
551 'name' => 'max_amount',
552 'type' => CRM_Utils_Type::T_MONEY,
553 'title' => ts('Maximum Amount') ,
554 'description' => 'if other amounts allowed, user can configure maximum allowed.',
555 'precision' => array(
556 20,
557 2
558 ) ,
559 ) ,
560 'goal_amount' => array(
561 'name' => 'goal_amount',
562 'type' => CRM_Utils_Type::T_MONEY,
563 'title' => ts('Goal Amount') ,
564 'description' => 'The target goal for this page, allows people to build a goal meter',
565 'precision' => array(
566 20,
567 2
568 ) ,
569 ) ,
570 'thankyou_title' => array(
571 'name' => 'thankyou_title',
572 'type' => CRM_Utils_Type::T_STRING,
573 'title' => ts('Thank-you Title') ,
574 'description' => 'Title for Thank-you page (header title tag, and display at the top of the page).',
575 'maxlength' => 255,
576 'size' => CRM_Utils_Type::HUGE,
577 ) ,
578 'thankyou_text' => array(
579 'name' => 'thankyou_text',
580 'type' => CRM_Utils_Type::T_TEXT,
581 'title' => ts('Thank-you Text') ,
582 'description' => 'text and html allowed. displayed above result on success page',
583 'rows' => 8,
584 'cols' => 60,
585 'html' => array(
586 'type' => 'RichTextEditor',
587 ) ,
588 ) ,
589 'thankyou_footer' => array(
590 'name' => 'thankyou_footer',
591 'type' => CRM_Utils_Type::T_TEXT,
592 'title' => ts('Thank-you Footer') ,
593 'description' => '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.',
594 'rows' => 8,
595 'cols' => 60,
596 'html' => array(
597 'type' => 'RichTextEditor',
598 ) ,
599 ) ,
600 'is_email_receipt' => array(
601 'name' => 'is_email_receipt',
602 'type' => CRM_Utils_Type::T_BOOLEAN,
603 'title' => ts('Send email Receipt') ,
604 'description' => 'if true, receipt is automatically emailed to contact on success',
605 ) ,
606 'receipt_from_name' => array(
607 'name' => 'receipt_from_name',
608 'type' => CRM_Utils_Type::T_STRING,
609 'title' => ts('Receipt From') ,
610 'description' => 'FROM email name used for receipts generated by contributions to this contribution page.',
611 'maxlength' => 255,
612 'size' => CRM_Utils_Type::HUGE,
613 ) ,
614 'receipt_from_email' => array(
615 'name' => 'receipt_from_email',
616 'type' => CRM_Utils_Type::T_STRING,
617 'title' => ts('Receipt From email') ,
618 'description' => 'FROM email address used for receipts generated by contributions to this contribution page.',
619 'maxlength' => 255,
620 'size' => CRM_Utils_Type::HUGE,
621 ) ,
622 'cc_receipt' => array(
623 'name' => 'cc_receipt',
624 'type' => CRM_Utils_Type::T_STRING,
625 'title' => ts('Receipt cc') ,
626 'description' => 'comma-separated list of email addresses to cc each time a receipt is sent',
627 'maxlength' => 255,
628 'size' => CRM_Utils_Type::HUGE,
629 ) ,
630 'bcc_receipt' => array(
631 'name' => 'bcc_receipt',
632 'type' => CRM_Utils_Type::T_STRING,
633 'title' => ts('Receipt bcc') ,
634 'description' => 'comma-separated list of email addresses to bcc each time a receipt is sent',
635 'maxlength' => 255,
636 'size' => CRM_Utils_Type::HUGE,
637 ) ,
638 'receipt_text' => array(
639 'name' => 'receipt_text',
640 'type' => CRM_Utils_Type::T_TEXT,
641 'title' => ts('Receipt Text') ,
642 'description' => 'text to include above standard receipt info on receipt email. emails are text-only, so do not allow html for now',
643 'rows' => 6,
644 'cols' => 50,
645 'html' => array(
646 'type' => 'TextArea',
647 ) ,
648 ) ,
649 'is_active' => array(
650 'name' => 'is_active',
651 'type' => CRM_Utils_Type::T_BOOLEAN,
652 'title' => ts('Is Page Active?') ,
653 'description' => 'Is this property active?',
654 ) ,
655 'footer_text' => array(
656 'name' => 'footer_text',
657 'type' => CRM_Utils_Type::T_TEXT,
658 'title' => ts('Footer Text') ,
659 'description' => 'Text and html allowed. Displayed at the bottom of the first page of the contribution wizard.',
660 'rows' => 6,
661 'cols' => 50,
662 'html' => array(
663 'type' => 'RichTextEditor',
664 ) ,
665 ) ,
666 'amount_block_is_active' => array(
667 'name' => 'amount_block_is_active',
668 'type' => CRM_Utils_Type::T_BOOLEAN,
669 'title' => ts('Is Amount Block Active?') ,
670 'description' => 'Is this property active?',
671 'default' => '1',
672 ) ,
673 'start_date' => array(
674 'name' => 'start_date',
675 'type' => CRM_Utils_Type::T_DATE + CRM_Utils_Type::T_TIME,
676 'title' => ts('Contribution Page Start Date') ,
677 'description' => 'Date and time that this page starts.',
678 ) ,
679 'end_date' => array(
680 'name' => 'end_date',
681 'type' => CRM_Utils_Type::T_DATE + CRM_Utils_Type::T_TIME,
682 'title' => ts('Contribution Page End Date') ,
683 'description' => 'Date and time that this page ends. May be NULL if no defined end date/time',
684 ) ,
685 'created_id' => array(
686 'name' => 'created_id',
687 'type' => CRM_Utils_Type::T_INT,
688 'title' => ts('Contribution Page Created By') ,
689 'description' => 'FK to civicrm_contact, who created this contribution page',
690 'FKClassName' => 'CRM_Contact_DAO_Contact',
691 ) ,
692 'created_date' => array(
693 'name' => 'created_date',
694 'type' => CRM_Utils_Type::T_DATE + CRM_Utils_Type::T_TIME,
695 'title' => ts('Contribution Page Created Date') ,
696 'description' => 'Date and time that contribution page was created.',
697 ) ,
698 'currency' => array(
699 'name' => 'currency',
700 'type' => CRM_Utils_Type::T_STRING,
701 'title' => ts('Contribution Page Currency') ,
702 'description' => '3 character string, value from config setting or input via user.',
703 'maxlength' => 3,
704 'size' => CRM_Utils_Type::FOUR,
705 'default' => 'NULL',
706 'html' => array(
707 'type' => 'Select',
708 ) ,
709 'pseudoconstant' => array(
710 'table' => 'civicrm_currency',
711 'keyColumn' => 'name',
712 'labelColumn' => 'full_name',
713 'nameColumn' => 'name',
714 )
715 ) ,
716 'campaign_id' => array(
717 'name' => 'campaign_id',
718 'type' => CRM_Utils_Type::T_INT,
719 'title' => ts('Contribution Page Campaign ID') ,
720 'description' => 'The campaign for which we are collecting contributions with this page.',
721 'FKClassName' => 'CRM_Campaign_DAO_Campaign',
722 'pseudoconstant' => array(
723 'table' => 'civicrm_campaign',
724 'keyColumn' => 'id',
725 'labelColumn' => 'title',
726 )
727 ) ,
728 'is_share' => array(
729 'name' => 'is_share',
730 'type' => CRM_Utils_Type::T_BOOLEAN,
731 'title' => ts('Is Contribution Page Shared?') ,
732 'description' => 'Can people share the contribution page through social media?',
733 'default' => '1',
734 ) ,
735 'is_billing_required' => array(
736 'name' => 'is_billing_required',
737 'type' => CRM_Utils_Type::T_BOOLEAN,
738 'title' => ts('Is billing block required') ,
739 'description' => 'if true - billing block is required for online contribution page',
740 ) ,
741 );
742 }
743 return self::$_fields;
744 }
745 /**
746 * Returns an array containing, for each field, the arary key used for that
747 * field in self::$_fields.
748 *
749 * @return array
750 */
751 static function &fieldKeys() {
752 if (!(self::$_fieldKeys)) {
753 self::$_fieldKeys = array(
754 'id' => 'id',
755 'title' => 'title',
756 'intro_text' => 'intro_text',
757 'financial_type_id' => 'financial_type_id',
758 'payment_processor' => 'payment_processor',
759 'is_credit_card_only' => 'is_credit_card_only',
760 'is_monetary' => 'is_monetary',
761 'is_recur' => 'is_recur',
762 'is_confirm_enabled' => 'is_confirm_enabled',
763 'recur_frequency_unit' => 'recur_frequency_unit',
764 'is_recur_interval' => 'is_recur_interval',
765 'is_recur_installments' => 'is_recur_installments',
766 'adjust_recur_start_date' => 'adjust_recur_start_date',
767 'is_pay_later' => 'is_pay_later',
768 'pay_later_text' => 'pay_later_text',
769 'pay_later_receipt' => 'pay_later_receipt',
770 'is_partial_payment' => 'is_partial_payment',
771 'initial_amount_label' => 'initial_amount_label',
772 'initial_amount_help_text' => 'initial_amount_help_text',
773 'min_initial_amount' => 'min_initial_amount',
774 'is_allow_other_amount' => 'is_allow_other_amount',
775 'default_amount_id' => 'default_amount_id',
776 'min_amount' => 'min_amount',
777 'max_amount' => 'max_amount',
778 'goal_amount' => 'goal_amount',
779 'thankyou_title' => 'thankyou_title',
780 'thankyou_text' => 'thankyou_text',
781 'thankyou_footer' => 'thankyou_footer',
782 'is_email_receipt' => 'is_email_receipt',
783 'receipt_from_name' => 'receipt_from_name',
784 'receipt_from_email' => 'receipt_from_email',
785 'cc_receipt' => 'cc_receipt',
786 'bcc_receipt' => 'bcc_receipt',
787 'receipt_text' => 'receipt_text',
788 'is_active' => 'is_active',
789 'footer_text' => 'footer_text',
790 'amount_block_is_active' => 'amount_block_is_active',
791 'start_date' => 'start_date',
792 'end_date' => 'end_date',
793 'created_id' => 'created_id',
794 'created_date' => 'created_date',
795 'currency' => 'currency',
796 'campaign_id' => 'campaign_id',
797 'is_share' => 'is_share',
798 'is_billing_required' => 'is_billing_required',
799 );
800 }
801 return self::$_fieldKeys;
802 }
803 /**
804 * Returns the names of this table
805 *
806 * @return string
807 */
808 static function getTableName() {
809 return CRM_Core_DAO::getLocaleTableName(self::$_tableName);
810 }
811 /**
812 * Returns if this table needs to be logged
813 *
814 * @return boolean
815 */
816 function getLog() {
817 return self::$_log;
818 }
819 /**
820 * Returns the list of fields that can be imported
821 *
822 * @param bool $prefix
823 *
824 * @return array
825 */
826 static function &import($prefix = false) {
827 $r = CRM_Core_DAO_AllCoreTables::getImports(__CLASS__, 'contribution_page', $prefix, array());
828 return $r;
829 }
830 /**
831 * Returns the list of fields that can be exported
832 *
833 * @param bool $prefix
834 *
835 * @return array
836 */
837 static function &export($prefix = false) {
838 $r = CRM_Core_DAO_AllCoreTables::getExports(__CLASS__, 'contribution_page', $prefix, array());
839 return $r;
840 }
841 }