diff --git a/Plugin.php b/Plugin.php index 1292bc3..8bd1d8d 100644 --- a/Plugin.php +++ b/Plugin.php @@ -5,188 +5,188 @@ use System\Classes\PluginBase; /** -* Employees Plugin Information File -*/ + * Employees Plugin Information File + */ class Plugin extends PluginBase { - /** - * Returns information about this plugin. - * - * @return array - */ - public function pluginDetails() - { - return [ - 'name' => 'hambern.company::lang.plugin.name', - 'description' => 'hambern.company::lang.plugin.description', - 'author' => 'Hambern', - 'icon' => 'icon-building', - ]; - } + /** + * Returns information about this plugin. + * + * @return array + */ + public function pluginDetails() + { + return [ + 'name' => 'hambern.company::lang.plugin.name', + 'description' => 'hambern.company::lang.plugin.description', + 'author' => 'Hambern', + 'icon' => 'icon-building', + ]; + } - public function registerNavigation() - { - return [ - 'company' => [ - 'label' => 'hambern.company::lang.plugin.name', - 'url' => Backend::url('hambern/company/' . $this->startPage()), - 'icon' => 'icon-building', - 'permissions' => ['hambern.company.*'], - 'order' => 500, - 'sideMenu' => [ - 'employees' => [ - 'label' => 'hambern.company::lang.employees.menu_label', - 'icon' => 'icon-user', - 'url' => Backend::url('hambern/company/employees'), - 'permissions' => ['hambern.company.access_employees'], - ], - 'roles' => [ - 'label' => 'hambern.company::lang.roles.menu_label', - 'icon' => 'icon-briefcase', - 'url' => Backend::url('hambern/company/roles'), - 'permissions' => ['hambern.company.access_employees'], - ], - 'projects' => [ - 'label' => 'hambern.company::lang.projects.menu_label', - 'icon' => 'icon-wrench', - 'url' => Backend::url('hambern/company/projects'), - 'permissions' => ['hambern.company.access_projects'], - ], - 'services' => [ - 'label' => 'hambern.company::lang.services.menu_label', - 'icon' => 'icon-certificate', - 'url' => Backend::url('hambern/company/services'), - 'permissions' => ['hambern.company.access_services'], - ], - 'galleries' => [ - 'label' => 'hambern.company::lang.galleries.menu_label', - 'icon' => 'icon-photo', - 'url' => Backend::url('hambern/company/galleries'), - 'permissions' => ['hambern.company.access_galleries'], - ], - 'testimonials' => [ - 'label' => 'hambern.company::lang.testimonials.menu_label', - 'icon' => 'icon-comment', - 'url' => Backend::url('hambern/company/testimonials'), - 'permissions' => ['hambern.company.access_testimonials'], - ], - 'links' => [ - 'label' => 'hambern.company::lang.links.menu_label', - 'icon' => 'icon-link', - 'url' => Backend::url('hambern/company/links'), - 'permissions' => ['hambern.company.access_links'], - ], - 'tags' => [ - 'label' => 'hambern.company::lang.tags.menu_label', - 'icon' => 'icon-tag', - 'url' => Backend::url('hambern/company/tags'), - 'permissions' => ['hambern.company.access_tags'], - ], - ], - ], - ]; - } + public function registerNavigation() + { + return [ + 'company' => [ + 'label' => 'hambern.company::lang.plugin.name', + 'url' => Backend::url('hambern/company/' . $this->startPage()), + 'icon' => 'icon-building', + 'permissions' => ['hambern.company.*'], + 'order' => 500, + 'sideMenu' => [ + 'employees' => [ + 'label' => 'hambern.company::lang.employees.menu_label', + 'icon' => 'icon-user', + 'url' => Backend::url('hambern/company/employees'), + 'permissions' => ['hambern.company.access_employees'], + ], + 'roles' => [ + 'label' => 'hambern.company::lang.roles.menu_label', + 'icon' => 'icon-briefcase', + 'url' => Backend::url('hambern/company/roles'), + 'permissions' => ['hambern.company.access_employees'], + ], + 'projects' => [ + 'label' => 'hambern.company::lang.projects.menu_label', + 'icon' => 'icon-wrench', + 'url' => Backend::url('hambern/company/projects'), + 'permissions' => ['hambern.company.access_projects'], + ], + 'services' => [ + 'label' => 'hambern.company::lang.services.menu_label', + 'icon' => 'icon-certificate', + 'url' => Backend::url('hambern/company/services'), + 'permissions' => ['hambern.company.access_services'], + ], + 'galleries' => [ + 'label' => 'hambern.company::lang.galleries.menu_label', + 'icon' => 'icon-photo', + 'url' => Backend::url('hambern/company/galleries'), + 'permissions' => ['hambern.company.access_galleries'], + ], + 'testimonials' => [ + 'label' => 'hambern.company::lang.testimonials.menu_label', + 'icon' => 'icon-comment', + 'url' => Backend::url('hambern/company/testimonials'), + 'permissions' => ['hambern.company.access_testimonials'], + ], + 'links' => [ + 'label' => 'hambern.company::lang.links.menu_label', + 'icon' => 'icon-link', + 'url' => Backend::url('hambern/company/links'), + 'permissions' => ['hambern.company.access_links'], + ], + 'tags' => [ + 'label' => 'hambern.company::lang.tags.menu_label', + 'icon' => 'icon-tag', + 'url' => Backend::url('hambern/company/tags'), + 'permissions' => ['hambern.company.access_tags'], + ], + ], + ], + ]; + } - public function startPage($page = 'projects') - { - $user = BackendAuth::getUser(); - $permissions = array_reverse(array_keys($this->registerPermissions())); - if (!isset($user->permissions['superuser']) && $user->hasAccess('hambern.company.*')) { - foreach ($permissions as $access) { - if ($user->hasAccess($access)) { - $page = explode('_', $access)[1]; - } - } - } - return $page; - } + public function startPage($page = 'projects') + { + $user = BackendAuth::getUser(); + $permissions = array_reverse(array_keys($this->registerPermissions())); + if (!isset($user->permissions['superuser']) && $user->hasAccess('hambern.company.*')) { + foreach ($permissions as $access) { + if ($user->hasAccess($access)) { + $page = explode('_', $access)[1]; + } + } + } + return $page; + } - public function registerPermissions() - { - return [ - 'hambern.company.access_employees' => [ - 'label' => 'hambern.company::lang.employee.list_title', - 'tab' => 'hambern.company::lang.plugin.name', - ], - 'hambern.company.access_projects' => [ - 'label' => 'hambern.company::lang.project.list_title', - 'tab' => 'hambern.company::lang.plugin.name', - ], - 'hambern.company.access_services' => [ - 'label' => 'hambern.company::lang.service.list_title', - 'tab' => 'hambern.company::lang.plugin.name', - ], - 'hambern.company.access_galleries' => [ - 'label' => 'hambern.company::lang.gallery.list_title', - 'tab' => 'hambern.company::lang.plugin.name', - ], - 'hambern.company.access_links' => [ - 'label' => 'hambern.company::lang.link.list_title', - 'tab' => 'hambern.company::lang.plugin.name', - ], - 'hambern.company.access_testimonials' => [ - 'label' => 'hambern.company::lang.testimonial.list_title', - 'tab' => 'hambern.company::lang.plugin.name', - ], - 'hambern.company.access_tags' => [ - 'label' => 'hambern.company::lang.tag.list_title', - 'tab' => 'hambern.company::lang.plugin.name', - ], - 'hambern.company.access_company' => [ - 'label' => 'hambern.company::lang.company.list_title', - 'tab' => 'hambern.company::lang.plugin.name', - ], - ]; - } + public function registerPermissions() + { + return [ + 'hambern.company.access_employees' => [ + 'label' => 'hambern.company::lang.employee.list_title', + 'tab' => 'hambern.company::lang.plugin.name', + ], + 'hambern.company.access_projects' => [ + 'label' => 'hambern.company::lang.project.list_title', + 'tab' => 'hambern.company::lang.plugin.name', + ], + 'hambern.company.access_services' => [ + 'label' => 'hambern.company::lang.service.list_title', + 'tab' => 'hambern.company::lang.plugin.name', + ], + 'hambern.company.access_galleries' => [ + 'label' => 'hambern.company::lang.gallery.list_title', + 'tab' => 'hambern.company::lang.plugin.name', + ], + 'hambern.company.access_links' => [ + 'label' => 'hambern.company::lang.link.list_title', + 'tab' => 'hambern.company::lang.plugin.name', + ], + 'hambern.company.access_testimonials' => [ + 'label' => 'hambern.company::lang.testimonial.list_title', + 'tab' => 'hambern.company::lang.plugin.name', + ], + 'hambern.company.access_tags' => [ + 'label' => 'hambern.company::lang.tag.list_title', + 'tab' => 'hambern.company::lang.plugin.name', + ], + 'hambern.company.access_company' => [ + 'label' => 'hambern.company::lang.company.list_title', + 'tab' => 'hambern.company::lang.plugin.name', + ], + ]; + } - public function registerComponents() - { - return [ - 'Hambern\Company\Components\Employees' => 'Employees', - 'Hambern\Company\Components\Roles' => 'Roles', - 'Hambern\Company\Components\Projects' => 'Projects', - 'Hambern\Company\Components\Services' => 'Services', - 'Hambern\Company\Components\Galleries' => 'Galleries', - 'Hambern\Company\Components\Company' => 'Company', - 'Hambern\Company\Components\Testimonials' => 'Testimonials', - 'Hambern\Company\Components\Links' => 'Links', - 'Hambern\Company\Components\Tags' => 'Tags', - ]; - } + public function registerComponents() + { + return [ + 'Hambern\Company\Components\Employees' => 'Employees', + 'Hambern\Company\Components\Roles' => 'Roles', + 'Hambern\Company\Components\Projects' => 'Projects', + 'Hambern\Company\Components\Services' => 'Services', + 'Hambern\Company\Components\Galleries' => 'Galleries', + 'Hambern\Company\Components\Company' => 'Company', + 'Hambern\Company\Components\Testimonials' => 'Testimonials', + 'Hambern\Company\Components\Links' => 'Links', + 'Hambern\Company\Components\Tags' => 'Tags', + ]; + } - public function registerSettings() - { - return [ - 'company' => [ - 'label' => 'hambern.company::lang.plugin.name', - 'description' => 'hambern.company::lang.settings.description', - 'category' => 'system::lang.system.categories.system', - 'icon' => 'icon-building-o', - 'class' => 'Hambern\Company\Models\Company', - 'order' => 500, - 'keywords' => 'hambern.company::lang.settings.label', - 'permissions' => ['hambern.company.access_company'], - ], - ]; - } + public function registerSettings() + { + return [ + 'company' => [ + 'label' => 'hambern.company::lang.plugin.name', + 'description' => 'hambern.company::lang.settings.description', + 'category' => 'system::lang.system.categories.system', + 'icon' => 'icon-building-o', + 'class' => 'Hambern\Company\Models\Company', + 'order' => 500, + 'keywords' => 'hambern.company::lang.settings.label', + 'permissions' => ['hambern.company.access_company'], + ], + ]; + } - public function register() - { - set_exception_handler([$this, 'handleException']); - } + public function register() + { + set_exception_handler([$this, 'handleException']); + } - public function handleException($e) - { - if (! $e instanceof Exception) { - $e = new \Symfony\Component\Debug\Exception\FatalThrowableError($e); - } - $handler = $this->app->make('Illuminate\Contracts\Debug\ExceptionHandler'); - $handler->report($e); - if ($this->app->runningInConsole()) { - $handler->renderForConsole(new ConsoleOutput, $e); - } else { - $handler->render($this->app['request'], $e)->send(); - } - } + public function handleException($e) + { + if (!$e instanceof Exception) { + $e = new \Symfony\Component\Debug\Exception\FatalThrowableError($e); + } + $handler = $this->app->make('Illuminate\Contracts\Debug\ExceptionHandler'); + $handler->report($e); + if ($this->app->runningInConsole()) { + $handler->renderForConsole(new ConsoleOutput, $e); + } else { + $handler->render($this->app['request'], $e)->send(); + } + } } diff --git a/components/Projects.php b/components/Projects.php index dcb737f..ce49936 100644 --- a/components/Projects.php +++ b/components/Projects.php @@ -72,7 +72,7 @@ public function defineProperties() 'title' => 'hambern.company::lang.tags.menu_label', 'description' => 'hambern.company::lang.descriptions.filter_tags', 'type' => 'dropdown', - 'depends' => ['tagIdentifier'], + 'depends' => ['tagIdentifier'], 'group' => 'hambern.company::lang.labels.filters', ]; return $properties; diff --git a/controllers/Controller.php b/controllers/Controller.php index a429b11..a75da53 100644 --- a/controllers/Controller.php +++ b/controllers/Controller.php @@ -5,14 +5,15 @@ /** * Courses Back-end Controller */ -class Controller extends BaseController { - public $implement = [ - 'Backend.Behaviors.FormController', - 'Backend.Behaviors.ListController', - 'Backend.Behaviors.RelationController', - ]; +class Controller extends BaseController +{ + public $implement = [ + 'Backend.Behaviors.FormController', + 'Backend.Behaviors.ListController', + 'Backend.Behaviors.RelationController', + ]; - public $formConfig = 'config_form.yaml'; - public $listConfig = 'config_list.yaml'; - public $relationConfig = '../relations/config_relation.yaml'; + public $formConfig = 'config_form.yaml'; + public $listConfig = 'config_list.yaml'; + public $relationConfig = '../relations/config_relation.yaml'; } diff --git a/controllers/Employees.php b/controllers/Employees.php index 4d600db..1b78bbf 100644 --- a/controllers/Employees.php +++ b/controllers/Employees.php @@ -11,35 +11,35 @@ class Employees extends Controller { - public $requiredPermissions = ['hambern.company.access_employees']; + public $requiredPermissions = ['hambern.company.access_employees']; - public function __construct() - { - parent::__construct(); + public function __construct() + { + parent::__construct(); - BackendMenu::setContext('Hambern.Company', 'company', 'employees'); - } + BackendMenu::setContext('Hambern.Company', 'company', 'employees'); + } - /** - * Deleted checked employees. - */ - public function index_onDelete() - { - if (($checkedIds = post('checked')) && is_array($checkedIds) && count($checkedIds)) { + /** + * Deleted checked employees. + */ + public function index_onDelete() + { + if (($checkedIds = post('checked')) && is_array($checkedIds) && count($checkedIds)) { - foreach ($checkedIds as $employeeId) { - if (!$employee = Employee::find($employeeId)) { - continue; - } + foreach ($checkedIds as $employeeId) { + if (!$employee = Employee::find($employeeId)) { + continue; + } - $employee->delete(); - } + $employee->delete(); + } - Flash::success(Lang::get('hambern.company::lang.employees.delete_selected_success')); - } else { - Flash::error(Lang::get('hambern.company::lang.employees.delete_selected_empty')); - } + Flash::success(Lang::get('hambern.company::lang.employees.delete_selected_success')); + } else { + Flash::error(Lang::get('hambern.company::lang.employees.delete_selected_empty')); + } - return $this->listRefresh(); - } + return $this->listRefresh(); + } } diff --git a/controllers/Galleries.php b/controllers/Galleries.php index 2f92646..dceeb54 100644 --- a/controllers/Galleries.php +++ b/controllers/Galleries.php @@ -11,35 +11,35 @@ class Galleries extends Controller { - public $requiredPermissions = ['hambern.company.access_galleries']; + public $requiredPermissions = ['hambern.company.access_galleries']; - public function __construct() - { - parent::__construct(); + public function __construct() + { + parent::__construct(); - BackendMenu::setContext('Hambern.Company', 'company', 'galleries'); - } + BackendMenu::setContext('Hambern.Company', 'company', 'galleries'); + } - /** - * Deleted checked galleries. - */ - public function index_onDelete() - { - if (($checkedIds = post('checked')) && is_array($checkedIds) && count($checkedIds)) { + /** + * Deleted checked galleries. + */ + public function index_onDelete() + { + if (($checkedIds = post('checked')) && is_array($checkedIds) && count($checkedIds)) { - foreach ($checkedIds as $galleryId) { - if (!$gallery = Gallery::find($galleryId)) { - continue; - } + foreach ($checkedIds as $galleryId) { + if (!$gallery = Gallery::find($galleryId)) { + continue; + } - $gallery->delete(); - } + $gallery->delete(); + } - Flash::success(Lang::get('hambern.company::lang.galleries.delete_selected_success')); - } else { - Flash::error(Lang::get('hambern.company::lang.galleries.delete_selected_empty')); - } + Flash::success(Lang::get('hambern.company::lang.galleries.delete_selected_success')); + } else { + Flash::error(Lang::get('hambern.company::lang.galleries.delete_selected_empty')); + } - return $this->listRefresh(); - } + return $this->listRefresh(); + } } diff --git a/controllers/Links.php b/controllers/Links.php index 979b2e5..b0b5d06 100644 --- a/controllers/Links.php +++ b/controllers/Links.php @@ -33,8 +33,7 @@ public function index_onDelete() } Flash::success(Lang::get('hambern.company::lang.links.delete_selected_success')); - } - else { + } else { Flash::error(Lang::get('hambern.company::lang.links.delete_selected_empty')); } diff --git a/controllers/Projects.php b/controllers/Projects.php index b58cc6d..295fb61 100644 --- a/controllers/Projects.php +++ b/controllers/Projects.php @@ -11,35 +11,35 @@ class Projects extends Controller { - public $requiredPermissions = ['hambern.company.access_projects']; + public $requiredPermissions = ['hambern.company.access_projects']; - public function __construct() - { - parent::__construct(); + public function __construct() + { + parent::__construct(); - BackendMenu::setContext('Hambern.Company', 'company', 'projects'); - } + BackendMenu::setContext('Hambern.Company', 'company', 'projects'); + } - /** - * Deleted checked projects. - */ - public function index_onDelete() - { - if (($checkedIds = post('checked')) && is_array($checkedIds) && count($checkedIds)) { + /** + * Deleted checked projects. + */ + public function index_onDelete() + { + if (($checkedIds = post('checked')) && is_array($checkedIds) && count($checkedIds)) { - foreach ($checkedIds as $projectId) { - if (!$project = Project::find($projectId)) { - continue; - } + foreach ($checkedIds as $projectId) { + if (!$project = Project::find($projectId)) { + continue; + } - $project->delete(); - } + $project->delete(); + } - Flash::success(Lang::get('hambern.company::lang.projects.delete_selected_success')); - } else { - Flash::error(Lang::get('hambern.company::lang.projects.delete_selected_empty')); - } + Flash::success(Lang::get('hambern.company::lang.projects.delete_selected_success')); + } else { + Flash::error(Lang::get('hambern.company::lang.projects.delete_selected_empty')); + } - return $this->listRefresh(); - } + return $this->listRefresh(); + } } diff --git a/controllers/Roles.php b/controllers/Roles.php index 54f26ce..3102327 100644 --- a/controllers/Roles.php +++ b/controllers/Roles.php @@ -11,35 +11,35 @@ class Roles extends Controller { - public $requiredPermissions = ['hambern.company.access_employees']; + public $requiredPermissions = ['hambern.company.access_employees']; - public function __construct() - { - parent::__construct(); + public function __construct() + { + parent::__construct(); - BackendMenu::setContext('Hambern.Company', 'company', 'roles'); - } + BackendMenu::setContext('Hambern.Company', 'company', 'roles'); + } - /** - * Deleted checked roles. - */ - public function index_onDelete() - { - if (($checkedIds = post('checked')) && is_array($checkedIds) && count($checkedIds)) { + /** + * Deleted checked roles. + */ + public function index_onDelete() + { + if (($checkedIds = post('checked')) && is_array($checkedIds) && count($checkedIds)) { - foreach ($checkedIds as $roleId) { - if (!$role = Role::find($roleId)) { - continue; - } + foreach ($checkedIds as $roleId) { + if (!$role = Role::find($roleId)) { + continue; + } - $role->delete(); - } + $role->delete(); + } - Flash::success(Lang::get('hambern.company::lang.roles.delete_selected_success')); - } else { - Flash::error(Lang::get('hambern.company::lang.roles.delete_selected_empty')); - } + Flash::success(Lang::get('hambern.company::lang.roles.delete_selected_success')); + } else { + Flash::error(Lang::get('hambern.company::lang.roles.delete_selected_empty')); + } - return $this->listRefresh(); - } + return $this->listRefresh(); + } } diff --git a/controllers/Services.php b/controllers/Services.php index 5b32fa3..6ad453c 100644 --- a/controllers/Services.php +++ b/controllers/Services.php @@ -11,35 +11,35 @@ class Services extends Controller { - public $requiredPermissions = ['hambern.company.access_services']; + public $requiredPermissions = ['hambern.company.access_services']; - public function __construct() - { - parent::__construct(); + public function __construct() + { + parent::__construct(); - BackendMenu::setContext('Hambern.Company', 'company', 'services'); - } + BackendMenu::setContext('Hambern.Company', 'company', 'services'); + } - /** - * Deleted checked services. - */ - public function index_onDelete() - { - if (($checkedIds = post('checked')) && is_array($checkedIds) && count($checkedIds)) { + /** + * Deleted checked services. + */ + public function index_onDelete() + { + if (($checkedIds = post('checked')) && is_array($checkedIds) && count($checkedIds)) { - foreach ($checkedIds as $serviceId) { - if (!$service = Service::find($serviceId)) { - continue; - } + foreach ($checkedIds as $serviceId) { + if (!$service = Service::find($serviceId)) { + continue; + } - $service->delete(); - } + $service->delete(); + } - Flash::success(Lang::get('hambern.company::lang.services.delete_selected_success')); - } else { - Flash::error(Lang::get('hambern.company::lang.services.delete_selected_empty')); - } + Flash::success(Lang::get('hambern.company::lang.services.delete_selected_success')); + } else { + Flash::error(Lang::get('hambern.company::lang.services.delete_selected_empty')); + } - return $this->listRefresh(); - } + return $this->listRefresh(); + } } diff --git a/controllers/Tags.php b/controllers/Tags.php index 85514aa..6ea1ab4 100644 --- a/controllers/Tags.php +++ b/controllers/Tags.php @@ -33,8 +33,7 @@ public function index_onDelete() } Flash::success(Lang::get('hambern.company::lang.tags.delete_selected_success')); - } - else { + } else { Flash::error(Lang::get('hambern.company::lang.tags.delete_selected_empty')); } diff --git a/controllers/Testimonials.php b/controllers/Testimonials.php index 4e9c924..6251cf9 100644 --- a/controllers/Testimonials.php +++ b/controllers/Testimonials.php @@ -11,35 +11,35 @@ class Testimonials extends Controller { - public $requiredPermissions = ['hambern.company.access_testimonials']; + public $requiredPermissions = ['hambern.company.access_testimonials']; - public function __construct() - { - parent::__construct(); + public function __construct() + { + parent::__construct(); - BackendMenu::setContext('Hambern.Company', 'company', 'testimonials'); - } + BackendMenu::setContext('Hambern.Company', 'company', 'testimonials'); + } - /** - * Deleted checked testimonials. - */ - public function index_onDelete() - { - if (($checkedIds = post('checked')) && is_array($checkedIds) && count($checkedIds)) { + /** + * Deleted checked testimonials. + */ + public function index_onDelete() + { + if (($checkedIds = post('checked')) && is_array($checkedIds) && count($checkedIds)) { - foreach ($checkedIds as $testimonialId) { - if (!$testimonial = Testimonial::find($testimonialId)) { - continue; - } + foreach ($checkedIds as $testimonialId) { + if (!$testimonial = Testimonial::find($testimonialId)) { + continue; + } - $testimonial->delete(); - } + $testimonial->delete(); + } - Flash::success(Lang::get('hambern.company::lang.testimonials.delete_selected_success')); - } else { - Flash::error(Lang::get('hambern.company::lang.testimonials.delete_selected_empty')); - } + Flash::success(Lang::get('hambern.company::lang.testimonials.delete_selected_success')); + } else { + Flash::error(Lang::get('hambern.company::lang.testimonials.delete_selected_empty')); + } - return $this->listRefresh(); - } + return $this->listRefresh(); + } } diff --git a/controllers/links/_list_toolbar.htm b/controllers/links/_list_toolbar.htm index c35071f..1eb3d12 100644 --- a/controllers/links/_list_toolbar.htm +++ b/controllers/links/_list_toolbar.htm @@ -1,23 +1,23 @@
+ href="" + class="btn btn-primary oc-icon-plus">
\ No newline at end of file diff --git a/controllers/links/create.htm b/controllers/links/create.htm index df7a661..c1608ff 100644 --- a/controllers/links/create.htm +++ b/controllers/links/create.htm @@ -1,48 +1,52 @@ - + fatalError): ?> - 'layout']) ?> - -
- formRender() ?> -
- -
-
- - + 'layout']) ?> + +
+ formRender() ?> +
+ +
+
+ + - + -
-
+
+
- + -

