Browse Source

Merge pull request 'handle super admin' (#63) from dev-wahyun into staging

Reviewed-on: ibnu/generic-ospro-backend#63
pull/1/head
farhantock 8 months ago
parent
commit
a9649bd2a3
  1. 4
      app/Http/Controllers/AuthController.php

4
app/Http/Controllers/AuthController.php

@ -45,8 +45,8 @@ class AuthController extends Controller
if ($usernameCheck & $passwordCheck) { if ($usernameCheck & $passwordCheck) {
$user = User::where([['username', $username],['password', md5($password)]])->first(); $user = User::where([['username', $username],['password', md5($password)]])->first();
$checkExpiredOspro = $this->setExpiredTimeOspro($user['company_id']); $checkExpiredOspro = $this->setExpiredTimeOspro($user['company_id']);
if($checkExpiredOspro === false) { if($checkExpiredOspro === false && $user['company_id'] != null) {
return response()->json(['status' => 'error', 'message' => 'Expired! Please update license!'], 201); return response()->json(['status' => 'error', 'message' => 'Expired! Please update license!','$checkExpiredOspro'=>$checkExpiredOspro], 201);
} }
if ($is_mobile) { if ($is_mobile) {
$fcm_token = $request->fcm_token; $fcm_token = $request->fcm_token;

Loading…
Cancel
Save