开设计费项目时才需要检查余额。
This commit is contained in:
parent
a77e37bb31
commit
9b0465fbeb
@ -42,7 +42,7 @@ public function store(Request $request)
|
|||||||
$user = User::findOrFail($request->user_id);
|
$user = User::findOrFail($request->user_id);
|
||||||
|
|
||||||
if ($user->balance <= 1) {
|
if ($user->balance <= 1) {
|
||||||
throw new BalanceNotEnoughException("余额不足,无法开设新的计费项目。");
|
return $this->error('此用户余额不足,无法开设计费项目。');
|
||||||
}
|
}
|
||||||
|
|
||||||
// 如果没有 name,则随机
|
// 如果没有 name,则随机
|
||||||
|
Loading…
Reference in New Issue
Block a user