Compare commits

..

No commits in common. "app" and "main" have entirely different histories.
app ... main

3149 changed files with 357188 additions and 18663 deletions

41
.env.example Normal file
View File

@ -0,0 +1,41 @@
APP_ENV=production
APP_DEBUG=true
APP_KEY=base64:ygngELJvE4TbfP8g/mBUl6+QzmWIvFW8Y2cgnADYIUY=
APP_URL=http://vanguard.test
LOG_CHANNEL=stack
DB_CONNECTION=mysql
DB_HOST="localhost"
DB_DATABASE="casadocdb"
DB_USERNAME="xxx"
DB_PASSWORD="xxx"
DB_PREFIX="auth_"
BROADCAST_DRIVER=log
CACHE_DRIVER=file
QUEUE_DRIVER=sync
SESSION_DRIVER=database
SESSION_LIFETIME=120
REDIS_HOST=127.0.0.1
REDIS_PASSWORD=null
REDIS_PORT=6379
MAIL_MAILER=mail
MAIL_FROM_NAME=Vanguard
MAIL_FROM_ADDRESS=vanguard@test.dev
MAIL_HOST=smtp.mailtrap.io
MAIL_PORT=2525
MAIL_USERNAME=null
MAIL_PASSWORD=null
MAIL_ENCRYPTION=null
PUSHER_APP_ID=
PUSHER_APP_KEY=
PUSHER_APP_SECRET=
PUSHER_APP_CLUSTER=mt1
MIX_PUSHER_APP_KEY="${PUSHER_APP_KEY}"
MIX_PUSHER_APP_CLUSTER="${PUSHER_APP_CLUSTER}"

83
.gitignore vendored
View File

@ -1,59 +1,28 @@
**/.DS_Store
.DS_Store
# Environment Variables (Secrets)
/node_modules
/public/hot
/public/storage
/storage/*.key
/vendor
/.idea
/.fleet
/.vscode
/.vagrant
Homestead.json
Homestead.yaml
npm-debug.log
yarn-error.log
.env
.env.*
!.env.example
server/.env
mobile/.env
# Server (PHP/Laravel)
server/auth.json
_ide_helper.php
_ide_helper_models.php
.phpstorm.meta.php
server/.fleet
server/.idea
server/.php_cs.cache
server/.phpunit.cache
server/.phpunit.result.cache
server/.vagrant
server/.vscode
server/Homestead.json
server/Homestead.yaml
server/bootstrap/cache
server/documentation
server/node_modules
server/npm-debug.log
server/public/build
server/public/hot
server/public/storage
server/public/userportal
server/storage/*.key
server/storage/app/private
server/storage/debugbar
server/storage/debugbar/*
server/storage/framework/cache/data
server/storage/framework/sessions
server/storage/framework/testing
server/storage/framework/views
server/storage/logs
server/vendor
# Mobile (React Native/Expo)
mobile/.expo
mobile/android
mobile/ios
mobile/node_modules
mobile/dist
mobile/web-build
mobile/npm-debug.log
# Docker
docker-compose.override.yml
# VS Code
.vscode/
# Ignore user-uploaded content
server/public/upload
.phpunit.result.cache
.php_cs.cache
/documentation
/.phpunit.cache
/public/build
.env.backup
.env.production
auth.json
public/Connections/casadocconn.php
public/userportal/tools/mailer.php
public/userportal/persondocuments/
public/userportal/mainphoto/
public/userportal/homedocuments/

28365
_ide_helper.php Normal file

File diff suppressed because it is too large Load Diff

View File

@ -19,7 +19,6 @@ class SocialLoginController extends ApiController
public function index(ApiAuthenticateRequest $request)
{
\Log::info('Social Login Hit: ' . $request->network);
try {
$socialUser = Socialite::driver($request->network)->userFromToken($request->social_token);
} catch (Exception $e) {

View File

@ -49,21 +49,4 @@ class DetailsController extends ApiController
return new UserResource($user);
}
/**
* Delete user's account.
* @return \Illuminate\Http\JsonResponse
*/
public function destroy()
{
$user = auth()->user();
try {
event(new \Vanguard\Events\User\Deleted($user));
$user->delete();
return $this->respondWithSuccess();
} catch (\Exception $e) {
return $this->errorInternal($e->getMessage());
}
}
}

View File

@ -127,16 +127,14 @@ class UsersController extends ApiController
*/
public function destroy(User $user)
{
try {
event(new Deleted($user));
$user->delete();
return $this->respondWithSuccess();
} catch (\Illuminate\Database\QueryException $e) {
return $this->errorInternal($e->getMessage());
} catch (\Exception $e) {
return $this->errorInternal($e->getMessage());
if ($user->id == auth()->id()) {
return $this->errorForbidden(__("You cannot delete yourself."));
}
event(new Deleted($user));
$this->users->delete($user->id);
return $this->respondWithSuccess();
}
}

View File

@ -106,7 +106,7 @@ class LoginController extends Controller
return redirect()->to($request->get('to'));
}
return redirect()->intended();
return redirect()->to("userportal/index.php");
}
/**

Some files were not shown because too many files have changed in this diff Show More