|
@@ -961,7 +961,7 @@ class Money extends Common
|
|
// 查询余额
|
|
// 查询余额
|
|
$userModel = new \app\common\model\User();
|
|
$userModel = new \app\common\model\User();
|
|
$userInfo = $userModel->lock('lock in share mode')->find($userId);
|
|
$userInfo = $userModel->lock('lock in share mode')->find($userId);
|
|
- if ($scoin > $userInfo["money"]) {
|
|
|
|
|
|
+ if ($exchangeMoney > $userInfo["money"]) {
|
|
throw new Exception("余额不足!");
|
|
throw new Exception("余额不足!");
|
|
}
|
|
}
|
|
|
|
|