类型调整

main
limu 1 year ago
parent ad7139e19f
commit 25ea1785e9
  1. 6
      app/command/dayUserValue.php

@ -35,7 +35,7 @@ class dayUserValue extends Command
{ {
$config = systemConfig('brand_config'); $config = systemConfig('brand_config');
$config_start = systemConfig('brand_config') ?? 1; $config_start = (int)systemConfig('brand_config') ?? 1;
$config_growth = systemConfig('brand_growth'); $config_growth = systemConfig('brand_growth');
if (empty($config)) { if (empty($config)) {
echo '无配置'; echo '无配置';
@ -53,10 +53,10 @@ class dayUserValue extends Command
$days = $config_start + 1; $days = $config_start + 1;
foreach ($resConfig as $rk => $rv) { foreach ($resConfig as $rk => $rv) {
if ($days >= $rv['start'] && $rv['bili'] > 0) { if ($days >= $rv['start'] && $rv['bili'] > 0) {
if ($config_growth) { if (empty($config_growth)) {
$growth_rate = $rv['bili']; $growth_rate = $rv['bili'];
} else { } else {
$growth_rate = bcadd($v['growth_rate'], $rv['bili'], 2); $growth_rate = bcadd($config_growth, $rv['bili'], 2);
} }
} }

Loading…
Cancel
Save