Example #1
0
 function watchCompare($old, $new)
 {
     $o = '';
     $items = $this->getItemIds();
     $n = $this->getItemLabels($items);
     return parent::watchCompare($o, $n);
     // then compare as text
 }
Example #2
0
 function watchCompare($old, $new)
 {
     global $prefs;
     $dformat = $prefs['short_date_format'] . ' ' . $prefs['short_time_format'];
     $old = TikiLib::lib('tiki')->date_format($dformat, (int) $old);
     $new = TikiLib::lib('tiki')->date_format($dformat, (int) $new);
     return parent::watchCompare($old, $new);
 }
Example #3
0
 function renderOutput($context = array())
 {
     if (isset($context['history']) && $context['history'] == 'y' && is_array($this->getConfiguration('value'))) {
         return $this->renderTemplate('trackeroutput/text_history.tpl');
     } else {
         return parent::renderOutput($context);
     }
 }
Example #4
0
 function getGlobalFields()
 {
     if ($this->getOption('indexGeometry') && $this->getValue()) {
         return array();
     } else {
         return parent::getGlobalFields();
     }
 }
Example #5
0
 public function renderInnerOutput($context = array())
 {
     $definition = Tracker_Definition::get($this->getOption('trackerId'));
     $field = $definition->getField($this->getOption('listFieldIdThere'));
     if ($field['type'] == 'e' || $field['type'] == 'r') {
         $item = $this->getItemData();
         $item['ins_' . $this->getOption('listFieldIdThere')] = array($this->getValue());
         $field['value'] = $this->getValue();
         $handler = TikiLib::lib('trk')->get_field_handler($field, $item);
         $field = array_merge($field, $handler->getFieldData($item));
         // get category field to build it's data arrays
         $handler = TikiLib::lib('trk')->get_field_handler($field, $item);
         return $handler->renderOutput($context);
     } else {
         return parent::renderInnerOutput($context);
     }
 }
Example #6
0
 function __construct($fieldInfo, $itemData, $trackerDefinition, $type)
 {
     $this->type = $type;
     parent::__construct($fieldInfo, $itemData, $trackerDefinition);
 }
Example #7
0
 function watchCompare($old, $new)
 {
     $o = $this->getItemLabel($old);
     $n = $this->getItemLabel($new);
     return parent::watchCompare($o, $n);
     // then compare as text
 }