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>
11 <add>civicrm/activity?reset=
1&action=add
&context=standalone
</add>
12 <view>civicrm/activity?reset=
1&action=view
&id=[id]
</view>
13 <update>civicrm/activity/add?reset=
1&action=update
&id=[id]
</update>
14 <delete>civicrm/activity?reset=
1&action=delete
&id=[id]
</delete>
18 <uniqueName>activity_id
</uniqueName>
19 <title>Activity ID
</title>
21 <type>int unsigned
</type>
22 <required>true
</required>
23 <comment>Unique Other Activity ID
</comment>
28 <autoincrement>true
</autoincrement>
31 <name>source_record_id
</name>
32 <type>int unsigned
</type>
33 <title>Source Record
</title>
34 <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>
38 <name>UI_source_record_id
</name>
39 <fieldName>source_record_id
</fieldName>
43 <name>activity_type_id
</name>
44 <title>Activity Type ID
</title>
46 <type>int unsigned
</type>
47 <required>true
</required>
50 <headerPattern>/(activity.)?type(.id$)/i
</headerPattern>
51 <comment>FK to civicrm_option_value.id, that has to be valid, registered activity type.
</comment>
54 <optionGroupName>activity_type
</optionGroupName>
58 <label>Activity Type
</label>
62 <name>UI_activity_type_id
</name>
63 <fieldName>activity_type_id
</fieldName>
68 <uniqueName>activity_subject
</uniqueName>
70 <title>Subject
</title>
72 <comment>The subject/purpose/short description of the activity.
</comment>
74 <headerPattern>/(activity.)?subject/i
</headerPattern>
82 <name>activity_date_time
</name>
84 <required>false
</required>
86 <default>CURRENT_TIMESTAMP
</default>
87 <title>Activity Date
</title>
89 <headerPattern>/(activity.)?date(.time$)?/i
</headerPattern>
90 <comment>Date and time this activity is scheduled to occur. Formerly named scheduled_date_time.
</comment>
92 <type>Select Date
</type>
93 <formatType>activityDateTime
</formatType>
98 <name>index_activity_date_time
</name>
99 <fieldName>activity_date_time
</fieldName>
103 <name>duration
</name>
104 <uniqueName>activity_duration
</uniqueName>
105 <title>Duration
</title>
106 <import>true
</import>
107 <type>int unsigned
</type>
108 <headerPattern>/(activity.)?duration(s)?$/i
</headerPattern>
109 <comment>Planned or actual duration of activity expressed in minutes. Conglomerate of former duration_hours and duration_minutes.
</comment>
116 <name>location
</name>
117 <uniqueName>activity_location
</uniqueName>
118 <title>Location
</title>
119 <import>true
</import>
122 <headerPattern>/(activity.)?location$/i
</headerPattern>
123 <comment>Location of the activity (optional, open text).
</comment>
130 <name>phone_id
</name>
131 <type>int unsigned
</type>
132 <title>Phone (called) ID
</title>
133 <comment>Phone ID of the number called (optional - used if an existing phone number is selected).
</comment>
136 <type>EntityRef
</type>
137 <label>Phone (called)
</label>
141 <name>phone_id
</name>
142 <table>civicrm_phone
</table>
145 <onDelete>SET NULL
</onDelete>
148 <name>phone_number
</name>
149 <title>Phone (called) Number
</title>
152 <comment>Phone number in case the number does not exist in the civicrm_phone table.
</comment>
160 <uniqueName>activity_details
</uniqueName>
161 <title>Details
</title>
162 <import>true
</import>
163 <type>longtext
</type>
164 <headerPattern>/(activity.)?detail(s)?$/i
</headerPattern>
165 <comment>Details about the activity (agenda, notes, etc).
</comment>
167 <type>RichTextEditor
</type>
174 <name>status_id
</name>
175 <uniqueName>activity_status_id
</uniqueName>
176 <title>Activity Status
</title>
177 <import>true
</import>
178 <export>true
</export>
179 <headerPattern>/(activity.)?status(.label$)?/i
</headerPattern>
180 <type>int unsigned
</type>
181 <comment>ID of the status this activity is currently in. Foreign key to civicrm_option_value.
</comment>
184 <optionGroupName>activity_status
</optionGroupName>
191 <name>index_status_id
</name>
192 <fieldName>status_id
</fieldName>
196 <name>priority_id
</name>
197 <type>int unsigned
</type>
198 <title>Priority
</title>
199 <export>true
</export>
200 <import>true
</import>
201 <comment>ID of the priority given to this activity. Foreign key to civicrm_option_value.
</comment>
204 <optionGroupName>priority
</optionGroupName>
211 <name>parent_id
</name>
212 <title>Parent Activity Id
</title>
213 <type>int unsigned
</type>
214 <comment>Parent meeting ID (if this is a follow-up item). This is not currently implemented
</comment>
218 <name>parent_id
</name>
219 <table>civicrm_activity
</table>
222 <onDelete>CASCADE
</onDelete>
227 <uniqueName>activity_is_test
</uniqueName>
230 <import>true
</import>
231 <headerPattern>/(is.)?test(.activity)?/i
</headerPattern>
234 <type>CheckBox
</type>
238 <name>medium_id
</name>
239 <uniqueName>activity_medium_id
</uniqueName>
240 <title>Activity Medium
</title>
241 <type>int unsigned
</type>
242 <default>NULL
</default>
243 <comment>Activity Medium, Implicit FK to civicrm_option_value where option_group = encounter_medium.
</comment>
245 <optionGroupName>encounter_medium
</optionGroupName>
253 <name>index_medium_id
</name>
254 <fieldName>medium_id
</fieldName>
266 <name>relationship_id
</name>
267 <title>Relationship Id
</title>
268 <type>int unsigned
</type>
269 <default>NULL
</default>
270 <comment>FK to Relationship ID
</comment>
274 <name>relationship_id
</name>
275 <table>civicrm_relationship
</table>
277 <onDelete>SET NULL
</onDelete>
280 <name>is_current_revision
</name>
281 <title>Is this activity a current revision in versioning chain?
</title>
284 <import>true
</import>
285 <headerPattern>/(is.)?(current.)?(revision|version(ing)?)/i
</headerPattern>
289 <name>index_is_current_revision
</name>
290 <fieldName>is_current_revision
</fieldName>
294 <name>original_id
</name>
295 <type>int unsigned
</type>
296 <title>Original Activity ID
</title>
297 <comment>Activity ID of the first activity record in versioning chain.
</comment>
301 <name>original_id
</name>
302 <table>civicrm_activity
</table>
305 <onDelete>CASCADE
</onDelete>
309 <uniqueName>activity_result
</uniqueName>
311 <title>Result
</title>
313 <comment>Currently being used to store result id for survey activity, FK to option value.
</comment>
317 <name>is_deleted
</name>
318 <uniqueName>activity_is_deleted
</uniqueName>
319 <title>Activity is in the Trash
</title>
322 <import>true
</import>
323 <headerPattern>/(activity.)?(trash|deleted)/i
</headerPattern>
326 <type>CheckBox
</type>
330 <name>index_is_deleted
</name>
331 <fieldName>is_deleted
</fieldName>
335 <name>campaign_id
</name>
336 <uniqueName>activity_campaign_id
</uniqueName>
337 <type>int unsigned
</type>
338 <title>Campaign
</title>
339 <import>true
</import>
340 <comment>The campaign for which this activity has been triggered.
</comment>
342 <table>civicrm_campaign
</table>
343 <keyColumn>id
</keyColumn>
344 <labelColumn>title
</labelColumn>
352 <name>campaign_id
</name>
353 <table>civicrm_campaign
</table>
355 <onDelete>SET NULL
</onDelete>
358 <name>engagement_level
</name>
359 <uniqueName>activity_engagement_level
</uniqueName>
360 <type>int unsigned
</type>
361 <title>Engagement Index
</title>
362 <import>true
</import>
363 <comment>Assign a specific level of engagement to this activity. Used for tracking constituents in ladder of engagement.
</comment>
365 <optionGroupName>engagement_index
</optionGroupName>
380 <title>Is Starred
</title>
383 <import>true
</import>
384 <comment>Activity marked as favorite.
</comment>
385 <headerPattern>/(activity.)?(star|favorite)/i
</headerPattern>
388 <type>Checkbox
</type>
392 <name>created_date
</name>
393 <uniqueName>activity_created_date
</uniqueName>
394 <type>timestamp
</type>
395 <comment>When was the activity was created.
</comment>
396 <required>false
</required>
397 <export>true
</export>
398 <default>CURRENT_TIMESTAMP
</default>
402 <name>modified_date
</name>
403 <uniqueName>activity_modified_date
</uniqueName>
404 <type>timestamp
</type>
405 <comment>When was the activity (or closely related entity) was created or modified or deleted.
</comment>
406 <required>false
</required>
407 <export>true
</export>
408 <default>CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
</default>