{{$now_year}}年经销商销售排行
@if(Auth::user()->role->code != 'c001') @include('report/select')   @endif 客户
@if($select['query']['tag'] == 'customer_id') @endif @if($select['query']['tag']=='city_id') @else @endif @foreach($categorys['name'] as $category) @endforeach [], // 今年比去年同期增加额正数求和 'b' => [], // 今年比去年同期增加额负数求和 'c' => [] ]; foreach((array)$this_year_data as $k => $v) { $res = $v - $last_year_data[$k]; $growth['a'][$k] += $res; // 正数求和 if($res > 0) { $growth['b'][$k] += $res; } // 负数求和 if($res < 0) { $growth['c'][$k] += $res; } } $this_year_sum = array_sum((array)$this_year_data); $last_year_sum = array_sum((array)$last_year_data); $growth_a = array_sum($growth['a']); $growth_b = array_sum($growth['b']); $growth_c = array_sum($growth['c']); ?> @foreach($this_year_data as $k => $v) @if($select['query']['tag'] == 'customer_id') @endif @if($select['query']['tag'] == 'city_id') @else @endif @foreach($categorys['name'] as $category) @endforeach @endforeach @if($select['query']['tag'] == 'customer_id') @endif @foreach($categorys['name'] as $category) @endforeach @if($select['query']['tag'] == 'customer_id') @endif @foreach($categorys['name'] as $category) @endforeach @if($select['query']['tag'] == 'customer_id') @endif @foreach($categorys['name'] as $category) @endforeach
排行销售组 负责人省份 城市客户编码 客户名称 销售等级 比去年同期增长率 比去年同期增长额 总销售额 销售额占区域比 增长额总销售贡献比 增长贡献率{{$category['name']}}
{{$i}}{{$regions[$single['info'][$k]['region_id']]['name']}} {{get_user($regions[$single['info'][$k]['region_id']]['owner_user_id'], 'name')}} {{$single['info'][$k]['province_name']}} {{$single['info'][$k]['city_name']}} {{$single['info'][$k]['customer_code']}} 32877) { $post_type = '军'; } elseif ($grade > 16438) { $post_type = '师'; } elseif ($grade > 6575) { $post_type = '旅'; } elseif ($grade > 3288) { $post_type = '团'; } elseif ($grade > 1643) { $post_type = '营'; } elseif ($grade > 657) { $post_type = '连'; } else { $post_type = '问题'; } } else if($post == 2) { if ($grade > 3288) { $post_type = '大队'; } elseif ($grade > 1643) { $post_type = '中队'; } elseif ($grade > 657) { $post_type = '小队'; } elseif ($grade > 328) { $post_type = '分队'; } else { $post_type = '问题'; } } ?> {{$single['info'][$k]['customer_name']}} {{$post_type}} @if($last_year_data[$k] > 0) {{$last_year_pre}}% @else 去年同期无 @endif {{number_format($growth['a'][$k], 2)}} {{number_format($this_year_data[$k], 2)}} {{number_format(($v / array_sum($this_year_data) * 100), 2)}}% {{number_format(($growth['a'][$k] / array_sum($this_year_data) * 100), 2)}}% 0) { echo number_format(($growth['a'][$k] / $growth_b) * 100, 2); } else { echo '-'.number_format(($growth['a'][$k] / $growth_c) * 100, 2); } ?>% {{number_format($category_money[$category['id']],2)}}
净值合计 0) { $pre = number_format(($v2 / $last_year_sum) * 100, 2); } ?> {{$pre}}% {{number_format($growth_a, 2)}} {{number_format($total['all'], 2)}} {{number_format($total[$category['id']],2)}}
增长合计 0) { $pre = number_format(($growth_b / $last_year_sum) * 100, 2); } ?> {{$pre}}% {{number_format($growth_b, 2)}}
下降合计 0) { $pre = number_format(($growth_c / $last_year_sum) * 100, 2); } ?> {{$pre}}% {{number_format($growth_c, 2)}}