|
@@ -128,10 +128,8 @@ class bonus_helper
|
|
|
{
|
|
|
$mod_bonus = Model('user_bonus');
|
|
|
|
|
|
- Db::beginTransaction();
|
|
|
$bind_bonus = $mod_bonus->getBinded($mobile);
|
|
|
if(empty($bind_bonus)) {
|
|
|
- Db::commit();
|
|
|
return false;
|
|
|
}
|
|
|
|
|
@@ -149,9 +147,7 @@ class bonus_helper
|
|
|
{
|
|
|
Db::beginTransaction();
|
|
|
$pd_helper->add_bonus($bonus,$type);
|
|
|
- if($manager->topup($mod_bonus,$val) === false) {
|
|
|
- throw new Exception();
|
|
|
- } else {
|
|
|
+ if($manager->topup($mod_bonus,$val) == true) {
|
|
|
array_push($bonusex,$val);
|
|
|
ranklist_helper::add_money($_SESSION['member_id'],$bonus->bonus_value());
|
|
|
}
|
|
@@ -160,7 +156,6 @@ class bonus_helper
|
|
|
Db::rollback();
|
|
|
}
|
|
|
}
|
|
|
- Db::commit();
|
|
|
|
|
|
if(empty($bonusex)) {
|
|
|
return false;
|