show bullet in right color

This commit is contained in:
Uwe Steinmann 2023-03-11 22:46:23 +01:00
parent 42c1e5c3fb
commit 34c7099f22

View File

@ -162,8 +162,8 @@ $(document).ready( function() {
$options[] = array("-1", getMLText("choose_category")); $options[] = array("-1", getMLText("choose_category"));
$options[] = array("0", getMLText("new_document_category")); $options[] = array("0", getMLText("new_document_category"));
foreach ($categories as $category) { foreach ($categories as $category) {
$color = substr(md5($category->getName()), 0, 6); $color = $category->getColor();
$options[] = array($category->getID(), htmlspecialchars($category->getName()), $selcat && $category->getID()==$selcat->getID(), array(array('data-before-title', "<i class='fa fa-circle' style='color: #".$color.";'></i> "), array('data-subtitle', $category->countDocumentsByCategory().' '.getMLText('documents')))); $options[] = array($category->getID(), htmlspecialchars($category->getName()), $selcat && $category->getID()==$selcat->getID(), array(array('data-before-title', "<i class='fa fa-circle' style='color: ".$color.";'></i> "), array('data-subtitle', $category->countDocumentsByCategory().' '.getMLText('documents'))));
} }
$this->formField( $this->formField(
null, //getMLText("selection"), null, //getMLText("selection"),