Esempio n. 1
0
 public function action_load_interaction()
 {
     $interactionid = $_REQUEST["interactionid"];
     $interaction = new InteractionObj($interactionid);
     $return = array();
     $return["notes"] = $interaction->notes;
     $attendees = $interaction->load_contact_objects();
     $return["date"] = StdLib::format_date($interaction->date_created, "d M Y");
     if (count($attendees) > 0) {
         foreach ($attendees as $attendee) {
             $return["attendees"][] = array("cid" => $attendee->cid, "name" => $attendee->firstname . " " . $attendee->lastname);
         }
     }
     $return["tags"] = $interaction->tags;
     return print json_encode($return);
 }
Esempio n. 2
0
        ?>
</div>
						<div class="ifeed-source">
						<?php 
        $output = '';
        foreach ($interaction->attendees as $cid) {
            $acontact = new ContactObj($cid);
            if (!$acontact->loaded) {
                continue;
            }
            $output .= '<a href="' . Yii::app()->createUrl("contact") . '?cid=' . $acontact->cid . '">' . $acontact->firstname . ' ' . $acontact->lastname . '</a>, ';
        }
        print substr($output, 0, -2);
        ?>
						<br/><em><?php 
        echo StdLib::format_date($interaction->meetingdate, "nice-notime");
        ?>
</em>
						<a href="#" class="iedit-link" interactionid="<?php 
        echo $interaction->interactionid;
        ?>
">[edit]</a> <a href="#" class="idelete-link" interactionid="<?php 
        echo $interaction->interactionid;
        ?>
">[delete]</a>
						</div>
					</div>
				</div>
			<?php 
    }
    ?>