东莞电信 余额转移 限定账户
Change-Id: I5d8de3678f638d955adfe27022fda2058f42ba7b
This commit is contained in:
parent
7ace1c206e
commit
afb2f2fcb0
|
@ -351,6 +351,15 @@ class Recharge extends REST_Controller
|
||||||
$zy_supplier_id = intval($a[0]);
|
$zy_supplier_id = intval($a[0]);
|
||||||
$zy_type_id = intval($a[1]);
|
$zy_type_id = intval($a[1]);
|
||||||
|
|
||||||
|
// 代码写死,东莞电信 company_id = 15 必须 supplier_id = 28,否则不符合余额转移
|
||||||
|
if($this->user->company_id == 15 && $zy_supplier_id != 28){
|
||||||
|
$this->response(array(
|
||||||
|
'status' => 0,
|
||||||
|
'message' => '当前只能转移公诚物业的积分账户',
|
||||||
|
'data' => array()
|
||||||
|
), REST_Controller::HTTP_OK);
|
||||||
|
}
|
||||||
|
|
||||||
$row = $this->Common_model->sql_get_one("select * from tb_account where supplier_id = {$zy_supplier_id} and type_id={$zy_type_id} and user_id = ".$this->user->id);
|
$row = $this->Common_model->sql_get_one("select * from tb_account where supplier_id = {$zy_supplier_id} and type_id={$zy_type_id} and user_id = ".$this->user->id);
|
||||||
if(!$row) {
|
if(!$row) {
|
||||||
$this->response(array(
|
$this->response(array(
|
||||||
|
@ -615,7 +624,6 @@ class Recharge extends REST_Controller
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
public function yezypage_get() {
|
public function yezypage_get() {
|
||||||
|
|
||||||
$spList = $this->Common_model->sql_get_all("select * from tb_supplier");
|
$spList = $this->Common_model->sql_get_all("select * from tb_supplier");
|
||||||
$spInfo = array();
|
$spInfo = array();
|
||||||
foreach($spList as $item) {
|
foreach($spList as $item) {
|
||||||
|
@ -627,6 +635,14 @@ class Recharge extends REST_Controller
|
||||||
|
|
||||||
$zy_list = array();
|
$zy_list = array();
|
||||||
foreach($list as $item) {
|
foreach($list as $item) {
|
||||||
|
if($this->user->company_id == 15){
|
||||||
|
if ($item['supplier_id'] == 28){
|
||||||
|
$acList[$item['supplier_id']."_".$item['type_id']]['supplier_name'] = $spInfo[$item['supplier_id']];
|
||||||
|
$acList[$item['supplier_id']."_".$item['type_id']]['amount'] += $item['account'];
|
||||||
|
$total += $item['account'];
|
||||||
|
}
|
||||||
|
continue;
|
||||||
|
}
|
||||||
$acList[$item['supplier_id']."_".$item['type_id']]['supplier_name'] = $spInfo[$item['supplier_id']];
|
$acList[$item['supplier_id']."_".$item['type_id']]['supplier_name'] = $spInfo[$item['supplier_id']];
|
||||||
$acList[$item['supplier_id']."_".$item['type_id']]['amount'] += $item['account'];
|
$acList[$item['supplier_id']."_".$item['type_id']]['amount'] += $item['account'];
|
||||||
$total += $item['account'];
|
$total += $item['account'];
|
||||||
|
|
Loading…
Reference in New Issue