fatalError) ?>

-

+

fatalError) ?>

+

\ No newline at end of file diff --git a/controllers/links/index.htm b/controllers/links/index.htm index 766877d..ea43a36 100644 --- a/controllers/links/index.htm +++ b/controllers/links/index.htm @@ -1,2 +1 @@ - listRender() ?> diff --git a/controllers/links/preview.htm b/controllers/links/preview.htm index 57a678f..a0cd32d 100644 --- a/controllers/links/preview.htm +++ b/controllers/links/preview.htm @@ -1,19 +1,22 @@ - + fatalError): ?> -
- formRenderPreview() ?> -
+
+ formRenderPreview() ?> +
-

fatalError) ?>

-

+

fatalError) ?>

+

\ No newline at end of file diff --git a/controllers/links/update.htm b/controllers/links/update.htm index fdf5b97..c3f5318 100644 --- a/controllers/links/update.htm +++ b/controllers/links/update.htm @@ -1,56 +1,60 @@ - + fatalError): ?> - 'layout']) ?> - -
- formRender() ?> -
- -
-
- - - + 'layout']) ?> + +
+ formRender() ?> +
+ +
+
+ + + - + -
-
+
+
- + -

fatalError) ?>

-

+

fatalError) ?>

+

\ No newline at end of file diff --git a/controllers/tags/_list_toolbar.htm b/controllers/tags/_list_toolbar.htm index c804b5f..76610f3 100644 --- a/controllers/tags/_list_toolbar.htm +++ b/controllers/tags/_list_toolbar.htm @@ -1,23 +1,23 @@
+ href="" + class="btn btn-primary oc-icon-plus">
\ No newline at end of file diff --git a/controllers/tags/create.htm b/controllers/tags/create.htm index bad40d9..e3eccbd 100644 --- a/controllers/tags/create.htm +++ b/controllers/tags/create.htm @@ -1,48 +1,52 @@ - + fatalError): ?> - 'layout']) ?> - -
- formRender() ?> -
- -
-
- - + 'layout']) ?> + +
+ formRender() ?> +
+ +
+
+ + - + -
-
+
+
- + -

