提交 e934d640 authored 作者: chengye's avatar chengye

test

上级 75613257
......@@ -159,7 +159,7 @@ class Invoice extends Base
$inv->type = 4;
$inv->rate = $uData['rate'];
$inv->repo_numb = round(($uData['current_sum_numb'] - $uData['last_sum_numb']) * $uData['rate'],3);
$inv->payment_amount = $inv->payment_balance = $inv->repo_numb * $uData['pay_price'];
$inv->payment_amount = $inv->payment_balance = $uData['amount'];
//结算信息
$inv->settle_amount = $inv->settle_balance = $inv->repo_numb * $uData['settle_price'];
$inv->status = '000';
......@@ -178,11 +178,11 @@ class Invoice extends Base
$eiu->save();
}
//更新电表账户
$useage = \app\em\model\Useage::get(['useage_id' => $uData['useage_id']]);
$account = new Account();
$account->updateAmount($useage->em_id,$inv->payment_amount,0);
// //更新电表账户
// $useage = \app\em\model\Useage::get(['useage_id' => $uData['useage_id']]);
//
// $account = new Account();
// $account->updateAmount($useage->em_id,$inv->payment_amount,0);
return $inv;
}
......@@ -221,6 +221,7 @@ class Invoice extends Base
$inv->account_id = (new Account())->getAccountId($uData['em_id']);
$inv->em_id = $uData['em_id'];
//更新抄表单的status
$useage = \app\em\model\Useage::get(['useage_id'=>$uData['useage_id']]);
$useage->status = 2;
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论