Skip to content

Commit

Permalink
Merge pull request #1278 from UN-OCHA/berliner/HPC-9976
Browse files Browse the repository at this point in the history
HPC-9976: Use default label 'Measure' for data points of types periodicalMeasure and cumulativeMeasure
  • Loading branch information
berliner authored Dec 23, 2024
2 parents a73dced + 202c13c commit 5aa486c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,8 @@ public function getDefaultFieldLabel($index, $langcode = NULL) {
case 'cumulative_reach':
return (string) $this->t('People reached', [], ['langcode' => $langcode]);

case 'periodical_measure':
case 'cumulative_measure':
case 'measure':
return (string) $this->t('Measure', [], ['langcode' => $langcode]);
}
Expand Down
2 changes: 1 addition & 1 deletion html/modules/custom/ghi_subpages/src/LogframeManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -478,7 +478,7 @@ private function buildCaseloadColumns(AttachmentPrototype $attachment_prototype,
'id' => count($columns),
'item_type' => 'data_point',
'config' => [
'label' => $attachment_prototype->getDefaultFieldLabel($index, $plan->getPlanLanguage()) . ' %',
'label' => $attachment_prototype->getDefaultFieldLabel($measure, $plan->getPlanLanguage()) . ' %',
'data_point' => [
'processing' => 'calculated',
'calculation' => 'percentage',
Expand Down

0 comments on commit 5aa486c

Please sign in to comment.