From ce18375ee90bd6c8cb86df550de08b0e9facb18c Mon Sep 17 00:00:00 2001 From: Thierry Bugier Date: Fri, 13 Mar 2026 21:41:12 +0100 Subject: [PATCH] refactor(Impact\Usage\Boavizta): remove disabled code --- src/Impact/Usage/Boavizta/AbstractAsset.php | 41 --------------------- 1 file changed, 41 deletions(-) diff --git a/src/Impact/Usage/Boavizta/AbstractAsset.php b/src/Impact/Usage/Boavizta/AbstractAsset.php index 5564178b..bc670dd8 100644 --- a/src/Impact/Usage/Boavizta/AbstractAsset.php +++ b/src/Impact/Usage/Boavizta/AbstractAsset.php @@ -140,47 +140,6 @@ protected function query($description): array return $response; } - // /** - // * Read the response to find the impacts provided by Boaviztapi - // * - // * @return array - // */ - // protected function parseResponse(array $response): array - // { - // $impacts = []; - // $types = Type::getImpactTypes(); - // foreach ($response['impacts'] as $type => $impact) { - // if (!in_array($type, $types)) { - // trigger_error(sprintf('Unsupported impact type %s in class %s', $type, __CLASS__)); - // continue; - // } - // $impact_id = Type::getImpactId($type); - // if ($impact_id === false) { - // continue; - // } - // $impacts[$impact_id] = $this->parseCriteria($type, $response['impacts'][$type]); - - // } - - // return $impacts; - // } - - // protected function parseCriteria(string $name, array $impact): ?TrackedFloat - // { - // if ($impact['embedded'] === 'not implemented') { - // return null; - // } - - // $unit_multiplier = $this->client->getCriteriaUnits()[$name]; - // $value = new TrackedFloat( - // $impact['embedded']['value'] * $unit_multiplier, - // null, - // TrackedFloat::DATA_QUALITY_ESTIMATED - // ); - - // return $value; - // } - public function getEvaluableQuery(string $itemtype, array $crit = [], bool $entity_restrict = true): array { $item_table = getTableForItemType($itemtype);