IssueReportTag.class.php 751 B

123456789101112131415161718192021222324252627282930
  1. <?php
  2. /**
  3. * Define a IssueReportTag.
  4. * @author Administrateur
  5. * @category Plugin
  6. * @license MIT
  7. */
  8. class IssueReportTag extends Entity{
  9. public $id,$tag,$report;
  10. protected $TABLE_NAME = 'issue_report_tag';
  11. public $fields = array(
  12. 'id' => 'key',
  13. 'tag' => 'string',
  14. 'report' => 'int'
  15. );
  16. public $indexes = array('report');
  17. public static function tags($key=null){
  18. $tags = array(
  19. 'bug' => array('icon'=>'fas fa-bug','label'=>'Bug','color'=>'#cb2431'),
  20. 'feature' => array('icon'=>'fas fa-check','label'=>'Demande','color'=>'#2cbe4e'),
  21. 'question' => array('icon'=>'far fa-question-circle','label'=>'Question','color'=>'#00BCD4')
  22. );
  23. if(!isset($key)) return $tags;
  24. return isset($tags[$key]) ? $tags[$key] : array();
  25. }
  26. }
  27. ?>