├── .env.example
├── .gitattributes
├── .gitignore
├── .scrutinizer.yml
├── .styleci.yml
├── LICENSE
├── app
├── Console
│ └── Kernel.php
├── Events
│ ├── MessageSent.php
│ └── NotificationRead.php
├── Exceptions
│ └── Handler.php
├── Helpers
│ ├── Funcoes.php
│ ├── LogView.php
│ └── ServerInfo.php
├── Http
│ ├── Controllers
│ │ ├── Auth
│ │ │ ├── ForgotPasswordController.php
│ │ │ ├── LoginController.php
│ │ │ ├── RegisterController.php
│ │ │ └── ResetPasswordController.php
│ │ ├── Backend
│ │ │ ├── AlertsController.php
│ │ │ ├── BackendController.php
│ │ │ ├── Chat
│ │ │ │ └── ChatsController.php
│ │ │ ├── DashboardController.php
│ │ │ ├── Empresas
│ │ │ │ └── EmpresaController.php
│ │ │ ├── Notifications
│ │ │ │ ├── NotificationController.php
│ │ │ │ └── PushSubscriptionController.php
│ │ │ ├── PermissionsController.php
│ │ │ ├── Profile
│ │ │ │ └── ProfileController.php
│ │ │ ├── RolesController.php
│ │ │ ├── Ticket
│ │ │ │ └── TicketController.php
│ │ │ └── UsersController.php
│ │ ├── Controller.php
│ │ └── Frontend
│ │ │ └── FrontendController.php
│ ├── Kernel.php
│ ├── Middleware
│ │ ├── Authenticate.php
│ │ ├── CheckHashSass.php
│ │ ├── EncryptCookies.php
│ │ ├── ForceHttps.php
│ │ ├── RedirectIfAuthenticated.php
│ │ ├── TrimStrings.php
│ │ ├── TrustProxies.php
│ │ └── VerifyCsrfToken.php
│ ├── Requests
│ │ ├── AdminEmpresaPostRequest.php
│ │ ├── AdminNotificationPostRequest.php
│ │ ├── AdminTicketPostRequest.php
│ │ ├── AdminUserPostRequest.php
│ │ ├── Request.php
│ │ └── ValidateSecretRequest.php
│ └── ViewComposers
│ │ └── BackendComposer.php
├── Listeners
│ └── UpdateLastLoginOnLogin.php
├── Mail
│ ├── EmpresaNova.php
│ ├── TicketFechado.php
│ ├── TicketNovo.php
│ └── TicketRespondido.php
├── Models
│ ├── Activity.php
│ ├── Alert.php
│ ├── Companie.php
│ ├── Message.php
│ ├── Permission.php
│ ├── Profile.php
│ ├── Role.php
│ ├── Social.php
│ ├── Ticket.php
│ └── TicketComment.php
├── Notifications
│ ├── CompanieNewNotification.php
│ ├── DashboardNotification.php
│ ├── ResetPasswordNotification.php
│ └── UserConfirmationNotification.php
├── Providers
│ ├── AppServiceProvider.php
│ ├── AuthServiceProvider.php
│ ├── BroadcastServiceProvider.php
│ ├── CarbonLanguageProvider.php
│ ├── ComposerServiceProvider.php
│ ├── EventServiceProvider.php
│ ├── RouteServiceProvider.php
│ └── SqlLoggingServiceProvider.php
├── Traits
│ ├── Auditando.php
│ ├── Empresa.php
│ ├── HasRoles.php
│ ├── Rememberable.php
│ ├── SaveToUpper.php
│ └── Slugado.php
└── User.php
├── artisan
├── bootstrap
├── app.php
└── cache
│ └── .gitignore
├── composer.json
├── composer.lock
├── config
├── app.php
├── auth.php
├── broadcasting.php
├── cache.php
├── database.php
├── filesystems.php
├── hashids.php
├── laravolt
│ └── avatar.php
├── mail.php
├── queue.php
├── scout.php
├── services.php
├── session.php
├── starter.php
├── view.php
└── webpush.php
├── database
├── .gitignore
├── factories
│ └── ModelFactory.php
├── migrations
│ ├── .gitkeep
│ ├── 2014_10_10_000000_create_companies_table.php
│ ├── 2014_10_12_000000_create_users_table.php
│ ├── 2014_10_12_100000_create_password_resets_table.php
│ ├── 2016_05_15_023906_create_roles_tables.php
│ ├── 2016_06_08_234345_create_profile_table.php
│ ├── 2016_06_09_002329_create_notification_table.php
│ ├── 2016_06_09_005404_create_activity_table.php
│ ├── 2016_06_09_010158_create_tickets_table.php
│ ├── 2016_12_13_091913_create_jobs_table.php
│ ├── 2016_12_13_091920_create_failed_jobs_table.php
│ ├── 2017_03_24_114526_create_alert_table.php
│ ├── 2017_05_05_155240_create_push_subscriptions_table.php
│ ├── 2017_05_10_153017_create_table_social_logins.php
│ ├── 2017_05_17_162156_add_google2fa_secret_to_users.php
│ └── 2017_05_30_155259_create_messages_table.php
└── seeds
│ ├── .gitkeep
│ ├── DatabaseSeeder.php
│ └── StarterSeeder.php
├── package-lock.json
├── package.json
├── phpunit.dusk.xml
├── phpunit.xml
├── public
├── blank.html
├── favicon.ico
├── favicon.png
├── index.php
├── launcher-icon-1x.png
├── launcher-icon-2x.png
├── launcher-icon-3x.png
├── launcher-icon-4x.png
├── launcher-icon-5x.png
├── logo.png
├── mix-manifest.json
├── notification-icon.png
├── robots.txt
├── static
│ ├── css
│ │ └── app.css
│ ├── img
│ │ ├── bg
│ │ │ ├── 000.png
│ │ │ ├── 001.png
│ │ │ ├── 002.png
│ │ │ ├── 003.png
│ │ │ ├── 004.png
│ │ │ ├── 005.png
│ │ │ ├── 006.png
│ │ │ ├── 007.png
│ │ │ ├── login-bg-1.jpg
│ │ │ ├── login-bg-2.jpg
│ │ │ ├── login-bg-3.jpg
│ │ │ ├── login-bg-4.jpg
│ │ │ ├── login-bg-5.jpg
│ │ │ ├── login-bg-6.jpg
│ │ │ ├── login-bg-7.jpg
│ │ │ └── login-bg-8.jpg
│ │ └── icos
│ │ │ ├── chrome-logo.png
│ │ │ ├── firefox-logo.png
│ │ │ ├── internet-logo.png
│ │ │ ├── opera-logo.png
│ │ │ └── safari-logo.png
│ └── js
│ │ ├── app.js
│ │ └── dashboard.js
└── sw.js
├── resources
├── assets
│ ├── js
│ │ ├── app.js
│ │ ├── components
│ │ │ ├── ChatForm.vue
│ │ │ ├── ChatMessages.vue
│ │ │ ├── Notification.vue
│ │ │ ├── NotificationsDemo.vue
│ │ │ └── NotificationsDropdown.vue
│ │ └── dashboard.js
│ └── sass
│ │ ├── app.scss
│ │ ├── helpers
│ │ └── _mixins.scss
│ │ └── modulos
│ │ ├── _animation.scss
│ │ ├── _app.scss
│ │ ├── _box.scss
│ │ ├── _chat.scss
│ │ ├── _cores.scss
│ │ ├── _default.scss
│ │ ├── _footer.scss
│ │ ├── _modal.scss
│ │ ├── _notification.scss
│ │ ├── _panel.scss
│ │ ├── _profile.scss
│ │ ├── _searchbar.scss
│ │ ├── _session.scss
│ │ ├── _sidebar.scss
│ │ ├── _socialbuttons.scss
│ │ └── _width991.scss
├── lang
│ ├── en
│ │ ├── auth.php
│ │ ├── pagination.php
│ │ ├── passwords.php
│ │ └── validation.php
│ └── pt_BR
│ │ ├── auth.php
│ │ ├── pagination.php
│ │ ├── passwords.php
│ │ └── validation.php
├── laravolt
│ └── avatar
│ │ └── fonts
│ │ ├── OpenSans-Bold.ttf
│ │ └── rockwell.ttf
└── views
│ ├── auth
│ ├── 2fa.blade.php
│ ├── login.blade.php
│ └── passwords
│ │ ├── email.blade.php
│ │ └── reset.blade.php
│ ├── backend
│ ├── alertas
│ │ ├── create.blade.php
│ │ ├── edit.blade.php
│ │ └── index.blade.php
│ ├── empresas
│ │ ├── create.blade.php
│ │ ├── edit.blade.php
│ │ └── index.blade.php
│ ├── index.blade.php
│ ├── internas
│ │ ├── atividades.blade.php
│ │ ├── lockscreen.blade.php
│ │ ├── logs.blade.php
│ │ ├── notificacoes.blade.php
│ │ └── server.blade.php
│ ├── no.blade.php
│ ├── partials
│ │ ├── aside.blade.php
│ │ ├── chat.blade.php
│ │ ├── errors.blade.php
│ │ ├── helper.blade.php
│ │ ├── logged-in-as.blade.php
│ │ └── searchBar.blade.php
│ ├── permissions
│ │ ├── create.blade.php
│ │ ├── edit.blade.php
│ │ └── index.blade.php
│ ├── profile
│ │ ├── 2fa.blade.php
│ │ ├── atividades.blade.php
│ │ ├── delete.blade.php
│ │ ├── index.blade.php
│ │ ├── logo.blade.php
│ │ ├── nav.blade.php
│ │ ├── notificacoes.blade.php
│ │ └── password.blade.php
│ ├── roles
│ │ ├── create.blade.php
│ │ ├── edit.blade.php
│ │ └── index.blade.php
│ ├── tickets
│ │ ├── create.blade.php
│ │ ├── edit.blade.php
│ │ ├── index.blade.php
│ │ └── show.blade.php
│ └── usuarios
│ │ ├── create.blade.php
│ │ ├── edit.blade.php
│ │ └── index.blade.php
│ ├── emails
│ ├── companie
│ │ └── new.blade.php
│ └── tickets
│ │ ├── closed.blade.php
│ │ ├── new.blade.php
│ │ └── reply.blade.php
│ ├── errors
│ ├── 403.blade.php
│ ├── 404.blade.php
│ ├── 429.blade.php
│ ├── 500.blade.php
│ └── 503.blade.php
│ ├── layouts
│ ├── backend.blade.php
│ └── email.blade.php
│ ├── vendor
│ ├── mail
│ │ ├── html
│ │ │ ├── button.blade.php
│ │ │ ├── footer.blade.php
│ │ │ ├── header.blade.php
│ │ │ ├── layout.blade.php
│ │ │ ├── message.blade.php
│ │ │ ├── panel.blade.php
│ │ │ ├── promotion.blade.php
│ │ │ ├── promotion
│ │ │ │ └── button.blade.php
│ │ │ ├── subcopy.blade.php
│ │ │ ├── table.blade.php
│ │ │ └── themes
│ │ │ │ └── default.css
│ │ └── markdown
│ │ │ ├── button.blade.php
│ │ │ ├── footer.blade.php
│ │ │ ├── header.blade.php
│ │ │ ├── layout.blade.php
│ │ │ ├── message.blade.php
│ │ │ ├── panel.blade.php
│ │ │ ├── promotion.blade.php
│ │ │ ├── promotion
│ │ │ └── button.blade.php
│ │ │ ├── subcopy.blade.php
│ │ │ └── table.blade.php
│ ├── notifications
│ │ └── email.blade.php
│ └── pagination
│ │ ├── bootstrap-4.blade.php
│ │ ├── default.blade.php
│ │ ├── simple-bootstrap-4.blade.php
│ │ └── simple-default.blade.php
│ └── welcome.blade.php
├── routes
├── admin.php
├── api.php
├── channels.php
├── console.php
└── web.php
├── server.php
├── storage
├── app
│ ├── .gitignore
│ └── public
│ │ └── .gitignore
├── debugbar
│ └── .gitignore
├── framework
│ ├── .gitignore
│ ├── cache
│ │ └── .gitignore
│ ├── sessions
│ │ └── .gitignore
│ └── views
│ │ └── .gitignore
└── logs
│ └── .gitignore
├── tests
├── Browser
│ ├── LoginTest.php
│ ├── Pages
│ │ ├── HomePage.php
│ │ └── Page.php
│ ├── console
│ │ └── .gitignore
│ └── screenshots
│ │ └── .gitignore
├── CreatesApplication.php
├── DuskTestCase.php
├── Feature
│ └── ExampleTest.php
├── TestCase.php
└── Unit
│ └── ExampleTest.php
└── webpack.mix.js
/.env.example:
--------------------------------------------------------------------------------
1 | APP_ADMIN_ONLY=true
2 | APP_SSL=true
3 | APP_MULTISAS=true
4 | APP_VERSION=0.0.1
5 | APP_ENV=local
6 | APP_KEY=
7 | APP_DEBUG=true
8 | APP_LOG_LEVEL=debug
9 | APP_URL=http://starterkit.app
10 |
11 | DB_CONNECTION=mysql
12 | DB_HOST=127.0.0.1
13 | DB_PORT=3306
14 | DB_DATABASE=starter
15 | DB_USERNAME=homestead
16 | DB_PASSWORD=secret
17 |
18 | BROADCAST_DRIVER=log
19 | CACHE_DRIVER=file
20 | CACHE_TIME=15
21 | SESSION_DRIVER=file
22 | SESSION_DOMAIN=starterkit.app
23 | QUEUE_DRIVER=sync
24 |
25 | REDIS_HOST=127.0.0.1
26 | REDIS_PASSWORD=null
27 | REDIS_PORT=6379
28 |
29 | MAIL_DRIVER=smtp
30 | MAIL_HOST=mailtrap.io
31 | MAIL_PORT=2525
32 | MAIL_USERNAME=
33 | MAIL_PASSWORD=
34 | MAIL_ENCRYPTION=null
35 | MAIL_REPLY="no-reply@starterkit.app"
36 |
37 | PUSHER_KEY=
38 | PUSHER_SECRET=
39 | PUSHER_APP_ID=
40 | PUSHER_CLUSTER=
41 |
42 | APP_TITLE="Meu Aplicativo"
43 | APP_MAIL_DEV="leandroross@gmail.com"
44 |
45 | TWITTER_ID=
46 | TWITTER_SECRET=
47 | TWITTER_URL=http://starterkit.app/auth/twitter/callback
48 |
49 | FACEBOOK_ID=
50 | FACEBOOK_SECRET=
51 | FACEBOOK_URL=http://starterkit.app/auth/facebook/callback
52 |
53 | GITHUB_ID=
54 | GITHUB_SECRET=
55 | GITHUB_URL=http://starterkit.app/auth/github/callback
56 |
57 | GOOGLE_ID=
58 | GOOGLE_SECRET=
59 | GOOGLE_URL=http://starterkit.app/auth/google/callback
60 |
61 | GCM_KEY=
62 | GCM_SENDER_ID=
63 |
64 | VAPID_PUBLIC_KEY=
65 | VAPID_PRIVATE_KEY=
66 |
67 | SES_KEY=
68 | SES_SECRET=
69 |
--------------------------------------------------------------------------------
/.gitattributes:
--------------------------------------------------------------------------------
1 | * text=auto
2 | *.css linguist-vendored
3 | *.scss linguist-vendored
4 | *.js linguist-vendored
5 | CHANGELOG.md export-ignore
6 | README.md export-ignore
7 | .travis.yml export-ignore
8 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | /node_modules
2 | /public/storage
3 | /storage/*.key
4 | /vendor
5 | /.idea
6 | Homestead.json
7 | Homestead.yaml
8 | npm-debug.log
9 | yarn-error.log
10 | .env
--------------------------------------------------------------------------------
/.scrutinizer.yml:
--------------------------------------------------------------------------------
1 | filter:
2 | excluded_paths: ["tests/*", "public/*"]
3 |
4 | checks:
5 | php:
6 | code_rating: true
7 | remove_extra_empty_lines: true
8 | remove_php_closing_tag: true
9 | remove_trailing_whitespace: true
10 | fix_use_statements:
11 | remove_unused: true
12 | preserve_multiple: false
13 | preserve_blanklines: true
14 | order_alphabetically: false
15 | fix_php_opening_tag: true
16 | fix_linefeed: true
17 | fix_line_ending: true
18 | fix_identation_4spaces: true
19 | fix_doc_comments: true
20 |
21 | tools:
22 | php_cpd: true
23 | php_analyzer: true
24 | external_code_coverage: true
--------------------------------------------------------------------------------
/.styleci.yml:
--------------------------------------------------------------------------------
1 | preset: laravel
2 |
3 | linting: true
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Copyright (c) 2018 Leandro Henrique Ross
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
22 |
--------------------------------------------------------------------------------
/app/Console/Kernel.php:
--------------------------------------------------------------------------------
1 | environment('production')) {
31 | $schedule->command('backup:clean')->weekly()->at('01:00');
32 | $schedule->command('backup:run')->daily()->at('02:00');
33 | }
34 | }
35 |
36 | /**
37 | * Register the commands for the application.
38 | *
39 | * @return void
40 | */
41 | protected function commands()
42 | {
43 | $this->load(__DIR__.'/Commands');
44 |
45 | require base_path('routes/console.php');
46 | }
47 | }
48 |
--------------------------------------------------------------------------------
/app/Events/MessageSent.php:
--------------------------------------------------------------------------------
1 | user = $user;
38 | $this->message = $message;
39 | }
40 |
41 | /**
42 | * Get the channels the event should broadcast on.
43 | *
44 | * @return Channel|array
45 | */
46 | public function broadcastOn()
47 | {
48 | return [new PrivateChannel('chat')];
49 | }
50 | }
51 |
--------------------------------------------------------------------------------
/app/Events/NotificationRead.php:
--------------------------------------------------------------------------------
1 | userId = $userId;
33 | $this->notificationId = $notificationId;
34 |
35 | $this->dontBroadcastToCurrentUser();
36 | }
37 |
38 | /**
39 | * Get the channels the event should be broadcast on.
40 | *
41 | * @return PrivateChannel[]
42 | */
43 | public function broadcastOn()
44 | {
45 | return [new PrivateChannel("App.User.{$this->userId}")];
46 | }
47 | }
48 |
--------------------------------------------------------------------------------
/app/Helpers/Funcoes.php:
--------------------------------------------------------------------------------
1 | format($format) == $date;
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/app/Http/Controllers/Auth/ForgotPasswordController.php:
--------------------------------------------------------------------------------
1 | middleware('guest');
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/app/Http/Controllers/Auth/RegisterController.php:
--------------------------------------------------------------------------------
1 | middleware('guest');
38 | $this->redirectTo = route('admin.dashboard');
39 | }
40 |
41 | /**
42 | * Get a validator for an incoming registration request.
43 | *
44 | * @param array $data
45 | * @return \Illuminate\Contracts\Validation\Validator
46 | */
47 | protected function validator(array $data)
48 | {
49 | return Validator::make($data, [
50 | 'name' => 'required|string|max:255',
51 | 'email' => 'required|string|email|max:255|unique:users',
52 | 'password' => 'required|string|min:6|confirmed',
53 | ]);
54 | }
55 |
56 | /**
57 | * Create a new user instance after a valid registration.
58 | *
59 | * @param array $data
60 | * @return \App\User
61 | */
62 | protected function create(array $data)
63 | {
64 | return User::create([
65 | 'name' => $data['name'],
66 | 'email' => $data['email'],
67 | 'password' => bcrypt($data['password']),
68 | ]);
69 | }
70 | }
71 |
--------------------------------------------------------------------------------
/app/Http/Controllers/Auth/ResetPasswordController.php:
--------------------------------------------------------------------------------
1 | middleware('guest');
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/app/Http/Controllers/Backend/BackendController.php:
--------------------------------------------------------------------------------
1 | orderBy('id', 'DESC')->paginate(50);
17 |
18 | return view('backend.internas.atividades', compact('Atividades'));
19 | }
20 |
21 | public function getNotificacoes()
22 | {
23 | $Notificacoes = Notification::with('User')->orderBy('id', 'DESC')->paginate(50);
24 |
25 | return view('backend.internas.notificacoes', compact('Notificacoes'));
26 | }
27 |
28 | public function getLogs()
29 | {
30 | $Logs = LogView::all();
31 |
32 | return view('backend.internas.logs', compact('Logs'));
33 | }
34 |
35 | public function getServer()
36 | {
37 | $ServerInfo = ServerInfo::getOSInformation();
38 | $Ping = Cache::remember('system.ping', 15, function () {
39 | return [
40 | 'facebook.com' => ServerInfo::ping('www.facebook.com'),
41 | 'google.com' => ServerInfo::ping('www.google.com'),
42 | 'uol.com.br' => ServerInfo::ping('www.uol.com.br'),
43 | ];
44 | });
45 |
46 | return view('backend.internas.server', compact('ServerInfo', 'Ping'));
47 | }
48 | }
49 |
--------------------------------------------------------------------------------
/app/Http/Controllers/Backend/Chat/ChatsController.php:
--------------------------------------------------------------------------------
1 | get();
20 | }
21 |
22 | /**
23 | * Persist message to database.
24 | *
25 | * @param Request $request
26 | * @return Response
27 | */
28 | public function sendMessage(Request $request)
29 | {
30 | $message = $request->user()->messages()->create([
31 | 'message' => $request->input('message'),
32 | ]);
33 |
34 | broadcast(new MessageSent($request->user(), $message))->toOthers();
35 |
36 | return ['status' => 'Message Sent!'];
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/app/Http/Controllers/Backend/DashboardController.php:
--------------------------------------------------------------------------------
1 | validate($request, ['endpoint' => 'required']);
23 |
24 | $request->user()->updatePushSubscription(
25 | $request->endpoint,
26 | $request->key,
27 | $request->token
28 | );
29 | }
30 |
31 | /**
32 | * Delete the specified subscription.
33 | *
34 | * @param \Illuminate\Http\Request $request
35 | *
36 | * @return \Illuminate\Http\Response
37 | */
38 | public function destroy(Request $request)
39 | {
40 | $this->validate($request, ['endpoint' => 'required']);
41 |
42 | $request->user()->deletePushSubscription($request->endpoint);
43 |
44 | return response()->json(null, 204);
45 | }
46 | }
47 |
--------------------------------------------------------------------------------
/app/Http/Controllers/Controller.php:
--------------------------------------------------------------------------------
1 | [
32 | \App\Http\Middleware\EncryptCookies::class,
33 | \Illuminate\Cookie\Middleware\AddQueuedCookiesToResponse::class,
34 | \Illuminate\Session\Middleware\StartSession::class,
35 | \Illuminate\View\Middleware\ShareErrorsFromSession::class,
36 | \App\Http\Middleware\VerifyCsrfToken::class,
37 | \Illuminate\Routing\Middleware\SubstituteBindings::class,
38 | \App\Http\Middleware\CheckHashSass::class,
39 | ],
40 |
41 | 'api' => [
42 | 'throttle:60,1',
43 | 'bindings',
44 | ],
45 | ];
46 |
47 | /**
48 | * The application's route middleware.
49 | *
50 | * These middleware may be assigned to groups or used individually.
51 | *
52 | * @var array
53 | */
54 | protected $routeMiddleware = [
55 | 'auth' => \App\Http\Middleware\Authenticate::class,
56 | 'auth.basic' => \Illuminate\Auth\Middleware\AuthenticateWithBasicAuth::class,
57 | 'bindings' => \Illuminate\Routing\Middleware\SubstituteBindings::class,
58 | 'can' => \Illuminate\Auth\Middleware\Authorize::class,
59 | 'guest' => \App\Http\Middleware\RedirectIfAuthenticated::class,
60 | 'throttle' => \Illuminate\Routing\Middleware\ThrottleRequests::class,
61 | ];
62 | }
63 |
--------------------------------------------------------------------------------
/app/Http/Middleware/CheckHashSass.php:
--------------------------------------------------------------------------------
1 | auth = $auth;
26 | }
27 |
28 | /**
29 | * Handle an incoming request.
30 | *
31 | * @param \Illuminate\Http\Request $request
32 | * @param \Closure $next
33 | *
34 | * @return mixed
35 | */
36 | public function handle($request, Closure $next)
37 | {
38 | foreach ($request->route()->parameters as $key => $string) {
39 | $request->route()->setParameter($key, $this->getHashId($string));
40 | }
41 |
42 | return $next($request);
43 | }
44 |
45 | /**
46 | * [getHashId description].
47 | *
48 | * @param string $value
49 | *
50 | * @return int
51 | */
52 | protected function getHashId($value)
53 | {
54 | if (! config('starter.MULTISAS')) {
55 | return $value;
56 | }
57 |
58 | $id = Hashids::decode($value);
59 |
60 | if (isset($id[0]) && is_numeric($id[0])) {
61 | return $id['0'];
62 | }
63 |
64 | if ($this->auth->user() && $this->auth->user()->is_super) {
65 | return $value;
66 | }
67 |
68 | if (! is_numeric($value)) {
69 | return $value;
70 | }
71 |
72 | return -1;
73 | }
74 | }
75 |
--------------------------------------------------------------------------------
/app/Http/Middleware/EncryptCookies.php:
--------------------------------------------------------------------------------
1 | environment('local') && config('starter.SSL') == true) {
21 | // for Proxies
22 | Request::setTrustedProxies([$request->getClientIp()], Request::HEADER_X_FORWARDED_ALL);
23 |
24 | if (! $request->isSecure()) {
25 | return redirect()->secure($request->getRequestUri());
26 | }
27 | }
28 |
29 | return $next($request);
30 | }
31 | }
32 |
--------------------------------------------------------------------------------
/app/Http/Middleware/RedirectIfAuthenticated.php:
--------------------------------------------------------------------------------
1 | check()) {
21 | return redirect()->route('admin.dashboard');
22 | }
23 |
24 | return $next($request);
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/app/Http/Middleware/TrimStrings.php:
--------------------------------------------------------------------------------
1 | 'FORWARDED',
24 | Request::HEADER_X_FORWARDED_FOR => 'X_FORWARDED_FOR',
25 | Request::HEADER_X_FORWARDED_HOST => 'X_FORWARDED_HOST',
26 | Request::HEADER_X_FORWARDED_PORT => 'X_FORWARDED_PORT',
27 | Request::HEADER_X_FORWARDED_PROTO => 'X_FORWARDED_PROTO',
28 | ];
29 | }
30 |
--------------------------------------------------------------------------------
/app/Http/Middleware/VerifyCsrfToken.php:
--------------------------------------------------------------------------------
1 | 'required',
28 | 'conteudo' => 'required',
29 | ];
30 | }
31 |
32 | /**
33 | * Get the error messages for the defined validation rules.
34 | *
35 | * @return array
36 | */
37 | public function messages()
38 | {
39 | return [
40 | 'titulo.required' => 'O campo título deve ser preenchido.',
41 | 'conteudo.required' => 'O campo conteudo deve ser preenchido.',
42 | ];
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/app/Http/Requests/AdminTicketPostRequest.php:
--------------------------------------------------------------------------------
1 | 'required',
28 | 'descricao' => 'required',
29 | 'tipo' => 'required',
30 | 'prioridade' => 'required',
31 | ];
32 | }
33 |
34 | /**
35 | * Get the error messages for the defined validation rules.
36 | *
37 | * @return array
38 | */
39 | public function messages()
40 | {
41 | return [
42 | 'titulo.required' => 'O campo título deve ser preenchido.',
43 | 'descricao.required' => 'O campo descrição deve ser preenchido.',
44 | 'tipo.required' => 'Você precisa especificar o tipo.',
45 | 'prioridade.required' => 'Você precisa especificar a prioridade.',
46 | ];
47 | }
48 | }
49 |
--------------------------------------------------------------------------------
/app/Http/Requests/AdminUserPostRequest.php:
--------------------------------------------------------------------------------
1 | method()) {
27 | case 'POST':
28 | return [
29 | 'name' => 'required|string|max:255',
30 | 'email' => 'required|email|unique:users,email',
31 | 'password' => 'required|confirmed|min:6',
32 | ];
33 | case 'PATCH':
34 | return [
35 | 'name' => 'required|string|max:255',
36 | ];
37 | case 'PUT':
38 | return [
39 | ];
40 | default:
41 | }
42 | }
43 |
44 | /**
45 | * Get the error messages for the defined validation rules.
46 | *
47 | * @return array
48 | */
49 | public function messages()
50 | {
51 | return [
52 | 'name.required' => 'O campo nome deve ser preenchido.',
53 | 'email.required' => 'O campo email deve ser preenchido.',
54 | 'email.email' => 'Email parece não ser válido.',
55 | 'email.unique' => 'Já existe um usuário com esse email.',
56 | 'password.required' => 'O campo senha deve ser preenchido.',
57 | 'password.confirmed' => 'Senhas não conferem.',
58 | ];
59 | }
60 | }
61 |
--------------------------------------------------------------------------------
/app/Http/Requests/Request.php:
--------------------------------------------------------------------------------
1 | user()->is_super) {
18 | $this->listaEmpresas = Companie::get();
19 | } else {
20 | $this->listaEmpresas = auth()->user()->Empresas;
21 | }
22 |
23 | $this->alertas = Alert::where('start_at', '<=', Carbon::now()->format('Y-m-d'))->where('end_at', '>=', Carbon::now()->format('Y-m-d'))->first();
24 | }
25 |
26 | public function compose(View $view)
27 | {
28 | return $view->with('alertas', $this->alertas)->with('listaEmpresas', $this->listaEmpresas);
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/app/Listeners/UpdateLastLoginOnLogin.php:
--------------------------------------------------------------------------------
1 | user();
29 | $user->last_login = Carbon::now();
30 | $user->last_login_ip = Request::ip();
31 | $user->save();
32 | */
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/app/Mail/EmpresaNova.php:
--------------------------------------------------------------------------------
1 | user = $user;
35 | $this->companie = $companie;
36 | }
37 |
38 | /**
39 | * Build the message.
40 | *
41 | * @return $this
42 | */
43 | public function build()
44 | {
45 | return $this->from(config('starter.MAIL_REPLY'), config('app.name'))
46 | ->subject('['.config('app.name').'] Nova Empresa ('.$this->companie->empresa.').')
47 | ->view('emails.companie.new')
48 | ->with([
49 | 'companie' => $this->companie,
50 | 'user' => $this->user,
51 | 'email' => config('starter.MAIL_DEV'),
52 | ]);
53 | }
54 | }
55 |
--------------------------------------------------------------------------------
/app/Mail/TicketFechado.php:
--------------------------------------------------------------------------------
1 | user = $user;
38 | $this->ticket = $ticket;
39 | }
40 |
41 | /**
42 | * Build the message.
43 | *
44 | * @return $this
45 | */
46 | public function build()
47 | {
48 | return $this->from(config('starter.MAIL_REPLY'), config('app.name'))
49 | ->subject('['.config('app.name').'] Ticket Fechado ('.$this->ticket->titulo.').')
50 | ->view('emails.tickets.closed')
51 | ->with([
52 | 'ticket' => $this->ticket,
53 | 'comentarios' => $this->ticket->Comment,
54 | 'user' => $this->user,
55 | 'email' => config('starter.MAIL_DEV'),
56 | ]);
57 | }
58 | }
59 |
--------------------------------------------------------------------------------
/app/Mail/TicketNovo.php:
--------------------------------------------------------------------------------
1 | user = $user;
35 | $this->ticket = $ticket;
36 | }
37 |
38 | /**
39 | * Build the message.
40 | *
41 | * @return $this
42 | */
43 | public function build()
44 | {
45 | return $this->from(config('starter.MAIL_REPLY'), config('app.name'))
46 | ->subject('['.config('app.name').'] Ticket ('.$this->ticket->titulo.').')
47 | ->view('emails.tickets.new')
48 | ->with([
49 | 'ticket' => $this->ticket,
50 | 'user' => $this->user,
51 | 'email' => config('starter.MAIL_DEV'),
52 | ]);
53 | }
54 | }
55 |
--------------------------------------------------------------------------------
/app/Mail/TicketRespondido.php:
--------------------------------------------------------------------------------
1 | user = $user;
43 | $this->ticket = $ticket;
44 | $this->comentario = $comentario;
45 | }
46 |
47 | /**
48 | * Build the message.
49 | *
50 | * @return $this
51 | */
52 | public function build()
53 | {
54 | return $this->from(config('starter.MAIL_REPLY'), config('app.name'))
55 | ->subject('['.config('app.name').'] Ticket ('.$this->ticket->titulo.').')
56 | ->view('emails.tickets.reply')
57 | ->with([
58 | 'ticket' => $this->ticket,
59 | 'comentario' => $this->comentario,
60 | 'user' => $this->user,
61 | 'email' => config('starter.MAIL_DEV'),
62 | ]);
63 | }
64 | }
65 |
--------------------------------------------------------------------------------
/app/Models/Alert.php:
--------------------------------------------------------------------------------
1 | user->email;
40 | }
41 |
42 | /**
43 | * Retorna todos os usuarios vinculados a empresa.
44 | *
45 | * @return \Illuminate\Database\Eloquent\Relations\belongsToMany
46 | */
47 | public function Usuarios()
48 | {
49 | return $this->belongsToMany('App\User', 'companie_user', 'companie_id', 'user_id');
50 | }
51 |
52 | /**
53 | * Retorna todos os usuarios vinculados a empresa.
54 | *
55 | * @return \Illuminate\Database\Eloquent\Relations\hasMany
56 | */
57 | public function UsersMany()
58 | {
59 | return $this->hasMany('App\User', 'company_id', 'id');
60 | }
61 |
62 | /**
63 | * Query the user that belongs to the user.
64 | *
65 | * @return \Illuminate\Database\Eloquent\Relations\BelongsTo
66 | */
67 | public function User()
68 | {
69 | return $this->belongsTo('App\User');
70 | }
71 |
72 | /**
73 | * Returns a LOGO URL for the companie.
74 | *
75 | * @return string
76 | */
77 | public function getLogoAttribute($value)
78 | {
79 | if ($value != 'default.jpg' && $value != null) {
80 | return '/images/'.$value;
81 | }
82 |
83 | return asset('/logo.png');
84 | }
85 | }
86 |
--------------------------------------------------------------------------------
/app/Models/Message.php:
--------------------------------------------------------------------------------
1 | belongsTo('App\User');
35 | }
36 | }
37 |
--------------------------------------------------------------------------------
/app/Models/Permission.php:
--------------------------------------------------------------------------------
1 | 'boolean',
23 | ];
24 |
25 | /**
26 | * A permission can be applied to roles.
27 | *
28 | * @return \Illuminate\Database\Eloquent\Relations\BelongsToMany
29 | */
30 | public function Roles()
31 | {
32 | return $this->belongsToMany(Role::class);
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/app/Models/Profile.php:
--------------------------------------------------------------------------------
1 | belongsTo(User::class);
32 | }
33 |
34 | /**
35 | * Seta atributo.
36 | *
37 | * @param string $value
38 | *
39 | * @return void
40 | */
41 | public function setAniversarioAttribute($value)
42 | {
43 | $this->attributes['aniversario'] = (Funcoes::validateDate($value, 'd/m/Y')) ? Carbon::createFromFormat('d/m/Y', $value)->format('Y-m-d') : null;
44 | }
45 |
46 | /**
47 | * Pega Valor.
48 | *
49 | * @param string $value
50 | *
51 | * @return string
52 | */
53 | public function getAniversarioAttribute($value)
54 | {
55 | return ! is_null($value) ? Carbon::parse($value)->format('d/m/Y') : null;
56 | }
57 | }
58 |
--------------------------------------------------------------------------------
/app/Models/Role.php:
--------------------------------------------------------------------------------
1 | belongsToMany(Permission::class);
27 | }
28 |
29 | /**
30 | * Get the list of users related to the current Role.
31 | *
32 | * @return array permissions
33 | */
34 | public function getPermissionsListAttribute()
35 | {
36 | return array_map('intval', $this->permissions->pluck('id')->toArray());
37 | }
38 |
39 | /**
40 | * A role may be given users.
41 | *
42 | * @return \Illuminate\Database\Eloquent\Relations\BelongsToMany
43 | */
44 | public function Users()
45 | {
46 | return $this->belongsToMany('App\User');
47 | }
48 |
49 | /**
50 | * Get the list of users related to the current Role.
51 | *
52 | * @return array permissions
53 | */
54 | public function getUsersListAttribute()
55 | {
56 | return $this->users->pluck('id');
57 | }
58 | }
59 |
--------------------------------------------------------------------------------
/app/Models/Social.php:
--------------------------------------------------------------------------------
1 | belongsTo('App\User');
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/app/Models/Ticket.php:
--------------------------------------------------------------------------------
1 | user()->is_admin) {
41 | $builder->where('user_id', auth()->user()->id);
42 | }
43 | });
44 | }
45 |
46 | /**
47 | * Query the user that belongs to the profile.
48 | *
49 | * @return \Illuminate\Database\Eloquent\Relations\BelongsTo
50 | */
51 | public function User()
52 | {
53 | return $this->belongsTo('App\User');
54 | }
55 |
56 | /**
57 | * Query the comment that belongs to the ticket.
58 | *
59 | * @return \Illuminate\Database\Eloquent\Relations\hasMany
60 | */
61 | public function Comment()
62 | {
63 | return $this->hasMany(TicketComment::class)->with('user');
64 | }
65 | }
66 |
--------------------------------------------------------------------------------
/app/Models/TicketComment.php:
--------------------------------------------------------------------------------
1 | belongsTo('App\User');
28 | }
29 |
30 | /**
31 | * Query the ticket that belongs to the comment.
32 | *
33 | * @return \Illuminate\Database\Eloquent\Relations\BelongsTo
34 | */
35 | public function Ticket()
36 | {
37 | return $this->belongsTo(Ticket::class);
38 | }
39 |
40 | /**
41 | * The attributes that are mass assignable.
42 | *
43 | * @var array
44 | */
45 | protected $fillable = ['comentario', 'user_id', 'ticket_id'];
46 | }
47 |
--------------------------------------------------------------------------------
/app/Notifications/CompanieNewNotification.php:
--------------------------------------------------------------------------------
1 | companie = $companie;
27 | }
28 |
29 | /**
30 | * Get the notification's delivery channels.
31 | *
32 | * @param mixed $notifiable
33 | *
34 | * @return string[]
35 | */
36 | public function via($notifiable)
37 | {
38 | return ['mail'];
39 | }
40 |
41 | /**
42 | * Get the mail representation of the notification.
43 | *
44 | * @param mixed $notifiable
45 | *
46 | * @return \Illuminate\Notifications\Messages\MailMessage
47 | */
48 | public function toMail($notifiable)
49 | {
50 | return (new MailMessage())
51 | ->subject('Sua empresa '.$this->companie->empresa.' agora faz parte do '.config('app.name'))
52 | ->line('Bem-vindo ao '.config('app.name').'! Esperamos que nossa parceria seja longa e de sucesso.')
53 | ->action('Começar', url('/'))
54 | ->line('Obrigado por usar o nosso aplicativo!');
55 | }
56 | }
57 |
--------------------------------------------------------------------------------
/app/Notifications/ResetPasswordNotification.php:
--------------------------------------------------------------------------------
1 | token = $token;
29 | }
30 |
31 | /**
32 | * Get the notification's delivery channels.
33 | *
34 | * @param mixed $notifiable
35 | *
36 | * @return string[]
37 | */
38 | public function via($notifiable)
39 | {
40 | return ['mail'];
41 | }
42 |
43 | /**
44 | * Build the mail representation of the notification.
45 | *
46 | * @param mixed $notifiable
47 | *
48 | * @return \Illuminate\Notifications\Messages\MailMessage
49 | */
50 | public function toMail($notifiable)
51 | {
52 | return (new MailMessage())
53 | ->subject('Ação necessária para redefinir sua senha')
54 | ->line('Você está recebendo este e-mail porque recebemos um pedido de redefinição de senha para sua conta.')
55 | ->action('Redefinir Senha', url(config('app.url').route('password.reset', $this->token, false)))
56 | ->line('Se você não solicitou uma redefinição de senha, nenhuma ação adicional é necessária.');
57 | }
58 | }
59 |
--------------------------------------------------------------------------------
/app/Notifications/UserConfirmationNotification.php:
--------------------------------------------------------------------------------
1 | token = $token;
29 | }
30 |
31 | /**
32 | * Get the notification's delivery channels.
33 | *
34 | * @param mixed $notifiable
35 | *
36 | * @return string[]
37 | */
38 | public function via($notifiable)
39 | {
40 | return ['mail'];
41 | }
42 |
43 | /**
44 | * Get the mail representation of the notification.
45 | *
46 | * @param mixed $notifiable
47 | *
48 | * @return \Illuminate\Notifications\Messages\MailMessage
49 | */
50 | public function toMail($notifiable)
51 | {
52 | return (new MailMessage())
53 | ->subject('Confirmar registro')
54 | ->line('Por favor, ative sua conta clicando no link abaixo.')
55 | ->action('Ativar Conta', url(config('app.url').route('auth.activation', $this->token, false)))
56 | ->line('Obrigado');
57 | }
58 | }
59 |
--------------------------------------------------------------------------------
/app/Providers/AppServiceProvider.php:
--------------------------------------------------------------------------------
1 | app->environment('local', 'testing', 'staging')) {
38 | $this->app->register(DuskServiceProvider::class);
39 | }
40 |
41 | // Em Produção
42 | if ($this->app->environment('production')) {
43 | $this->app->alias('bugsnag.multi', \Illuminate\Contracts\Logging\Log::class);
44 | $this->app->alias('bugsnag.multi', \Psr\Log\LoggerInterface::class);
45 | }
46 | }
47 | }
48 |
--------------------------------------------------------------------------------
/app/Providers/AuthServiceProvider.php:
--------------------------------------------------------------------------------
1 | 'App\Policies\ModelPolicy',
19 | ];
20 |
21 | /**
22 | * Register any authentication / authorization services.
23 | *
24 | * @return void
25 | */
26 | public function boot()
27 | {
28 | $this->registerPolicies();
29 |
30 | Gate::define('is-admin', function ($user) {
31 | if ($user->is_admin && $user->id == $user->Companie->user_id || $user->is_super) {
32 | return true;
33 | }
34 | });
35 |
36 | Gate::define('is-super', function ($user) {
37 | if ($user->is_super) {
38 | return true;
39 | }
40 | });
41 |
42 | foreach ($this->getPermissions() as $permission) {
43 | Gate::define($permission->name, function ($user) use ($permission) {
44 | if ($permission->visible) {
45 | return true;
46 | }
47 |
48 | if ($user->is_super) {
49 | return true;
50 | }
51 |
52 | if ($user->is_admin) {
53 | return true;
54 | }
55 |
56 | return $user->hasPermission($permission);
57 | });
58 | }
59 | }
60 |
61 | protected function getPermissions()
62 | {
63 | try {
64 | return Cache::rememberForever('Permissions', function () {
65 | return Permission::with('roles')->get();
66 | });
67 | } catch (\Exception $e) {
68 | return [];
69 | }
70 | }
71 | }
72 |
--------------------------------------------------------------------------------
/app/Providers/BroadcastServiceProvider.php:
--------------------------------------------------------------------------------
1 | app->getLocale());
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/app/Providers/ComposerServiceProvider.php:
--------------------------------------------------------------------------------
1 | [
17 | 'App\Listeners\EventListener',
18 | ],
19 | 'Illuminate\Auth\Events\Login' => [
20 | 'App\Listeners\UpdateLastLoginOnLogin@handle',
21 | ],
22 | 'Lakshmaji\Plivo\Events\LogBeforeSend' => [
23 | 'App\Listeners\LogSMS',
24 | ],
25 | ];
26 |
27 | /**
28 | * Register any events for your application.
29 | *
30 | * @return void
31 | */
32 | public function boot()
33 | {
34 | parent::boot();
35 |
36 | //
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/app/Providers/SqlLoggingServiceProvider.php:
--------------------------------------------------------------------------------
1 | bindings as $i => $binding) {
32 | if ($binding instanceof \DateTime) {
33 | $query->bindings[$i] = $binding->format('\'Y-m-d H:i:s\'');
34 | } elseif (is_string($binding)) {
35 | $query->bindings[$i] = "'$binding'";
36 | }
37 | }
38 |
39 | // Insert bindings into query
40 | $query->sql = str_replace(['%', '?'], ['%%', '%s'], $query->sql);
41 | $query->sql = vsprintf($query->sql, $query->bindings);
42 |
43 | $data['request_path'] = url()->full();
44 | $data['request_method'] = Request::method();
45 | $data['request_data'] = Request::all();
46 |
47 | $log = new Logger('sql');
48 | $log->pushHandler(new StreamHandler(storage_path().'/logs/sql-'.date('Y-m-d').'.log', Logger::INFO));
49 | $log->addInfo($query->sql, $data);
50 | });
51 | }
52 | }
53 |
--------------------------------------------------------------------------------
/app/Traits/Auditando.php:
--------------------------------------------------------------------------------
1 | auditCreation();
18 | });
19 |
20 | static::saved(function ($model) {
21 | $model->auditUpdate();
22 | });
23 |
24 | static::deleted(function ($model) {
25 | $model->auditDeletion();
26 | });
27 | }
28 |
29 | /**
30 | * Audit creation.
31 | *
32 | * @return void
33 | */
34 | public function auditCreation()
35 | {
36 | $this->audit($this->attributes, 'created');
37 | }
38 |
39 | /**
40 | * Audit creation.
41 | *
42 | * @return void
43 | */
44 | public function auditUpdate()
45 | {
46 | $this->audit($this->attributes, 'updated');
47 | }
48 |
49 | /**
50 | * Audit creation.
51 | *
52 | * @return void
53 | */
54 | public function auditDeletion()
55 | {
56 | $this->audit($this->attributes, 'deleted');
57 | }
58 |
59 | /**
60 | * Audit model.
61 | *
62 | * @param string $type
63 | *
64 | * @return Log
65 | */
66 | public function audit(array $log, $type)
67 | {
68 | // Log data
69 | $logAuditing = [
70 | 'content_type' => $this->getMorphClass(),
71 | 'content_id' => $this->getKey(),
72 | 'acao' => $type,
73 | 'descricao' => $this->getCurrentRoute(),
74 | 'detalhes' => $log,
75 | ];
76 |
77 | Activity::log($logAuditing);
78 | }
79 |
80 | /**
81 | * Get the current request's route if available.
82 | *
83 | * @return string
84 | */
85 | protected function getCurrentRoute()
86 | {
87 | if (App::runningInConsole()) {
88 | return 'console';
89 | }
90 |
91 | return Request::fullUrl();
92 | }
93 | }
94 |
--------------------------------------------------------------------------------
/app/Traits/Empresa.php:
--------------------------------------------------------------------------------
1 | prepareCompany();
37 | });
38 |
39 | if (Auth::getUser()) {
40 | static::addGlobalScope('company', function (Builder $builder) {
41 | // i need to pass a table name to avoid 'ambiguous error'
42 | // like that: $builder->where($builder->getTable . '.' . self::$coluna, Auth::getUser()->company_id);
43 | $builder->where(self::$coluna, Auth::getUser()->company_id);
44 | });
45 | }
46 | }
47 |
48 | /**
49 | * Prepare Company.
50 | *
51 | * @return string|null
52 | */
53 | public function prepareCompany()
54 | {
55 | if ($this->attributes && isset($this->attributes['company_id'])) {
56 | return 'possui company ID';
57 | }
58 |
59 | if (Auth::getUser()) {
60 | $this[self::$coluna] = Auth::user()->company_id;
61 | }
62 | }
63 |
64 | /**
65 | * Get the value of the model's route key.
66 | *
67 | * @return mixed
68 | */
69 | public function getRouteKey()
70 | {
71 | if (config('starter.MULTISAS')) {
72 | return Hashids::encode($this->getKey());
73 | }
74 |
75 | return $this->getKey();
76 | }
77 | }
78 |
--------------------------------------------------------------------------------
/app/Traits/HasRoles.php:
--------------------------------------------------------------------------------
1 | belongsToMany(Role::class);
15 | }
16 |
17 | /**
18 | * Assign the given role to the user.
19 | *
20 | * @param string $role
21 | *
22 | * @return \Illuminate\Database\Eloquent\Model
23 | */
24 | public function assignRole($role)
25 | {
26 | return $this->roles()->save(Role::whereName($role)->firstOrFail());
27 | }
28 |
29 | /**
30 | * Determine if the user has the given role.
31 | *
32 | * @param mixed $role
33 | *
34 | * @return bool
35 | */
36 | public function hasRole($role)
37 | {
38 | if (is_string($role)) {
39 | return $this->roles->contains('name', $role);
40 | }
41 |
42 | return (bool) $role->intersect($this->roles)->count();
43 | }
44 |
45 | /**
46 | * Determine if the user may perform the given permission.
47 | *
48 | * @param Permission $permission
49 | *
50 | * @return bool
51 | */
52 | public function hasPermission(Permission $permission)
53 | {
54 | return $this->hasRole($permission->roles);
55 | }
56 | }
57 |
--------------------------------------------------------------------------------
/app/Traits/Rememberable.php:
--------------------------------------------------------------------------------
1 | getConnection();
17 |
18 | $grammar = $conn->getQueryGrammar();
19 | $builder = new CacheBuilder($conn, $grammar, $conn->getPostProcessor());
20 |
21 | if (isset($this->rememberFor)) {
22 | $builder->remember($this->rememberFor);
23 | }
24 |
25 | if (isset($this->rememberCacheTag)) {
26 | $builder->cacheTags($this->rememberCacheTag);
27 | }
28 |
29 | return $builder;
30 | }
31 | }
32 |
--------------------------------------------------------------------------------
/app/Traits/SaveToUpper.php:
--------------------------------------------------------------------------------
1 | attributes[$key] = trim(mb_strtoupper($value, $encoding));
15 | }
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/app/Traits/Slugado.php:
--------------------------------------------------------------------------------
1 | prepareSlug();
29 | });
30 | }
31 |
32 | /**
33 | * Definindo a coluna do titulo.
34 | *
35 | * @return string
36 | */
37 | private function colunaTitulo()
38 | {
39 | return ($this->SlugTitulo) ? $this->SlugTitulo : $this->colunaTitulo;
40 | }
41 |
42 | /**
43 | * Definindo a coluna que vai receber o slug.
44 | *
45 | * @return string
46 | */
47 | private function colunaSlug()
48 | {
49 | return ($this->SlugColuna) ? $this->SlugColuna : $this->colunaSlug;
50 | }
51 |
52 | /**
53 | * Prepare slug model.
54 | *
55 | * @return void
56 | */
57 | public function prepareSlug()
58 | {
59 | if ($this->slug == '') {
60 | $slugado = Str::slug($this[$this->colunaTitulo]);
61 | $workingModel = clone $this;
62 | $count = 0;
63 | while ($workingModel->where($this->colunaSlug, '=', $slugado)->first()) {
64 | $count += 1;
65 | $slugado = Str::slug($this->titulo.'-'.dechex($count));
66 | }
67 | $this->salvaSlug($slugado);
68 | }
69 | }
70 |
71 | /**
72 | * @param string $slug
73 | */
74 | public function salvaSlug($slug)
75 | {
76 | $this[$this->colunaSlug] = $slug;
77 | }
78 | }
79 |
--------------------------------------------------------------------------------
/artisan:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env php
2 | make(Illuminate\Contracts\Console\Kernel::class);
34 |
35 | $status = $kernel->handle(
36 | $input = new Symfony\Component\Console\Input\ArgvInput,
37 | new Symfony\Component\Console\Output\ConsoleOutput
38 | );
39 |
40 | /*
41 | |--------------------------------------------------------------------------
42 | | Shutdown The Application
43 | |--------------------------------------------------------------------------
44 | |
45 | | Once Artisan has finished running. We will fire off the shutdown events
46 | | so that any final work may be done by the application before we shut
47 | | down the process. This is the last thing to happen to the request.
48 | |
49 | */
50 |
51 | $kernel->terminate($input, $status);
52 |
53 | exit($status);
54 |
--------------------------------------------------------------------------------
/bootstrap/app.php:
--------------------------------------------------------------------------------
1 | singleton(
35 | Illuminate\Contracts\Http\Kernel::class,
36 | App\Http\Kernel::class
37 | );
38 |
39 | $app->singleton(
40 | Illuminate\Contracts\Console\Kernel::class,
41 | App\Console\Kernel::class
42 | );
43 |
44 | $app->singleton(
45 | Illuminate\Contracts\Debug\ExceptionHandler::class,
46 | App\Exceptions\Handler::class
47 | );
48 |
49 | /*
50 | |--------------------------------------------------------------------------
51 | | Return The Application
52 | |--------------------------------------------------------------------------
53 | |
54 | | This script returns the application instance. The instance is given to
55 | | the calling script so we can separate the building of the instances
56 | | from the actual running of the application and sending responses.
57 | |
58 | */
59 |
60 | return $app;
61 |
--------------------------------------------------------------------------------
/bootstrap/cache/.gitignore:
--------------------------------------------------------------------------------
1 | *
2 | !.gitignore
3 |
--------------------------------------------------------------------------------
/composer.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "drolean/Starter-Kit-Laravel",
3 | "description": "Laravel Starter Kit Admin Panel.",
4 | "keywords": ["php", "framework", "laravel"],
5 | "license": "MIT",
6 | "type": "project",
7 | "require": {
8 | "php": ">=7.0.0",
9 | "fideloper/proxy": "~3.3",
10 | "intervention/image": "^2.3",
11 | "laravel-notification-channels/webpush": "^1.0",
12 | "laravel/framework": "5.5.*",
13 | "laravel/socialite": "^3.0",
14 | "laravel/tinker": "^1.0",
15 | "laravelcollective/html": "^5.5",
16 | "laravolt/avatar": "^1.8",
17 | "pragmarx/google2fa": "^1.0",
18 | "pusher/pusher-php-server": "^3.0",
19 | "vinkla/hashids": "^3.1"
20 | },
21 | "require-dev": {
22 | "filp/whoops": "~2.0",
23 | "fzaninotto/faker": "~1.4",
24 | "mockery/mockery": "0.9.*",
25 | "phpunit/phpunit": "~6.0",
26 | "barryvdh/laravel-debugbar": "^2.3",
27 | "doctrine/dbal": "^2.5",
28 | "laravel/dusk": "^2.0"
29 | },
30 | "autoload": {
31 | "classmap": [
32 | "database/seeds",
33 | "database/factories"
34 | ],
35 | "psr-4": {
36 | "App\\": "app/"
37 | }
38 | },
39 | "autoload-dev": {
40 | "psr-4": {
41 | "Tests\\": "tests/"
42 | }
43 | },
44 | "extra": {
45 | "laravel": {
46 | "dont-discover": [
47 | "laravel/dusk"
48 | ]
49 | }
50 | },
51 | "scripts": {
52 | "post-root-package-install": [
53 | "@php -r \"file_exists('.env') || copy('.env.example', '.env');\""
54 | ],
55 | "post-create-project-cmd": [
56 | "@php artisan key:generate"
57 | ],
58 | "post-autoload-dump": [
59 | "Illuminate\\Foundation\\ComposerScripts::postAutoloadDump",
60 | "@php artisan package:discover"
61 | ]
62 | },
63 | "config": {
64 | "preferred-install": "dist",
65 | "sort-packages": true,
66 | "optimize-autoloader": true
67 | }
68 | }
69 |
--------------------------------------------------------------------------------
/config/broadcasting.php:
--------------------------------------------------------------------------------
1 | env('BROADCAST_DRIVER', 'null'),
19 |
20 | /*
21 | |--------------------------------------------------------------------------
22 | | Broadcast Connections
23 | |--------------------------------------------------------------------------
24 | |
25 | | Here you may define all of the broadcast connections that will be used
26 | | to broadcast events to other systems or over websockets. Samples of
27 | | each available type of connection are provided inside this array.
28 | |
29 | */
30 |
31 | 'connections' => [
32 |
33 | 'pusher' => [
34 | 'driver' => 'pusher',
35 | 'key' => env('PUSHER_KEY'),
36 | 'secret' => env('PUSHER_SECRET'),
37 | 'app_id' => env('PUSHER_APP_ID'),
38 | 'options' => [
39 | 'cluster' => env('PUSHER_CLUSTER', 'mt1'),
40 | 'encrypted' => true,
41 | ],
42 | ],
43 |
44 | 'redis' => [
45 | 'driver' => 'redis',
46 | 'connection' => 'default',
47 | ],
48 |
49 | 'log' => [
50 | 'driver' => 'log',
51 | ],
52 |
53 | 'null' => [
54 | 'driver' => 'null',
55 | ],
56 |
57 | ],
58 |
59 | ];
60 |
--------------------------------------------------------------------------------
/config/filesystems.php:
--------------------------------------------------------------------------------
1 | env('FILESYSTEM_DRIVER', 'local'),
17 |
18 | /*
19 | |--------------------------------------------------------------------------
20 | | Default Cloud Filesystem Disk
21 | |--------------------------------------------------------------------------
22 | |
23 | | Many applications store files both locally and in the cloud. For this
24 | | reason, you may specify a default "cloud" driver here. This driver
25 | | will be bound as the Cloud disk implementation in the container.
26 | |
27 | */
28 |
29 | 'cloud' => env('FILESYSTEM_CLOUD', 's3'),
30 |
31 | /*
32 | |--------------------------------------------------------------------------
33 | | Filesystem Disks
34 | |--------------------------------------------------------------------------
35 | |
36 | | Here you may configure as many filesystem "disks" as you wish, and you
37 | | may even configure multiple disks of the same driver. Defaults have
38 | | been setup for each driver as an example of the required options.
39 | |
40 | | Supported Drivers: "local", "ftp", "s3", "rackspace"
41 | |
42 | */
43 |
44 | 'disks' => [
45 |
46 | 'local' => [
47 | 'driver' => 'local',
48 | 'root' => storage_path('app'),
49 | ],
50 |
51 | 'public' => [
52 | 'driver' => 'local',
53 | 'root' => storage_path('app/public'),
54 | 'url' => env('APP_URL').'/storage',
55 | 'visibility' => 'public',
56 | ],
57 |
58 | 's3' => [
59 | 'driver' => 's3',
60 | 'key' => env('AWS_KEY'),
61 | 'secret' => env('AWS_SECRET'),
62 | 'region' => env('AWS_REGION'),
63 | 'bucket' => env('AWS_BUCKET'),
64 | ],
65 |
66 | ],
67 |
68 | ];
69 |
--------------------------------------------------------------------------------
/config/hashids.php:
--------------------------------------------------------------------------------
1 |
7 | *
8 | * For the full copyright and license information, please view the LICENSE
9 | * file that was distributed with this source code.
10 | */
11 |
12 | declare(strict_types=1);
13 |
14 | return [
15 |
16 | /*
17 | |--------------------------------------------------------------------------
18 | | Default Connection Name
19 | |--------------------------------------------------------------------------
20 | |
21 | | Here you may specify which of the connections below you wish to use as
22 | | your default connection for all work. Of course, you may use many
23 | | connections at once using the manager class.
24 | |
25 | */
26 |
27 | 'default' => 'main',
28 |
29 | /*
30 | |--------------------------------------------------------------------------
31 | | Hashids Connections
32 | |--------------------------------------------------------------------------
33 | |
34 | | Here are each of the connections setup for your application. Example
35 | | configuration has been included, but you may add as many connections as
36 | | you would like.
37 | |
38 | */
39 |
40 | 'connections' => [
41 |
42 | 'main' => [
43 | 'salt' => env('APP_KEY'),
44 | 'length' => '8',
45 | 'alphabet' => 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890',
46 | ],
47 |
48 | 'alternative' => [
49 | 'salt' => 'your-salt-string',
50 | 'length' => 'your-length-integer',
51 | 'alphabet' => 'your-alphabet-string',
52 | ],
53 |
54 | ],
55 |
56 | ];
57 |
--------------------------------------------------------------------------------
/config/starter.php:
--------------------------------------------------------------------------------
1 | env('APP_ADMIN_ONLY', true),
6 |
7 | 'SSL' => env('APP_SSL', true),
8 |
9 | 'MULTISAS' => env('APP_MULTISAS', true),
10 |
11 | 'VERSION' => env('APP_VERSION', '1.0.0'),
12 |
13 | 'MAIL_DEV' => env('APP_MAIL_DEV', 'dev@domain.com'),
14 |
15 | 'MAIL_REPLY' => env('MAIL_REPLY', 'no-reply@domain.com'),
16 |
17 | 'GCM_SENDER_ID' => env('GCM_SENDER_ID', null),
18 |
19 | 'CACHE_TIME' => env('CACHE_TIME', 15),
20 |
21 | ];
22 |
--------------------------------------------------------------------------------
/config/view.php:
--------------------------------------------------------------------------------
1 | [
17 | resource_path('views'),
18 | ],
19 |
20 | /*
21 | |--------------------------------------------------------------------------
22 | | Compiled View Path
23 | |--------------------------------------------------------------------------
24 | |
25 | | This option determines where all the compiled Blade templates will be
26 | | stored for your application. Typically, this is within the storage
27 | | directory. However, as usual, you are free to change this value.
28 | |
29 | */
30 |
31 | 'compiled' => realpath(storage_path('framework/views')),
32 |
33 | ];
34 |
--------------------------------------------------------------------------------
/config/webpush.php:
--------------------------------------------------------------------------------
1 | [
16 | 'subject' => env('VAPID_SUBJECT'),
17 | 'public_key' => env('VAPID_PUBLIC_KEY'),
18 | 'private_key' => env('VAPID_PRIVATE_KEY'),
19 | 'pem_file' => env('VAPID_PEM_FILE'),
20 | ],
21 |
22 | /*
23 | |--------------------------------------------------------------------------
24 | | Google Cloud Messaging
25 | |--------------------------------------------------------------------------
26 | |
27 | | Deprecated and optional. It's here only for compatibility reasons.
28 | |
29 | */
30 |
31 | 'gcm' => [
32 | 'key' => env('GCM_KEY'),
33 | 'sender_id' => env('GCM_SENDER_ID'),
34 | ],
35 |
36 | ];
37 |
--------------------------------------------------------------------------------
/database/.gitignore:
--------------------------------------------------------------------------------
1 | *.sqlite
2 |
--------------------------------------------------------------------------------
/database/factories/ModelFactory.php:
--------------------------------------------------------------------------------
1 | define(App\User::class, function (Faker\Generator $faker) {
16 | static $password;
17 |
18 | return [
19 | 'name' => $faker->name,
20 | 'email' => $faker->unique()->safeEmail,
21 | 'password' => $password ?: $password = bcrypt('secret'),
22 | 'remember_token' => str_random(10),
23 | ];
24 | });
25 |
--------------------------------------------------------------------------------
/database/migrations/.gitkeep:
--------------------------------------------------------------------------------
1 |
2 |
--------------------------------------------------------------------------------
/database/migrations/2014_10_10_000000_create_companies_table.php:
--------------------------------------------------------------------------------
1 | increments('id');
18 | $table->string('empresa');
19 | $table->string('cnpj')->unique();
20 | $table->string('telefone')->nullable();
21 | $table->string('endereco')->nullable();
22 | $table->boolean('active');
23 | $table->integer('max_users')->unsigned()->nullable();
24 | $table->integer('user_id')->unsigned()->nullable();
25 | $table->string('logo')->default('default.jpg');
26 | $table->timestamps();
27 | $table->softDeletes();
28 | });
29 | }
30 |
31 | /**
32 | * Reverse the migrations.
33 | *
34 | * @return void
35 | */
36 | public function down()
37 | {
38 | Schema::drop('companies');
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/database/migrations/2014_10_12_100000_create_password_resets_table.php:
--------------------------------------------------------------------------------
1 | string('email')->index();
18 | $table->string('token')->index();
19 | $table->timestamp('created_at')->nullable();
20 | });
21 | }
22 |
23 | /**
24 | * Reverse the migrations.
25 | *
26 | * @return void
27 | */
28 | public function down()
29 | {
30 | Schema::dropIfExists('password_resets');
31 | }
32 | }
33 |
--------------------------------------------------------------------------------
/database/migrations/2016_05_15_023906_create_roles_tables.php:
--------------------------------------------------------------------------------
1 | increments('id');
17 | $table->string('name', 40);
18 | $table->string('description', 255)->nullable();
19 | $table->timestamps();
20 |
21 | $table->integer('company_id')->unsigned()->nullable();
22 | $table->foreign('company_id')->references('id')->on('companies')->onDelete('cascade');
23 | });
24 |
25 | Schema::create('permissions', function (Blueprint $table) {
26 | $table->increments('id');
27 | $table->string('name');
28 | $table->string('label')->nullable();
29 | $table->boolean('visible')->nullable();
30 | $table->timestamps();
31 | });
32 |
33 | Schema::create('permission_role', function (Blueprint $table) {
34 | $table->integer('permission_id')->unsigned();
35 | $table->foreign('permission_id')->references('id')->on('permissions')->onDelete('cascade');
36 | $table->integer('role_id')->unsigned();
37 | $table->foreign('role_id')->references('id')->on('roles')->onDelete('cascade');
38 | $table->primary(['permission_id', 'role_id']);
39 | });
40 |
41 | Schema::create('role_user', function (Blueprint $table) {
42 | $table->integer('role_id')->unsigned();
43 | $table->foreign('role_id')->references('id')->on('roles')->onDelete('cascade');
44 | $table->integer('user_id')->unsigned();
45 | $table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
46 | $table->primary(['role_id', 'user_id']);
47 | });
48 | }
49 |
50 | /**
51 | * Reverse the migrations.
52 | *
53 | * @return void
54 | */
55 | public function down()
56 | {
57 | Schema::dropIfExists('permission_role');
58 | Schema::dropIfExists('role_user');
59 | Schema::dropIfExists('permissions');
60 | Schema::dropIfExists('roles');
61 | }
62 | }
63 |
--------------------------------------------------------------------------------
/database/migrations/2016_06_08_234345_create_profile_table.php:
--------------------------------------------------------------------------------
1 | increments('id');
17 | $table->integer('user_id')->unsigned();
18 | $table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
19 |
20 | $table->string('endereco')->nullable();
21 | $table->string('cidade')->nullable();
22 | $table->string('estado')->nullable();
23 | $table->string('cep')->nullable();
24 | $table->string('telefone')->nullable();
25 | $table->text('bio')->nullable();
26 | $table->date('aniversario')->nullable();
27 | $table->binary('avatar')->nullable();
28 | $table->string('cpfcnpj')->nullable();
29 |
30 | $table->timestamps();
31 | });
32 | }
33 |
34 | /**
35 | * Reverse the migrations.
36 | *
37 | * @return void
38 | */
39 | public function down()
40 | {
41 | Schema::drop('profiles');
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/database/migrations/2016_06_09_002329_create_notification_table.php:
--------------------------------------------------------------------------------
1 | uuid('id')->primary();
17 | $table->string('title')->nullable();
18 | $table->text('data')->nullable();
19 | $table->string('type')->nullable();
20 | $table->timestamp('read_at')->nullable();
21 | $table->string('notifiable_type')->nullable();
22 | $table->integer('notifiable_id')->nullable();
23 | $table->timestamps();
24 | $table->index(['notifiable_type', 'notifiable_id']);
25 | });
26 | }
27 |
28 | /**
29 | * Reverse the migrations.
30 | *
31 | * @return void
32 | */
33 | public function down()
34 | {
35 | Schema::drop('notifications');
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/database/migrations/2016_06_09_005404_create_activity_table.php:
--------------------------------------------------------------------------------
1 | increments('id');
17 | $table->integer('user_id')->nullable();
18 | $table->string('content_type', 72)->nullable();
19 | $table->integer('content_id')->nullable();
20 | $table->string('acao', 32)->nullable();
21 | $table->text('descricao')->nullable();
22 | $table->text('detalhes')->nullable();
23 | $table->string('ip_address', 64);
24 | $table->text('user_agent');
25 | $table->timestamps();
26 |
27 | $table->integer('company_id')->unsigned()->nullable();
28 | $table->foreign('company_id')->references('id')->on('companies')->onDelete('cascade');
29 | });
30 | }
31 |
32 | /**
33 | * Reverse the migrations.
34 | *
35 | * @return void
36 | */
37 | public function down()
38 | {
39 | Schema::drop('activities');
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/database/migrations/2016_06_09_010158_create_tickets_table.php:
--------------------------------------------------------------------------------
1 | increments('id');
17 | $table->integer('user_id')->unsigned();
18 | $table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
19 | $table->string('titulo');
20 | $table->text('descricao');
21 | $table->enum('tipo', ['bug', 'tarefa', 'outro'])->default('bug');
22 | $table->enum('prioridade', ['alta', 'media', 'baixa'])->default('baixa');
23 | $table->enum('status', ['aberto', 'fechado'])->default('aberto');
24 | $table->integer('dev_loe')->unsigned()->default(0);
25 | $table->timestamps();
26 | $table->softDeletes();
27 |
28 | $table->integer('company_id')->unsigned()->nullable();
29 | $table->foreign('company_id')->references('id')->on('companies')->onDelete('cascade');
30 | });
31 |
32 | Schema::create('tickets_comment', function (Blueprint $table) {
33 | $table->increments('id');
34 | $table->text('comentario');
35 | $table->integer('user_id')->unsigned();
36 | $table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
37 | $table->integer('ticket_id')->unsigned();
38 | $table->foreign('ticket_id')->references('id')->on('tickets')->onDelete('cascade');
39 | $table->timestamps();
40 | $table->softDeletes();
41 |
42 | $table->integer('company_id')->unsigned()->nullable();
43 | $table->foreign('company_id')->references('id')->on('companies')->onDelete('cascade');
44 | });
45 | }
46 |
47 | /**
48 | * Reverse the migrations.
49 | *
50 | * @return void
51 | */
52 | public function down()
53 | {
54 | Schema::drop('tickets_comment');
55 | Schema::drop('tickets');
56 | }
57 | }
58 |
--------------------------------------------------------------------------------
/database/migrations/2016_12_13_091913_create_jobs_table.php:
--------------------------------------------------------------------------------
1 | bigIncrements('id');
18 | $table->string('queue');
19 | $table->longText('payload');
20 | $table->tinyInteger('attempts')->unsigned();
21 | $table->unsignedInteger('reserved_at')->nullable();
22 | $table->unsignedInteger('available_at');
23 | $table->unsignedInteger('created_at');
24 | $table->index(['queue', 'reserved_at']);
25 | });
26 | }
27 |
28 | /**
29 | * Reverse the migrations.
30 | *
31 | * @return void
32 | */
33 | public function down()
34 | {
35 | Schema::dropIfExists('jobs');
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/database/migrations/2016_12_13_091920_create_failed_jobs_table.php:
--------------------------------------------------------------------------------
1 | increments('id');
18 | $table->text('connection');
19 | $table->text('queue');
20 | $table->longText('payload');
21 | $table->longText('exception');
22 | $table->timestamp('failed_at')->useCurrent();
23 | });
24 | }
25 |
26 | /**
27 | * Reverse the migrations.
28 | *
29 | * @return void
30 | */
31 | public function down()
32 | {
33 | Schema::dropIfExists('failed_jobs');
34 | }
35 | }
36 |
--------------------------------------------------------------------------------
/database/migrations/2017_03_24_114526_create_alert_table.php:
--------------------------------------------------------------------------------
1 | increments('id');
18 | $table->text('title');
19 | $table->longText('description');
20 | $table->text('button_text')->nullable();
21 | $table->text('button_link')->nullable();
22 | $table->date('start_at')->nullable();
23 | $table->date('end_at')->nullable();
24 |
25 | $table->integer('company_id')->unsigned()->nullable();
26 | $table->foreign('company_id')->references('id')->on('companies')->onDelete('cascade');
27 |
28 | $table->timestamps();
29 | $table->softDeletes();
30 | });
31 | }
32 |
33 | /**
34 | * Reverse the migrations.
35 | *
36 | * @return void
37 | */
38 | public function down()
39 | {
40 | Schema::dropIfExists('alerts');
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/database/migrations/2017_05_05_155240_create_push_subscriptions_table.php:
--------------------------------------------------------------------------------
1 | increments('id');
18 | $table->integer('user_id')->unsigned()->index();
19 | $table->string('endpoint')->unique();
20 | $table->string('public_key')->nullable();
21 | $table->string('auth_token')->nullable();
22 | $table->timestamps();
23 |
24 | $table->foreign('user_id')
25 | ->references('id')
26 | ->on('users')
27 | ->onDelete('cascade');
28 | });
29 | }
30 |
31 | /**
32 | * Reverse the migrations.
33 | *
34 | * @return void
35 | */
36 | public function down()
37 | {
38 | Schema::drop('push_subscriptions');
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/database/migrations/2017_05_10_153017_create_table_social_logins.php:
--------------------------------------------------------------------------------
1 | integer('user_id')->unsigned()->index();
18 | $table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
19 | $table->string('provider', 32);
20 | $table->timestamps();
21 | });
22 | }
23 |
24 | /**
25 | * Reverse the migrations.
26 | *
27 | * @return void
28 | */
29 | public function down()
30 | {
31 | Schema::drop('users_socials');
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/database/migrations/2017_05_17_162156_add_google2fa_secret_to_users.php:
--------------------------------------------------------------------------------
1 | text('google2fa_secret')->nullable();
17 | });
18 | }
19 |
20 | /**
21 | * Reverse the migrations.
22 | *
23 | * @return void
24 | */
25 | public function down()
26 | {
27 | Schema::table('users', function ($table) {
28 | $table->dropColumn('google2fa_secret');
29 | });
30 | }
31 | }
32 |
--------------------------------------------------------------------------------
/database/migrations/2017_05_30_155259_create_messages_table.php:
--------------------------------------------------------------------------------
1 | increments('id');
18 | $table->integer('user_id')->unsigned();
19 | $table->text('message');
20 |
21 | $table->integer('company_id')->unsigned()->nullable();
22 | $table->foreign('company_id')->references('id')->on('companies')->onDelete('cascade');
23 | $table->timestamps();
24 | });
25 | }
26 |
27 | /**
28 | * Reverse the migrations.
29 | *
30 | * @return void
31 | */
32 | public function down()
33 | {
34 | Schema::dropIfExists('messages');
35 | }
36 | }
37 |
--------------------------------------------------------------------------------
/database/seeds/.gitkeep:
--------------------------------------------------------------------------------
1 |
2 |
--------------------------------------------------------------------------------
/database/seeds/DatabaseSeeder.php:
--------------------------------------------------------------------------------
1 | call(StarterSeeder::class);
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/database/seeds/StarterSeeder.php:
--------------------------------------------------------------------------------
1 | insert([
16 | 'empresa' => 'Empresa Starter KIT',
17 | 'cnpj' => '00.000.000/0000-00',
18 | 'active' => true,
19 | 'max_users' => 999,
20 | 'created_at' => Carbon::now(),
21 | 'updated_at' => Carbon::now(),
22 | ]);
23 |
24 | DB::table('users')->insert([
25 | 'name' => 'Fulano Beltrano',
26 | 'email' => 'usuario@email.com',
27 | 'password' => bcrypt('secret'),
28 | 'activation' => 1,
29 | 'is_admin' => 1,
30 | 'is_super' => 1,
31 | 'company_id' => 1,
32 | 'created_at' => Carbon::now(),
33 | 'updated_at' => Carbon::now(),
34 | ]);
35 |
36 | DB::table('profiles')->insert([
37 | 'user_id' => 1,
38 | 'created_at' => Carbon::now(),
39 | 'updated_at' => Carbon::now(),
40 | ]);
41 |
42 | DB::table('companie_user')->insert([
43 | 'companie_id' => 1,
44 | 'user_id' => 1,
45 | ]);
46 |
47 | DB::table('companies')->update(['user_id' => 1]);
48 | }
49 | }
50 |
--------------------------------------------------------------------------------
/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "scripts": {
4 | "dev": "npm run development",
5 | "development": "cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js",
6 | "watch": "cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --watch --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js",
7 | "watch-poll": "npm run watch -- --watch-poll",
8 | "hot": "cross-env NODE_ENV=development node_modules/webpack-dev-server/bin/webpack-dev-server.js --inline --hot --config=node_modules/laravel-mix/setup/webpack.config.js",
9 | "prod": "npm run production",
10 | "production": "cross-env NODE_ENV=production node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js"
11 | },
12 | "devDependencies": {
13 | "alertify.js": "^1.0.12",
14 | "axios": "^0.17.1",
15 | "jquery": "^3.2.1",
16 | "jquery-ujs": "^1.2.2",
17 | "laravel-mix": "^1.7",
18 | "lodash": "^4.17.4",
19 | "popper.js": "^1.12.9",
20 | "vue": "^2.5.13"
21 | },
22 | "dependencies": {
23 | "@fortawesome/fontawesome": "^1.1.2",
24 | "@fortawesome/fontawesome-free-brands": "^5.0.4",
25 | "@fortawesome/fontawesome-free-regular": "^5.0.4",
26 | "@fortawesome/fontawesome-free-solid": "^5.0.4",
27 | "babel-polyfill": "^6.26.0",
28 | "bootstrap": "^4.0.0",
29 | "cross-env": "^5.1.3",
30 | "flatpickr": "^4.2.3",
31 | "laravel-echo": "^1.3.3",
32 | "pusher-js": "^4.2.2",
33 | "vue-tables-2": "^1.2.45",
34 | "vue-template-compiler": "^2.5.13",
35 | "vue-timeago": "^3.4.2"
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/phpunit.dusk.xml:
--------------------------------------------------------------------------------
1 |
2 |
11 |
12 |
13 | ./tests/Browser
14 |
15 |
16 |
17 |
18 | ./app
19 |
20 |
21 |
22 |
--------------------------------------------------------------------------------
/phpunit.xml:
--------------------------------------------------------------------------------
1 |
2 |
11 |
12 |
13 | ./tests/Feature
14 |
15 |
16 |
17 | ./tests/Unit
18 |
19 |
20 |
21 |
22 | ./app
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
--------------------------------------------------------------------------------
/public/blank.html:
--------------------------------------------------------------------------------
1 | Blank page
--------------------------------------------------------------------------------
/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/favicon.ico
--------------------------------------------------------------------------------
/public/favicon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/favicon.png
--------------------------------------------------------------------------------
/public/index.php:
--------------------------------------------------------------------------------
1 |
7 | */
8 | define('LARAVEL_START', microtime(true));
9 |
10 | /*
11 | |--------------------------------------------------------------------------
12 | | Register The Auto Loader
13 | |--------------------------------------------------------------------------
14 | |
15 | | Composer provides a convenient, automatically generated class loader for
16 | | our application. We just need to utilize it! We'll simply require it
17 | | into the script here so that we don't have to worry about manual
18 | | loading any of our classes later on. It feels great to relax.
19 | |
20 | */
21 |
22 | require __DIR__.'/../vendor/autoload.php';
23 |
24 | /*
25 | |--------------------------------------------------------------------------
26 | | Turn On The Lights
27 | |--------------------------------------------------------------------------
28 | |
29 | | We need to illuminate PHP development, so let us turn on the lights.
30 | | This bootstraps the framework and gets it ready for use, then it
31 | | will load up this application so that we can run it and send
32 | | the responses back to the browser and delight our users.
33 | |
34 | */
35 |
36 | $app = require_once __DIR__.'/../bootstrap/app.php';
37 |
38 | /*
39 | |--------------------------------------------------------------------------
40 | | Run The Application
41 | |--------------------------------------------------------------------------
42 | |
43 | | Once we have the application, we can handle the incoming request
44 | | through the kernel, and send the associated response back to
45 | | the client's browser allowing them to enjoy the creative
46 | | and wonderful application we have prepared for them.
47 | |
48 | */
49 |
50 | $kernel = $app->make(Illuminate\Contracts\Http\Kernel::class);
51 |
52 | $response = $kernel->handle(
53 | $request = Illuminate\Http\Request::capture()
54 | );
55 |
56 | $response->send();
57 |
58 | $kernel->terminate($request, $response);
59 |
--------------------------------------------------------------------------------
/public/launcher-icon-1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/launcher-icon-1x.png
--------------------------------------------------------------------------------
/public/launcher-icon-2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/launcher-icon-2x.png
--------------------------------------------------------------------------------
/public/launcher-icon-3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/launcher-icon-3x.png
--------------------------------------------------------------------------------
/public/launcher-icon-4x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/launcher-icon-4x.png
--------------------------------------------------------------------------------
/public/launcher-icon-5x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/launcher-icon-5x.png
--------------------------------------------------------------------------------
/public/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/logo.png
--------------------------------------------------------------------------------
/public/mix-manifest.json:
--------------------------------------------------------------------------------
1 | {
2 | "/static/js/dashboard.js": "/static/js/dashboard.js?id=90cf635912cda72443fa",
3 | "/static/js/app.js": "/static/js/app.js?id=08404abcffffb00df521",
4 | "/static/css/app.css": "/static/css/app.css?id=dc7908f31ce5b749d75d"
5 | }
--------------------------------------------------------------------------------
/public/notification-icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/notification-icon.png
--------------------------------------------------------------------------------
/public/robots.txt:
--------------------------------------------------------------------------------
1 | User-agent: *
2 | Disallow:
3 |
--------------------------------------------------------------------------------
/public/static/img/bg/000.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/bg/000.png
--------------------------------------------------------------------------------
/public/static/img/bg/001.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/bg/001.png
--------------------------------------------------------------------------------
/public/static/img/bg/002.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/bg/002.png
--------------------------------------------------------------------------------
/public/static/img/bg/003.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/bg/003.png
--------------------------------------------------------------------------------
/public/static/img/bg/004.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/bg/004.png
--------------------------------------------------------------------------------
/public/static/img/bg/005.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/bg/005.png
--------------------------------------------------------------------------------
/public/static/img/bg/006.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/bg/006.png
--------------------------------------------------------------------------------
/public/static/img/bg/007.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/bg/007.png
--------------------------------------------------------------------------------
/public/static/img/bg/login-bg-1.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/bg/login-bg-1.jpg
--------------------------------------------------------------------------------
/public/static/img/bg/login-bg-2.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/bg/login-bg-2.jpg
--------------------------------------------------------------------------------
/public/static/img/bg/login-bg-3.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/bg/login-bg-3.jpg
--------------------------------------------------------------------------------
/public/static/img/bg/login-bg-4.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/bg/login-bg-4.jpg
--------------------------------------------------------------------------------
/public/static/img/bg/login-bg-5.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/bg/login-bg-5.jpg
--------------------------------------------------------------------------------
/public/static/img/bg/login-bg-6.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/bg/login-bg-6.jpg
--------------------------------------------------------------------------------
/public/static/img/bg/login-bg-7.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/bg/login-bg-7.jpg
--------------------------------------------------------------------------------
/public/static/img/bg/login-bg-8.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/bg/login-bg-8.jpg
--------------------------------------------------------------------------------
/public/static/img/icos/chrome-logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/icos/chrome-logo.png
--------------------------------------------------------------------------------
/public/static/img/icos/firefox-logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/icos/firefox-logo.png
--------------------------------------------------------------------------------
/public/static/img/icos/internet-logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/icos/internet-logo.png
--------------------------------------------------------------------------------
/public/static/img/icos/opera-logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/icos/opera-logo.png
--------------------------------------------------------------------------------
/public/static/img/icos/safari-logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/public/static/img/icos/safari-logo.png
--------------------------------------------------------------------------------
/resources/assets/js/components/ChatForm.vue:
--------------------------------------------------------------------------------
1 |
2 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/resources/assets/js/components/ChatMessages.vue:
--------------------------------------------------------------------------------
1 |
2 |
28 |
29 |
30 |
--------------------------------------------------------------------------------
/resources/assets/js/components/Notification.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
7 | {{ notification.body }}
8 |
9 |
10 | Marcar como lida
11 |
12 |
13 |
14 |
15 |
16 |
27 |
--------------------------------------------------------------------------------
/resources/assets/sass/modulos/_app.scss:
--------------------------------------------------------------------------------
1 | .app {
2 | position: relative;
3 | width: 100%;
4 | max-width: 100%;
5 | min-height: 100%;
6 | background: $background-app;
7 | @include x-display-flex;
8 | -webkit-box-direction: normal;
9 | -webkit-box-orient: horizontal;
10 | @include flex-direction(row);
11 | &:not(.layout-static) {
12 | //max-height: 100%;
13 | //height: 100%;
14 | }
15 | &.layout-static {
16 | max-height: initial !important;
17 | height: initial !important;
18 | background-size: cover;
19 | background-repeat: no-repeat;
20 | background-position: center center;
21 | padding: 5% 0;
22 | position: fixed;
23 | .card-block {
24 | @include flex(initial);
25 | }
26 |
27 | @for $i from 1 through 8 {
28 | &.bg-#{$i} {
29 | background-image: url('/static/img/bg/login-bg-#{$i}.jpg');
30 | }
31 | }
32 | }
33 | &.error-page .card {
34 | display: block;
35 | width: 100%;
36 | margin: 100px auto;
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/resources/assets/sass/modulos/_box.scss:
--------------------------------------------------------------------------------
1 | .box {
2 | overflow: hidden;
3 | padding: 10px;
4 | @include border-radius(3);
5 | .box-title {
6 | h1 > a, h2 > a, h3 > a, h4 > a, h5 > a, h6 > a {
7 | color: #fff;
8 | margin: 0;
9 | }
10 | }
11 | h1, h2, h3, h4, h5, h6 {
12 | color: #fff;
13 | margin: 0;
14 | }
15 | .box-title {
16 | padding: 10px 0 20px 0;
17 | position: relative;
18 | border-bottom: rgba(0, 0, 0, 0.1) 1px solid;
19 | i.fa {
20 | position: absolute;
21 | top: 0;
22 | right: 0;
23 | @include font-size(70);
24 | color: rgba(0, 0, 0, 0.1);
25 | }
26 | }
27 | .box-body {
28 | .sparkline {
29 | display: block;
30 | margin-top: 10px;
31 | }
32 | border-top: rgba(255, 255, 255, 0.1) 1px solid;
33 | }
34 | &.warning {
35 | background-color: #f4b04f;
36 | }
37 | &.info {
38 | background-color: #1D89CF;
39 | }
40 | &.danger {
41 | background-color: #E66454;
42 | }
43 | &.default {
44 | background-color: #999999;
45 | }
46 | &.success {
47 | background-color: #5CB85C;
48 | }
49 | }
--------------------------------------------------------------------------------
/resources/assets/sass/modulos/_chat.scss:
--------------------------------------------------------------------------------
1 | .chat-conversation {
2 | position: fixed;
3 | top: 50px;
4 | background-color: white;
5 | right: 0;
6 | display: none;
7 | width: 300px;
8 | height: 100%;
9 | z-index: 99;
10 | border-left: 2px solid #ccc;
11 | &.show {
12 | display: block;
13 | }
14 | .scroll-y {
15 | overflow-x: hidden;
16 | overflow-y: auto;
17 | -webkit-overflow-scrolling: touch;
18 | height: 100%;
19 | max-height: -webkit-calc(100vh - 180px);
20 | max-height: -moz-calc(100vh - 180px);
21 | max-height: -o-calc(100% - 180px);
22 | max-height: calc(100% - 180px);
23 | }
24 | .inner-header {
25 | border-bottom: 1px solid #ccc;
26 | }
27 | .chat-reply-box {
28 | border-top: 1px solid #ccc;
29 | .right-icon-control {
30 | position: relative;
31 | .form-icon {
32 | position: absolute;
33 | top: 7px;
34 | right: 17px;
35 | }
36 | }
37 | }
38 | .conversation {
39 | .photo-table img {
40 | width: 40px;
41 | }
42 | .chat-menu-reply {
43 | background: #1abc9c;
44 | margin-right: 10px;
45 | position: relative;
46 | overflow: visible;
47 | @include border-radius(4px);
48 | > p {
49 | color: #fff;
50 | }
51 | &:before {
52 | position: absolute;
53 | top: 20px;
54 | right: -14px;
55 | width: 0;
56 | height: 0;
57 | content: '';
58 | border: 8px solid transparent;
59 | border-left-color: #1abc9c;
60 | }
61 | }
62 | .chat-menu-content {
63 | background: #f3f3f3;
64 | position: relative;
65 | overflow: visible;
66 | @include border-radius(4px);
67 | &:before {
68 | position: absolute;
69 | top: 20px;
70 | left: -14px;
71 | width: 0;
72 | height: 0;
73 | content: '';
74 | border: 8px solid transparent;
75 | border-right-color: #f3f3f3;
76 | }
77 | }
78 | }
79 | }
80 |
--------------------------------------------------------------------------------
/resources/assets/sass/modulos/_cores.scss:
--------------------------------------------------------------------------------
1 | $background-color: #d1d1d2;
2 | $background-app: #f2f7f8;
3 | $link-texto: #54667a; //rgba(0, 0, 0, 0.7);
4 | $link-titulo: hsla(0, 0%, 100%, 0.9);
5 | $background-header: #4c7ff0;
--------------------------------------------------------------------------------
/resources/assets/sass/modulos/_footer.scss:
--------------------------------------------------------------------------------
1 | .content-footer {
2 | padding: 0 1.5rem;
3 | .footer-right {
4 | float: right;
5 | margin-right: 0;
6 | }
7 | nav {
8 | margin-right: 1rem;
9 | ul {
10 | li {
11 | display: inline-block;
12 | vertical-align: -webkit-baseline-middle;
13 | a {
14 | display: block;
15 | padding: .906rem .625rem;
16 | color: $link-texto;
17 | @include font-size(11);
18 | line-height: 17px;
19 | color: #777;
20 | }
21 | }
22 | }
23 | }
24 | }
--------------------------------------------------------------------------------
/resources/assets/sass/modulos/_modal.scss:
--------------------------------------------------------------------------------
1 | .modal {
2 | &.fade {
3 | &.in .right {
4 | @include transform(translate3d(0, 0, 0));
5 | }
6 | .right {
7 | @include transform(translate3d(100%, 0, 0));
8 | @include transition(transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1));
9 | }
10 | }
11 | > .right {
12 | position: absolute;
13 | top: 0;
14 | right: 0;
15 | bottom: 0;
16 | left: auto;
17 | }
18 | }
--------------------------------------------------------------------------------
/resources/assets/sass/modulos/_notification.scss:
--------------------------------------------------------------------------------
1 | .modal.docked {
2 | .modal-dialog {
3 | position: fixed;
4 | top: 0;
5 | margin: 0;
6 | height: 100vh;
7 | width: 350px;
8 | }
9 | &.docked-left .modal-dialog {
10 | left: 0;
11 | }
12 | &.docked-right .modal-dialog {
13 | right: 0;
14 | }
15 | .modal-content {
16 | border-radius: 0;
17 | height: 100vh;
18 | border: none;
19 | overflow-y: scroll;
20 | min-height: 100vh;
21 | }
22 | .modal-footer {
23 | position: fixed;
24 | bottom: 0;
25 | right: 0;
26 | }
27 | .modal-body {
28 | height: 100vh;
29 | min-height: 100vh;
30 | }
31 | .modal-header {
32 | background: #fff;
33 | border-bottom: 1px dashed rgba(0, 0, 0, 0.1);
34 | margin-bottom: 0;
35 | height: 70px;
36 | width: 100%;
37 | position: fixed;
38 | z-index: 100;
39 | }
40 | .helper-container {
41 | padding-top: 70px;
42 | }
43 | }
--------------------------------------------------------------------------------
/resources/assets/sass/modulos/_profile.scss:
--------------------------------------------------------------------------------
1 | .profile-bio {
2 | @include border-radius(5px);
3 | .background {
4 | display: block;
5 | width: 100%;
6 | height: 60px;
7 | border: 2px 2px 0 0;
8 | }
9 | .avatar {
10 | display: flex;
11 | max-width: 100%;
12 | margin: -30px 5px 0 10px;
13 | padding: 1px;
14 | vertical-align: bottom;
15 | border-radius: 2px;
16 | img {
17 | box-sizing: border-box;
18 | width: 72px;
19 | height: 72px;
20 | color: #fff;
21 | border: 2px solid #fff;
22 | border-radius: 4px;
23 | float: left;
24 | background-color: #fff;
25 | }
26 | }
27 | .user-details {
28 | padding: 34px 8px 0;
29 | float: left;
30 | .user-name {
31 | @include font-size(16);
32 | font-weight: 500;
33 | line-height: 1rem;
34 | }
35 | }
36 | .user-stats {
37 | > ul {
38 | display: table;
39 | box-sizing: border-box;
40 | min-width: 100%;
41 | margin: 0;
42 | padding: 0;
43 | table-layout: auto;
44 | list-style: outside none none;
45 | > li {
46 | display: table-cell;
47 | padding: 0;
48 | vertical-align: top;
49 | text-align: center;
50 | > a:hover {
51 | text-decoration: none;
52 | }
53 | }
54 | }
55 | .small {
56 | @include font-size(10);
57 | font-weight: 600;
58 | letter-spacing: .01rem;
59 | }
60 | }
61 | }
62 |
63 | .profile-reccomendations .user-meta{margin-bottom:0;padding:0;list-style:none}
64 | .profile-reccomendations .user-meta li{padding:5px 0}
--------------------------------------------------------------------------------
/resources/assets/sass/modulos/_searchbar.scss:
--------------------------------------------------------------------------------
1 | .search-bar {
2 | position: fixed;
3 | top: -100px;
4 | left: 0;
5 | z-index: 9999999;
6 | width: 100%;
7 | @include transition(.25s);
8 | &.open {
9 | top: 0;
10 | }
11 | .search-icon {
12 | position: absolute;
13 | top: 15px;
14 | left: 15px;
15 | .fa {
16 | color: #999;
17 | }
18 | }
19 | .close-search {
20 | position: absolute;
21 | cursor: pointer;
22 | top: 10px;
23 | right: 18px;
24 | .fa {
25 | color: #999;
26 | @include opacity(1);
27 | @include transition(0.5s);
28 | &:hover {
29 | @include opacity(0.5);
30 | }
31 | }
32 | }
33 | input[type="text"] {
34 | width: 100%;
35 | @include font-size(19);
36 | padding: 15px 53px;
37 | border: none;
38 | outline: 0;
39 | }
40 | }
--------------------------------------------------------------------------------
/resources/assets/sass/modulos/_session.scss:
--------------------------------------------------------------------------------
1 | .session-panel {
2 | width: 100%;
3 | min-height: 100vh;
4 | }
5 |
6 | .session {
7 | min-height: 100vh;
8 | @include x-display-flex;
9 | @include flex-direction(column);
10 | }
11 |
12 | .session-content {
13 | @include x-display-flex;
14 | //@include flex(1);
15 | @include flex-direction(column);
16 | padding: 40px 0;
17 | justify-content: center;
18 | }
19 |
20 | .session-wrapper {
21 | min-height: 100%;
22 | margin: 0 auto-3rem;
23 | &:after {
24 | content: "";
25 | display: table;
26 | clear: both;
27 | height: 3rem;
28 | }
29 | }
--------------------------------------------------------------------------------
/resources/assets/sass/modulos/_socialbuttons.scss:
--------------------------------------------------------------------------------
1 | $social-colors: (
2 | facebook: #3b5998,
3 | twitter: #00aced,
4 | googleplus: #dd4b39,
5 | github: #333333,
6 | linkedin: #007bb6,
7 | youtube: #bb0000,
8 | vimeo: #aad450,
9 | tumblr: #32506d,
10 | instagram: #517fa4,
11 | flickr: #ff0084,
12 | vk: #45668e,
13 | stumbleupon: #EB4823,
14 | yahoo: #7B0099
15 | ) !default;
16 |
17 | @each $media, $color in $social-colors {
18 | .btn-#{$media} {
19 | color: #fff;
20 | background-color: $color;
21 | cursor: inherit;
22 | &:hover {
23 | @include opacity(.8);
24 | }
25 | }
26 | }
--------------------------------------------------------------------------------
/resources/assets/sass/modulos/_width991.scss:
--------------------------------------------------------------------------------
1 | @media (max-width: 991px) {
2 | .sidebar-panel {
3 | position: absolute;
4 | z-index: 9999;
5 | width: 18rem;
6 | @include transform(translate3d(-100%, 0, 0));
7 | }
8 |
9 | .move-right .sidebar-panel > nav {
10 | @include transform(translateZ(0));
11 | }
12 |
13 | .offscreen {
14 | .sidebar-panel {
15 | @include transform(translateZ(0));
16 | }
17 | .off-canvas-overlay {
18 | display: block;
19 | visibility: visible;
20 | }
21 | }
22 |
23 | .off-canvas-overlay {
24 | background-color: rgba(0, 0, 0, 0.5) !important;
25 | }
26 |
27 | * {
28 | -webkit-overflow-scrolling: touch;
29 | }
30 |
31 | .sidebar-panel {
32 | z-index: 9999;
33 | width: 18rem;
34 | @include transform(translate3d(-100%, 0, 0));
35 | }
36 |
37 | .main-panel, .sidebar-panel .brand {
38 | width: 100%;
39 | }
40 |
41 | .main-panel, .sidebar-panel {
42 | position: absolute;
43 | @include transition(transform 0.2s cubic-bezier(0.7, 0, 0.3, 1));
44 | @include transition(transform 0.2s cubic-bezier(0.7, 0, 0.3, 1), -webkit-transform 0.2s cubic-bezier(0.7, 0, 0.3, 1));
45 | }
46 |
47 | .main-panel {
48 | position: relative;
49 | min-height: 100%;
50 | }
51 |
52 | .offscreen .sidebar-panel {
53 | @include transform(translateZ(0));
54 | width: 70% !important;
55 | }
56 | }
57 |
58 | @media (max-device-width: 480px) {
59 | .form-layout {
60 | width: 100%;
61 | }
62 | .navbar-heading {
63 | display: none !important;
64 | }
65 | }
--------------------------------------------------------------------------------
/resources/lang/en/auth.php:
--------------------------------------------------------------------------------
1 | 'These credentials do not match our records.',
17 | 'throttle' => 'Too many login attempts. Please try again in :seconds seconds.',
18 |
19 | ];
20 |
--------------------------------------------------------------------------------
/resources/lang/en/pagination.php:
--------------------------------------------------------------------------------
1 | '« Previous',
17 | 'next' => 'Next »',
18 |
19 | ];
20 |
--------------------------------------------------------------------------------
/resources/lang/en/passwords.php:
--------------------------------------------------------------------------------
1 | 'Passwords must be at least six characters and match the confirmation.',
17 | 'reset' => 'Your password has been reset!',
18 | 'sent' => 'We have e-mailed your password reset link!',
19 | 'token' => 'This password reset token is invalid.',
20 | 'user' => "We can't find a user with that e-mail address.",
21 |
22 | ];
23 |
--------------------------------------------------------------------------------
/resources/lang/pt_BR/auth.php:
--------------------------------------------------------------------------------
1 | 'Nos desculpe, mas, as informações de login não foram encontradas.',
17 | 'throttle' => 'Você realizou muitas tentativas de login. Por favor tente novamente em :seconds segundos.',
18 |
19 | ];
20 |
--------------------------------------------------------------------------------
/resources/lang/pt_BR/pagination.php:
--------------------------------------------------------------------------------
1 | '« Anterior',
15 | 'next' => 'Próxima »',
16 | ];
17 |
--------------------------------------------------------------------------------
/resources/lang/pt_BR/passwords.php:
--------------------------------------------------------------------------------
1 | 'A senha deve possuir no mínimo 6 caracteres e ser igual a confirmação, poderia verificar isso por favor?',
17 | 'reset' => 'Parabéns, a sua senha foi redefinida!',
18 | 'sent' => 'O link para redefinição de senha foi enviado para o seu e-mail, ok?',
19 | 'token' => 'Ops... O token para recuperação de senha é inválido.',
20 | 'user' => 'Ops... Infelizmente não encontramos nenhum usuário com esse endereço de e-mail!',
21 | ];
22 |
--------------------------------------------------------------------------------
/resources/laravolt/avatar/fonts/OpenSans-Bold.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/resources/laravolt/avatar/fonts/OpenSans-Bold.ttf
--------------------------------------------------------------------------------
/resources/laravolt/avatar/fonts/rockwell.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/drolean/Starter-Kit-Laravel/2fdf4510405fbfa2bb4a5c70b68913540c84b5d0/resources/laravolt/avatar/fonts/rockwell.ttf
--------------------------------------------------------------------------------
/resources/views/backend/internas/atividades.blade.php:
--------------------------------------------------------------------------------
1 | @extends('layouts.backend')
2 |
3 | @section('titulo')
4 | Atividades dos Usuários
5 | @endsection
6 |
7 | @section('conteudo')
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 | #
17 | Tipo
18 | Ação
19 | Data
20 | Usuário
21 | Descrição
22 |
23 |
24 |
25 |
26 | @foreach ($Atividades as $key => $Atividade)
27 |
28 | {{ $Atividade->id }}
29 | {{ $Atividade->content_type }}
30 | {{ $Atividade->acao }}
31 | {{ $Atividade->created_at->format('d.m.Y H:i:s') }}
32 | @if($Atividade->User){{ $Atividade->User->name }} @endif
33 | {{ $Atividade->descricao }}
34 |
35 | @endforeach
36 |
37 |
38 |
39 |
40 | @stop
--------------------------------------------------------------------------------
/resources/views/backend/internas/logs.blade.php:
--------------------------------------------------------------------------------
1 | @extends('layouts.backend')
2 |
3 | @section('titulo')
4 | Logs do Sistema
5 | @endsection
6 |
7 | @section('conteudo')
8 |
9 |
10 |
11 |
12 |
13 | @foreach ($Logs as $key => $Log)
14 |
15 |
{{ $Log['date'] }} ( {{ $Log['level'] }} )
16 |
17 | @if ($Log['stack'])
@endif
18 | {{ $Log['text'] }}
19 | @if (isset($Log['in_file']))
{{ $Log['in_file'] }}@endif
20 | @if ($Log['stack'])
{{ trim($Log['stack']) }}
@endif
21 |
22 |
23 | @endforeach
24 |
25 |
26 |
27 | @stop
28 |
--------------------------------------------------------------------------------
/resources/views/backend/internas/notificacoes.blade.php:
--------------------------------------------------------------------------------
1 | @extends('layouts.backend')
2 |
3 | @section('titulo')
4 | Lista de Notificações
5 | @endsection
6 |
7 | @section('conteudo')
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 | #
17 | Sender
18 | Receipt
19 | Enviado em
20 | Titulo
21 | Mensagem
22 |
23 |
24 |
25 |
26 | @foreach ($Notificacoes as $key => $Notification)
27 |
28 | {{ $Notification->id }}
29 | {{ $Notification->sender->name }}
30 | {{ $Notification->user->name }}
31 | {{ $Notification->created_at->format('d.m.Y H:i:s') }}
32 | {{ $Notification->titulo }}
33 | {{ $Notification->conteudo }}
34 |
35 | @endforeach
36 |
37 |
38 |
39 |
40 | @stop
41 |
--------------------------------------------------------------------------------
/resources/views/backend/no.blade.php:
--------------------------------------------------------------------------------
1 | @extends('layouts.backend')
2 |
3 | @section('titulo')
4 | Acesso não permitido
5 | @endsection
6 |
7 | @section('conteudo')
8 |
9 |
Acesso não permitido ou conta suspensa
10 |
11 | @stop
--------------------------------------------------------------------------------
/resources/views/backend/partials/chat.blade.php:
--------------------------------------------------------------------------------
1 |
2 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
--------------------------------------------------------------------------------
/resources/views/backend/partials/errors.blade.php:
--------------------------------------------------------------------------------
1 | @if ( count($errors) > 0 )
2 |
3 |
Whoops Ocorreu algum erro.
4 | @foreach ($errors->all() as $error)
5 |
{{ $error }}
6 | @endforeach
7 |
8 | @endif
9 |
10 | @if ( session('info') )
11 |
12 |
13 | ×
14 |
15 | {{ session('info') }}
16 |
17 | @endif
18 |
19 | @if ( session('warning') )
20 |
21 |
22 | ×
23 |
24 | {{ session('warning') }}
25 |
26 | @endif
27 |
28 | @if ( session('success') )
29 |
30 |
31 | ×
32 |
33 | {{ session('success') }}
34 |
35 | @endif
36 |
37 | @if ( session('error') )
38 |
39 |
40 | ×
41 |
42 | {{ session('error') }}
43 |
44 | @endif
45 |
46 | @if ( session('status') )
47 |
48 |
49 | ×
50 |
51 | {{ session('status') }}
52 |
53 | @endif
--------------------------------------------------------------------------------
/resources/views/backend/partials/helper.blade.php:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
11 |
12 |
13 |
14 |
15 | Não temos nada para mostrar agora!
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
--------------------------------------------------------------------------------
/resources/views/backend/partials/logged-in-as.blade.php:
--------------------------------------------------------------------------------
1 | @if (session()->has("admin_user_id"))
2 |
5 | @endif
--------------------------------------------------------------------------------
/resources/views/backend/partials/searchBar.blade.php:
--------------------------------------------------------------------------------
1 |
6 |
--------------------------------------------------------------------------------
/resources/views/backend/permissions/create.blade.php:
--------------------------------------------------------------------------------
1 | @extends('layouts.backend')
2 |
3 | @section('titulo')
4 | Lista de Permissões
5 | @endsection
6 |
7 | @section('conteudo')
8 |
9 |
20 |
21 |
22 |
39 |
40 |
41 |
42 | @stop
--------------------------------------------------------------------------------
/resources/views/backend/permissions/edit.blade.php:
--------------------------------------------------------------------------------
1 | @extends('layouts.backend')
2 |
3 | @section('titulo')
4 | Lista de Permissões
5 | @endsection
6 |
7 | @section('conteudo')
8 |
9 |
20 |
21 |
22 |
23 | {{ Form::model($Permissao, ['method' => 'PATCH', 'route' => ['admin.permissions.update', $Permissao], 'files' => true, 'class' => 'form-horizontal']) }}
24 |
25 |
26 | Nome
27 | {{ Form::text('name', old('name') , ['class' => 'form-control']) }}
28 |
29 |
30 |
31 | Label
32 | {{ Form::text('label', old('label') , ['class' => 'form-control']) }}
33 |
34 |
35 | Atualizar
36 |
37 |
38 |
39 | @stop
--------------------------------------------------------------------------------
/resources/views/backend/profile/atividades.blade.php:
--------------------------------------------------------------------------------
1 | @extends('layouts.backend')
2 |
3 | @section('titulo')
4 | Perfil do Usuário
5 | @endsection
6 |
7 | @section('conteudo')
8 |
9 |
10 | @include('backend.profile.nav')
11 |
12 |
13 |
29 |
30 |
31 | @stop
32 |
--------------------------------------------------------------------------------
/resources/views/backend/profile/logo.blade.php:
--------------------------------------------------------------------------------
1 | @extends('layouts.backend')
2 |
3 | @section('titulo')
4 | Alterar Logo da Empresa
5 | @endsection
6 |
7 | @section('conteudo')
8 |
9 |
10 | @include('backend.profile.nav')
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 | {{ Form::model(Auth::user(), ['method' => 'POST', 'route' => ['admin.profile.logo'], 'autocomplete' => 'off', 'files' => true]) }}
21 |
22 | Logo Image
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
Atualizar
31 |
32 |
33 |
34 |
35 |
36 |
37 | @stop
38 |
39 | @section('footer.script')
40 |
46 |
53 | @stop
--------------------------------------------------------------------------------
/resources/views/backend/profile/notificacoes.blade.php:
--------------------------------------------------------------------------------
1 | @extends('layouts.backend')
2 |
3 | @section('titulo')
4 | Perfil do Usuário
5 | @endsection
6 |
7 | @section('conteudo')
8 |
9 |
10 | @include('backend.profile.nav')
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 | @foreach (Auth::user()->notifications as $key => $Notification)
19 |
20 |
21 |
22 |
{{ $Notification->created_at->format('d.m.Y H:i:s') }}
23 |
24 |
{{ $Notification->data['body'] }}
25 | @if(!$Notification->read_at)
marcar como lida @endif
26 |
27 | @endforeach
28 |
29 |
30 |
31 |
32 |
33 |
34 | @stop
35 |
--------------------------------------------------------------------------------
/resources/views/backend/profile/password.blade.php:
--------------------------------------------------------------------------------
1 | @extends('layouts.backend')
2 |
3 | @section('titulo')
4 | Perfil do Usuário
5 | @endsection
6 |
7 | @section('conteudo')
8 |
9 |
10 | @include('backend.profile.nav')
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 | {{ Form::model(Auth::user(), ['method' => 'POST', 'route' => ['admin.profile.password'], 'autocomplete' => 'off']) }}
21 |
22 | {{ Form::label('old_password', 'Senha Atual') }}
23 | {{ Form::password('old_password', ['class' => 'form-control', 'autocomplete' => 'off']) }}
24 |
25 |
26 |
27 | {{ Form::label('password', 'Nova Senha') }}
28 | {{ Form::password('password', ['class' => 'form-control', 'autocomplete' => 'off']) }}
29 |
30 |
31 |
32 | {{ Form::label('password_confirmation', 'Confirmar Nova Senha') }}
33 | {{ Form::password('password_confirmation', ['class' => 'form-control', 'autocomplete' => 'off']) }}
34 |
35 |
36 |
Atualizar
37 |
38 |
39 |
40 |
41 |
42 |
43 | @stop
--------------------------------------------------------------------------------
/resources/views/backend/tickets/create.blade.php:
--------------------------------------------------------------------------------
1 | @extends('layouts.backend')
2 |
3 | @section('titulo')
4 | Abrir Chamado
5 | @endsection
6 |
7 | @section('conteudo')
8 |
9 |
20 |
21 |
22 |
53 | @stop
--------------------------------------------------------------------------------
/resources/views/backend/usuarios/create.blade.php:
--------------------------------------------------------------------------------
1 | @extends('layouts.backend')
2 |
3 | @section('titulo')
4 | Criar novo Usuário
5 | @endsection
6 |
7 | @section('conteudo')
8 |
52 | @stop
--------------------------------------------------------------------------------
/resources/views/emails/companie/new.blade.php:
--------------------------------------------------------------------------------
1 | @extends('layouts.email')
2 |
3 | @section('conteudo')
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
Empresa cadastrada em {{ $companie->created_at->format('d/m/Y H:i:s') }}
12 |
13 |
14 | Empresa: {{ $companie->empresa }}
15 | CNPJ: {{ $companie->cnpj }}
16 | Telefone: {{ $companie->telefone }}
17 | Endereço: {{ $companie->endereco }}
18 |
19 | Usuario: {{ $user->name }}
20 | Email: {{ $user->email }}
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 | @stop
--------------------------------------------------------------------------------
/resources/views/emails/tickets/closed.blade.php:
--------------------------------------------------------------------------------
1 | @extends('layouts.email')
2 |
3 | @section('conteudo')
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
Ticket fechado em {{ config('app.name') }}
12 |
13 |
14 | Titulo: {{ $ticket->titulo }}
15 | Descrição: {{ $ticket->descricao }}
16 | Tipo: {{ $ticket->tipo }}
17 | Aberto por: {{ $user->name }} ({{ $ticket->created_at->format('d/m/Y H:i:s') }})
18 |
19 | @foreach($comentarios as $comentario)
20 |
21 |
22 | Resposta: {{ $comentario->comentario }}
23 | Por: {{ $comentario->user->name }}
24 | Data: {{ $comentario->created_at->format('d/m/Y H:i:s') }}
25 |
26 | @endforeach
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 | @stop
--------------------------------------------------------------------------------
/resources/views/emails/tickets/new.blade.php:
--------------------------------------------------------------------------------
1 | @extends('layouts.email')
2 |
3 | @section('conteudo')
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
Ticket aberto em {{ config('app.name') }}
12 |
13 |
14 | Titulo: {{ $ticket->titulo }}
15 | Descrição: {{ $ticket->descricao }}
16 | Tipo: {{ $ticket->tipo }}
17 | Aberto por: {{ $user->name }}
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 | @stop
--------------------------------------------------------------------------------
/resources/views/emails/tickets/reply.blade.php:
--------------------------------------------------------------------------------
1 | @extends('layouts.email')
2 |
3 | @section('conteudo')
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
Ticket respondido em {{ config('app.name') }}
12 |
13 |
14 | Titulo: {{ $ticket->titulo }}
15 | Descrição: {{ $ticket->descricao }}
16 | Resposta: {{ $comentario->comentario }}
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 | @stop
--------------------------------------------------------------------------------
/resources/views/errors/403.blade.php:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 | Error 403 - Forbidden
9 |
10 |
11 |
12 |
13 |
14 |
45 |
46 |
47 |
48 |
49 |
Unn
50 |
Server Error: 403 (Forbidden)
51 |
52 |
O que isto significa?
53 | @if (session()->has('nop'))
54 | {{ session()->get('nop') }}
55 | @else
56 |
Você não tem as credenciais certas para ver a página solicitada.
57 |
58 | Talvez você gostaria de ir para a página inicial ?
59 |
60 | @endif
61 |
62 |
63 |
64 |
65 |
--------------------------------------------------------------------------------
/resources/views/errors/429.blade.php:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 | Error 429 - Too Many Attempts
9 |
10 |
11 |
12 |
13 |
14 |
45 |
46 |
47 |
48 |
49 |
Server Error: 429 (Too Many Attempts)
50 |
51 |
O que isto significa?
52 |
53 | Você fez muitas solicitações para a mesma página, e agora você terá que esperar por {{ (isset($retryAfter)) ? $retryAfter : '1 minuto' }} antes de acessar essa página novamente.
54 |
55 |
56 |
57 |
58 |
59 |
--------------------------------------------------------------------------------
/resources/views/errors/500.blade.php:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Desculpe...
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 | {{ config('app.name') }}
14 |
15 |
16 | Desculpe...
17 |
18 |
19 |
20 |
21 |
22 |
23 |
Pedimos desculpas...
24 |
... estamos passando por uma instabilidade em nosso site.
25 |
26 |
29 |
30 |
--------------------------------------------------------------------------------
/resources/views/errors/503.blade.php:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 | Volto logo
9 |
10 |
11 |
12 |
13 |
14 |
57 |
58 |
59 |
60 |
61 |
62 | Volto logo
63 |
64 |
65 |
66 |
{{ json_decode(file_get_contents(storage_path('framework/down')), true)['message'] }}
67 | Pedimos desculpas...
68 | ... estamos passando por uma instabilidade em nosso site.
69 |
70 |
71 |
72 |
73 |
74 |
--------------------------------------------------------------------------------
/resources/views/vendor/mail/html/button.blade.php:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/resources/views/vendor/mail/html/footer.blade.php:
--------------------------------------------------------------------------------
1 |
2 |
3 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/resources/views/vendor/mail/html/header.blade.php:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
--------------------------------------------------------------------------------
/resources/views/vendor/mail/html/layout.blade.php:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
25 |
26 |
27 |
28 |
29 |
30 | {{ $header or '' }}
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 | {{ Illuminate\Mail\Markdown::parse($slot) }}
40 |
41 | {{ $subcopy or '' }}
42 |
43 |
44 |
45 |
46 |
47 |
48 | {{ $footer or '' }}
49 |
50 |
51 |
52 |
53 |
54 |
55 |
--------------------------------------------------------------------------------
/resources/views/vendor/mail/html/message.blade.php:
--------------------------------------------------------------------------------
1 | @component('mail::layout')
2 | {{-- Header --}}
3 | @slot('header')
4 | @component('mail::header', ['url' => config('app.url')])
5 | {{ config('app.name') }}
6 | @endcomponent
7 | @endslot
8 |
9 | {{-- Body --}}
10 | {{ $slot }}
11 |
12 | {{-- Subcopy --}}
13 | @if (isset($subcopy))
14 | @slot('subcopy')
15 | @component('mail::subcopy')
16 | {{ $subcopy }}
17 | @endcomponent
18 | @endslot
19 | @endif
20 |
21 | {{-- Footer --}}
22 | @slot('footer')
23 | @component('mail::footer')
24 | © {{ date('Y') }} {{ config('app.name') }}. All rights reserved.
25 | @endcomponent
26 | @endslot
27 | @endcomponent
28 |
--------------------------------------------------------------------------------
/resources/views/vendor/mail/html/panel.blade.php:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | {{ Illuminate\Mail\Markdown::parse($slot) }}
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/resources/views/vendor/mail/html/promotion.blade.php:
--------------------------------------------------------------------------------
1 |
8 |
--------------------------------------------------------------------------------
/resources/views/vendor/mail/html/promotion/button.blade.php:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/resources/views/vendor/mail/html/subcopy.blade.php:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | {{ Illuminate\Mail\Markdown::parse($slot) }}
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/resources/views/vendor/mail/html/table.blade.php:
--------------------------------------------------------------------------------
1 |
2 | {{ Illuminate\Mail\Markdown::parse($slot) }}
3 |
4 |
--------------------------------------------------------------------------------
/resources/views/vendor/mail/markdown/button.blade.php:
--------------------------------------------------------------------------------
1 | {{ $slot }}: {{ $url }}
2 |
--------------------------------------------------------------------------------
/resources/views/vendor/mail/markdown/footer.blade.php:
--------------------------------------------------------------------------------
1 | {{ $slot }}
2 |
--------------------------------------------------------------------------------
/resources/views/vendor/mail/markdown/header.blade.php:
--------------------------------------------------------------------------------
1 | [{{ $slot }}]({{ $url }})
2 |
--------------------------------------------------------------------------------
/resources/views/vendor/mail/markdown/layout.blade.php:
--------------------------------------------------------------------------------
1 | {!! strip_tags($header) !!}
2 |
3 | {!! strip_tags($slot) !!}
4 | @if (isset($subcopy))
5 |
6 | {!! strip_tags($subcopy) !!}
7 | @endif
8 |
9 | {!! strip_tags($footer) !!}
10 |
--------------------------------------------------------------------------------
/resources/views/vendor/mail/markdown/message.blade.php:
--------------------------------------------------------------------------------
1 | @component('mail::layout')
2 | {{-- Header --}}
3 | @slot('header')
4 | @component('mail::header', ['url' => config('app.url')])
5 | {{ config('app.name') }}
6 | @endcomponent
7 | @endslot
8 |
9 | {{-- Body --}}
10 | {{ $slot }}
11 |
12 | {{-- Subcopy --}}
13 | @if (isset($subcopy))
14 | @slot('subcopy')
15 | @component('mail::subcopy')
16 | {{ $subcopy }}
17 | @endcomponent
18 | @endslot
19 | @endif
20 |
21 | {{-- Footer --}}
22 | @slot('footer')
23 | @component('mail::footer')
24 | © {{ date('Y') }} {{ config('app.name') }}. All rights reserved.
25 | @endcomponent
26 | @endslot
27 | @endcomponent
28 |
--------------------------------------------------------------------------------
/resources/views/vendor/mail/markdown/panel.blade.php:
--------------------------------------------------------------------------------
1 | {{ $slot }}
2 |
--------------------------------------------------------------------------------
/resources/views/vendor/mail/markdown/promotion.blade.php:
--------------------------------------------------------------------------------
1 | {{ $slot }}
2 |
--------------------------------------------------------------------------------
/resources/views/vendor/mail/markdown/promotion/button.blade.php:
--------------------------------------------------------------------------------
1 | [{{ $slot }}]({{ $url }})
2 |
--------------------------------------------------------------------------------
/resources/views/vendor/mail/markdown/subcopy.blade.php:
--------------------------------------------------------------------------------
1 | {{ $slot }}
2 |
--------------------------------------------------------------------------------
/resources/views/vendor/mail/markdown/table.blade.php:
--------------------------------------------------------------------------------
1 | {{ $slot }}
2 |
--------------------------------------------------------------------------------
/resources/views/vendor/notifications/email.blade.php:
--------------------------------------------------------------------------------
1 | @component('mail::message')
2 | {{-- Greeting --}}
3 | @if (! empty($greeting))
4 | # {{ $greeting }}
5 | @else
6 | @if ($level == 'error')
7 | # Whoops!
8 | @else
9 | # Ola!
10 | @endif
11 | @endif
12 |
13 | {{-- Intro Lines --}}
14 | @foreach ($introLines as $line)
15 | {{ $line }}
16 |
17 | @endforeach
18 |
19 | {{-- Action Button --}}
20 | @if (isset($actionText))
21 |
33 | @component('mail::button', ['url' => $actionUrl, 'color' => $color])
34 | {{ $actionText }}
35 | @endcomponent
36 | @endif
37 |
38 | {{-- Outro Lines --}}
39 | @foreach ($outroLines as $line)
40 | {{ $line }}
41 |
42 | @endforeach
43 |
44 |
45 | @if (! empty($salutation))
46 | {{ $salutation }}
47 | @else
48 | Atenciosamente, {{ config('app.name') }}
49 | @endif
50 |
51 |
52 | @if (isset($actionText))
53 | @component('mail::subcopy')
54 | Se tiver problemas ao clicar no botão "{{ $actionText }}", copie e cole o URL abaixo
55 | em seu navegador da Web: [{{ $actionUrl }}]({{ $actionUrl }})
56 | @endcomponent
57 | @endif
58 | @endcomponent
59 |
--------------------------------------------------------------------------------
/resources/views/vendor/pagination/bootstrap-4.blade.php:
--------------------------------------------------------------------------------
1 | @if ($paginator->hasPages())
2 |
3 |
37 |
38 | @endif
39 |
--------------------------------------------------------------------------------
/resources/views/vendor/pagination/default.blade.php:
--------------------------------------------------------------------------------
1 | @if ($paginator->hasPages())
2 |
36 | @endif
37 |
--------------------------------------------------------------------------------
/resources/views/vendor/pagination/simple-bootstrap-4.blade.php:
--------------------------------------------------------------------------------
1 | @if ($paginator->hasPages())
2 |
17 | @endif
18 |
--------------------------------------------------------------------------------
/resources/views/vendor/pagination/simple-default.blade.php:
--------------------------------------------------------------------------------
1 | @if ($paginator->hasPages())
2 |
17 | @endif
18 |
--------------------------------------------------------------------------------
/resources/views/welcome.blade.php:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 | Starter KIT
9 |
10 |
11 |
12 |
13 |
14 |
50 |
51 |
52 |
53 |
54 |
55 | Starter APP
56 |
57 |
58 |
59 |
60 |
61 |
--------------------------------------------------------------------------------
/routes/api.php:
--------------------------------------------------------------------------------
1 | get('/user', function (Request $request) {
17 | return $request->user();
18 | });
19 |
--------------------------------------------------------------------------------
/routes/channels.php:
--------------------------------------------------------------------------------
1 | id === (int) $id;
16 | });
17 |
18 | Broadcast::channel('chat', function ($user) {
19 | return Auth::check();
20 | });
21 |
--------------------------------------------------------------------------------
/routes/console.php:
--------------------------------------------------------------------------------
1 | name('auth.login');
18 | Route::post('auth/login', 'Auth\LoginController@login')->name('auth.login');
19 | Route::post('auth/logout', 'Auth\LoginController@logout')->name('auth.logout');
20 | Route::get('auth/logout', 'Auth\LoginController@logout')->name('auth.logout');
21 | Route::get('auth/activation/{token}', 'Auth\LoginController@activation')->name('auth.activation');
22 | Route::get('auth/2fa', 'Auth\LoginController@valida2Fa')->name('auth.valida2fa');
23 | Route::post('auth/2fa', ['middleware' => 'throttle:5', 'uses' => 'Auth\LoginController@postvalida2Fa'])->name('auth.valida2fa');
24 | Route::get('auth/{provider}', 'Auth\LoginController@redirectToProvider')->name('auth.provider');
25 | Route::get('auth/{provider}/callback', 'Auth\LoginController@handleProviderCallback')->name('auth.provider.callback');
26 |
27 | /*! Password Reset Email */
28 | Route::get('password/email', 'Auth\ForgotPasswordController@showLinkRequestForm')->name('password.email');
29 | Route::post('password/email', 'Auth\ForgotPasswordController@sendResetLinkEmail')->name('password.email');
30 | Route::get('password/reset/{token}', 'Auth\ResetPasswordController@showResetForm')->name('password.reset');
31 | Route::post('password/reset', 'Auth\ResetPasswordController@reset');
32 |
33 | /*! ROTAS DO FRONTEND */
34 | Route::group(['namespace' => 'Frontend'], function () {
35 | Route::get('/', ['as' => 'home', 'uses' => 'FrontendController@index']);
36 | Route::get('/images/{folder}/{filename?}', 'FrontendController@getAvatar');
37 | Route::get('/manifest.json', 'FrontendController@getManifest');
38 | });
39 |
--------------------------------------------------------------------------------
/server.php:
--------------------------------------------------------------------------------
1 |
7 | */
8 | $uri = urldecode(
9 | parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH)
10 | );
11 |
12 | // This file allows us to emulate Apache's "mod_rewrite" functionality from the
13 | // built-in PHP web server. This provides a convenient way to test a Laravel
14 | // application without having installed a "real" web server software here.
15 | if ($uri !== '/' && file_exists(__DIR__.'/public'.$uri)) {
16 | return false;
17 | }
18 |
19 | require_once __DIR__.'/public/index.php';
20 |
--------------------------------------------------------------------------------
/storage/app/.gitignore:
--------------------------------------------------------------------------------
1 | *
2 | !public/
3 | !.gitignore
4 |
--------------------------------------------------------------------------------
/storage/app/public/.gitignore:
--------------------------------------------------------------------------------
1 | *
2 | !.gitignore
3 |
--------------------------------------------------------------------------------
/storage/debugbar/.gitignore:
--------------------------------------------------------------------------------
1 | *
2 | !.gitignore
--------------------------------------------------------------------------------
/storage/framework/.gitignore:
--------------------------------------------------------------------------------
1 | config.php
2 | routes.php
3 | schedule-*
4 | compiled.php
5 | services.json
6 | events.scanned.php
7 | routes.scanned.php
8 | down
9 |
--------------------------------------------------------------------------------
/storage/framework/cache/.gitignore:
--------------------------------------------------------------------------------
1 | *
2 | !.gitignore
3 |
--------------------------------------------------------------------------------
/storage/framework/sessions/.gitignore:
--------------------------------------------------------------------------------
1 | *
2 | !.gitignore
3 |
--------------------------------------------------------------------------------
/storage/framework/views/.gitignore:
--------------------------------------------------------------------------------
1 | *
2 | !.gitignore
3 |
--------------------------------------------------------------------------------
/storage/logs/.gitignore:
--------------------------------------------------------------------------------
1 | *
2 | !.gitignore
3 |
--------------------------------------------------------------------------------
/tests/Browser/Pages/HomePage.php:
--------------------------------------------------------------------------------
1 | '#selector',
39 | ];
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/tests/Browser/Pages/Page.php:
--------------------------------------------------------------------------------
1 | '#selector',
18 | ];
19 | }
20 | }
21 |
--------------------------------------------------------------------------------
/tests/Browser/console/.gitignore:
--------------------------------------------------------------------------------
1 | *
2 | !.gitignore
3 |
--------------------------------------------------------------------------------
/tests/Browser/screenshots/.gitignore:
--------------------------------------------------------------------------------
1 | *
2 | !.gitignore
3 |
--------------------------------------------------------------------------------
/tests/CreatesApplication.php:
--------------------------------------------------------------------------------
1 | make(Kernel::class)->bootstrap();
19 |
20 | return $app;
21 | }
22 | }
23 |
--------------------------------------------------------------------------------
/tests/DuskTestCase.php:
--------------------------------------------------------------------------------
1 | uri()) && in_array('GET', $route->methods()) && ! in_array($route->uri(), $blacklist)) {
33 | $response = $this->call('GET', $route->uri());
34 | fwrite(STDERR, print_r("[ ] Test => {$response->getStatusCode()} [ ".$route->uri()."\n", true));
35 | $this->assertNotEquals(500, $response->getStatusCode(), $route->uri().' => failed to load');
36 | }
37 | }
38 | }
39 | }
40 |
--------------------------------------------------------------------------------
/tests/TestCase.php:
--------------------------------------------------------------------------------
1 | assertTrue(true);
17 | }
18 | }
19 |
--------------------------------------------------------------------------------
/webpack.mix.js:
--------------------------------------------------------------------------------
1 | const { mix } = require('laravel-mix');
2 |
3 | /*
4 | |--------------------------------------------------------------------------
5 | | Mix Asset Management
6 | |--------------------------------------------------------------------------
7 | |
8 | | Mix provides a clean, fluent API for defining some Webpack build steps
9 | | for your Laravel application. By default, we are compiling the Sass
10 | | file for the application as well as bundling up all the JS files.
11 | |
12 | */
13 |
14 | mix.autoload({})
15 |
16 | // Base Directories
17 | var npm = 'node_modules/';
18 |
19 | // CSS
20 | mix.sass('resources/assets/sass/app.scss', 'public/static/css/app.css').version();
21 |
22 | // JS
23 | mix.js('resources/assets/js/app.js', 'public/static/js/app.js').version();
24 |
25 | // Vue
26 | mix.js('resources/assets/js/dashboard.js', 'public/static/js').version();
27 |
--------------------------------------------------------------------------------