市场结算管理公司税率提交

master
zhengyongxing 4 years ago
parent 682ce333b1
commit 2bc4bf79d9

@ -128,7 +128,8 @@ class MarketPercentageController extends ThinkController
// dump(getMarketAdmin());die(); // dump(getMarketAdmin());die();
$data = M("settleup_marketorder","tab_") $data = M("settleup_marketorder","tab_")
->field("pay_time,promote_account,company_belong,member.real_name,develop_type,game_name, ->field("pay_time,promote_account,company_belong,member.real_name,develop_type,game_name,
sum(pay_amount) pay_amount,sum(company_profit) company_profit,group_id,market_percentage") sum(pay_amount) pay_amount,sum(company_profit) company_profit,group_id,market_percentage,
sum(if(develop_type = 1, pay_amount, 0)) performance_revenue,sum(if(develop_type = 2, pay_amount, 0)) appraisal_bonuses")
->join("left join sys_auth_group_access access on admin_id=access.uid") ->join("left join sys_auth_group_access access on admin_id=access.uid")
->join("left join sys_auth_group auth on access.group_id=auth.id") ->join("left join sys_auth_group auth on access.group_id=auth.id")
->join("left join sys_member member on access.uid=member.uid"); ->join("left join sys_member member on access.uid=member.uid");
@ -146,6 +147,8 @@ class MarketPercentageController extends ThinkController
->select(); ->select();
} }
// var_dump($data);die();
$count = M("settleup_marketorder","tab_") $count = M("settleup_marketorder","tab_")
->field("pay_time,promote_account,company_belong,real_name,develop_type,game_name, ->field("pay_time,promote_account,company_belong,real_name,develop_type,game_name,
sum(pay_amount) pay_amount,sum(company_profit) company_profit,group_id,market_percentage") sum(pay_amount) pay_amount,sum(company_profit) company_profit,group_id,market_percentage")
@ -175,8 +178,8 @@ class MarketPercentageController extends ThinkController
} }
$market_percentage = json_decode($value['market_percentage'],true); $market_percentage = json_decode($value['market_percentage'],true);
$data[$key]['performance_revenue'] = number_format($market_percentage['performance_revenue'], 2, '.', ''); // $data[$key]['performance_revenue'] = number_format($market_percentage['performance_revenue'], 2, '.', '');
$data[$key]['appraisal_bonuses'] = number_format($market_percentage['appraisal_bonuses'], 2, '.', ''); // $data[$key]['appraisal_bonuses'] = number_format($market_percentage['appraisal_bonuses'], 2, '.', '');
//业绩提成 //业绩提成
$data[$key]['performance_commission'] = $data[$key]['performance_commission'] =
number_format($value['company_profit']*($market_percentage['develop_commission_ratio']/100) + number_format($value['company_profit']*($market_percentage['develop_commission_ratio']/100) +
@ -231,7 +234,8 @@ class MarketPercentageController extends ThinkController
$data = M("settleup_marketorder","tab_") $data = M("settleup_marketorder","tab_")
->field("tab_settleup_marketorder.id,pay_time,promote_account,company_belong,member.real_name,develop_type,game_name, ->field("tab_settleup_marketorder.id,pay_time,promote_account,company_belong,member.real_name,develop_type,game_name,
sum(pay_amount) pay_amount,sum(company_profit) company_profit,group_id,market_percentage,nickname,admin_id") sum(pay_amount) pay_amount,sum(company_profit) company_profit,group_id,market_percentage,nickname,admin_id,
sum(if(develop_type = 1, pay_amount, 0)) performance_revenue,sum(if(develop_type = 2, pay_amount, 0)) appraisal_bonuses")
->join("left join sys_auth_group_access access on admin_id=access.uid") ->join("left join sys_auth_group_access access on admin_id=access.uid")
->join("left join sys_auth_group auth on access.group_id=auth.id") ->join("left join sys_auth_group auth on access.group_id=auth.id")
->join("left join sys_member member on access.uid=member.uid"); ->join("left join sys_member member on access.uid=member.uid");

@ -24,7 +24,7 @@
<td class="r"> <td class="r">
<input name="real_name" type="text" class=""> <input name="real_name" type="text" class="">
<!-- <input type="hidden" class="" name="username" value="{$list.username}" > --> <!-- <input type="hidden" class="" name="username" value="{$list.username}" > -->
<span class="notice-text">管理员账号用于管理后台登录</span> <span class="notice-text">管理员真实姓名</span>
</td> </td>
</tr> </tr>
<tr> <tr>

@ -23,7 +23,7 @@
<td class="r"> <td class="r">
<input name="real_name" value="{$data.real_name}" type="text" class=""> <input name="real_name" value="{$data.real_name}" type="text" class="">
<!-- <input type="hidden" class="" name="username" value="{$list.username}" > --> <!-- <input type="hidden" class="" name="username" value="{$list.username}" > -->
<span class="notice-text">管理员账号用于管理后台登录</span> <span class="notice-text">管理员真实姓名</span>
</td> </td>
</tr> </tr>
<tr> <tr>

Loading…
Cancel
Save