/**
  * Fetch the html code to display the field value in artifact in read only mode
  *
  * @param Tracker_Artifact                $artifact The artifact
  * @param Tracker_Artifact_ChangesetValue $value    The actual value of the field
  *
  * @return string
  */
 public function fetchArtifactValueReadOnly(Tracker_Artifact $artifact, Tracker_Artifact_ChangesetValue $value = null)
 {
     $html = '';
     $selected_values = $value ? $value->getListValues() : array();
     $tablo = array();
     if (empty($selected_values)) {
         return $this->getNoValueLabel();
     }
     foreach ($selected_values as $id => $selected) {
         $tablo[] = $this->getBind()->formatArtifactValue($id);
     }
     $html .= implode(', ', $tablo);
     return $html;
 }
 /**
  * Fetch data to display the field value in mail
  *
  * @param Tracker_Artifact                $artifact         The artifact
  * @param PFUser                          $user             The user who will receive the email
  * @param Tracker_Artifact_ChangesetValue $value            The actual value of the field
  * @param string                          $format           output format
  *
  * @return string
  */
 public function fetchMailArtifactValue(Tracker_Artifact $artifact, PFUser $user, Tracker_Artifact_ChangesetValue $value = null, $format = 'text')
 {
     if (empty($value) || !$value->getListValues()) {
         return '-';
     }
     $output = '';
     switch ($format) {
         case 'html':
             $output = $this->fetchArtifactValueReadOnly($artifact, $value);
             break;
         default:
             $selected_values = !empty($value) ? $value->getListValues() : array();
             foreach ($selected_values as $value) {
                 if ($value->getId() != 100) {
                     $output .= $value->getLabel();
                 }
             }
             break;
     }
     return $output;
 }
 /**
  * Fetch the html code to display the field value in artifact in read only mode
  *
  * @param Tracker_Artifact                $artifact The artifact
  * @param Tracker_Artifact_ChangesetValue $value    The actual value of the field
  *
  * @return string
  */
 public function fetchArtifactValueReadOnly(Tracker_Artifact $artifact, Tracker_Artifact_ChangesetValue $value = null)
 {
     $html = '';
     $selected_values = $value ? $value->getListValues() : array();
     foreach ($selected_values as $id => $v) {
         if ($id != 100) {
             $html .= $v->getLabel();
         }
     }
     return $html;
 }