1 <?xml version=
"1.0" encoding=
"iso-8859-1" ?>
3 <base>CRM/Activity
</base>
4 <class>Activity
</class>
5 <name>civicrm_activity
</name>
6 <comment>Other Activity details stored here include contact, location, details.
</comment>
12 <uniqueName>activity_id
</uniqueName>
13 <title>Activity ID
</title>
15 <type>int unsigned
</type>
16 <required>true
</required>
17 <comment>Unique Other Activity ID
</comment>
22 <autoincrement>true
</autoincrement>
25 <name>source_record_id
</name>
26 <type>int unsigned
</type>
27 <title>Source Record
</title>
28 <comment>Artificial FK to original transaction (e.g. contribution) IF it is not an Activity. Table can be figured out through activity_type_id, and further through component registry.
</comment>
32 <name>UI_source_record_id
</name>
33 <fieldName>source_record_id
</fieldName>
37 <name>activity_type_id
</name>
38 <title>Activity Type ID
</title>
40 <type>int unsigned
</type>
41 <required>true
</required>
44 <headerPattern>/(activity.)?type(.id$)/i
</headerPattern>
45 <comment>FK to civicrm_option_value.id, that has to be valid, registered activity type.
</comment>
48 <optionGroupName>activity_type
</optionGroupName>
52 <label>Activity Type
</label>
56 <name>UI_activity_type_id
</name>
57 <fieldName>activity_type_id
</fieldName>
62 <uniqueName>activity_subject
</uniqueName>
64 <title>Subject
</title>
66 <comment>The subject/purpose/short description of the activity.
</comment>
68 <headerPattern>/(activity.)?subject/i
</headerPattern>
76 <name>activity_date_time
</name>
78 <required>false
</required>
80 <default>CURRENT_TIMESTAMP
</default>
81 <title>Activity Date
</title>
83 <headerPattern>/(activity.)?date(.time$)?/i
</headerPattern>
84 <comment>Date and time this activity is scheduled to occur. Formerly named scheduled_date_time.
</comment>
86 <type>Select Date
</type>
87 <formatType>activityDateTime
</formatType>
92 <name>index_activity_date_time
</name>
93 <fieldName>activity_date_time
</fieldName>
98 <uniqueName>activity_duration
</uniqueName>
99 <title>Duration
</title>
100 <import>true
</import>
101 <type>int unsigned
</type>
102 <headerPattern>/(activity.)?duration(s)?$/i
</headerPattern>
103 <comment>Planned or actual duration of activity expressed in minutes. Conglomerate of former duration_hours and duration_minutes.
</comment>
110 <name>location
</name>
111 <uniqueName>activity_location
</uniqueName>
112 <title>Location
</title>
113 <import>true
</import>
116 <headerPattern>/(activity.)?location$/i
</headerPattern>
117 <comment>Location of the activity (optional, open text).
</comment>
124 <name>phone_id
</name>
125 <type>int unsigned
</type>
126 <title>Phone (called) ID
</title>
127 <comment>Phone ID of the number called (optional - used if an existing phone number is selected).
</comment>
130 <type>EntityRef
</type>
131 <label>Phone (called)
</label>
135 <name>phone_id
</name>
136 <table>civicrm_phone
</table>
139 <onDelete>SET NULL
</onDelete>
142 <name>phone_number
</name>
143 <title>Phone (called) Number
</title>
146 <comment>Phone number in case the number does not exist in the civicrm_phone table.
</comment>
154 <uniqueName>activity_details
</uniqueName>
155 <title>Details
</title>
156 <import>true
</import>
157 <type>longtext
</type>
158 <headerPattern>/(activity.)?detail(s)?$/i
</headerPattern>
159 <comment>Details about the activity (agenda, notes, etc).
</comment>
161 <type>RichTextEditor
</type>
168 <name>status_id
</name>
169 <uniqueName>activity_status_id
</uniqueName>
170 <title>Activity Status
</title>
171 <import>true
</import>
172 <export>true
</export>
173 <headerPattern>/(activity.)?status(.label$)?/i
</headerPattern>
174 <type>int unsigned
</type>
175 <comment>ID of the status this activity is currently in. Foreign key to civicrm_option_value.
</comment>
178 <optionGroupName>activity_status
</optionGroupName>
185 <name>index_status_id
</name>
186 <fieldName>status_id
</fieldName>
190 <name>priority_id
</name>
191 <type>int unsigned
</type>
192 <title>Priority
</title>
193 <export>true
</export>
194 <import>true
</import>
195 <comment>ID of the priority given to this activity. Foreign key to civicrm_option_value.
</comment>
198 <optionGroupName>priority
</optionGroupName>
205 <name>parent_id
</name>
206 <title>Parent Activity Id
</title>
207 <type>int unsigned
</type>
208 <comment>Parent meeting ID (if this is a follow-up item). This is not currently implemented
</comment>
212 <name>parent_id
</name>
213 <table>civicrm_activity
</table>
216 <onDelete>CASCADE
</onDelete>
221 <uniqueName>activity_is_test
</uniqueName>
224 <import>true
</import>
225 <headerPattern>/(is.)?test(.activity)?/i
</headerPattern>
228 <type>CheckBox
</type>
232 <name>medium_id
</name>
233 <uniqueName>activity_medium_id
</uniqueName>
234 <title>Activity Medium
</title>
235 <type>int unsigned
</type>
236 <default>NULL
</default>
237 <comment>Activity Medium, Implicit FK to civicrm_option_value where option_group = encounter_medium.
</comment>
239 <optionGroupName>encounter_medium
</optionGroupName>
247 <name>index_medium_id
</name>
248 <fieldName>medium_id
</fieldName>
260 <name>relationship_id
</name>
261 <title>Relationship Id
</title>
262 <type>int unsigned
</type>
263 <default>NULL
</default>
264 <comment>FK to Relationship ID
</comment>
268 <name>relationship_id
</name>
269 <table>civicrm_relationship
</table>
271 <onDelete>SET NULL
</onDelete>
274 <name>is_current_revision
</name>
275 <title>Is this activity a current revision in versioning chain?
</title>
278 <import>true
</import>
279 <headerPattern>/(is.)?(current.)?(revision|version(ing)?)/i
</headerPattern>
283 <name>index_is_current_revision
</name>
284 <fieldName>is_current_revision
</fieldName>
288 <name>original_id
</name>
289 <type>int unsigned
</type>
290 <title>Original Activity ID
</title>
291 <comment>Activity ID of the first activity record in versioning chain.
</comment>
295 <name>original_id
</name>
296 <table>civicrm_activity
</table>
299 <onDelete>CASCADE
</onDelete>
303 <uniqueName>activity_result
</uniqueName>
305 <title>Result
</title>
307 <comment>Currently being used to store result id for survey activity, FK to option value.
</comment>
311 <name>is_deleted
</name>
312 <uniqueName>activity_is_deleted
</uniqueName>
313 <title>Activity is in the Trash
</title>
316 <import>true
</import>
317 <headerPattern>/(activity.)?(trash|deleted)/i
</headerPattern>
320 <type>CheckBox
</type>
324 <name>index_is_deleted
</name>
325 <fieldName>is_deleted
</fieldName>
329 <name>campaign_id
</name>
330 <uniqueName>activity_campaign_id
</uniqueName>
331 <type>int unsigned
</type>
332 <title>Campaign
</title>
333 <import>true
</import>
334 <comment>The campaign for which this activity has been triggered.
</comment>
336 <table>civicrm_campaign
</table>
337 <keyColumn>id
</keyColumn>
338 <labelColumn>title
</labelColumn>
346 <name>campaign_id
</name>
347 <table>civicrm_campaign
</table>
349 <onDelete>SET NULL
</onDelete>
352 <name>engagement_level
</name>
353 <uniqueName>activity_engagement_level
</uniqueName>
354 <type>int unsigned
</type>
355 <title>Engagement Index
</title>
356 <import>true
</import>
357 <comment>Assign a specific level of engagement to this activity. Used for tracking constituents in ladder of engagement.
</comment>
359 <optionGroupName>engagement_index
</optionGroupName>
374 <title>Is Starred
</title>
377 <import>true
</import>
378 <comment>Activity marked as favorite.
</comment>
379 <headerPattern>/(activity.)?(star|favorite)/i
</headerPattern>
382 <type>Checkbox
</type>
386 <name>created_date
</name>
387 <uniqueName>activity_created_date
</uniqueName>
388 <type>timestamp
</type>
389 <comment>When was the activity was created.
</comment>
390 <required>false
</required>
391 <export>true
</export>
392 <default>CURRENT_TIMESTAMP
</default>
396 <name>modified_date
</name>
397 <uniqueName>activity_modified_date
</uniqueName>
398 <type>timestamp
</type>
399 <comment>When was the activity (or closely related entity) was created or modified or deleted.
</comment>
400 <required>false
</required>
401 <export>true
</export>
402 <default>CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
</default>