public function getConditionList($condition = false)
{
$conditions = [];
foreach (Yii::app()->getModules() as $key => $value) {
$key = strtolower($key);
$module = Yii::app()->getModule($key);
if ($module !== null && $module instanceof yupe\components\WebModule && isset($module->conditions)) {
$conditionsList = [];
foreach ($module->conditions as $keyList => $valueList) {
$conditionsList[$keyList] = !$condition ? $valueList['name'] : $valueList['condition'];
}
$conditions = array_merge($conditions, $conditionsList);
}
}
return $conditions;
}