fatalError) ?>

-

+

fatalError) ?>

+

\ No newline at end of file diff --git a/controllers/tags/index.htm b/controllers/tags/index.htm index 766877d..ea43a36 100644 --- a/controllers/tags/index.htm +++ b/controllers/tags/index.htm @@ -1,2 +1 @@ - listRender() ?> diff --git a/controllers/tags/preview.htm b/controllers/tags/preview.htm index 6786494..45a4d8a 100644 --- a/controllers/tags/preview.htm +++ b/controllers/tags/preview.htm @@ -1,19 +1,22 @@ - + fatalError): ?> -
- formRenderPreview() ?> -
+
+ formRenderPreview() ?> +
-

fatalError) ?>

-

+

fatalError) ?>

+

\ No newline at end of file diff --git a/controllers/tags/update.htm b/controllers/tags/update.htm index d32c218..7080fbf 100644 --- a/controllers/tags/update.htm +++ b/controllers/tags/update.htm @@ -1,56 +1,60 @@ - + fatalError): ?> - 'layout']) ?> - -
- formRender() ?> -
- -
-
- - - + 'layout']) ?> + +
+ formRender() ?> +
+ +
+
+ + + - + -
-
+
+
- + -

fatalError) ?>

-

+

fatalError) ?>

+

\ No newline at end of file diff --git a/lang/sv/lang.php b/lang/sv/lang.php index 2f9a4dc..d229030 100644 --- a/lang/sv/lang.php +++ b/lang/sv/lang.php @@ -230,11 +230,11 @@ 'list_title' => 'Hantera etiketter', ], 'tags' => [ - 'delete_selected_confirm' => 'Radera markerade länkar?', - 'menu_label' => 'Etiketter', - 'return_to_list' => 'Tillbaka till etiketter', - 'delete_confirm' => 'Vill du verkligen ta bort denna etikett?', - 'delete_selected_success' => 'Raderade de markerade etiketterna.', - 'delete_selected_empty' => 'Det finns inga :name att radera.', + 'delete_selected_confirm' => 'Radera markerade länkar?', + 'menu_label' => 'Etiketter', + 'return_to_list' => 'Tillbaka till etiketter', + 'delete_confirm' => 'Vill du verkligen ta bort denna etikett?', + 'delete_selected_success' => 'Raderade de markerade etiketterna.', + 'delete_selected_empty' => 'Det finns inga :name att radera.', ], ]; diff --git a/models/Company.php b/models/Company.php index 840c5d3..e937f70 100644 --- a/models/Company.php +++ b/models/Company.php @@ -4,33 +4,33 @@ use BackendMenu; /** -* Settings Model -*/ + * Settings Model + */ class Company extends BaseModel { - public $implement = [ - 'System.Behaviors.SettingsModel', - '@RainLab.Translate.Behaviors.TranslatableModel', - ]; + public $implement = [ + 'System.Behaviors.SettingsModel', + '@RainLab.Translate.Behaviors.TranslatableModel', + ]; - public $translatable = ['story', 'slogan']; + public $translatable = ['story', 'slogan']; - public $settingsCode = 'hambern_company_settings'; + public $settingsCode = 'hambern_company_settings'; - public $settingsFields = 'fields.yaml'; + public $settingsFields = 'fields.yaml'; - public $attachOne = [ - 'logo' => ['System\Models\File'], - ]; + public $attachOne = [ + 'logo' => ['System\Models\File'], + ]; - public function getContactOptions() - { - $options = []; - if ($data = Employee::orderBy('last_name')->get()) { - foreach ($data as $record){ - $options[$record->id] = $record->name; - } - } - return $options; - } + public function getContactOptions() + { + $options = []; + if ($data = Employee::orderBy('last_name')->get()) { + foreach ($data as $record) { + $options[$record->id] = $record->name; + } + } + return $options; + } } diff --git a/models/Model.php b/models/Model.php index a2f348a..cba0e75 100644 --- a/models/Model.php +++ b/models/Model.php @@ -13,25 +13,25 @@ class Model extends BaseModel protected $guarded = ['*']; - public function scopePublished($query) - { - return $query->where('published_at', '<', date('Y-m-d H:i:s')); - } - - public function afterDelete() - { - if (!empty($this->picture)) { - $this->picture->delete(); - } - if (!empty($this->pictures)) { - foreach ($this->pictures as $item) { - $item->delete(); - } - } - if (!empty($this->files)) { - foreach ($this->files as $item) { - $item->delete(); - } - } - } + public function scopePublished($query) + { + return $query->where('published_at', '<', date('Y-m-d H:i:s')); + } + + public function afterDelete() + { + if (!empty($this->picture)) { + $this->picture->delete(); + } + if (!empty($this->pictures)) { + foreach ($this->pictures as $item) { + $item->delete(); + } + } + if (!empty($this->files)) { + foreach ($this->files as $item) { + $item->delete(); + } + } + } } diff --git a/updates/builder_table_update_hambern_company_employees.php b/updates/builder_table_update_hambern_company_employees.php index a901f0c..c45c7d9 100644 --- a/updates/builder_table_update_hambern_company_employees.php +++ b/updates/builder_table_update_hambern_company_employees.php @@ -8,8 +8,7 @@ class BuilderTableUpdateHambernCompanyEmployees extends Migration { public function up() { - Schema::table('hambern_company_employees', function($table) - { + Schema::table('hambern_company_employees', function ($table) { $table->string('slug')->index(); }); @@ -19,11 +18,10 @@ public function up() $model->save(); }); } - + public function down() { - Schema::table('hambern_company_employees', function($table) - { + Schema::table('hambern_company_employees', function ($table) { $table->dropColumn('slug'); }); } diff --git a/updates/builder_table_update_hambern_company_galleries.php b/updates/builder_table_update_hambern_company_galleries.php index e0a0c9c..d95914b 100644 --- a/updates/builder_table_update_hambern_company_galleries.php +++ b/updates/builder_table_update_hambern_company_galleries.php @@ -8,8 +8,7 @@ class BuilderTableUpdateHambernCompanyGalleries extends Migration { public function up() { - Schema::table('hambern_company_galleries', function($table) - { + Schema::table('hambern_company_galleries', function ($table) { $table->string('slug')->index(); }); @@ -19,11 +18,10 @@ public function up() $model->save(); }); } - + public function down() { - Schema::table('hambern_company_galleries', function($table) - { + Schema::table('hambern_company_galleries', function ($table) { $table->dropColumn('slug'); }); } diff --git a/updates/builder_table_update_hambern_company_links.php b/updates/builder_table_update_hambern_company_links.php index 9c1326d..6b10578 100644 --- a/updates/builder_table_update_hambern_company_links.php +++ b/updates/builder_table_update_hambern_company_links.php @@ -8,8 +8,7 @@ class BuilderTableUpdateHambernCompanyLinks extends Migration { public function up() { - Schema::table('hambern_company_links', function($table) - { + Schema::table('hambern_company_links', function ($table) { $table->string('slug')->index(); }); @@ -19,11 +18,10 @@ public function up() $model->save(); }); } - + public function down() { - Schema::table('hambern_company_links', function($table) - { + Schema::table('hambern_company_links', function ($table) { $table->dropColumn('slug'); }); } diff --git a/updates/builder_table_update_hambern_company_projects.php b/updates/builder_table_update_hambern_company_projects.php index 24c6736..12ff0d4 100644 --- a/updates/builder_table_update_hambern_company_projects.php +++ b/updates/builder_table_update_hambern_company_projects.php @@ -8,8 +8,7 @@ class BuilderTableUpdateHambernCompanyProjects extends Migration { public function up() { - Schema::table('hambern_company_projects', function($table) - { + Schema::table('hambern_company_projects', function ($table) { $table->string('slug')->index(); }); @@ -19,11 +18,10 @@ public function up() $model->save(); }); } - + public function down() { - Schema::table('hambern_company_projects', function($table) - { + Schema::table('hambern_company_projects', function ($table) { $table->dropColumn('slug'); }); } diff --git a/updates/builder_table_update_hambern_company_roles.php b/updates/builder_table_update_hambern_company_roles.php index 422f8eb..3b02bed 100644 --- a/updates/builder_table_update_hambern_company_roles.php +++ b/updates/builder_table_update_hambern_company_roles.php @@ -8,8 +8,7 @@ class BuilderTableUpdateHambernCompanyRoles extends Migration { public function up() { - Schema::table('hambern_company_roles', function($table) - { + Schema::table('hambern_company_roles', function ($table) { $table->string('slug')->index(); }); @@ -19,11 +18,10 @@ public function up() $model->save(); }); } - + public function down() { - Schema::table('hambern_company_roles', function($table) - { + Schema::table('hambern_company_roles', function ($table) { $table->dropColumn('slug'); }); } diff --git a/updates/builder_table_update_hambern_company_services.php b/updates/builder_table_update_hambern_company_services.php index 2c0fd29..2f9652f 100644 --- a/updates/builder_table_update_hambern_company_services.php +++ b/updates/builder_table_update_hambern_company_services.php @@ -1,23 +1,21 @@ -string('link', 255)->nullable(); }); } - + public function down() { - Schema::table('hambern_company_services', function($table) - { + Schema::table('hambern_company_services', function ($table) { $table->dropColumn('link'); }); - } -} + } +} diff --git a/updates/builder_table_update_hambern_company_services2.php b/updates/builder_table_update_hambern_company_services2.php index a5d2a2d..1071bb1 100644 --- a/updates/builder_table_update_hambern_company_services2.php +++ b/updates/builder_table_update_hambern_company_services2.php @@ -8,8 +8,7 @@ class BuilderTableUpdateHambernCompanyServices2 extends Migration { public function up() { - Schema::table('hambern_company_services', function($table) - { + Schema::table('hambern_company_services', function ($table) { $table->string('slug')->index(); }); @@ -19,11 +18,10 @@ public function up() $model->save(); }); } - + public function down() { - Schema::table('hambern_company_services', function($table) - { + Schema::table('hambern_company_services', function ($table) { $table->dropColumn('slug'); }); } diff --git a/updates/builder_table_update_hambern_company_tags.php b/updates/builder_table_update_hambern_company_tags.php index edc56ca..dca3816 100644 --- a/updates/builder_table_update_hambern_company_tags.php +++ b/updates/builder_table_update_hambern_company_tags.php @@ -8,8 +8,7 @@ class BuilderTableUpdateHambernCompanyTags extends Migration { public function up() { - Schema::table('hambern_company_tags', function($table) - { + Schema::table('hambern_company_tags', function ($table) { $table->string('slug')->index(); }); @@ -19,11 +18,10 @@ public function up() $model->save(); }); } - + public function down() { - Schema::table('hambern_company_tags', function($table) - { + Schema::table('hambern_company_tags', function ($table) { $table->dropColumn('slug'); }); } diff --git a/updates/change_employees_table_20160816.php b/updates/change_employees_table_20160816.php index 4da3a07..528df9c 100644 --- a/updates/change_employees_table_20160816.php +++ b/updates/change_employees_table_20160816.php @@ -6,17 +6,17 @@ class ChangeEmployeesTable20160816 extends Migration { - public function up() - { - Schema::table('hambern_company_employees', function ($table) { - $table->text('social_media')->nullable(); - }); - } + public function up() + { + Schema::table('hambern_company_employees', function ($table) { + $table->text('social_media')->nullable(); + }); + } - public function down() - { - Schema::table('hambern_company_employees', function($table) { - $table->dropColumn('social_media'); - }); - } + public function down() + { + Schema::table('hambern_company_employees', function ($table) { + $table->dropColumn('social_media'); + }); + } } diff --git a/updates/change_employees_table_20160831.php b/updates/change_employees_table_20160831.php index 78569ae..24a59d1 100644 --- a/updates/change_employees_table_20160831.php +++ b/updates/change_employees_table_20160831.php @@ -6,17 +6,17 @@ class ChangeEmployeesTable20160831 extends Migration { - public function up() - { - Schema::table('hambern_company_employees', function ($table) { - $table->text('social_media')->nullable()->change(); - }); - } + public function up() + { + Schema::table('hambern_company_employees', function ($table) { + $table->text('social_media')->nullable()->change(); + }); + } - public function down() - { - Schema::table('hambern_company_employees', function ($table) { - $table->text('social_media')->change(); - }); - } + public function down() + { + Schema::table('hambern_company_employees', function ($table) { + $table->text('social_media')->change(); + }); + } } diff --git a/updates/change_pivots_table_20160918.php b/updates/change_pivots_table_20160918.php index f002d40..49f05cd 100644 --- a/updates/change_pivots_table_20160918.php +++ b/updates/change_pivots_table_20160918.php @@ -6,17 +6,17 @@ class ChangePivotsTable20160918 extends Migration { - public function up() - { - Schema::table('hambern_company_pivots', function ($table) { - $table->integer('tag_id')->nullable(); - }); - } + public function up() + { + Schema::table('hambern_company_pivots', function ($table) { + $table->integer('tag_id')->nullable(); + }); + } - public function down() - { - Schema::table('hambern_company_pivots', function($table) { - $table->dropColumn('tag_id'); - }); - } + public function down() + { + Schema::table('hambern_company_pivots', function ($table) { + $table->dropColumn('tag_id'); + }); + } } diff --git a/updates/change_roles_table_20160202.php b/updates/change_roles_table_20160202.php index b5a73a2..f77a89c 100644 --- a/updates/change_roles_table_20160202.php +++ b/updates/change_roles_table_20160202.php @@ -6,22 +6,22 @@ class ChangeRolesTable20160202 extends Migration { - public function up() - { - Schema::table('hambern_company_roles', function ($table) { - $table->text('description')->change(); - $table->date('published_at')->nullable(); - }); - } + public function up() + { + Schema::table('hambern_company_roles', function ($table) { + $table->text('description')->change(); + $table->date('published_at')->nullable(); + }); + } - public function down() - { - Schema::table('hambern_company_roles', function ($table) { - $table->string('description')->change(); - if (Schema::hasColumn('hambern_company_roles', 'published_at')) { - $table->dropColumn('published_at'); - } - }); - } + public function down() + { + Schema::table('hambern_company_roles', function ($table) { + $table->string('description')->change(); + if (Schema::hasColumn('hambern_company_roles', 'published_at')) { + $table->dropColumn('published_at'); + } + }); + } } diff --git a/updates/change_testimonials_table_20160201.php b/updates/change_testimonials_table_20160201.php index c3fb056..136cf6e 100644 --- a/updates/change_testimonials_table_20160201.php +++ b/updates/change_testimonials_table_20160201.php @@ -6,18 +6,18 @@ class ChangeTestimonialsTable20160201 extends Migration { - public function up() - { - Schema::table('hambern_company_testimonials', function ($table) { - $table->text('content')->change(); - }); - } + public function up() + { + Schema::table('hambern_company_testimonials', function ($table) { + $table->text('content')->change(); + }); + } - public function down() - { - Schema::table('hambern_company_testimonials', function ($table) { - $table->string('content')->change(); - }); - } + public function down() + { + Schema::table('hambern_company_testimonials', function ($table) { + $table->string('content')->change(); + }); + } } diff --git a/updates/create_employees_table.php b/updates/create_employees_table.php index c0eca72..fb75f8d 100644 --- a/updates/create_employees_table.php +++ b/updates/create_employees_table.php @@ -6,26 +6,26 @@ class CreateEmployeesTable extends Migration { - public function up() - { - Schema::create('hambern_company_employees', function ($table) { - $table->engine = 'InnoDB'; - $table->increments('id'); - $table->string('first_name'); - $table->string('last_name'); - $table->text('description'); - $table->string('quote'); - $table->string('email'); - $table->string('phone'); - $table->date('born_at')->nullable(); - $table->date('published_at')->nullable(); - $table->nullableTimestamps(); - }); - } + public function up() + { + Schema::create('hambern_company_employees', function ($table) { + $table->engine = 'InnoDB'; + $table->increments('id'); + $table->string('first_name'); + $table->string('last_name'); + $table->text('description'); + $table->string('quote'); + $table->string('email'); + $table->string('phone'); + $table->date('born_at')->nullable(); + $table->date('published_at')->nullable(); + $table->nullableTimestamps(); + }); + } - public function down() - { - Schema::dropIfExists('hambern_company_employees'); - } + public function down() + { + Schema::dropIfExists('hambern_company_employees'); + } } diff --git a/updates/create_galleries_table.php b/updates/create_galleries_table.php index 78356a8..561d69a 100644 --- a/updates/create_galleries_table.php +++ b/updates/create_galleries_table.php @@ -6,21 +6,21 @@ class CreateGalleriesTable extends Migration { - public function up() - { - Schema::create('hambern_company_galleries', function ($table) { - $table->engine = 'InnoDB'; - $table->increments('id'); - $table->string('name'); - $table->text('description'); - $table->date('published_at')->nullable(); - $table->nullableTimestamps(); - }); - } + public function up() + { + Schema::create('hambern_company_galleries', function ($table) { + $table->engine = 'InnoDB'; + $table->increments('id'); + $table->string('name'); + $table->text('description'); + $table->date('published_at')->nullable(); + $table->nullableTimestamps(); + }); + } - public function down() - { - Schema::dropIfExists('hambern_company_galleries'); - } + public function down() + { + Schema::dropIfExists('hambern_company_galleries'); + } } diff --git a/updates/create_links_table.php b/updates/create_links_table.php index 6cdbaa7..247170f 100644 --- a/updates/create_links_table.php +++ b/updates/create_links_table.php @@ -8,7 +8,7 @@ class CreateLinksTable extends Migration public function up() { - Schema::create('hambern_company_links', function($table) { + Schema::create('hambern_company_links', function ($table) { $table->engine = 'InnoDB'; $table->increments('id'); $table->string('name'); @@ -18,7 +18,7 @@ public function up() $table->date('published_at')->nullable(); $table->nullableTimestamps(); }); - Schema::table('hambern_company_pivots', function($table) { + Schema::table('hambern_company_pivots', function ($table) { $table->integer('link_id')->unsigned()->nullable()->index(); }); } @@ -26,12 +26,12 @@ public function up() public function down() { Schema::dropIfExists('hambern_company_links'); - + if (Schema::hasColumn('hambern_company_pivots', 'link_id')) { - Schema::table('hambern_company_pivots', function($table) { + Schema::table('hambern_company_pivots', function ($table) { $table->dropColumn('link_id'); }); - } + } } } diff --git a/updates/create_pivots_table.php b/updates/create_pivots_table.php index 48417db..41c182d 100644 --- a/updates/create_pivots_table.php +++ b/updates/create_pivots_table.php @@ -6,28 +6,28 @@ class CreatePivotsTable extends Migration { - public $models = [ - 'employee', - 'gallery', - 'project', - 'role', - 'service', - 'testimonial', - ]; + public $models = [ + 'employee', + 'gallery', + 'project', + 'role', + 'service', + 'testimonial', + ]; - public function up() - { - Schema::create('hambern_company_pivots', function ($table) { - $table->engine = 'InnoDB'; - foreach ($this->models as $model) { - $table->integer($model . '_id')->unsigned()->nullable()->index(); - } - }); - } + public function up() + { + Schema::create('hambern_company_pivots', function ($table) { + $table->engine = 'InnoDB'; + foreach ($this->models as $model) { + $table->integer($model . '_id')->unsigned()->nullable()->index(); + } + }); + } - public function down() - { - Schema::dropIfExists('hambern_company_pivots'); - } + public function down() + { + Schema::dropIfExists('hambern_company_pivots'); + } } diff --git a/updates/create_projects_table.php b/updates/create_projects_table.php index 91f197f..8ce9367 100644 --- a/updates/create_projects_table.php +++ b/updates/create_projects_table.php @@ -6,23 +6,23 @@ class CreateProjectsTable extends Migration { - public function up() - { - Schema::create('hambern_company_projects', function ($table) { - $table->engine = 'InnoDB'; - $table->increments('id'); - $table->string('name'); - $table->text('description'); - $table->string('customer'); - $table->string('url'); - $table->date('published_at')->nullable(); - $table->nullableTimestamps(); - }); - } + public function up() + { + Schema::create('hambern_company_projects', function ($table) { + $table->engine = 'InnoDB'; + $table->increments('id'); + $table->string('name'); + $table->text('description'); + $table->string('customer'); + $table->string('url'); + $table->date('published_at')->nullable(); + $table->nullableTimestamps(); + }); + } - public function down() - { - Schema::dropIfExists('hambern_company_projects'); - } + public function down() + { + Schema::dropIfExists('hambern_company_projects'); + } } diff --git a/updates/create_roles_table.php b/updates/create_roles_table.php index 6d6237e..d86352d 100644 --- a/updates/create_roles_table.php +++ b/updates/create_roles_table.php @@ -6,20 +6,20 @@ class CreateRolesTable extends Migration { - public function up() - { - Schema::create('hambern_company_roles', function ($table) { - $table->engine = 'InnoDB'; - $table->increments('id'); - $table->string('name'); - $table->string('description'); - $table->nullableTimestamps(); - }); - } + public function up() + { + Schema::create('hambern_company_roles', function ($table) { + $table->engine = 'InnoDB'; + $table->increments('id'); + $table->string('name'); + $table->string('description'); + $table->nullableTimestamps(); + }); + } - public function down() - { - Schema::dropIfExists('hambern_company_roles'); - } + public function down() + { + Schema::dropIfExists('hambern_company_roles'); + } } diff --git a/updates/create_services_table.php b/updates/create_services_table.php index ba23f3c..a7a1849 100644 --- a/updates/create_services_table.php +++ b/updates/create_services_table.php @@ -6,22 +6,22 @@ class CreateServicesTable extends Migration { - public function up() - { - Schema::create('hambern_company_services', function ($table) { - $table->engine = 'InnoDB'; - $table->increments('id'); - $table->string('name'); - $table->string('icon'); - $table->text('description'); - $table->date('published_at')->nullable(); - $table->nullableTimestamps(); - }); - } + public function up() + { + Schema::create('hambern_company_services', function ($table) { + $table->engine = 'InnoDB'; + $table->increments('id'); + $table->string('name'); + $table->string('icon'); + $table->text('description'); + $table->date('published_at')->nullable(); + $table->nullableTimestamps(); + }); + } - public function down() - { - Schema::dropIfExists('hambern_company_services'); - } + public function down() + { + Schema::dropIfExists('hambern_company_services'); + } } diff --git a/updates/create_tags_table.php b/updates/create_tags_table.php index af8f21b..2ce3103 100644 --- a/updates/create_tags_table.php +++ b/updates/create_tags_table.php @@ -8,7 +8,7 @@ class CreateTagsTable extends Migration { public function up() { - Schema::create('hambern_company_tags', function(Blueprint $table) { + Schema::create('hambern_company_tags', function (Blueprint $table) { $table->engine = 'InnoDB'; $table->increments('id'); $table->string('name'); diff --git a/updates/create_testimonials_table.php b/updates/create_testimonials_table.php index c256e8f..6576a54 100644 --- a/updates/create_testimonials_table.php +++ b/updates/create_testimonials_table.php @@ -6,22 +6,22 @@ class CreateTestimonialsTable extends Migration { - public function up() - { - Schema::create('hambern_company_testimonials', function ($table) { - $table->engine = 'InnoDB'; - $table->increments('id'); - $table->string('content'); - $table->string('source'); - $table->string('url'); - $table->date('published_at')->nullable(); - $table->nullableTimestamps(); - }); - } + public function up() + { + Schema::create('hambern_company_testimonials', function ($table) { + $table->engine = 'InnoDB'; + $table->increments('id'); + $table->string('content'); + $table->string('source'); + $table->string('url'); + $table->date('published_at')->nullable(); + $table->nullableTimestamps(); + }); + } - public function down() - { - Schema::dropIfExists('hambern_company_testimonials'); - } + public function down() + { + Schema::dropIfExists('hambern_company_testimonials'); + } } diff --git a/updates/version.yaml b/updates/version.yaml index 60a34a6..930e91b 100644 --- a/updates/version.yaml +++ b/updates/version.yaml @@ -131,3 +131,4 @@ - 'Updated table hambern_company_roles' - builder_table_update_hambern_company_roles.php 1.4.8: 'Slug attribute for pretty urls' +1.4.9: 'Codebase PSR2 coding standard' \ No newline at end of file