Commit 56a1a44c authored by Viral Solani's avatar Viral Solani
parents ffae1c31 94d956e6
APP_NAME=Laravel APP_NAME="Laravel Admin Panel"
APP_ENV=local APP_ENV=local
APP_KEY=base64:O+TrollIDwasHEREtMG9kBc+/Q32exQLusNVhnq558w= APP_KEY=base64:O+TrollIDwasHEREtMG9kBc+/Q32exQLusNVhnq558w=
APP_DEBUG=true APP_DEBUG=true
......
...@@ -99,13 +99,13 @@ Password: `1234` ...@@ -99,13 +99,13 @@ Password: `1234`
## ScreenShots ## ScreenShots
## Dashboard ## Dashboard
![Screenshot](screenshots/dashboard_sc.png) ![Screenshot](screenshots/dashboard.png)
## User Listing ## User Listing
![Screenshot](screenshots/users_sc.png) ![Screenshot](screenshots/users.png)
## Settings ## Settings
![Screenshot](screenshots/settings_sc.png) ![Screenshot](screenshots/settings.png)
## Issues ## Issues
......
...@@ -15,4 +15,5 @@ require __DIR__.'/Blog_Category.php'; ...@@ -15,4 +15,5 @@ require __DIR__.'/Blog_Category.php';
require __DIR__.'/Blog_Tag.php'; require __DIR__.'/Blog_Tag.php';
require __DIR__.'/Blog_Management.php'; require __DIR__.'/Blog_Management.php';
require __DIR__.'/Faqs.php'; require __DIR__.'/Faqs.php';
require __DIR__.'/Menu.php';
require __DIR__.'/LogViewer.php'; require __DIR__.'/LogViewer.php';
<?php
Breadcrumbs::register('admin.menus.index', function ($breadcrumbs) {
$breadcrumbs->parent('admin.dashboard');
$breadcrumbs->push(trans('menus.backend.menus.management'), route('admin.menus.index'));
});
Breadcrumbs::register('admin.menus.create', function ($breadcrumbs) {
$breadcrumbs->parent('admin.menus.index');
$breadcrumbs->push(trans('menus.backend.menus.create'), route('admin.menus.create'));
});
Breadcrumbs::register('admin.menus.edit', function ($breadcrumbs, $id) {
$breadcrumbs->parent('admin.menus.index');
$breadcrumbs->push(trans('menus.backend.menus.edit'), route('admin.menus.edit', $id));
});
...@@ -22,7 +22,7 @@ class BlogsController extends Controller ...@@ -22,7 +22,7 @@ class BlogsController extends Controller
protected $status = [ protected $status = [
'Published' => 'Published', 'Published' => 'Published',
'Draft' => 'Draft', 'Draft' => 'Draft',
'Inactive' => 'Inactive', 'InActive' => 'InActive',
'Scheduled' => 'Scheduled', 'Scheduled' => 'Scheduled',
]; ];
......
...@@ -44,12 +44,6 @@ class DashboardController extends Controller ...@@ -44,12 +44,6 @@ class DashboardController extends Controller
$user = User::find($userId); $user = User::find($userId);
$user->first_name = $input['first_name']; $user->first_name = $input['first_name'];
$user->last_name = $input['last_name']; $user->last_name = $input['last_name'];
$user->address = $input['address'];
$user->state_id = $input['state_id'];
$user->country_id = config('access.constants.default_country');
$user->city_id = $input['city_id'];
$user->zip_code = $input['zip_code'];
$user->ssn = $input['ssn'];
$user->updated_by = access()->user()->id; $user->updated_by = access()->user()->id;
if ($user->save()) { if ($user->save()) {
......
...@@ -14,13 +14,10 @@ use Illuminate\Http\Request; ...@@ -14,13 +14,10 @@ use Illuminate\Http\Request;
*/ */
class SettingsController extends Controller class SettingsController extends Controller
{ {
/**
* @var SettingsRepository
*/
protected $settings; protected $settings;
/** /**
* @param SettingsRepository $settings * @param \App\Repositories\Backend\Settings\SettingsRepository $settings
*/ */
public function __construct(SettingsRepository $settings) public function __construct(SettingsRepository $settings)
{ {
...@@ -28,8 +25,8 @@ class SettingsController extends Controller ...@@ -28,8 +25,8 @@ class SettingsController extends Controller
} }
/** /**
* @param Setting $setting * @param \App\Models\Settings\Setting $setting
* @param ManageEmailTemplatesRequest $request * @param \App\Http\Requests\Backend\Settings\ManageSettingsRequest $request
* *
* @return mixed * @return mixed
*/ */
...@@ -40,16 +37,18 @@ class SettingsController extends Controller ...@@ -40,16 +37,18 @@ class SettingsController extends Controller
} }
/** /**
* @param Setting $setting * @param \App\Models\Settings\Setting $setting
* @param UpdateEmailTemplatesRequest $request * @param \App\Http\Requests\Backend\Settings\UpdateSettingsRequest $request
* *
* @return mixed * @return mixed
*/ */
public function update(Setting $setting, UpdateSettingsRequest $request) public function update(Setting $setting, UpdateSettingsRequest $request)
{ {
$this->settings->update($setting, $request->all()); $this->settings->update($setting, $request->except(['_token', '_method']));
return redirect()->route('admin.settings.edit', $setting->id)->withFlashSuccess(trans('alerts.backend.settings.updated')); return redirect()
->route('admin.settings.edit', $setting->id)
->with('flash_success', trans('alerts.backend.settings.updated'));
} }
/** /**
......
...@@ -3,7 +3,6 @@ ...@@ -3,7 +3,6 @@
namespace App\Http\Requests\Backend\Settings; namespace App\Http\Requests\Backend\Settings;
use App\Http\Requests\Request; use App\Http\Requests\Request;
use App\Models\Settings\Setting;
/** /**
* Class UpdateSettingsRequest. * Class UpdateSettingsRequest.
...@@ -27,25 +26,9 @@ class UpdateSettingsRequest extends Request ...@@ -27,25 +26,9 @@ class UpdateSettingsRequest extends Request
*/ */
public function rules() public function rules()
{ {
$data = Setting::find(1);
$checkLogo = $data->logo;
$checkFavicon = $data->favicon;
if (!empty($checkLogo)) {
$logoValidation = 'image|dimensions:min_width=226,min_height=48';
} else {
$logoValidation = 'required|image|dimensions:min_width=226,min_height=48';
}
if (!empty($checkFavicon)) {
$faviconValidation = 'mimes:jpg,jpeg,png,ico|dimensions:width=16,height=16';
} else {
$faviconValidation = 'required|mimes:jpg,jpeg,png,ico|dimensions:width=16,height=16';
}
return [ return [
'logo' => $logoValidation, 'logo' => 'image|dimensions:min_width=226,min_height=48',
'favicon' => $faviconValidation, 'favicon' => 'mimes:jpg,jpeg,png,ico|dimensions:width=16,height=16',
'from_name' => 'required',
'from_email' => 'required',
]; ];
} }
...@@ -58,11 +41,7 @@ class UpdateSettingsRequest extends Request ...@@ -58,11 +41,7 @@ class UpdateSettingsRequest extends Request
{ {
return [ return [
'logo.dimensions' => 'Invalid logo - should be minimum 226*48', 'logo.dimensions' => 'Invalid logo - should be minimum 226*48',
'favicon.dimensions' => 'Invalid icon - should be 16*16', 'favicon.dimensions' => 'Invalid favicon - should be 16*16',
'logo.required' => 'The logo field is required in seo settings.',
'favicon.required' => 'The favicon field is required in seo settings.',
'from_name.required' => 'The from name field is required in mail settings.',
'from_email.required' => 'The from email field is required in mail settings.',
]; ];
} }
} }
...@@ -372,6 +372,11 @@ trait UserAttribute ...@@ -372,6 +372,11 @@ trait UserAttribute
return $button; return $button;
} }
public function getNameAttribute()
{
return $this->first_name.' '.$this->last_name;
}
/** /**
* @return string * @return string
*/ */
......
...@@ -5,7 +5,6 @@ namespace App\Repositories\Backend\Settings; ...@@ -5,7 +5,6 @@ namespace App\Repositories\Backend\Settings;
use App\Exceptions\GeneralException; use App\Exceptions\GeneralException;
use App\Models\Settings\Setting; use App\Models\Settings\Setting;
use App\Repositories\BaseRepository; use App\Repositories\BaseRepository;
use DB;
/** /**
* Class SettingsRepository. * Class SettingsRepository.
...@@ -18,19 +17,15 @@ class SettingsRepository extends BaseRepository ...@@ -18,19 +17,15 @@ class SettingsRepository extends BaseRepository
const MODEL = Setting::class; const MODEL = Setting::class;
/** /**
* @param Model $permission * @param \App\Models\Settings\Setting $setting
* @param $input * @param $input
* *
* @throws GeneralException * @throws \App\Exceptions\GeneralException
* *
* return bool * return bool
*/ */
public function update(Model $setting, array $input) public function update(Setting $setting, array $input)
{ {
// Unsetting method and token values from array
unset($input['_method']);
unset($input['_token']);
if (isset($input['logo'])) { if (isset($input['logo'])) {
$image_upload = $this->uploadlogoimage($setting, $input['logo']); $image_upload = $this->uploadlogoimage($setting, $input['logo']);
$input['logo'] = $image_upload; $input['logo'] = $image_upload;
...@@ -41,13 +36,11 @@ class SettingsRepository extends BaseRepository ...@@ -41,13 +36,11 @@ class SettingsRepository extends BaseRepository
$input['favicon'] = $image_upload; $input['favicon'] = $image_upload;
} }
DB::transaction(function () use ($setting, $input) { if ($setting->update($input)) {
if ($setting->update($input)) { return true;
return true; }
}
throw new GeneralException(trans('exceptions.backend.settings.update_error')); throw new GeneralException(trans('exceptions.backend.settings.update_error'));
});
} }
/* /*
......
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
}, },
"require-dev": { "require-dev": {
"barryvdh/laravel-debugbar": "^3.0", "barryvdh/laravel-debugbar": "^3.0",
"bvipul/generator": "v0.9.1", "bvipul/generator": "^0.9.1",
"filp/whoops": "~2.0", "filp/whoops": "~2.0",
"fzaninotto/faker": "~1.4", "fzaninotto/faker": "~1.4",
"mockery/mockery": "0.9.*", "mockery/mockery": "0.9.*",
...@@ -37,7 +37,8 @@ ...@@ -37,7 +37,8 @@
"autoload": { "autoload": {
"classmap": [ "classmap": [
"database/seeds", "database/seeds",
"database/factories" "database/factories",
"database"
], ],
"psr-4": { "psr-4": {
"App\\": "app/" "App\\": "app/"
...@@ -51,8 +52,7 @@ ...@@ -51,8 +52,7 @@
"Tests\\": "tests/" "Tests\\": "tests/"
}, },
"classmap": [ "classmap": [
"tests/TestCase.php", "tests/TestCase.php"
"tests/BrowserKitTestCase.php"
] ]
}, },
"scripts": { "scripts": {
......
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
"This file is @generated automatically" "This file is @generated automatically"
], ],
"content-hash": "eaf124ce6ebcd97eb723b03a582b2f3c", "content-hash": "28f4a8afe279c0e13e3e7bdb7cd3d0be",
"packages": [ "packages": [
{ {
"name": "arcanedev/log-viewer", "name": "arcanedev/log-viewer",
...@@ -331,16 +331,16 @@ ...@@ -331,16 +331,16 @@
}, },
{ {
"name": "doctrine/annotations", "name": "doctrine/annotations",
"version": "v1.5.0", "version": "v1.6.0",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/doctrine/annotations.git", "url": "https://github.com/doctrine/annotations.git",
"reference": "5beebb01b025c94e93686b7a0ed3edae81fe3e7f" "reference": "c7f2050c68a9ab0bdb0f98567ec08d80ea7d24d5"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/doctrine/annotations/zipball/5beebb01b025c94e93686b7a0ed3edae81fe3e7f", "url": "https://api.github.com/repos/doctrine/annotations/zipball/c7f2050c68a9ab0bdb0f98567ec08d80ea7d24d5",
"reference": "5beebb01b025c94e93686b7a0ed3edae81fe3e7f", "reference": "c7f2050c68a9ab0bdb0f98567ec08d80ea7d24d5",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
...@@ -349,12 +349,12 @@ ...@@ -349,12 +349,12 @@
}, },
"require-dev": { "require-dev": {
"doctrine/cache": "1.*", "doctrine/cache": "1.*",
"phpunit/phpunit": "^5.7" "phpunit/phpunit": "^6.4"
}, },
"type": "library", "type": "library",
"extra": { "extra": {
"branch-alias": { "branch-alias": {
"dev-master": "1.5.x-dev" "dev-master": "1.6.x-dev"
} }
}, },
"autoload": { "autoload": {
...@@ -395,7 +395,7 @@ ...@@ -395,7 +395,7 @@
"docblock", "docblock",
"parser" "parser"
], ],
"time": "2017-07-22T10:58:02+00:00" "time": "2017-12-06T07:11:42+00:00"
}, },
{ {
"name": "doctrine/cache", "name": "doctrine/cache",
...@@ -1367,16 +1367,16 @@ ...@@ -1367,16 +1367,16 @@
}, },
{ {
"name": "laravel/framework", "name": "laravel/framework",
"version": "v5.5.24", "version": "v5.5.25",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/laravel/framework.git", "url": "https://github.com/laravel/framework.git",
"reference": "06135405bb1f736dac5e9529ed1541fc446c9c0f" "reference": "0a5b6112f325c56ae5a6679c08a0a10723153fe0"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/laravel/framework/zipball/06135405bb1f736dac5e9529ed1541fc446c9c0f", "url": "https://api.github.com/repos/laravel/framework/zipball/0a5b6112f325c56ae5a6679c08a0a10723153fe0",
"reference": "06135405bb1f736dac5e9529ed1541fc446c9c0f", "reference": "0a5b6112f325c56ae5a6679c08a0a10723153fe0",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
...@@ -1456,6 +1456,7 @@ ...@@ -1456,6 +1456,7 @@
"guzzlehttp/guzzle": "Required to use the Mailgun and Mandrill mail drivers and the ping methods on schedules (~6.0).", "guzzlehttp/guzzle": "Required to use the Mailgun and Mandrill mail drivers and the ping methods on schedules (~6.0).",
"laravel/tinker": "Required to use the tinker console command (~1.0).", "laravel/tinker": "Required to use the tinker console command (~1.0).",
"league/flysystem-aws-s3-v3": "Required to use the Flysystem S3 driver (~1.0).", "league/flysystem-aws-s3-v3": "Required to use the Flysystem S3 driver (~1.0).",
"league/flysystem-cached-adapter": "Required to use Flysystem caching (~1.0).",
"league/flysystem-rackspace": "Required to use the Flysystem Rackspace driver (~1.0).", "league/flysystem-rackspace": "Required to use the Flysystem Rackspace driver (~1.0).",
"nexmo/client": "Required to use the Nexmo transport (~1.0).", "nexmo/client": "Required to use the Nexmo transport (~1.0).",
"pda/pheanstalk": "Required to use the beanstalk queue driver (~3.0).", "pda/pheanstalk": "Required to use the beanstalk queue driver (~3.0).",
...@@ -1496,7 +1497,7 @@ ...@@ -1496,7 +1497,7 @@
"framework", "framework",
"laravel" "laravel"
], ],
"time": "2017-12-07T01:28:21+00:00" "time": "2017-12-11T14:59:28+00:00"
}, },
{ {
"name": "laravel/socialite", "name": "laravel/socialite",
...@@ -2367,16 +2368,16 @@ ...@@ -2367,16 +2368,16 @@
}, },
{ {
"name": "psy/psysh", "name": "psy/psysh",
"version": "v0.8.15", "version": "v0.8.16",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/bobthecow/psysh.git", "url": "https://github.com/bobthecow/psysh.git",
"reference": "b1d289c2cb03a2f8249912c53e96ced38f879926" "reference": "d4c8eab0683dc056f2ca54ca67f5388527c068b1"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/bobthecow/psysh/zipball/b1d289c2cb03a2f8249912c53e96ced38f879926", "url": "https://api.github.com/repos/bobthecow/psysh/zipball/d4c8eab0683dc056f2ca54ca67f5388527c068b1",
"reference": "b1d289c2cb03a2f8249912c53e96ced38f879926", "reference": "d4c8eab0683dc056f2ca54ca67f5388527c068b1",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
...@@ -2384,14 +2385,13 @@ ...@@ -2384,14 +2385,13 @@
"jakub-onderka/php-console-highlighter": "0.3.*", "jakub-onderka/php-console-highlighter": "0.3.*",
"nikic/php-parser": "~1.3|~2.0|~3.0", "nikic/php-parser": "~1.3|~2.0|~3.0",
"php": ">=5.3.9", "php": ">=5.3.9",
"symfony/console": "~2.3.10|^2.4.2|~3.0", "symfony/console": "~2.3.10|^2.4.2|~3.0|~4.0",
"symfony/var-dumper": "~2.7|~3.0" "symfony/var-dumper": "~2.7|~3.0|~4.0"
}, },
"require-dev": { "require-dev": {
"friendsofphp/php-cs-fixer": "~1.11",
"hoa/console": "~3.16|~1.14", "hoa/console": "~3.16|~1.14",
"phpunit/phpunit": "^4.8.35|^5.4.3", "phpunit/phpunit": "^4.8.35|^5.4.3",
"symfony/finder": "~2.1|~3.0" "symfony/finder": "~2.1|~3.0|~4.0"
}, },
"suggest": { "suggest": {
"ext-pcntl": "Enabling the PCNTL extension makes PsySH a lot happier :)", "ext-pcntl": "Enabling the PCNTL extension makes PsySH a lot happier :)",
...@@ -2436,7 +2436,7 @@ ...@@ -2436,7 +2436,7 @@
"interactive", "interactive",
"shell" "shell"
], ],
"time": "2017-11-16T14:29:51+00:00" "time": "2017-12-10T21:49:27+00:00"
}, },
{ {
"name": "ramsey/uuid", "name": "ramsey/uuid",
...@@ -2577,16 +2577,16 @@ ...@@ -2577,16 +2577,16 @@
}, },
{ {
"name": "symfony/console", "name": "symfony/console",
"version": "v3.4.1", "version": "v3.4.2",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/console.git", "url": "https://github.com/symfony/console.git",
"reference": "2cdef78de8f54f68ff16a857e710e7302b47d4c7" "reference": "9f21adfb92a9315b73ae2ed43138988ee4913d4e"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/console/zipball/2cdef78de8f54f68ff16a857e710e7302b47d4c7", "url": "https://api.github.com/repos/symfony/console/zipball/9f21adfb92a9315b73ae2ed43138988ee4913d4e",
"reference": "2cdef78de8f54f68ff16a857e710e7302b47d4c7", "reference": "9f21adfb92a9315b73ae2ed43138988ee4913d4e",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
...@@ -2642,20 +2642,20 @@ ...@@ -2642,20 +2642,20 @@
], ],
"description": "Symfony Console Component", "description": "Symfony Console Component",
"homepage": "https://symfony.com", "homepage": "https://symfony.com",
"time": "2017-12-02T18:20:11+00:00" "time": "2017-12-14T19:40:10+00:00"
}, },
{ {
"name": "symfony/css-selector", "name": "symfony/css-selector",
"version": "v3.4.1", "version": "v3.4.2",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/css-selector.git", "url": "https://github.com/symfony/css-selector.git",
"reference": "7134b93e90ea7e7881fcb2da006d21b4c5f31908" "reference": "eac760b414cf1f64362c3dd047b989e4db121332"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/css-selector/zipball/7134b93e90ea7e7881fcb2da006d21b4c5f31908", "url": "https://api.github.com/repos/symfony/css-selector/zipball/eac760b414cf1f64362c3dd047b989e4db121332",
"reference": "7134b93e90ea7e7881fcb2da006d21b4c5f31908", "reference": "eac760b414cf1f64362c3dd047b989e4db121332",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
...@@ -2695,20 +2695,20 @@ ...@@ -2695,20 +2695,20 @@
], ],
"description": "Symfony CssSelector Component", "description": "Symfony CssSelector Component",
"homepage": "https://symfony.com", "homepage": "https://symfony.com",
"time": "2017-11-05T16:10:10+00:00" "time": "2017-12-14T19:40:10+00:00"
}, },
{ {
"name": "symfony/debug", "name": "symfony/debug",
"version": "v3.4.1", "version": "v3.4.2",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/debug.git", "url": "https://github.com/symfony/debug.git",
"reference": "fb2001e5d85f95d8b6ab94ae3be5d2672df128fd" "reference": "543deab3ffff94402440b326fc94153bae2dfa7a"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/debug/zipball/fb2001e5d85f95d8b6ab94ae3be5d2672df128fd", "url": "https://api.github.com/repos/symfony/debug/zipball/543deab3ffff94402440b326fc94153bae2dfa7a",
"reference": "fb2001e5d85f95d8b6ab94ae3be5d2672df128fd", "reference": "543deab3ffff94402440b326fc94153bae2dfa7a",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
...@@ -2751,20 +2751,20 @@ ...@@ -2751,20 +2751,20 @@
], ],
"description": "Symfony Debug Component", "description": "Symfony Debug Component",
"homepage": "https://symfony.com", "homepage": "https://symfony.com",
"time": "2017-11-21T09:01:46+00:00" "time": "2017-12-12T08:27:14+00:00"
}, },
{ {
"name": "symfony/event-dispatcher", "name": "symfony/event-dispatcher",
"version": "v4.0.1", "version": "v4.0.2",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/event-dispatcher.git", "url": "https://github.com/symfony/event-dispatcher.git",
"reference": "6223fb2b68e7059e8d5843c0103999a84e7275cf" "reference": "d4face19ed8002eec8280bc1c5ec18130472bf43"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/6223fb2b68e7059e8d5843c0103999a84e7275cf", "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/d4face19ed8002eec8280bc1c5ec18130472bf43",
"reference": "6223fb2b68e7059e8d5843c0103999a84e7275cf", "reference": "d4face19ed8002eec8280bc1c5ec18130472bf43",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
...@@ -2814,11 +2814,11 @@ ...@@ -2814,11 +2814,11 @@
], ],
"description": "Symfony EventDispatcher Component", "description": "Symfony EventDispatcher Component",
"homepage": "https://symfony.com", "homepage": "https://symfony.com",
"time": "2017-11-09T17:30:28+00:00" "time": "2017-12-14T19:48:22+00:00"
}, },
{ {
"name": "symfony/finder", "name": "symfony/finder",
"version": "v3.4.1", "version": "v3.4.2",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/finder.git", "url": "https://github.com/symfony/finder.git",
...@@ -2867,16 +2867,16 @@ ...@@ -2867,16 +2867,16 @@
}, },
{ {
"name": "symfony/http-foundation", "name": "symfony/http-foundation",
"version": "v3.4.1", "version": "v3.4.2",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/http-foundation.git", "url": "https://github.com/symfony/http-foundation.git",
"reference": "d9625c8abb907e0ca2d7506afd7a719a572c766f" "reference": "59bf131b5460227a2f583a7dbe6b179f98f9e0a5"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/http-foundation/zipball/d9625c8abb907e0ca2d7506afd7a719a572c766f", "url": "https://api.github.com/repos/symfony/http-foundation/zipball/59bf131b5460227a2f583a7dbe6b179f98f9e0a5",
"reference": "d9625c8abb907e0ca2d7506afd7a719a572c766f", "reference": "59bf131b5460227a2f583a7dbe6b179f98f9e0a5",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
...@@ -2917,20 +2917,20 @@ ...@@ -2917,20 +2917,20 @@
], ],
"description": "Symfony HttpFoundation Component", "description": "Symfony HttpFoundation Component",
"homepage": "https://symfony.com", "homepage": "https://symfony.com",
"time": "2017-11-30T14:56:21+00:00" "time": "2017-12-14T19:40:10+00:00"
}, },
{ {
"name": "symfony/http-kernel", "name": "symfony/http-kernel",
"version": "v3.4.1", "version": "v3.4.2",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/http-kernel.git", "url": "https://github.com/symfony/http-kernel.git",
"reference": "b101bb29071163563d4c8b537b35845eaf909235" "reference": "48325096bbda77b983e642d21a4dd9bdde3ab73e"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/http-kernel/zipball/b101bb29071163563d4c8b537b35845eaf909235", "url": "https://api.github.com/repos/symfony/http-kernel/zipball/48325096bbda77b983e642d21a4dd9bdde3ab73e",
"reference": "b101bb29071163563d4c8b537b35845eaf909235", "reference": "48325096bbda77b983e642d21a4dd9bdde3ab73e",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
...@@ -3005,7 +3005,7 @@ ...@@ -3005,7 +3005,7 @@
], ],
"description": "Symfony HttpKernel Component", "description": "Symfony HttpKernel Component",
"homepage": "https://symfony.com", "homepage": "https://symfony.com",
"time": "2017-12-04T23:05:00+00:00" "time": "2017-12-15T02:05:18+00:00"
}, },
{ {
"name": "symfony/polyfill-mbstring", "name": "symfony/polyfill-mbstring",
...@@ -3235,16 +3235,16 @@ ...@@ -3235,16 +3235,16 @@
}, },
{ {
"name": "symfony/process", "name": "symfony/process",
"version": "v3.4.1", "version": "v3.4.2",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/process.git", "url": "https://github.com/symfony/process.git",
"reference": "db25e810fd5e124085e3777257d0cf4ae533d0ea" "reference": "bb3ef65d493a6d57297cad6c560ee04e2a8f5098"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/process/zipball/db25e810fd5e124085e3777257d0cf4ae533d0ea", "url": "https://api.github.com/repos/symfony/process/zipball/bb3ef65d493a6d57297cad6c560ee04e2a8f5098",
"reference": "db25e810fd5e124085e3777257d0cf4ae533d0ea", "reference": "bb3ef65d493a6d57297cad6c560ee04e2a8f5098",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
...@@ -3280,20 +3280,20 @@ ...@@ -3280,20 +3280,20 @@
], ],
"description": "Symfony Process Component", "description": "Symfony Process Component",
"homepage": "https://symfony.com", "homepage": "https://symfony.com",
"time": "2017-11-22T12:18:49+00:00" "time": "2017-12-14T19:40:10+00:00"
}, },
{ {
"name": "symfony/routing", "name": "symfony/routing",
"version": "v3.4.1", "version": "v3.4.2",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/routing.git", "url": "https://github.com/symfony/routing.git",
"reference": "d768aa5b25d98188bae3fe4ce3eb2924c97aafac" "reference": "5f248dfac5e4660c74982eb3dadc71cf58595570"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/routing/zipball/d768aa5b25d98188bae3fe4ce3eb2924c97aafac", "url": "https://api.github.com/repos/symfony/routing/zipball/5f248dfac5e4660c74982eb3dadc71cf58595570",
"reference": "d768aa5b25d98188bae3fe4ce3eb2924c97aafac", "reference": "5f248dfac5e4660c74982eb3dadc71cf58595570",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
...@@ -3358,20 +3358,20 @@ ...@@ -3358,20 +3358,20 @@
"uri", "uri",
"url" "url"
], ],
"time": "2017-11-24T14:13:49+00:00" "time": "2017-12-14T22:37:31+00:00"
}, },
{ {
"name": "symfony/translation", "name": "symfony/translation",
"version": "v3.4.1", "version": "v3.4.2",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/translation.git", "url": "https://github.com/symfony/translation.git",
"reference": "e05b0a5996ad7a35ba3a19ffad8b72c9daa64dfa" "reference": "4c5d5582baf2829751a5207659329c1f52eedeb6"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/translation/zipball/e05b0a5996ad7a35ba3a19ffad8b72c9daa64dfa", "url": "https://api.github.com/repos/symfony/translation/zipball/4c5d5582baf2829751a5207659329c1f52eedeb6",
"reference": "e05b0a5996ad7a35ba3a19ffad8b72c9daa64dfa", "reference": "4c5d5582baf2829751a5207659329c1f52eedeb6",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
...@@ -3426,20 +3426,20 @@ ...@@ -3426,20 +3426,20 @@
], ],
"description": "Symfony Translation Component", "description": "Symfony Translation Component",
"homepage": "https://symfony.com", "homepage": "https://symfony.com",
"time": "2017-11-27T14:23:00+00:00" "time": "2017-12-12T08:27:14+00:00"
}, },
{ {
"name": "symfony/var-dumper", "name": "symfony/var-dumper",
"version": "v3.4.1", "version": "v3.4.2",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/var-dumper.git", "url": "https://github.com/symfony/var-dumper.git",
"reference": "ec650a975a8e04e0c114d35eab732981243db3a2" "reference": "757074cf71b952ce9e75b557538948811c2bf006"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/var-dumper/zipball/ec650a975a8e04e0c114d35eab732981243db3a2", "url": "https://api.github.com/repos/symfony/var-dumper/zipball/757074cf71b952ce9e75b557538948811c2bf006",
"reference": "ec650a975a8e04e0c114d35eab732981243db3a2", "reference": "757074cf71b952ce9e75b557538948811c2bf006",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
...@@ -3495,7 +3495,7 @@ ...@@ -3495,7 +3495,7 @@
"debug", "debug",
"dump" "dump"
], ],
"time": "2017-11-30T14:59:23+00:00" "time": "2017-12-11T22:06:16+00:00"
}, },
{ {
"name": "tijsverkoyen/css-to-inline-styles", "name": "tijsverkoyen/css-to-inline-styles",
...@@ -3550,12 +3550,12 @@ ...@@ -3550,12 +3550,12 @@
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/tymondesigns/jwt-auth.git", "url": "https://github.com/tymondesigns/jwt-auth.git",
"reference": "63a8d09ee44aa14d778d32d76b76dbe14023c88f" "reference": "d3f40ab90f451f265afb9775be9787b3accf1db2"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/tymondesigns/jwt-auth/zipball/63a8d09ee44aa14d778d32d76b76dbe14023c88f", "url": "https://api.github.com/repos/tymondesigns/jwt-auth/zipball/d3f40ab90f451f265afb9775be9787b3accf1db2",
"reference": "63a8d09ee44aa14d778d32d76b76dbe14023c88f", "reference": "d3f40ab90f451f265afb9775be9787b3accf1db2",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
...@@ -3616,7 +3616,7 @@ ...@@ -3616,7 +3616,7 @@
"jwt", "jwt",
"laravel" "laravel"
], ],
"time": "2017-12-04T09:52:01+00:00" "time": "2017-12-14T18:52:20+00:00"
}, },
{ {
"name": "unisharp/laravel-filemanager", "name": "unisharp/laravel-filemanager",
...@@ -3884,16 +3884,16 @@ ...@@ -3884,16 +3884,16 @@
}, },
{ {
"name": "bvipul/generator", "name": "bvipul/generator",
"version": "v0.9.1", "version": "0.9.3",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/bvipul/generator.git", "url": "https://github.com/bvipul/generator.git",
"reference": "e909ea2f6b031d6425f530aa66b948fde303e1d7" "reference": "9aa7d1aa9c2c748fa3890ab25628ea2cd7042103"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/bvipul/generator/zipball/e909ea2f6b031d6425f530aa66b948fde303e1d7", "url": "https://api.github.com/repos/bvipul/generator/zipball/9aa7d1aa9c2c748fa3890ab25628ea2cd7042103",
"reference": "e909ea2f6b031d6425f530aa66b948fde303e1d7", "reference": "9aa7d1aa9c2c748fa3890ab25628ea2cd7042103",
"shasum": "" "shasum": ""
}, },
"type": "package", "type": "package",
...@@ -3913,7 +3913,7 @@ ...@@ -3913,7 +3913,7 @@
} }
], ],
"description": "To create a whole module with all related files like model, controller, repository, routes, views etc with a simple GUI.", "description": "To create a whole module with all related files like model, controller, repository, routes, views etc with a simple GUI.",
"time": "2017-11-30T18:31:14+00:00" "time": "2017-12-16T18:48:20+00:00"
}, },
{ {
"name": "doctrine/instantiator", "name": "doctrine/instantiator",
...@@ -4864,16 +4864,16 @@ ...@@ -4864,16 +4864,16 @@
}, },
{ {
"name": "phpunit/phpunit", "name": "phpunit/phpunit",
"version": "6.5.3", "version": "6.5.4",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/sebastianbergmann/phpunit.git", "url": "https://github.com/sebastianbergmann/phpunit.git",
"reference": "882e886cc928a0abd3c61282b2a64026237d14a4" "reference": "1b2f933d5775f9237369deaa2d2bfbf9d652be4c"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/882e886cc928a0abd3c61282b2a64026237d14a4", "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/1b2f933d5775f9237369deaa2d2bfbf9d652be4c",
"reference": "882e886cc928a0abd3c61282b2a64026237d14a4", "reference": "1b2f933d5775f9237369deaa2d2bfbf9d652be4c",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
...@@ -4891,7 +4891,7 @@ ...@@ -4891,7 +4891,7 @@
"phpunit/php-file-iterator": "^1.4.3", "phpunit/php-file-iterator": "^1.4.3",
"phpunit/php-text-template": "^1.2.1", "phpunit/php-text-template": "^1.2.1",
"phpunit/php-timer": "^1.0.9", "phpunit/php-timer": "^1.0.9",
"phpunit/phpunit-mock-objects": "^5.0.4", "phpunit/phpunit-mock-objects": "^5.0.5",
"sebastian/comparator": "^2.1", "sebastian/comparator": "^2.1",
"sebastian/diff": "^2.0", "sebastian/diff": "^2.0",
"sebastian/environment": "^3.1", "sebastian/environment": "^3.1",
...@@ -4944,27 +4944,27 @@ ...@@ -4944,27 +4944,27 @@
"testing", "testing",
"xunit" "xunit"
], ],
"time": "2017-12-06T09:42:03+00:00" "time": "2017-12-10T08:06:19+00:00"
}, },
{ {
"name": "phpunit/phpunit-mock-objects", "name": "phpunit/phpunit-mock-objects",
"version": "5.0.4", "version": "5.0.5",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/sebastianbergmann/phpunit-mock-objects.git", "url": "https://github.com/sebastianbergmann/phpunit-mock-objects.git",
"reference": "16b50f4167e5e85e81ca8a3dd105d0a5fd32009a" "reference": "283b9f4f670e3a6fd6c4ff95c51a952eb5c75933"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/16b50f4167e5e85e81ca8a3dd105d0a5fd32009a", "url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/283b9f4f670e3a6fd6c4ff95c51a952eb5c75933",
"reference": "16b50f4167e5e85e81ca8a3dd105d0a5fd32009a", "reference": "283b9f4f670e3a6fd6c4ff95c51a952eb5c75933",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
"doctrine/instantiator": "^1.0.5", "doctrine/instantiator": "^1.0.5",
"php": "^7.0", "php": "^7.0",
"phpunit/php-text-template": "^1.2.1", "phpunit/php-text-template": "^1.2.1",
"sebastian/exporter": "^3.0" "sebastian/exporter": "^3.1"
}, },
"conflict": { "conflict": {
"phpunit/phpunit": "<6.0" "phpunit/phpunit": "<6.0"
...@@ -5003,7 +5003,7 @@ ...@@ -5003,7 +5003,7 @@
"mock", "mock",
"xunit" "xunit"
], ],
"time": "2017-12-02T05:31:19+00:00" "time": "2017-12-10T08:01:53+00:00"
}, },
{ {
"name": "sebastian/code-unit-reverse-lookup", "name": "sebastian/code-unit-reverse-lookup",
......
...@@ -8,7 +8,7 @@ return [ ...@@ -8,7 +8,7 @@ return [
* *
* @var bool * @var bool
*/ */
'status' => true, 'status' => false,
/* /*
* Available languages * Available languages
...@@ -29,19 +29,19 @@ return [ ...@@ -29,19 +29,19 @@ return [
* Index 1 of sub-array is the PHP locale code for setlocale() * Index 1 of sub-array is the PHP locale code for setlocale()
* Index 2 of sub-array is whether or not to use RTL (right-to-left) css for this language * Index 2 of sub-array is whether or not to use RTL (right-to-left) css for this language
*/ */
'ar' => ['ar', 'ar_AR', true], // 'ar' => ['ar', 'ar_AR', true],
'da' => ['da', 'da_DK', false], // 'da' => ['da', 'da_DK', false],
'de' => ['de', 'de_DE', false], // 'de' => ['de', 'de_DE', false],
'el' => ['el', 'el_GR', false], // 'el' => ['el', 'el_GR', false],
'en' => ['en', 'en_US', false], 'en' => ['en', 'en_US', false],
'es' => ['es', 'es_ES', false], // 'es' => ['es', 'es_ES', false],
'fr' => ['fr', 'fr_FR', false], // 'fr' => ['fr', 'fr_FR', false],
'id' => ['id', 'id_ID', false], // 'id' => ['id', 'id_ID', false],
'it' => ['it', 'it_IT', false], // 'it' => ['it', 'it_IT', false],
'nl' => ['nl', 'nl_NL', false], // 'nl' => ['nl', 'nl_NL', false],
'pt_BR' => ['pt_BR', 'pt_BR', false], // 'pt_BR' => ['pt_BR', 'pt_BR', false],
'ru' => ['ru', 'ru-RU', false], // 'ru' => ['ru', 'ru-RU', false],
'sv' => ['sv', 'sv_SE', false], // 'sv' => ['sv', 'sv_SE', false],
'th' => ['th', 'th_TH', false], // 'th' => ['th', 'th_TH', false],
], ],
]; ];
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateMenusTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('menus', function (Blueprint $table) {
$table->increments('id')->unsigned();
$table->enum('type', ['backend', 'frontend']);
$table->string('name');
$table->text('items')->nullable();
$table->integer('created_by')->unsigned();
$table->integer('updated_by')->unsigned()->nullable();
$table->timestamps();
$table->softDeletes();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('menus');
}
}
...@@ -24,6 +24,8 @@ class DatabaseSeeder extends Seeder ...@@ -24,6 +24,8 @@ class DatabaseSeeder extends Seeder
$this->call(EmailTemplateTableSeeder::class); $this->call(EmailTemplateTableSeeder::class);
$this->call(SettingsTableSeeder::class); $this->call(SettingsTableSeeder::class);
$this->call(PagesTableSeeder::class); $this->call(PagesTableSeeder::class);
$this->call(MenuTableSeeder::class);
$this->call(ModulesTableSeeder::class);
Model::reguard(); Model::reguard();
} }
......
<?php
use Carbon\Carbon;
use Illuminate\Database\Seeder;
use Illuminate\Support\Facades\DB;
class MenuTableSeeder extends Seeder
{
/**
* Run the database seeds.
*
* @return void
*/
public function run()
{
DB::table(config('access.menus_table'))->truncate();
$menu = [
'id' => 1,
'type' => 'backend',
'name' => 'Backend Sidebar Menu',
'items' => '[{"view_permission_id":"view-access-management","icon":"fa-users","open_in_new_tab":0,"url_type":"route","url":"","name":"Access Management","id":11,"content":"Access Management","children":[{"view_permission_id":"view-user-management","open_in_new_tab":0,"url_type":"route","url":"admin.access.user.index","name":"User Management","id":12,"content":"User Management"},{"view_permission_id":"view-role-management","open_in_new_tab":0,"url_type":"route","url":"admin.access.role.index","name":"Role Management","id":13,"content":"Role Management"},{"view_permission_id":"view-permission-management","open_in_new_tab":0,"url_type":"route","url":"admin.access.permission.index","name":"Permission Management","id":14,"content":"Permission Management"}]},{"view_permission_id":"view-module","icon":"fa-wrench","open_in_new_tab":0,"url_type":"route","url":"admin.modules.index","name":"Module","id":1,"content":"Module"},{"view_permission_id":"view-menu","icon":"fa-bars","open_in_new_tab":0,"url_type":"route","url":"admin.menus.index","name":"Menus","id":3,"content":"Menus"},{"view_permission_id":"view-page","icon":"fa-file-text","open_in_new_tab":0,"url_type":"route","url":"admin.pages.index","name":"Pages","id":2,"content":"Pages"},{"view_permission_id":"view-email-template","icon":"fa-envelope","open_in_new_tab":0,"url_type":"route","url":"admin.emailtemplates.index","name":"Email Templates","id":8,"content":"Email Templates"},{"view_permission_id":"edit-settings","icon":"fa-gear","open_in_new_tab":0,"url_type":"route","url":"admin.settings.edit?id=1","name":"Settings","id":9,"content":"Settings"},{"view_permission_id":"view-blog","icon":"fa-commenting","open_in_new_tab":0,"url_type":"route","url":"","name":"Blog Management","id":15,"content":"Blog Management","children":[{"view_permission_id":"view-blog-category","open_in_new_tab":0,"url_type":"route","url":"admin.blogcategories.index","name":"Blog Category Management","id":16,"content":"Blog Category Management"},{"view_permission_id":"view-blog-tag","open_in_new_tab":0,"url_type":"route","url":"admin.blogtags.index","name":"Blog Tag Management","id":17,"content":"Blog Tag Management"},{"view_permission_id":"view-blog","open_in_new_tab":0,"url_type":"route","url":"admin.blogs.index","name":"Blog Management","id":18,"content":"Blog Management"}]},{"view_permission_id":"view-faq","icon":"fa-question-circle","open_in_new_tab":0,"url_type":"route","url":"admin.faqs.index","name":"Faq Management","id":19,"content":"Faq Management"}]',
'created_by' => 1,
'created_at' => Carbon::now(),
];
DB::table(config('access.menus_table'))->insert($menu);
}
}
<?php
use Carbon\Carbon;
use Illuminate\Database\Seeder;
use Illuminate\Support\Facades\DB;
class ModulesTableSeeder extends Seeder
{
/**
* Run the database seeds.
*
* @return void
*/
public function run()
{
DB::table('modules')->truncate();
$modules = [
[
'name' => trans('menus.backend.access.title'),
'url' => null,
'view_permission_id' => 'view-access-management',
'created_by' => 1,
'created_at' => Carbon::now(),
],
[
'name' => trans('labels.backend.access.users.management'),
'url' => 'admin.access.user.index',
'view_permission_id' => 'view-user-management',
'created_by' => 1,
'created_at' => Carbon::now(),
],
[
'name' => trans('labels.backend.access.roles.management'),
'url' => 'admin.access.role.index',
'view_permission_id' => 'view-role-management',
'created_by' => 1,
'created_at' => Carbon::now(),
],
[
'name' => trans('labels.backend.access.permissions.management'),
'url' => 'admin.access.permission.index',
'view_permission_id' => 'view-permission-management',
'created_by' => 1,
'created_at' => Carbon::now(),
],
[
'name' => trans('labels.backend.menus.title'),
'url' => 'admin.menus.index',
'view_permission_id' => 'view-menu',
'created_by' => 1,
'created_at' => Carbon::now(),
],
[
'name' => trans('labels.backend.modules.title'),
'url' => 'admin.modules.index',
'view_permission_id' => 'view-module',
'created_by' => 1,
'created_at' => Carbon::now(),
],
[
'name' => trans('labels.backend.pages.title'),
'url' => 'admin.pages.index',
'view_permission_id' => 'view-page',
'created_by' => 1,
'created_at' => Carbon::now(),
],
[
'name' => trans('labels.backend.emailtemplates.title'),
'url' => 'admin.emailtemplates.index',
'view_permission_id' => 'view-email-template',
'created_by' => 1,
'created_at' => Carbon::now(),
],
[
'name' => trans('labels.backend.settings.title'),
'url' => 'admin.settings.edit',
'view_permission_id' => 'edit-settings',
'created_by' => 1,
'created_at' => Carbon::now(),
],
[
'name' => trans('menus.backend.blog.management'),
'url' => null,
'view_permission_id' => 'view-blog',
'created_by' => 1,
'created_at' => Carbon::now(),
],
[
'name' => trans('menus.backend.blogcategories.management'),
'url' => 'admin.blogcategories.index',
'view_permission_id' => 'view-blog-category',
'created_by' => 1,
'created_at' => Carbon::now(),
],
[
'name' => trans('menus.backend.blogtags.management'),
'url' => 'admin.blogtags.index',
'view_permission_id' => 'view-blog-tag',
'created_by' => 1,
'created_at' => Carbon::now(),
],
[
'name' => trans('menus.backend.blog.management'),
'url' => 'admin.blogs.index',
'view_permission_id' => 'view-blog',
'created_by' => 1,
'created_at' => Carbon::now(),
],
[
'name' => trans('menus.backend.faqs.management'),
'url' => 'admin.faqs.index',
'view_permission_id' => 'view-faq',
'created_by' => 1,
'created_at' => Carbon::now(),
],
];
DB::table('modules')->insert($modules);
}
}
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<phpunit backupGlobals="false" backupStaticAttributes="false" bootstrap="bootstrap/autoload.php" colors="true" <phpunit backupGlobals="false"
convertErrorsToExceptions="true" convertNoticesToExceptions="true" convertWarningsToExceptions="true" backupStaticAttributes="false"
processIsolation="false" stopOnFailure="false"> bootstrap="bootstrap/autoload.php"
colors="true"
convertErrorsToExceptions="true"
convertNoticesToExceptions="true"
convertWarningsToExceptions="true"
processIsolation="false"
stopOnFailure="false">
<testsuites>
<testsuite name="Feature Tests">
<directory suffix="Test.php">./tests/Feature</directory>
</testsuite>
<testsuite name="Unit Tests">
<directory suffix="Test.php">./tests/Unit</directory>
</testsuite>
</testsuites>
<filter> <filter>
<whitelist processUncoveredFilesFromWhitelist="true"> <whitelist processUncoveredFilesFromWhitelist="true">
<directory suffix=".php"> <directory suffix=".php">./app</directory>
./app
</directory>
</whitelist> </whitelist>
</filter> </filter>
<php> <php>
<env name="APP_ENV" value="testing"/> <env name="APP_ENV" value="testing"/>
<env name="CACHE_DRIVER" value="array"/>
<env name="DB_CONNECTION" value="sqlite"/> <env name="DB_CONNECTION" value="sqlite"/>
<env name="ENABLE_REGISTRATION" value="true"/> <env name="DB_DATABASE" value=":memory:"/>
<env name="QUEUE_DRIVER" value="sync"/> <env name="CACHE_DRIVER" value="array"/>
<env name="REGISTRATION_CAPTCHA_STATUS" value="false"/>
<env name="SESSION_DRIVER" value="array"/> <env name="SESSION_DRIVER" value="array"/>
<env name="QUEUE_DRIVER" value="sync"/>
<env name="SCOUT_DRIVER" value="null"/>
</php> </php>
<testsuites>
<testsuite name="Application Test Suite">
<directory suffix="Test.php">
./tests
</directory>
</testsuite>
</testsuites>
</phpunit> </phpunit>
...@@ -2,6 +2,9 @@ ...@@ -2,6 +2,9 @@
--theme-co: #495867; --theme-co: #495867;
--light-blue: #BDD5EA; --light-blue: #BDD5EA;
} }
html, body {
height: 100%;
}
.box { .box {
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2); box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
-webkit-box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2); -webkit-box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
...@@ -9,6 +12,9 @@ ...@@ -9,6 +12,9 @@
-ms-box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2); -ms-box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
-o-box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2); -o-box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
} }
.box.box-info {
border-top-color: var(--theme-co);
}
.box-header { .box-header {
padding: 15px 10px; padding: 15px 10px;
...@@ -219,13 +225,13 @@ textarea.form-control { max-width: 100%; min-height: 50px; } ...@@ -219,13 +225,13 @@ textarea.form-control { max-width: 100%; min-height: 50px; }
.control-group { display: block; text-align: left; padding: 0; margin: 3px 0 0; } .control-group { display: block; text-align: left; padding: 0; margin: 3px 0 0; }
.control { display: inline-block; vertical-align: top; position: relative; padding-left: 32px; padding-right: 10px; cursor: pointer; font-size: 14px; line-height: 28px; font-weight: 500; } .control { display: inline-block; vertical-align: top; position: relative; padding-left: 32px; padding-right: 10px; cursor: pointer; font-size: 14px; line-height: 28px; font-weight: 500; }
.control input { position: absolute; z-index: -1; opacity: 0; } .control input { position: absolute; z-index: -1; opacity: 0; }
.control__indicator { position: absolute; top: 3px; left: 0; height: 24px; width: 24px; } .control__indicator { position: absolute; top: 3px; left: 0; height: 24px; width: 24px; border: 1px solid var(--theme-co); }
.control--radio .control__indicator { border-radius: 50%; } .control--radio .control__indicator { border-radius: 50%; }
.control input:disabled ~ .control__indicator { opacity: 0.6; pointer-events: none; } .control input:disabled ~ .control__indicator { opacity: 0.6; pointer-events: none; }
.control__indicator:after { content: ''; position: absolute; display: none; } .control__indicator:after { content: ''; position: absolute; display: none; }
.control input:checked ~ .control__indicator:after { display: block; } .control input:checked ~ .control__indicator:after { display: block; }
.control--checkbox .control__indicator:after { left: 8px; top: 4px; width: 7px; height: 12px; border: solid #fff; border-width: 0 3px 3px 0; transform: rotate(45deg); } .control--checkbox .control__indicator:after { left: 8px; top: 4px; width: 7px; height: 12px; border: solid var(--theme-co); border-width: 0 3px 3px 0; transform: rotate(45deg); }
.control--radio .control__indicator:after { left: 7px; top: 7px; height: 10px; width: 10px; border-radius: 50%; background: #fff; } .control--radio .control__indicator:after { left: 6px; top: 6px; height: 10px; width: 10px; border-radius: 50%; background: var(--theme-co); }
/* selectbox css */ /* selectbox css */
::-moz-focus-inner, select:focus, select:active { outline: 0 !important; -moz-outline: 0 !important; } ::-moz-focus-inner, select:focus, select:active { outline: 0 !important; -moz-outline: 0 !important; }
.data-table-wrapper .dataTables_length label { position: relative; display: inline-block; width: 100%; } .data-table-wrapper .dataTables_length label { position: relative; display: inline-block; width: 100%; }
...@@ -322,6 +328,11 @@ ul.timeline.notification-list>li>.timeline-item { margin-right: 0; } ...@@ -322,6 +328,11 @@ ul.timeline.notification-list>li>.timeline-item { margin-right: 0; }
ul.timeline.notification-list>li>.timeline-item>.timeline-header { border-bottom: 0; font-size: 15px; } ul.timeline.notification-list>li>.timeline-item>.timeline-header { border-bottom: 0; font-size: 15px; }
ul.timeline.notification-list>li>.timeline-item>.timeline-header>span.comment-hl { padding-right: 3px; font-weight: 600; } ul.timeline.notification-list>li>.timeline-item>.timeline-header>span.comment-hl { padding-right: 3px; font-weight: 600; }
.pagination>.active>a, .pagination>.active>a:focus, .pagination>.active>a:hover, .pagination>.active>span, .pagination>.active>span:focus, .pagination>.active>span:hover {
background-color: var(--theme-co);
border-color: var(--theme-co);
}
/* Tab CSS start */ /* Tab CSS start */
.setting-tab-list.nav-tabs>li>a { color: #555; } .setting-tab-list.nav-tabs>li>a { color: #555; }
.tab-content.setting-tab { padding-top: 30px; } .tab-content.setting-tab { padding-top: 30px; }
...@@ -346,4 +357,4 @@ ul.timeline.notification-list>li>.timeline-item>.timeline-header>span.comment-hl ...@@ -346,4 +357,4 @@ ul.timeline.notification-list>li>.timeline-item>.timeline-header>span.comment-hl
@media screen and (max-width: 992px){ @media screen and (max-width: 992px){
.navbar-custom-menu>.navbar-nav>li>.dropdown-menu { right: 3%; } .navbar-custom-menu>.navbar-nav>li>.dropdown-menu { right: 3%; }
} }
/*Responsive CSS end*/ /*Responsive CSS end*/
\ No newline at end of file
{ {
"/js/frontend.js": "/js/frontend.945469bbbc12df3ad9e1.js", "/js/frontend.js": "/js/frontend.70ee44a92d84e7318a9d.js",
"/js/backend.js": "/js/backend.79d9e4698dadbc0d93c7.js", "/js/backend.js": "/js/backend.9cdae6ab449e701ce881.js",
"/mix.js": "/mix.247ab120fe7680658924.js", "/mix.js": "/mix.247ab120fe7680658924.js",
"/css/frontend.css": "/css/frontend.3af0a6cbd7d1d8d042f2a37e97008b7c.css", "/css/frontend.css": "/css/frontend.3af0a6cbd7d1d8d042f2a37e97008b7c.css",
"/css/backend.css": "/css/backend.f8550f50504e5b8ef6055285205f223a.css", "/css/backend.css": "/css/backend.f8550f50504e5b8ef6055285205f223a.css",
"/css/backend-custom.css": "/css/backend-custom.6366f7137897ebe08267f74909121944.css", "/css/backend-custom.css": "/css/backend-custom.18e74fbe4c755b817a022d6d3d4e76b1.css",
"/js/backend-custom.js": "/js/backend-custom.e6ea05e1824d0dd8e7c62027c135b7f2.js", "/js/backend-custom.js": "/js/backend-custom.694670b0d97bf54111bac3bd91ba3fcf.js",
"/js/dataTable.js": "/js/dataTable.f968d300a6a0b871f138f114361259c8.js" "/js/dataTable.js": "/js/dataTable.f968d300a6a0b871f138f114361259c8.js"
} }
\ No newline at end of file
...@@ -30,45 +30,6 @@ ...@@ -30,45 +30,6 @@
</div> </div>
</div> </div>
<div class="form-group">
{{ Form::label('address', trans('validation.attributes.frontend.register-user.address'), ['class' => 'col-lg-2 control-label']) }}
<div class="col-lg-10">
{{ Form::input('textarea', 'address', null, ['class' => 'form-control box-size', 'placeholder' => trans('validation.attributes.frontend.register-user.address')]) }}
</div>
</div>
{{-- state --}}
<div class="form-group">
{{ Form::label('state_id', trans('validation.attributes.frontend.register-user.state'), ['class' => 'col-lg-2 control-label']) }}
<div class="col-lg-10">
{{ Form::select('state_id', [] , null, ['class' => 'form-control box-size st', 'placeholder' => trans('validation.attributes.frontend.register-user.state'), 'id' => 'state']) }}
</div><!--col-lg-10-->
</div><!--form-group-->
{{-- city --}}
<div class="form-group">
{{ Form::label('city_id', trans('validation.attributes.frontend.register-user.city'), ['class' => 'col-lg-2 control-label']) }}
<div class="col-lg-10">
{{ Form::select('city_id', [], null, ['class' => 'form-control box-size ct', 'placeholder' => trans('validation.attributes.frontend.register-user.city'), 'id' => 'city']) }}
</div><!--col-lg-10-->
</div><!--form-group-->
{{-- zipcode --}}
<div class="form-group">
{{ Form::label('zip_code', trans('validation.attributes.frontend.register-user.zipcode'), ['class' => 'col-lg-2 control-label']) }}
<div class="col-lg-10">
{{ Form::input('name', 'zip_code', null, ['class' => 'form-control box-size', 'placeholder' => trans('validation.attributes.frontend.register-user.zipcode')]) }}
</div><!--col-lg-10-->
</div><!--form-group-->
{{-- SSN --}}
<div class="form-group">
{{ Form::label('ssn', trans('validation.attributes.frontend.register-user.ssn'), ['class' => 'col-lg-2 control-label']) }}
<div class="col-lg-10">
{{ Form::input('name', 'ssn', null, ['class' => 'form-control box-size', 'placeholder' => trans('validation.attributes.frontend.register-user.ssn')]) }}
</div><!--col-lg-10-->
</div><!--form-group-->
<div class="form-group"> <div class="form-group">
<div class="col-lg-10 col-md-offset-4"> <div class="col-lg-10 col-md-offset-4">
{{ Form::submit(trans('labels.general.buttons.update'), ['class' => 'btn btn-primary', 'id' => 'update-profile']) }} {{ Form::submit(trans('labels.general.buttons.update'), ['class' => 'btn btn-primary', 'id' => 'update-profile']) }}
...@@ -83,57 +44,6 @@ ...@@ -83,57 +44,6 @@
<script type="text/javascript"> <script type="text/javascript">
$(document).ready(function() { $(document).ready(function() {
Backend.Profile.init(); Backend.Profile.init();
//Getting States of default contry
ajaxCall("{{route('admin.get.states')}}");
//Getting Cities of select State
$("#state").on("change", function() {
var stateId = $(this).val();
var url = "{{route('admin.get.cities')}}";
ajaxCall(url, stateId);
});
function ajaxCall(url, data = null)
{
$.ajax({
url: url,
type: "POST",
data: {stateId: data},
success: function(result) {
if(result != null)
{
if(result.status == "city")
{
var userCity = "{{ $logged_in_user->city_id }}";
var options;
$.each(result.data, function(key, value) {
if(key == userCity)
options += "<option value='" + key + "' selected>" + value + "</option>";
else
options += "<option value='" + key + "'>" + value + "</option>";
});
$("#city").html('');
$("#city").append(options);
}
else
{
var userState = "{{ $logged_in_user->state_id }}";
var options;
$.each(result.data, function(key, value) {
if(key == userState)
options += "<option value='" + key + "' selected>" + value + "</option>";
else
options += "<option value='" + key + "'>" + value + "</option>";
});
$("#state").append(options);
$("#state").trigger('change');
}
}
}
});
}
}); });
</script> </script>
@endsection @endsection
\ No newline at end of file
...@@ -77,7 +77,7 @@ ...@@ -77,7 +77,7 @@
<li class="dropdown user user-menu"> <li class="dropdown user user-menu">
<a href="#" class="dropdown-toggle" data-toggle="dropdown"> <a href="#" class="dropdown-toggle" data-toggle="dropdown">
<img src="{{ access()->user()->picture }}" class="user-image" alt="User Avatar"/> <img src="{{ access()->user()->picture }}" class="user-image" alt="User Avatar"/>
<span class="hidden-xs">{{ access()->user()->name }}</span> <span class="hidden-xs">{{ access()->user()->first_name }}</span>
<div class="clearfix"></div> <div class="clearfix"></div>
</a> </a>
......
...@@ -46,7 +46,7 @@ ...@@ -46,7 +46,7 @@
<div class="wrapper"> <div class="wrapper">
@include('backend.includes.header') @include('backend.includes.header')
@include('backend.includes.sidebar') @include('backend.includes.sidebar-dynamic')
<!-- Content Wrapper. Contains page content --> <!-- Content Wrapper. Contains page content -->
<div class="content-wrapper"> <div class="content-wrapper">
...@@ -54,7 +54,9 @@ ...@@ -54,7 +54,9 @@
<section class="content-header"> <section class="content-header">
@yield('page-header') @yield('page-header')
<!-- Breadcrumbs would render from routes/breadcrumb.php --> <!-- Breadcrumbs would render from routes/breadcrumb.php -->
@if(Breadcrumbs::exists())
{!! Breadcrumbs::render() !!}
@endif
</section> </section>
<!-- Main content --> <!-- Main content -->
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
@section('content') @section('content')
{{ Form::open(['route' => 'admin.dummy_small_plural_model.store', 'class' => 'form-horizontal', 'role' => 'form', 'method' => 'post', 'id' => 'create-dummy_small_model']) }} {{ Form::open(['route' => 'admin.dummy_small_plural_model.store', 'class' => 'form-horizontal', 'role' => 'form', 'method' => 'post', 'id' => 'create-dummy_small_model']) }}
<div class="box box-success"> <div class="box box-info">
<div class="box-header with-border"> <div class="box-header with-border">
<h3 class="box-title">{{ trans('labels.backend.dummy_small_plural_model.create') }}</h3> <h3 class="box-title">{{ trans('labels.backend.dummy_small_plural_model.create') }}</h3>
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
@section('content') @section('content')
{{ Form::model($dummy_small_model, ['route' => ['admin.dummy_small_plural_model.update', $dummy_small_model], 'class' => 'form-horizontal', 'role' => 'form', 'method' => 'PATCH', 'id' => 'edit-dummy_small_model']) }} {{ Form::model($dummy_small_model, ['route' => ['admin.dummy_small_plural_model.update', $dummy_small_model], 'class' => 'form-horizontal', 'role' => 'form', 'method' => 'PATCH', 'id' => 'edit-dummy_small_model']) }}
<div class="box box-success"> <div class="box box-info">
<div class="box-header with-border"> <div class="box-header with-border">
<h3 class="box-title">{{ trans('labels.backend.dummy_small_plural_model.edit') }}</h3> <h3 class="box-title">{{ trans('labels.backend.dummy_small_plural_model.edit') }}</h3>
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
@endsection @endsection
@section('content') @section('content')
<div class="box box-success"> <div class="box box-info">
<div class="box-header with-border"> <div class="box-header with-border">
<h3 class="box-title">{{ trans('labels.backend.dummy_small_plural_model.management') }}</h3> <h3 class="box-title">{{ trans('labels.backend.dummy_small_plural_model.management') }}</h3>
......
...@@ -3,14 +3,16 @@ ...@@ -3,14 +3,16 @@
* DummyModuleName * DummyModuleName
* *
*/ */
@startNamespace Route::group(['namespace' => 'route_namespace', 'prefix' => 'admin', 'as' => 'admin.', 'middleware' => 'admin'], function () {
Route::group( ['namespace' => 'DummyModel'], function () { @startNamespace
Route::group( ['namespace' => 'DummyModel'], function () {
Route::resource('dummy_name', 'DummyController');
//For Datatable
Route::post('dummy_name/get', 'DummyTableController')->name('dummy_name.get');
});
@endNamespace@startWithoutNamespace
Route::resource('dummy_name', 'DummyController'); Route::resource('dummy_name', 'DummyController');
//For Datatable //For Datatable
Route::post('dummy_name/get', 'DummyTableController')->name('dummy_name.get'); Route::post('dummy_name/get', 'DummyTableController')->name('dummy_name.get');
}); @endWithoutNamespace
@endNamespace@startWithoutNamespace });
Route::resource('dummy_name', 'DummyController'); \ No newline at end of file
//For Datatable
Route::post('dummy_name/get', 'DummyTableController')->name('dummy_name.get');
@endWithoutNamespace
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
@section('content') @section('content')
{{ Form::open(['route' => 'admin.modules.store', 'class' => 'form-horizontal', 'role' => 'form', 'method' => 'post', 'id' => 'create-module', 'files' => true]) }} {{ Form::open(['route' => 'admin.modules.store', 'class' => 'form-horizontal', 'role' => 'form', 'method' => 'post', 'id' => 'create-module', 'files' => true]) }}
<div class="box box-success"> <div class="box box-info">
<div class="box-header with-border"> <div class="box-header with-border">
<h3 class="box-title">{{ trans('generator::labels.modules.create') }}</h3> <h3 class="box-title">{{ trans('generator::labels.modules.create') }}</h3>
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
@section('content') @section('content')
{{ Form::model($module, ['route' => ['admin.modules.update', $module], 'class' => 'form-horizontal', 'role' => 'form', 'method' => 'PATCH', 'id' => 'edit-module', 'files' => true]) }} {{ Form::model($module, ['route' => ['admin.modules.update', $module], 'class' => 'form-horizontal', 'role' => 'form', 'method' => 'PATCH', 'id' => 'edit-module', 'files' => true]) }}
<div class="box box-success"> <div class="box box-info">
<div class="box-header with-border"> <div class="box-header with-border">
<h3 class="box-title">{{ trans('generator::labels.modules.edit') }}</h3> <h3 class="box-title">{{ trans('generator::labels.modules.edit') }}</h3>
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
@endsection @endsection
@section('content') @section('content')
<div class="box box-success"> <div class="box box-info">
<div class="box-header with-border"> <div class="box-header with-border">
<h3 class="box-title">{{ trans('labels.backend.modules.management') }}</h3> <h3 class="box-title">{{ trans('labels.backend.modules.management') }}</h3>
...@@ -68,7 +68,7 @@ ...@@ -68,7 +68,7 @@
@section('after-scripts') @section('after-scripts')
{{-- For DataTables --}} {{-- For DataTables --}}
{{ Html::script(mix('js/dataTable.js')) }} {{ Html::script(mix('js/dataTable.js')) }}
<script> <script>
$(function() { $(function() {
var dataTable = $('#modules-table').dataTable({ var dataTable = $('#modules-table').dataTable({
...@@ -98,7 +98,7 @@ ...@@ -98,7 +98,7 @@
} }
}); });
FinBuilders.DataTableSearch.init(dataTable); Backend.DataTableSearch.init(dataTable);
}); });
</script> </script>
@endsection @endsection
\ No newline at end of file
<?php
/**
* Menu Management.
*/
Route::group(['namespace' => 'Menu'], function () {
Route::resource('menus', 'MenuController', ['except' => []]);
//For DataTables
Route::post('menus/get', 'MenuTableController')->name('menus.get');
// for Model Forms
Route::get('menus/get-form/{name?}', 'MenuFormController@create')->name('menus.getform');
});
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment