mirror of
https://github.com/v2board/v2board.git
synced 2025-06-12 12:37:54 +08:00
update
This commit is contained in:
@ -12,11 +12,6 @@ use App\Models\InviteCode;
|
||||
|
||||
class RegisterController extends Controller
|
||||
{
|
||||
private function setTryOut()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public function index(RegisterIndex $request)
|
||||
{
|
||||
if ((int)config('v2board.stop_register', 0)) {
|
||||
@ -85,4 +80,17 @@ class RegisterController extends Controller
|
||||
'data' => true
|
||||
]);
|
||||
}
|
||||
|
||||
public function pv(Request $request)
|
||||
{
|
||||
$inviteCode = InviteCode::where('code', $request->input('invite_code'))->first();
|
||||
if ($inviteCode) {
|
||||
$inviteCode->pv = $inviteCode->pv + 1;
|
||||
$inviteCode->save();
|
||||
}
|
||||
|
||||
return response([
|
||||
'data' => true
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user