|
|
|
@ -191,13 +191,16 @@ class CompanySystemRatioController extends AdminController
|
|
|
|
|
//将比例整合
|
|
|
|
|
function handleRatio($handleData = []) {
|
|
|
|
|
$finalData = [];
|
|
|
|
|
|
|
|
|
|
// dump($handleData);die();
|
|
|
|
|
foreach ($handleData as $key => $value) {
|
|
|
|
|
foreach ($value as $vk => $vv) {
|
|
|
|
|
foreach ($vv as $k => $v) {
|
|
|
|
|
|
|
|
|
|
if ($finalData[$key][$v['turnover']]) {
|
|
|
|
|
$finalData[$key][$v['turnover']][$vk] = $v["ratio"];
|
|
|
|
|
// if($v["instanceof"] != 0 && ($vk==0||$vk==1||$vk==2) && $handleData[$key][$vk][$k-1]["ratio"]) {
|
|
|
|
|
// $finalData[$key][$v['turnover']][$vk] = $handleData[$key][$vk][$k-1]["ratio"];
|
|
|
|
|
// }
|
|
|
|
|
//判断是否有相同值且一个是>=另一个是>的情况
|
|
|
|
|
if ($finalData[$key][$v['turnover']]["instanceof"] != $v["instanceof"]) {
|
|
|
|
|
$finalData[$key][$v['turnover']]["instanceof"] = 0;
|
|
|
|
@ -224,7 +227,7 @@ class CompanySystemRatioController extends AdminController
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// dump($finalData);
|
|
|
|
|
// dump($finalData);die();
|
|
|
|
|
$data = [];
|
|
|
|
|
foreach ($finalData as $key => $value) {
|
|
|
|
|
|
|
|
|
|