feat: consistent display of included services and prices
This commit is contained in:
@@ -605,10 +605,14 @@ class ParticipantFieldOptionsProvider extends AbstractFieldOptionsProvider
|
||||
return '';
|
||||
}
|
||||
|
||||
if (null === $service->price || 0.0 === $service->price) {
|
||||
if (null === $service->price) {
|
||||
return $service->label;
|
||||
}
|
||||
|
||||
if (0.0 === $service->price) {
|
||||
return sprintf('%s (inkl.)', $service->label);
|
||||
}
|
||||
|
||||
if ($service->price < 0) {
|
||||
// Negative prices are discounts
|
||||
return sprintf('%s (-%s€ Rabatt)', $service->label, number_format(abs($service->price), 2, ',', '.'));
|
||||
|
||||
Reference in New Issue
Block a user