where(['is_active' => 1])->all() as $item) { if (in_array($item->id, $model->getRightsIds())) $checkedList .= ''; } foreach (self::find()->where(['is_active' => 1])->all() as $item) { if (!in_array($item->id, $model->getRightsIds())) $checkList .= ''; } return '