feat : config

This commit is contained in:
2025-03-20 15:32:13 +08:00
parent 3069744bfa
commit 06915620f2

View File

@@ -277,7 +277,7 @@ trait OrderTrait
*/
protected function computeSundryPrice(): void
{
$this->orderRes['sundry_num'] = match ($this->configCache->getConfigValueByKey(ConfigCode::SUNDRY_PRICE_COMPUTE_TYPE))
$this->orderRes['sundry_num'] = match ((int)$this->configCache->getConfigValueByKey(ConfigCode::SUNDRY_PRICE_COMPUTE_TYPE))
{
1 => $this->orderType == OrderCode::ORDER_TYPE_OPTIONAL ? $this->copies : 0,
2 => $this->orderType == OrderCode::ORDER_TYPE_MEAL ? $this->copies : 0,