public function HeartbeatMessageTemplate::set_attachments in Heartbeat 6.4
Sets the attachments
File
- includes/
heartbeatmessagetemplate.inc, line 70 - HeartbeatMessageTemplate Template object that holds configuration for a message template. A HeartbeatActivity object will be able to have the template as composite.
Class
- HeartbeatMessageTemplate
- Class HeartbeatMessageTemplate
Code
public function set_attachments($attachments = array()) {
// if it is empty, or an array or whatever, fill it in.
$this->attachments = $attachments;
// Strings however should be converted to array
if (!empty($attachments)) {
if (is_string($attachments)) {
$this->attachments = unserialize($attachments);
}
}
}