5 * @copyright CiviCRM LLC https://civicrm.org/licensing
7 * Generated from xml/schema/CRM/Event/Event.xml
8 * DO NOT EDIT. Generated by CRM_Core_CodeGen
9 * (GenCodeChecksum:8e47b6d674b9aa18013e67f27b4b355d)
13 * Database access object for the Event entity.
15 class CRM_Event_DAO_Event
extends CRM_Core_DAO
{
16 const EXT
= 'civicrm';
17 const TABLE_ADDED
= '1.7';
18 const COMPONENT
= 'CiviEvent';
21 * Static instance to hold the table name.
25 public static $_tableName = 'civicrm_event';
28 * Icon associated with this entity.
32 public static $_icon = 'fa-calendar';
35 * Field to show when displaying a record.
39 public static $_labelField = 'title';
42 * Should CiviCRM log any modifications to this table in the civicrm_log table.
46 public static $_log = TRUE;
49 * Paths for accessing this entity in the UI.
53 protected static $_paths = [
54 'add' => 'civicrm/event/add?reset=1',
55 'view' => 'civicrm/event/info?reset=1&id=[id]',
61 * @var int|string|null
62 * (SQL type: int unsigned)
63 * Note that values will be retrieved from the database as a string.
68 * Event Title (e.g. Fall Fundraiser Dinner)
71 * (SQL type: varchar(255))
72 * Note that values will be retrieved from the database as a string.
77 * Brief summary of event. Text and html allowed. Displayed on Event Registration form and can be used on other CMS pages which need an event summary.
81 * Note that values will be retrieved from the database as a string.
86 * Full description of event. Text and html allowed. Displayed on built-in Event Information screens.
90 * Note that values will be retrieved from the database as a string.
95 * Event Type ID.Implicit FK to civicrm_option_value where option_group = event_type.
97 * @var int|string|null
98 * (SQL type: int unsigned)
99 * Note that values will be retrieved from the database as a string.
101 public $event_type_id;
104 * Should we expose the participant list? Implicit FK to civicrm_option_value where option_group = participant_listing.
106 * @var int|string|null
107 * (SQL type: int unsigned)
108 * Note that values will be retrieved from the database as a string.
110 public $participant_listing_id;
113 * Public events will be included in the iCal feeds. Access to private event information may be limited using ACLs.
116 * (SQL type: tinyint)
117 * Note that values will be retrieved from the database as a string.
122 * Date and time that event starts.
125 * (SQL type: datetime)
126 * Note that values will be retrieved from the database as a string.
131 * Date and time that event ends. May be NULL if no defined end date/time
134 * (SQL type: datetime)
135 * Note that values will be retrieved from the database as a string.
140 * If true, include registration link on Event Info page.
143 * (SQL type: tinyint)
144 * Note that values will be retrieved from the database as a string.
146 public $is_online_registration;
149 * Text for link to Event Registration form which is displayed on Event Information screen when is_online_registration is true.
152 * (SQL type: varchar(255))
153 * Note that values will be retrieved from the database as a string.
155 public $registration_link_text;
158 * Date and time that online registration starts.
161 * (SQL type: datetime)
162 * Note that values will be retrieved from the database as a string.
164 public $registration_start_date;
167 * Date and time that online registration ends.
170 * (SQL type: datetime)
171 * Note that values will be retrieved from the database as a string.
173 public $registration_end_date;
176 * Maximum number of registered participants to allow. After max is reached, a custom Event Full message is displayed. If NULL, allow unlimited number of participants.
178 * @var int|string|null
179 * (SQL type: int unsigned)
180 * Note that values will be retrieved from the database as a string.
182 public $max_participants;
185 * Message to display on Event Information page and INSTEAD OF Event Registration form if maximum participants are signed up. Can include email address/info about getting on a waiting list, etc. Text and html allowed.
189 * Note that values will be retrieved from the database as a string.
191 public $event_full_text;
194 * If true, one or more fee amounts must be set and a Payment Processor must be configured for Online Event Registration.
197 * (SQL type: tinyint)
198 * Note that values will be retrieved from the database as a string.
203 * Financial type assigned to paid event registrations for this event. Required if is_monetary is true.
205 * @var int|string|null
206 * (SQL type: int unsigned)
207 * Note that values will be retrieved from the database as a string.
209 public $financial_type_id;
212 * Payment Processors configured for this Event (if is_monetary is true)
215 * (SQL type: varchar(128))
216 * Note that values will be retrieved from the database as a string.
218 public $payment_processor;
221 * Include a map block on the Event Information page when geocode info is available and a mapping provider has been specified?
224 * (SQL type: tinyint)
225 * Note that values will be retrieved from the database as a string.
230 * Is this Event enabled or disabled/cancelled?
233 * (SQL type: tinyint)
234 * Note that values will be retrieved from the database as a string.
240 * (SQL type: varchar(255))
241 * Note that values will be retrieved from the database as a string.
246 * If true, show event location.
249 * (SQL type: tinyint)
250 * Note that values will be retrieved from the database as a string.
252 public $is_show_location;
255 * FK to Location Block ID
257 * @var int|string|null
258 * (SQL type: int unsigned)
259 * Note that values will be retrieved from the database as a string.
261 public $loc_block_id;
264 * Participant role ID. Implicit FK to civicrm_option_value where option_group = participant_role.
266 * @var int|string|null
267 * (SQL type: int unsigned)
268 * Note that values will be retrieved from the database as a string.
270 public $default_role_id;
273 * Introductory message for Event Registration page. Text and html allowed. Displayed at the top of Event Registration form.
277 * Note that values will be retrieved from the database as a string.
282 * Footer message for Event Registration page. Text and html allowed. Displayed at the bottom of Event Registration form.
286 * Note that values will be retrieved from the database as a string.
291 * Title for Confirmation page.
294 * (SQL type: varchar(255))
295 * Note that values will be retrieved from the database as a string.
297 public $confirm_title;
300 * Introductory message for Event Registration page. Text and html allowed. Displayed at the top of Event Registration form.
304 * Note that values will be retrieved from the database as a string.
306 public $confirm_text;
309 * Footer message for Event Registration page. Text and html allowed. Displayed at the bottom of Event Registration form.
313 * Note that values will be retrieved from the database as a string.
315 public $confirm_footer_text;
318 * If true, confirmation is automatically emailed to contact on successful registration.
321 * (SQL type: tinyint)
322 * Note that values will be retrieved from the database as a string.
324 public $is_email_confirm;
327 * text to include above standard event info on confirmation email. emails are text-only, so do not allow html for now
331 * Note that values will be retrieved from the database as a string.
333 public $confirm_email_text;
336 * FROM email name used for confirmation emails.
339 * (SQL type: varchar(255))
340 * Note that values will be retrieved from the database as a string.
342 public $confirm_from_name;
345 * FROM email address used for confirmation emails.
348 * (SQL type: varchar(255))
349 * Note that values will be retrieved from the database as a string.
351 public $confirm_from_email;
354 * comma-separated list of email addresses to cc each time a confirmation is sent
357 * (SQL type: varchar(255))
358 * Note that values will be retrieved from the database as a string.
363 * comma-separated list of email addresses to bcc each time a confirmation is sent
366 * (SQL type: varchar(255))
367 * Note that values will be retrieved from the database as a string.
372 * FK to civicrm_option_value.
374 * @var int|string|null
375 * (SQL type: int unsigned)
376 * Note that values will be retrieved from the database as a string.
378 public $default_fee_id;
381 * FK to civicrm_option_value.
383 * @var int|string|null
384 * (SQL type: int unsigned)
385 * Note that values will be retrieved from the database as a string.
387 public $default_discount_fee_id;
390 * Title for ThankYou page.
393 * (SQL type: varchar(255))
394 * Note that values will be retrieved from the database as a string.
396 public $thankyou_title;
403 * Note that values will be retrieved from the database as a string.
405 public $thankyou_text;
412 * Note that values will be retrieved from the database as a string.
414 public $thankyou_footer_text;
417 * if true - allows the user to send payment directly to the org later
420 * (SQL type: tinyint)
421 * Note that values will be retrieved from the database as a string.
423 public $is_pay_later;
426 * The text displayed to the user in the main form
430 * Note that values will be retrieved from the database as a string.
432 public $pay_later_text;
435 * The receipt sent to the user instead of the normal receipt text
439 * Note that values will be retrieved from the database as a string.
441 public $pay_later_receipt;
444 * is partial payment enabled for this event
447 * (SQL type: tinyint)
448 * Note that values will be retrieved from the database as a string.
450 public $is_partial_payment;
453 * Initial amount label for partial payment
456 * (SQL type: varchar(255))
457 * Note that values will be retrieved from the database as a string.
459 public $initial_amount_label;
462 * Initial amount help text for partial payment
466 * Note that values will be retrieved from the database as a string.
468 public $initial_amount_help_text;
471 * Minimum initial amount for partial payment
473 * @var float|string|null
474 * (SQL type: decimal(20,2))
475 * Note that values will be retrieved from the database as a string.
477 public $min_initial_amount;
480 * if true - allows the user to register multiple participants for event
483 * (SQL type: tinyint)
484 * Note that values will be retrieved from the database as a string.
486 public $is_multiple_registrations;
489 * Maximum number of additional participants that can be registered on a single booking
491 * @var int|string|null
492 * (SQL type: int unsigned)
493 * Note that values will be retrieved from the database as a string.
495 public $max_additional_participants;
498 * if true - allows the user to register multiple registrations from same email address.
501 * (SQL type: tinyint)
502 * Note that values will be retrieved from the database as a string.
504 public $allow_same_participant_emails;
507 * Whether the event has waitlist support.
510 * (SQL type: tinyint)
511 * Note that values will be retrieved from the database as a string.
513 public $has_waitlist;
516 * Whether participants require approval before they can finish registering.
519 * (SQL type: tinyint)
520 * Note that values will be retrieved from the database as a string.
522 public $requires_approval;
525 * Expire pending but unconfirmed registrations after this many hours.
527 * @var int|string|null
528 * (SQL type: int unsigned)
529 * Note that values will be retrieved from the database as a string.
531 public $expiration_time;
534 * Allow self service cancellation or transfer for event?
537 * (SQL type: tinyint)
538 * Note that values will be retrieved from the database as a string.
540 public $allow_selfcancelxfer;
543 * Number of hours prior to event start date to allow self-service cancellation or transfer.
545 * @var int|string|null
547 * Note that values will be retrieved from the database as a string.
549 public $selfcancelxfer_time;
552 * Text to display when the event is full, but participants can signup for a waitlist.
556 * Note that values will be retrieved from the database as a string.
558 public $waitlist_text;
561 * Text to display when the approval is required to complete registration for an event.
565 * Note that values will be retrieved from the database as a string.
567 public $approval_req_text;
570 * whether the event has template
573 * (SQL type: tinyint)
574 * Note that values will be retrieved from the database as a string.
579 * Event Template Title
582 * (SQL type: varchar(255))
583 * Note that values will be retrieved from the database as a string.
585 public $template_title;
588 * FK to civicrm_contact, who created this event
590 * @var int|string|null
591 * (SQL type: int unsigned)
592 * Note that values will be retrieved from the database as a string.
597 * Date and time that event was created.
600 * (SQL type: datetime)
601 * Note that values will be retrieved from the database as a string.
603 public $created_date;
606 * 3 character string, value from config setting or input via user.
609 * (SQL type: varchar(3))
610 * Note that values will be retrieved from the database as a string.
615 * The campaign for which this event has been created.
617 * @var int|string|null
618 * (SQL type: int unsigned)
619 * Note that values will be retrieved from the database as a string.
624 * Can people share the event through social media?
627 * (SQL type: tinyint)
628 * Note that values will be retrieved from the database as a string.
633 * If false, the event booking confirmation screen gets skipped
636 * (SQL type: tinyint)
637 * Note that values will be retrieved from the database as a string.
639 public $is_confirm_enabled;
642 * Implicit FK to civicrm_event: parent event
644 * @var int|string|null
645 * (SQL type: int unsigned)
646 * Note that values will be retrieved from the database as a string.
648 public $parent_event_id;
651 * Subevent slot label. Implicit FK to civicrm_option_value where option_group = conference_slot.
653 * @var int|string|null
654 * (SQL type: int unsigned)
655 * Note that values will be retrieved from the database as a string.
657 public $slot_label_id;
660 * Rule to use when matching registrations for this event
662 * @var int|string|null
663 * (SQL type: int unsigned)
664 * Note that values will be retrieved from the database as a string.
666 public $dedupe_rule_group_id;
669 * if true than billing block is required this event
672 * (SQL type: tinyint)
673 * Note that values will be retrieved from the database as a string.
675 public $is_billing_required;
680 public function __construct() {
681 $this->__table
= 'civicrm_event';
682 parent
::__construct();
686 * Returns localized title of this entity.
688 * @param bool $plural
689 * Whether to return the plural version of the title.
691 public static function getEntityTitle($plural = FALSE) {
692 return $plural ?
ts('Events') : ts('Event');
696 * Returns user-friendly description of this entity.
700 public static function getEntityDescription() {
701 return ts('Scheduled in-person or online events which contacts can register for and attend.');
705 * Returns foreign keys and entity references.
708 * [CRM_Core_Reference_Interface]
710 public static function getReferenceColumns() {
711 if (!isset(Civi
::$statics[__CLASS__
]['links'])) {
712 Civi
::$statics[__CLASS__
]['links'] = static::createReferenceColumns(__CLASS__
);
713 Civi
::$statics[__CLASS__
]['links'][] = new CRM_Core_Reference_Basic(self
::getTableName(), 'loc_block_id', 'civicrm_loc_block', 'id');
714 Civi
::$statics[__CLASS__
]['links'][] = new CRM_Core_Reference_Basic(self
::getTableName(), 'created_id', 'civicrm_contact', 'id');
715 Civi
::$statics[__CLASS__
]['links'][] = new CRM_Core_Reference_Basic(self
::getTableName(), 'campaign_id', 'civicrm_campaign', 'id');
716 Civi
::$statics[__CLASS__
]['links'][] = new CRM_Core_Reference_Basic(self
::getTableName(), 'dedupe_rule_group_id', 'civicrm_dedupe_rule_group', 'id');
717 CRM_Core_DAO_AllCoreTables
::invoke(__CLASS__
, 'links_callback', Civi
::$statics[__CLASS__
]['links']);
719 return Civi
::$statics[__CLASS__
]['links'];
723 * Returns all the column names of this table
727 public static function &fields() {
728 if (!isset(Civi
::$statics[__CLASS__
]['fields'])) {
729 Civi
::$statics[__CLASS__
]['fields'] = [
732 'type' => CRM_Utils_Type
::T_INT
,
733 'title' => ts('Event ID'),
734 'description' => ts('Event'),
736 'where' => 'civicrm_event.id',
737 'table_name' => 'civicrm_event',
739 'bao' => 'CRM_Event_BAO_Event',
749 'type' => CRM_Utils_Type
::T_STRING
,
750 'title' => ts('Event Title'),
751 'description' => ts('Event Title (e.g. Fall Fundraiser Dinner)'),
753 'size' => CRM_Utils_Type
::HUGE
,
755 'where' => 'civicrm_event.title',
756 'headerPattern' => '/(event.)?title$/i',
758 'table_name' => 'civicrm_event',
760 'bao' => 'CRM_Event_BAO_Event',
769 'type' => CRM_Utils_Type
::T_TEXT
,
770 'title' => ts('Event Summary'),
771 'description' => ts('Brief summary of event. Text and html allowed. Displayed on Event Registration form and can be used on other CMS pages which need an event summary.'),
774 'where' => 'civicrm_event.summary',
775 'table_name' => 'civicrm_event',
777 'bao' => 'CRM_Event_BAO_Event',
780 'type' => 'TextArea',
784 'event_description' => [
785 'name' => 'description',
786 'type' => CRM_Utils_Type
::T_TEXT
,
787 'title' => ts('Event Description'),
788 'description' => ts('Full description of event. Text and html allowed. Displayed on built-in Event Information screens.'),
791 'where' => 'civicrm_event.description',
792 'table_name' => 'civicrm_event',
794 'bao' => 'CRM_Event_BAO_Event',
797 'type' => 'RichTextEditor',
802 'name' => 'event_type_id',
803 'type' => CRM_Utils_Type
::T_INT
,
804 'title' => ts('Event Type'),
805 'description' => ts('Event Type ID.Implicit FK to civicrm_option_value where option_group = event_type.'),
806 'where' => 'civicrm_event.event_type_id',
808 'table_name' => 'civicrm_event',
810 'bao' => 'CRM_Event_BAO_Event',
815 'pseudoconstant' => [
816 'optionGroupName' => 'event_type',
817 'optionEditPath' => 'civicrm/admin/options/event_type',
821 'participant_listing_id' => [
822 'name' => 'participant_listing_id',
823 'type' => CRM_Utils_Type
::T_INT
,
824 'title' => ts('Participant Listing'),
825 'description' => ts('Should we expose the participant list? Implicit FK to civicrm_option_value where option_group = participant_listing.'),
826 'where' => 'civicrm_event.participant_listing_id',
828 'table_name' => 'civicrm_event',
830 'bao' => 'CRM_Event_BAO_Event',
835 'pseudoconstant' => [
836 'optionGroupName' => 'participant_listing',
837 'optionEditPath' => 'civicrm/admin/options/participant_listing',
842 'name' => 'is_public',
843 'type' => CRM_Utils_Type
::T_BOOLEAN
,
844 'title' => ts('Is Event Public'),
845 'description' => ts('Public events will be included in the iCal feeds. Access to private event information may be limited using ACLs.'),
847 'where' => 'civicrm_event.is_public',
849 'table_name' => 'civicrm_event',
851 'bao' => 'CRM_Event_BAO_Event',
854 'type' => 'CheckBox',
858 'event_start_date' => [
859 'name' => 'start_date',
860 'type' => CRM_Utils_Type
::T_DATE + CRM_Utils_Type
::T_TIME
,
861 'title' => ts('Event Start Date'),
862 'description' => ts('Date and time that event starts.'),
864 'where' => 'civicrm_event.start_date',
865 'headerPattern' => '/^start|(s(tart\s)?date)$/i',
867 'table_name' => 'civicrm_event',
869 'bao' => 'CRM_Event_BAO_Event',
872 'type' => 'Select Date',
873 'formatType' => 'activityDateTime',
877 'event_end_date' => [
878 'name' => 'end_date',
879 'type' => CRM_Utils_Type
::T_DATE + CRM_Utils_Type
::T_TIME
,
880 'title' => ts('Event End Date'),
881 'description' => ts('Date and time that event ends. May be NULL if no defined end date/time'),
883 'where' => 'civicrm_event.end_date',
884 'headerPattern' => '/^end|(e(nd\s)?date)$/i',
886 'table_name' => 'civicrm_event',
888 'bao' => 'CRM_Event_BAO_Event',
891 'type' => 'Select Date',
892 'formatType' => 'activityDateTime',
896 'is_online_registration' => [
897 'name' => 'is_online_registration',
898 'type' => CRM_Utils_Type
::T_BOOLEAN
,
899 'title' => ts('Is Online Registration'),
900 'description' => ts('If true, include registration link on Event Info page.'),
902 'where' => 'civicrm_event.is_online_registration',
904 'table_name' => 'civicrm_event',
906 'bao' => 'CRM_Event_BAO_Event',
909 'type' => 'CheckBox',
913 'registration_link_text' => [
914 'name' => 'registration_link_text',
915 'type' => CRM_Utils_Type
::T_STRING
,
916 'title' => ts('Event Registration Link Text'),
917 'description' => ts('Text for link to Event Registration form which is displayed on Event Information screen when is_online_registration is true.'),
919 'size' => CRM_Utils_Type
::HUGE
,
920 'where' => 'civicrm_event.registration_link_text',
921 'table_name' => 'civicrm_event',
923 'bao' => 'CRM_Event_BAO_Event',
930 'registration_start_date' => [
931 'name' => 'registration_start_date',
932 'type' => CRM_Utils_Type
::T_DATE + CRM_Utils_Type
::T_TIME
,
933 'title' => ts('Registration Start Date'),
934 'description' => ts('Date and time that online registration starts.'),
935 'where' => 'civicrm_event.registration_start_date',
936 'table_name' => 'civicrm_event',
938 'bao' => 'CRM_Event_BAO_Event',
941 'type' => 'Select Date',
942 'formatType' => 'activityDateTime',
943 'label' => ts("Registration Start Date"),
947 'registration_end_date' => [
948 'name' => 'registration_end_date',
949 'type' => CRM_Utils_Type
::T_DATE + CRM_Utils_Type
::T_TIME
,
950 'title' => ts('Registration End Date'),
951 'description' => ts('Date and time that online registration ends.'),
952 'where' => 'civicrm_event.registration_end_date',
953 'table_name' => 'civicrm_event',
955 'bao' => 'CRM_Event_BAO_Event',
958 'type' => 'Select Date',
959 'formatType' => 'activityDateTime',
960 'label' => ts("Registration End Date"),
964 'max_participants' => [
965 'name' => 'max_participants',
966 'type' => CRM_Utils_Type
::T_INT
,
967 'title' => ts('Max Participants'),
968 'description' => ts('Maximum number of registered participants to allow. After max is reached, a custom Event Full message is displayed. If NULL, allow unlimited number of participants.'),
969 'where' => 'civicrm_event.max_participants',
971 'table_name' => 'civicrm_event',
973 'bao' => 'CRM_Event_BAO_Event',
980 'event_full_text' => [
981 'name' => 'event_full_text',
982 'type' => CRM_Utils_Type
::T_TEXT
,
983 'title' => ts('Event Information'),
984 'description' => ts('Message to display on Event Information page and INSTEAD OF Event Registration form if maximum participants are signed up. Can include email address/info about getting on a waiting list, etc. Text and html allowed.'),
987 'where' => 'civicrm_event.event_full_text',
988 'table_name' => 'civicrm_event',
990 'bao' => 'CRM_Event_BAO_Event',
993 'type' => 'TextArea',
998 'name' => 'is_monetary',
999 'type' => CRM_Utils_Type
::T_BOOLEAN
,
1000 'title' => ts('Is this a PAID event?'),
1001 'description' => ts('If true, one or more fee amounts must be set and a Payment Processor must be configured for Online Event Registration.'),
1003 'where' => 'civicrm_event.is_monetary',
1005 'table_name' => 'civicrm_event',
1006 'entity' => 'Event',
1007 'bao' => 'CRM_Event_BAO_Event',
1010 'type' => 'CheckBox',
1014 'financial_type_id' => [
1015 'name' => 'financial_type_id',
1016 'type' => CRM_Utils_Type
::T_INT
,
1017 'title' => ts('Financial Type'),
1018 'description' => ts('Financial type assigned to paid event registrations for this event. Required if is_monetary is true.'),
1019 'where' => 'civicrm_event.financial_type_id',
1021 'table_name' => 'civicrm_event',
1022 'entity' => 'Event',
1023 'bao' => 'CRM_Event_BAO_Event',
1028 'pseudoconstant' => [
1029 'table' => 'civicrm_financial_type',
1030 'keyColumn' => 'id',
1031 'labelColumn' => 'name',
1035 'payment_processor' => [
1036 'name' => 'payment_processor',
1037 'type' => CRM_Utils_Type
::T_STRING
,
1038 'title' => ts('Payment Processor'),
1039 'description' => ts('Payment Processors configured for this Event (if is_monetary is true)'),
1041 'size' => CRM_Utils_Type
::HUGE
,
1042 'where' => 'civicrm_event.payment_processor',
1043 'table_name' => 'civicrm_event',
1044 'entity' => 'Event',
1045 'bao' => 'CRM_Event_BAO_Event',
1047 'serialize' => self
::SERIALIZE_SEPARATOR_TRIMMED
,
1050 'label' => ts("Payment Processors"),
1052 'pseudoconstant' => [
1053 'table' => 'civicrm_payment_processor',
1054 'keyColumn' => 'id',
1055 'labelColumn' => 'name',
1061 'type' => CRM_Utils_Type
::T_BOOLEAN
,
1062 'title' => ts('Map Enabled'),
1063 'description' => ts('Include a map block on the Event Information page when geocode info is available and a mapping provider has been specified?'),
1065 'where' => 'civicrm_event.is_map',
1067 'table_name' => 'civicrm_event',
1068 'entity' => 'Event',
1069 'bao' => 'CRM_Event_BAO_Event',
1072 'type' => 'CheckBox',
1077 'name' => 'is_active',
1078 'type' => CRM_Utils_Type
::T_BOOLEAN
,
1079 'title' => ts('Is Active'),
1080 'description' => ts('Is this Event enabled or disabled/cancelled?'),
1082 'where' => 'civicrm_event.is_active',
1084 'table_name' => 'civicrm_event',
1085 'entity' => 'Event',
1086 'bao' => 'CRM_Event_BAO_Event',
1089 'type' => 'CheckBox',
1094 'name' => 'fee_label',
1095 'type' => CRM_Utils_Type
::T_STRING
,
1096 'title' => ts('Fee Label'),
1098 'size' => CRM_Utils_Type
::HUGE
,
1100 'where' => 'civicrm_event.fee_label',
1101 'headerPattern' => '/^fee|(f(ee\s)?label)$/i',
1103 'table_name' => 'civicrm_event',
1104 'entity' => 'Event',
1105 'bao' => 'CRM_Event_BAO_Event',
1112 'is_show_location' => [
1113 'name' => 'is_show_location',
1114 'type' => CRM_Utils_Type
::T_BOOLEAN
,
1115 'title' => ts('show location'),
1116 'description' => ts('If true, show event location.'),
1118 'where' => 'civicrm_event.is_show_location',
1120 'table_name' => 'civicrm_event',
1121 'entity' => 'Event',
1122 'bao' => 'CRM_Event_BAO_Event',
1125 'type' => 'CheckBox',
1130 'name' => 'loc_block_id',
1131 'type' => CRM_Utils_Type
::T_INT
,
1132 'title' => ts('Location Block ID'),
1133 'description' => ts('FK to Location Block ID'),
1134 'where' => 'civicrm_event.loc_block_id',
1135 'table_name' => 'civicrm_event',
1136 'entity' => 'Event',
1137 'bao' => 'CRM_Event_BAO_Event',
1139 'FKClassName' => 'CRM_Core_DAO_LocBlock',
1141 'label' => ts("Location Block"),
1145 'default_role_id' => [
1146 'name' => 'default_role_id',
1147 'type' => CRM_Utils_Type
::T_INT
,
1148 'title' => ts('Default Role'),
1149 'description' => ts('Participant role ID. Implicit FK to civicrm_option_value where option_group = participant_role.'),
1151 'where' => 'civicrm_event.default_role_id',
1154 'table_name' => 'civicrm_event',
1155 'entity' => 'Event',
1156 'bao' => 'CRM_Event_BAO_Event',
1161 'pseudoconstant' => [
1162 'optionGroupName' => 'participant_role',
1163 'optionEditPath' => 'civicrm/admin/options/participant_role',
1168 'name' => 'intro_text',
1169 'type' => CRM_Utils_Type
::T_TEXT
,
1170 'title' => ts('Introductory Message'),
1171 'description' => ts('Introductory message for Event Registration page. Text and html allowed. Displayed at the top of Event Registration form.'),
1174 'where' => 'civicrm_event.intro_text',
1175 'table_name' => 'civicrm_event',
1176 'entity' => 'Event',
1177 'bao' => 'CRM_Event_BAO_Event',
1180 'type' => 'RichTextEditor',
1185 'name' => 'footer_text',
1186 'type' => CRM_Utils_Type
::T_TEXT
,
1187 'title' => ts('Footer Message'),
1188 'description' => ts('Footer message for Event Registration page. Text and html allowed. Displayed at the bottom of Event Registration form.'),
1191 'where' => 'civicrm_event.footer_text',
1192 'table_name' => 'civicrm_event',
1193 'entity' => 'Event',
1194 'bao' => 'CRM_Event_BAO_Event',
1197 'type' => 'RichTextEditor',
1201 'confirm_title' => [
1202 'name' => 'confirm_title',
1203 'type' => CRM_Utils_Type
::T_STRING
,
1204 'title' => ts('Confirmation Title'),
1205 'description' => ts('Title for Confirmation page.'),
1207 'size' => CRM_Utils_Type
::HUGE
,
1208 'where' => 'civicrm_event.confirm_title',
1210 'table_name' => 'civicrm_event',
1211 'entity' => 'Event',
1212 'bao' => 'CRM_Event_BAO_Event',
1220 'name' => 'confirm_text',
1221 'type' => CRM_Utils_Type
::T_TEXT
,
1222 'title' => ts('Confirm Text'),
1223 'description' => ts('Introductory message for Event Registration page. Text and html allowed. Displayed at the top of Event Registration form.'),
1226 'where' => 'civicrm_event.confirm_text',
1227 'table_name' => 'civicrm_event',
1228 'entity' => 'Event',
1229 'bao' => 'CRM_Event_BAO_Event',
1232 'type' => 'RichTextEditor',
1236 'confirm_footer_text' => [
1237 'name' => 'confirm_footer_text',
1238 'type' => CRM_Utils_Type
::T_TEXT
,
1239 'title' => ts('Footer Text'),
1240 'description' => ts('Footer message for Event Registration page. Text and html allowed. Displayed at the bottom of Event Registration form.'),
1243 'where' => 'civicrm_event.confirm_footer_text',
1244 'table_name' => 'civicrm_event',
1245 'entity' => 'Event',
1246 'bao' => 'CRM_Event_BAO_Event',
1249 'type' => 'RichTextEditor',
1253 'is_email_confirm' => [
1254 'name' => 'is_email_confirm',
1255 'type' => CRM_Utils_Type
::T_BOOLEAN
,
1256 'title' => ts('Is confirm email'),
1257 'description' => ts('If true, confirmation is automatically emailed to contact on successful registration.'),
1259 'where' => 'civicrm_event.is_email_confirm',
1261 'table_name' => 'civicrm_event',
1262 'entity' => 'Event',
1263 'bao' => 'CRM_Event_BAO_Event',
1266 'type' => 'CheckBox',
1270 'confirm_email_text' => [
1271 'name' => 'confirm_email_text',
1272 'type' => CRM_Utils_Type
::T_TEXT
,
1273 'title' => ts('Confirmation Email Text'),
1274 'description' => ts('text to include above standard event info on confirmation email. emails are text-only, so do not allow html for now'),
1277 'where' => 'civicrm_event.confirm_email_text',
1278 'table_name' => 'civicrm_event',
1279 'entity' => 'Event',
1280 'bao' => 'CRM_Event_BAO_Event',
1283 'type' => 'TextArea',
1287 'confirm_from_name' => [
1288 'name' => 'confirm_from_name',
1289 'type' => CRM_Utils_Type
::T_STRING
,
1290 'title' => ts('Confirm From Name'),
1291 'description' => ts('FROM email name used for confirmation emails.'),
1293 'size' => CRM_Utils_Type
::HUGE
,
1294 'where' => 'civicrm_event.confirm_from_name',
1295 'table_name' => 'civicrm_event',
1296 'entity' => 'Event',
1297 'bao' => 'CRM_Event_BAO_Event',
1304 'confirm_from_email' => [
1305 'name' => 'confirm_from_email',
1306 'type' => CRM_Utils_Type
::T_STRING
,
1307 'title' => ts('Confirm From Email'),
1308 'description' => ts('FROM email address used for confirmation emails.'),
1310 'size' => CRM_Utils_Type
::HUGE
,
1311 'where' => 'civicrm_event.confirm_from_email',
1312 'table_name' => 'civicrm_event',
1313 'entity' => 'Event',
1314 'bao' => 'CRM_Event_BAO_Event',
1322 'name' => 'cc_confirm',
1323 'type' => CRM_Utils_Type
::T_STRING
,
1324 'title' => ts('Cc Confirm'),
1325 'description' => ts('comma-separated list of email addresses to cc each time a confirmation is sent'),
1327 'size' => CRM_Utils_Type
::HUGE
,
1328 'where' => 'civicrm_event.cc_confirm',
1329 'table_name' => 'civicrm_event',
1330 'entity' => 'Event',
1331 'bao' => 'CRM_Event_BAO_Event',
1335 'label' => ts("CC Confirm"),
1340 'name' => 'bcc_confirm',
1341 'type' => CRM_Utils_Type
::T_STRING
,
1342 'title' => ts('Bcc Confirm'),
1343 'description' => ts('comma-separated list of email addresses to bcc each time a confirmation is sent'),
1345 'size' => CRM_Utils_Type
::HUGE
,
1346 'where' => 'civicrm_event.bcc_confirm',
1347 'table_name' => 'civicrm_event',
1348 'entity' => 'Event',
1349 'bao' => 'CRM_Event_BAO_Event',
1353 'label' => ts("BCC Confirm"),
1357 'default_fee_id' => [
1358 'name' => 'default_fee_id',
1359 'type' => CRM_Utils_Type
::T_INT
,
1360 'title' => ts('Default Fee ID'),
1361 'description' => ts('FK to civicrm_option_value.'),
1362 'where' => 'civicrm_event.default_fee_id',
1363 'table_name' => 'civicrm_event',
1364 'entity' => 'Event',
1365 'bao' => 'CRM_Event_BAO_Event',
1369 'default_discount_fee_id' => [
1370 'name' => 'default_discount_fee_id',
1371 'type' => CRM_Utils_Type
::T_INT
,
1372 'title' => ts('Default Discount Fee ID'),
1373 'description' => ts('FK to civicrm_option_value.'),
1374 'where' => 'civicrm_event.default_discount_fee_id',
1375 'table_name' => 'civicrm_event',
1376 'entity' => 'Event',
1377 'bao' => 'CRM_Event_BAO_Event',
1381 'thankyou_title' => [
1382 'name' => 'thankyou_title',
1383 'type' => CRM_Utils_Type
::T_STRING
,
1384 'title' => ts('ThankYou Title'),
1385 'description' => ts('Title for ThankYou page.'),
1387 'size' => CRM_Utils_Type
::HUGE
,
1388 'where' => 'civicrm_event.thankyou_title',
1390 'table_name' => 'civicrm_event',
1391 'entity' => 'Event',
1392 'bao' => 'CRM_Event_BAO_Event',
1399 'thankyou_text' => [
1400 'name' => 'thankyou_text',
1401 'type' => CRM_Utils_Type
::T_TEXT
,
1402 'title' => ts('ThankYou Text'),
1403 'description' => ts('ThankYou Text.'),
1406 'where' => 'civicrm_event.thankyou_text',
1407 'table_name' => 'civicrm_event',
1408 'entity' => 'Event',
1409 'bao' => 'CRM_Event_BAO_Event',
1412 'type' => 'RichTextEditor',
1416 'thankyou_footer_text' => [
1417 'name' => 'thankyou_footer_text',
1418 'type' => CRM_Utils_Type
::T_TEXT
,
1419 'title' => ts('Footer Text'),
1420 'description' => ts('Footer message.'),
1423 'where' => 'civicrm_event.thankyou_footer_text',
1424 'table_name' => 'civicrm_event',
1425 'entity' => 'Event',
1426 'bao' => 'CRM_Event_BAO_Event',
1429 'type' => 'RichTextEditor',
1434 'name' => 'is_pay_later',
1435 'type' => CRM_Utils_Type
::T_BOOLEAN
,
1436 'title' => ts('Pay Later Allowed'),
1437 'description' => ts('if true - allows the user to send payment directly to the org later'),
1439 'where' => 'civicrm_event.is_pay_later',
1441 'table_name' => 'civicrm_event',
1442 'entity' => 'Event',
1443 'bao' => 'CRM_Event_BAO_Event',
1446 'type' => 'CheckBox',
1450 'pay_later_text' => [
1451 'name' => 'pay_later_text',
1452 'type' => CRM_Utils_Type
::T_TEXT
,
1453 'title' => ts('Pay Later Text'),
1454 'description' => ts('The text displayed to the user in the main form'),
1455 'where' => 'civicrm_event.pay_later_text',
1456 'table_name' => 'civicrm_event',
1457 'entity' => 'Event',
1458 'bao' => 'CRM_Event_BAO_Event',
1461 'type' => 'RichTextEditor',
1465 'pay_later_receipt' => [
1466 'name' => 'pay_later_receipt',
1467 'type' => CRM_Utils_Type
::T_TEXT
,
1468 'title' => ts('Pay Later Receipt Text'),
1469 'description' => ts('The receipt sent to the user instead of the normal receipt text'),
1470 'where' => 'civicrm_event.pay_later_receipt',
1471 'table_name' => 'civicrm_event',
1472 'entity' => 'Event',
1473 'bao' => 'CRM_Event_BAO_Event',
1480 'is_partial_payment' => [
1481 'name' => 'is_partial_payment',
1482 'type' => CRM_Utils_Type
::T_BOOLEAN
,
1483 'title' => ts('Partial Payments Enabled'),
1484 'description' => ts('is partial payment enabled for this event'),
1486 'where' => 'civicrm_event.is_partial_payment',
1488 'table_name' => 'civicrm_event',
1489 'entity' => 'Event',
1490 'bao' => 'CRM_Event_BAO_Event',
1493 'type' => 'CheckBox',
1497 'initial_amount_label' => [
1498 'name' => 'initial_amount_label',
1499 'type' => CRM_Utils_Type
::T_STRING
,
1500 'title' => ts('Initial Amount Label'),
1501 'description' => ts('Initial amount label for partial payment'),
1503 'size' => CRM_Utils_Type
::HUGE
,
1504 'where' => 'civicrm_event.initial_amount_label',
1505 'table_name' => 'civicrm_event',
1506 'entity' => 'Event',
1507 'bao' => 'CRM_Event_BAO_Event',
1514 'initial_amount_help_text' => [
1515 'name' => 'initial_amount_help_text',
1516 'type' => CRM_Utils_Type
::T_TEXT
,
1517 'title' => ts('Initial Amount Help Text'),
1518 'description' => ts('Initial amount help text for partial payment'),
1519 'where' => 'civicrm_event.initial_amount_help_text',
1520 'table_name' => 'civicrm_event',
1521 'entity' => 'Event',
1522 'bao' => 'CRM_Event_BAO_Event',
1529 'min_initial_amount' => [
1530 'name' => 'min_initial_amount',
1531 'type' => CRM_Utils_Type
::T_MONEY
,
1532 'title' => ts('Minimum Initial Amount'),
1533 'description' => ts('Minimum initial amount for partial payment'),
1538 'where' => 'civicrm_event.min_initial_amount',
1539 'table_name' => 'civicrm_event',
1540 'entity' => 'Event',
1541 'bao' => 'CRM_Event_BAO_Event',
1548 'is_multiple_registrations' => [
1549 'name' => 'is_multiple_registrations',
1550 'type' => CRM_Utils_Type
::T_BOOLEAN
,
1551 'title' => ts('Allow Multiple Registrations'),
1552 'description' => ts('if true - allows the user to register multiple participants for event'),
1554 'where' => 'civicrm_event.is_multiple_registrations',
1556 'table_name' => 'civicrm_event',
1557 'entity' => 'Event',
1558 'bao' => 'CRM_Event_BAO_Event',
1561 'type' => 'CheckBox',
1565 'max_additional_participants' => [
1566 'name' => 'max_additional_participants',
1567 'type' => CRM_Utils_Type
::T_INT
,
1568 'title' => ts('Maximum number of additional participants per registration'),
1569 'description' => ts('Maximum number of additional participants that can be registered on a single booking'),
1570 'where' => 'civicrm_event.max_additional_participants',
1572 'table_name' => 'civicrm_event',
1573 'entity' => 'Event',
1574 'bao' => 'CRM_Event_BAO_Event',
1578 'allow_same_participant_emails' => [
1579 'name' => 'allow_same_participant_emails',
1580 'type' => CRM_Utils_Type
::T_BOOLEAN
,
1581 'title' => ts('Does Event allow multiple registrations from same email address?'),
1582 'description' => ts('if true - allows the user to register multiple registrations from same email address.'),
1584 'where' => 'civicrm_event.allow_same_participant_emails',
1586 'table_name' => 'civicrm_event',
1587 'entity' => 'Event',
1588 'bao' => 'CRM_Event_BAO_Event',
1591 'type' => 'CheckBox',
1596 'name' => 'has_waitlist',
1597 'type' => CRM_Utils_Type
::T_BOOLEAN
,
1598 'title' => ts('Waitlist Enabled'),
1599 'description' => ts('Whether the event has waitlist support.'),
1601 'where' => 'civicrm_event.has_waitlist',
1603 'table_name' => 'civicrm_event',
1604 'entity' => 'Event',
1605 'bao' => 'CRM_Event_BAO_Event',
1608 'type' => 'CheckBox',
1612 'requires_approval' => [
1613 'name' => 'requires_approval',
1614 'type' => CRM_Utils_Type
::T_BOOLEAN
,
1615 'title' => ts('Requires Approval'),
1616 'description' => ts('Whether participants require approval before they can finish registering.'),
1618 'where' => 'civicrm_event.requires_approval',
1620 'table_name' => 'civicrm_event',
1621 'entity' => 'Event',
1622 'bao' => 'CRM_Event_BAO_Event',
1625 'type' => 'CheckBox',
1626 'label' => ts("Requires Approval"),
1630 'expiration_time' => [
1631 'name' => 'expiration_time',
1632 'type' => CRM_Utils_Type
::T_INT
,
1633 'title' => ts('Expiration Time'),
1634 'description' => ts('Expire pending but unconfirmed registrations after this many hours.'),
1635 'where' => 'civicrm_event.expiration_time',
1636 'table_name' => 'civicrm_event',
1637 'entity' => 'Event',
1638 'bao' => 'CRM_Event_BAO_Event',
1642 'label' => ts("Expiration Time"),
1646 'allow_selfcancelxfer' => [
1647 'name' => 'allow_selfcancelxfer',
1648 'type' => CRM_Utils_Type
::T_BOOLEAN
,
1649 'title' => ts('Allow Self-service Cancellation or Transfer'),
1650 'description' => ts('Allow self service cancellation or transfer for event?'),
1652 'where' => 'civicrm_event.allow_selfcancelxfer',
1654 'table_name' => 'civicrm_event',
1655 'entity' => 'Event',
1656 'bao' => 'CRM_Event_BAO_Event',
1659 'type' => 'CheckBox',
1663 'selfcancelxfer_time' => [
1664 'name' => 'selfcancelxfer_time',
1665 'type' => CRM_Utils_Type
::T_INT
,
1666 'title' => ts('Self-service Cancellation or Transfer Time'),
1667 'description' => ts('Number of hours prior to event start date to allow self-service cancellation or transfer.'),
1668 'where' => 'civicrm_event.selfcancelxfer_time',
1670 'table_name' => 'civicrm_event',
1671 'entity' => 'Event',
1672 'bao' => 'CRM_Event_BAO_Event',
1679 'waitlist_text' => [
1680 'name' => 'waitlist_text',
1681 'type' => CRM_Utils_Type
::T_TEXT
,
1682 'title' => ts('Waitlist Text'),
1683 'description' => ts('Text to display when the event is full, but participants can signup for a waitlist.'),
1686 'where' => 'civicrm_event.waitlist_text',
1687 'table_name' => 'civicrm_event',
1688 'entity' => 'Event',
1689 'bao' => 'CRM_Event_BAO_Event',
1692 'type' => 'TextArea',
1693 'label' => ts("Waitlist Text"),
1697 'approval_req_text' => [
1698 'name' => 'approval_req_text',
1699 'type' => CRM_Utils_Type
::T_TEXT
,
1700 'title' => ts('Approval Req Text'),
1701 'description' => ts('Text to display when the approval is required to complete registration for an event.'),
1704 'where' => 'civicrm_event.approval_req_text',
1705 'table_name' => 'civicrm_event',
1706 'entity' => 'Event',
1707 'bao' => 'CRM_Event_BAO_Event',
1710 'type' => 'TextArea',
1711 'label' => ts("Approval Required Text"),
1716 'name' => 'is_template',
1717 'type' => CRM_Utils_Type
::T_BOOLEAN
,
1718 'title' => ts('Is an Event Template'),
1719 'description' => ts('whether the event has template'),
1721 'where' => 'civicrm_event.is_template',
1723 'table_name' => 'civicrm_event',
1724 'entity' => 'Event',
1725 'bao' => 'CRM_Event_BAO_Event',
1728 'type' => 'CheckBox',
1732 'template_title' => [
1733 'name' => 'template_title',
1734 'type' => CRM_Utils_Type
::T_STRING
,
1735 'title' => ts('Event Template Title'),
1736 'description' => ts('Event Template Title'),
1738 'size' => CRM_Utils_Type
::HUGE
,
1740 'where' => 'civicrm_event.template_title',
1741 'headerPattern' => '/(template.)?title$/i',
1743 'table_name' => 'civicrm_event',
1744 'entity' => 'Event',
1745 'bao' => 'CRM_Event_BAO_Event',
1753 'name' => 'created_id',
1754 'type' => CRM_Utils_Type
::T_INT
,
1755 'title' => ts('Created By Contact ID'),
1756 'description' => ts('FK to civicrm_contact, who created this event'),
1757 'where' => 'civicrm_event.created_id',
1758 'table_name' => 'civicrm_event',
1759 'entity' => 'Event',
1760 'bao' => 'CRM_Event_BAO_Event',
1762 'FKClassName' => 'CRM_Contact_DAO_Contact',
1764 'label' => ts("Created By"),
1769 'name' => 'created_date',
1770 'type' => CRM_Utils_Type
::T_DATE + CRM_Utils_Type
::T_TIME
,
1771 'title' => ts('Event Created Date'),
1772 'description' => ts('Date and time that event was created.'),
1773 'where' => 'civicrm_event.created_date',
1774 'table_name' => 'civicrm_event',
1775 'entity' => 'Event',
1776 'bao' => 'CRM_Event_BAO_Event',
1781 'name' => 'currency',
1782 'type' => CRM_Utils_Type
::T_STRING
,
1783 'title' => ts('Currency'),
1784 'description' => ts('3 character string, value from config setting or input via user.'),
1786 'size' => CRM_Utils_Type
::FOUR
,
1788 'where' => 'civicrm_event.currency',
1789 'headerPattern' => '/cur(rency)?/i',
1790 'dataPattern' => '/^[A-Z]{3}$/i',
1792 'table_name' => 'civicrm_event',
1793 'entity' => 'Event',
1794 'bao' => 'CRM_Event_BAO_Event',
1798 'label' => ts("Currency"),
1800 'pseudoconstant' => [
1801 'table' => 'civicrm_currency',
1802 'keyColumn' => 'name',
1803 'labelColumn' => 'full_name',
1804 'nameColumn' => 'name',
1805 'abbrColumn' => 'symbol',
1810 'name' => 'campaign_id',
1811 'type' => CRM_Utils_Type
::T_INT
,
1812 'title' => ts('Campaign ID'),
1813 'description' => ts('The campaign for which this event has been created.'),
1814 'where' => 'civicrm_event.campaign_id',
1815 'table_name' => 'civicrm_event',
1816 'entity' => 'Event',
1817 'bao' => 'CRM_Event_BAO_Event',
1819 'FKClassName' => 'CRM_Campaign_DAO_Campaign',
1820 'component' => 'CiviCampaign',
1822 'type' => 'EntityRef',
1823 'label' => ts("Campaign"),
1825 'pseudoconstant' => [
1826 'table' => 'civicrm_campaign',
1827 'keyColumn' => 'id',
1828 'labelColumn' => 'title',
1829 'prefetch' => 'FALSE',
1834 'name' => 'is_share',
1835 'type' => CRM_Utils_Type
::T_BOOLEAN
,
1836 'title' => ts('Is shared through social media'),
1837 'description' => ts('Can people share the event through social media?'),
1839 'where' => 'civicrm_event.is_share',
1841 'table_name' => 'civicrm_event',
1842 'entity' => 'Event',
1843 'bao' => 'CRM_Event_BAO_Event',
1846 'type' => 'CheckBox',
1850 'is_confirm_enabled' => [
1851 'name' => 'is_confirm_enabled',
1852 'type' => CRM_Utils_Type
::T_BOOLEAN
,
1853 'title' => ts('Is the booking confirmation screen enabled?'),
1854 'description' => ts('If false, the event booking confirmation screen gets skipped'),
1856 'where' => 'civicrm_event.is_confirm_enabled',
1858 'table_name' => 'civicrm_event',
1859 'entity' => 'Event',
1860 'bao' => 'CRM_Event_BAO_Event',
1863 'type' => 'CheckBox',
1867 'parent_event_id' => [
1868 'name' => 'parent_event_id',
1869 'type' => CRM_Utils_Type
::T_INT
,
1870 'title' => ts('Parent Event ID'),
1871 'description' => ts('Implicit FK to civicrm_event: parent event'),
1872 'where' => 'civicrm_event.parent_event_id',
1874 'table_name' => 'civicrm_event',
1875 'entity' => 'Event',
1876 'bao' => 'CRM_Event_BAO_Event',
1879 'type' => 'EntityRef',
1883 'slot_label_id' => [
1884 'name' => 'slot_label_id',
1885 'type' => CRM_Utils_Type
::T_INT
,
1886 'title' => ts('Subevent Slot Label ID'),
1887 'description' => ts('Subevent slot label. Implicit FK to civicrm_option_value where option_group = conference_slot.'),
1888 'where' => 'civicrm_event.slot_label_id',
1890 'table_name' => 'civicrm_event',
1891 'entity' => 'Event',
1892 'bao' => 'CRM_Event_BAO_Event',
1899 'dedupe_rule_group_id' => [
1900 'name' => 'dedupe_rule_group_id',
1901 'type' => CRM_Utils_Type
::T_INT
,
1902 'title' => ts('Dedupe Rule ID'),
1903 'description' => ts('Rule to use when matching registrations for this event'),
1904 'where' => 'civicrm_event.dedupe_rule_group_id',
1906 'table_name' => 'civicrm_event',
1907 'entity' => 'Event',
1908 'bao' => 'CRM_Event_BAO_Event',
1910 'FKClassName' => 'CRM_Dedupe_DAO_DedupeRuleGroup',
1913 'label' => ts("Dedupe Rule"),
1915 'pseudoconstant' => [
1916 'table' => 'civicrm_dedupe_rule_group',
1917 'keyColumn' => 'id',
1918 'labelColumn' => 'title',
1919 'nameColumn' => 'name',
1923 'is_billing_required' => [
1924 'name' => 'is_billing_required',
1925 'type' => CRM_Utils_Type
::T_BOOLEAN
,
1926 'title' => ts('Is billing block required'),
1927 'description' => ts('if true than billing block is required this event'),
1929 'where' => 'civicrm_event.is_billing_required',
1931 'table_name' => 'civicrm_event',
1932 'entity' => 'Event',
1933 'bao' => 'CRM_Event_BAO_Event',
1936 'type' => 'CheckBox',
1941 CRM_Core_DAO_AllCoreTables
::invoke(__CLASS__
, 'fields_callback', Civi
::$statics[__CLASS__
]['fields']);
1943 return Civi
::$statics[__CLASS__
]['fields'];
1947 * Return a mapping from field-name to the corresponding key (as used in fields()).
1950 * Array(string $name => string $uniqueName).
1952 public static function &fieldKeys() {
1953 if (!isset(Civi
::$statics[__CLASS__
]['fieldKeys'])) {
1954 Civi
::$statics[__CLASS__
]['fieldKeys'] = array_flip(CRM_Utils_Array
::collect('name', self
::fields()));
1956 return Civi
::$statics[__CLASS__
]['fieldKeys'];
1960 * Returns the names of this table
1964 public static function getTableName() {
1965 return CRM_Core_DAO
::getLocaleTableName(self
::$_tableName);
1969 * Returns if this table needs to be logged
1973 public function getLog() {
1978 * Returns the list of fields that can be imported
1980 * @param bool $prefix
1984 public static function &import($prefix = FALSE) {
1985 $r = CRM_Core_DAO_AllCoreTables
::getImports(__CLASS__
, 'event', $prefix, []);
1990 * Returns the list of fields that can be exported
1992 * @param bool $prefix
1996 public static function &export($prefix = FALSE) {
1997 $r = CRM_Core_DAO_AllCoreTables
::getExports(__CLASS__
, 'event', $prefix, []);
2002 * Returns the list of indices
2004 * @param bool $localize
2008 public static function indices($localize = TRUE) {
2010 'index_event_type_id' => [
2011 'name' => 'index_event_type_id',
2013 0 => 'event_type_id',
2015 'localizable' => FALSE,
2016 'sig' => 'civicrm_event::0::event_type_id',
2018 'index_participant_listing_id' => [
2019 'name' => 'index_participant_listing_id',
2021 0 => 'participant_listing_id',
2023 'localizable' => FALSE,
2024 'sig' => 'civicrm_event::0::participant_listing_id',
2026 'index_parent_event_id' => [
2027 'name' => 'index_parent_event_id',
2029 0 => 'parent_event_id',
2031 'localizable' => FALSE,
2032 'sig' => 'civicrm_event::0::parent_event_id',
2035 return ($localize && !empty($indices)) ? CRM_Core_DAO_AllCoreTables
::multilingualize(__CLASS__
, $indices) : $indices;