Add (categories)
This commit is contained in:
@@ -57,3 +57,5 @@ VITE_PUSHER_HOST="${PUSHER_HOST}"
|
||||
VITE_PUSHER_PORT="${PUSHER_PORT}"
|
||||
VITE_PUSHER_SCHEME="${PUSHER_SCHEME}"
|
||||
VITE_PUSHER_APP_CLUSTER="${PUSHER_APP_CLUSTER}"
|
||||
|
||||
GOOGLE_TAG_MANAGER_ID=xxx
|
||||
|
||||
@@ -36,6 +36,7 @@ class Kernel extends HttpKernel
|
||||
\Illuminate\View\Middleware\ShareErrorsFromSession::class,
|
||||
\App\Http\Middleware\VerifyCsrfToken::class,
|
||||
\Illuminate\Routing\Middleware\SubstituteBindings::class,
|
||||
\Spatie\GoogleTagManager\GoogleTagManagerMiddleware::class,
|
||||
],
|
||||
|
||||
'api' => [
|
||||
|
||||
73
app/Models/Category.php
Normal file
73
app/Models/Category.php
Normal file
@@ -0,0 +1,73 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Created by Reliese Model.
|
||||
*/
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Carbon\Carbon;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Kalnoy\Nestedset\NodeTrait;
|
||||
use Illuminate\Support\Str;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Class Category
|
||||
*
|
||||
* @property int $id
|
||||
* @property string $name
|
||||
* @property string|null $slug
|
||||
* @property bool $enabled
|
||||
* @property Carbon|null $created_at
|
||||
* @property Carbon|null $updated_at
|
||||
* @property int $_lft
|
||||
* @property int $_rgt
|
||||
* @property int|null $parent_id
|
||||
*
|
||||
* @package App\Models
|
||||
*/
|
||||
class Category extends Model
|
||||
{
|
||||
use NodeTrait;
|
||||
|
||||
protected $table = 'categories';
|
||||
|
||||
protected $casts = [
|
||||
'enabled' => 'bool',
|
||||
'_lft' => 'int',
|
||||
'_rgt' => 'int',
|
||||
'parent_id' => 'int'
|
||||
];
|
||||
|
||||
protected $fillable = [
|
||||
'name',
|
||||
'slug',
|
||||
'enabled',
|
||||
'_lft',
|
||||
'_rgt',
|
||||
'parent_id'
|
||||
];
|
||||
|
||||
protected static function boot()
|
||||
{
|
||||
parent::boot();
|
||||
|
||||
static::saved(function ($category) {
|
||||
if (empty($category->slug)) {
|
||||
$category->slug = Str::slug($category->name);
|
||||
$category->saveQuietly();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
public function saveQuietly(array $options = [])
|
||||
{
|
||||
return static::withoutEvents(function () use ($options) {
|
||||
return $this->save($options);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -6,10 +6,13 @@
|
||||
"license": "MIT",
|
||||
"require": {
|
||||
"php": "^8.1",
|
||||
"artesaos/seotools": "^1.2",
|
||||
"guzzlehttp/guzzle": "^7.2",
|
||||
"kalnoy/nestedset": "^6.0",
|
||||
"laravel/framework": "^10.10",
|
||||
"laravel/sanctum": "^3.2",
|
||||
"laravel/tinker": "^2.8"
|
||||
"laravel/tinker": "^2.8",
|
||||
"spatie/laravel-googletagmanager": "^2.6"
|
||||
},
|
||||
"require-dev": {
|
||||
"fakerphp/faker": "^1.9.1",
|
||||
@@ -19,6 +22,7 @@
|
||||
"nunomaduro/collision": "^7.0",
|
||||
"pestphp/pest": "^2.0",
|
||||
"pestphp/pest-plugin-laravel": "^2.0",
|
||||
"reliese/laravel": "^1.2",
|
||||
"spatie/laravel-ignition": "^2.0"
|
||||
},
|
||||
"autoload": {
|
||||
|
||||
614
composer.lock
generated
614
composer.lock
generated
@@ -4,8 +4,80 @@
|
||||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
||||
"This file is @generated automatically"
|
||||
],
|
||||
"content-hash": "f396510c7eef1c549b45608d897cd6b5",
|
||||
"content-hash": "c15e60f5acf3cb829ee1ea5a9cf4432c",
|
||||
"packages": [
|
||||
{
|
||||
"name": "artesaos/seotools",
|
||||
"version": "v1.2.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/artesaos/seotools.git",
|
||||
"reference": "99744eaa8c3e21a2121914d8a7ca61284e5497a4"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/artesaos/seotools/zipball/99744eaa8c3e21a2121914d8a7ca61284e5497a4",
|
||||
"reference": "99744eaa8c3e21a2121914d8a7ca61284e5497a4",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"ext-json": "*",
|
||||
"illuminate/config": "5.8.* || ^6.0 || ^7.0 || ^8.0 || ^9.0 || ^10.0",
|
||||
"illuminate/support": "5.8.* || ^6.0 || ^7.0 || ^8.0 || ^9.0 || ^10.0",
|
||||
"php": ">=7.1|^8.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"orchestra/testbench": "~3.8.4 || ^4.0 || ^5.0 || ^6.0 || ^7.0 || ^8.0",
|
||||
"phpspec/phpspec": "~5.1.1 || ^6.0 || ^7.0",
|
||||
"phpunit/phpunit": "^9.0"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"laravel": {
|
||||
"providers": [
|
||||
"Artesaos\\SEOTools\\Providers\\SEOToolsServiceProvider"
|
||||
],
|
||||
"aliases": {
|
||||
"SEOMeta": "Artesaos\\SEOTools\\Facades\\SEOMeta",
|
||||
"OpenGraph": "Artesaos\\SEOTools\\Facades\\OpenGraph",
|
||||
"Twitter": "Artesaos\\SEOTools\\Facades\\TwitterCard",
|
||||
"JsonLd": "Artesaos\\SEOTools\\Facades\\JsonLd",
|
||||
"SEO": "Artesaos\\SEOTools\\Facades\\SEOTools"
|
||||
}
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Artesaos\\SEOTools\\": "src/SEOTools/"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Vinicius",
|
||||
"email": "luiz.vinicius73@gmail.com"
|
||||
}
|
||||
],
|
||||
"description": "SEO Tools for Laravel and Lumen",
|
||||
"keywords": [
|
||||
"JSON-LD",
|
||||
"laravel",
|
||||
"lumen",
|
||||
"metatags",
|
||||
"opengraph",
|
||||
"seo",
|
||||
"seotools",
|
||||
"webmaster"
|
||||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/artesaos/seotools/issues",
|
||||
"source": "https://github.com/artesaos/seotools"
|
||||
},
|
||||
"time": "2023-05-09T14:20:42+00:00"
|
||||
},
|
||||
{
|
||||
"name": "brick/math",
|
||||
"version": "0.11.0",
|
||||
@@ -970,6 +1042,69 @@
|
||||
],
|
||||
"time": "2023-08-27T10:19:19+00:00"
|
||||
},
|
||||
{
|
||||
"name": "kalnoy/nestedset",
|
||||
"version": "v6.0.2",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/lazychaser/laravel-nestedset.git",
|
||||
"reference": "2d5c99fe1bfbaa4004f8d6fb24475f7ff88bb526"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/lazychaser/laravel-nestedset/zipball/2d5c99fe1bfbaa4004f8d6fb24475f7ff88bb526",
|
||||
"reference": "2d5c99fe1bfbaa4004f8d6fb24475f7ff88bb526",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"illuminate/database": "^7.0|^8.0|^9.0|^10.0",
|
||||
"illuminate/events": "^7.0|^8.0|^9.0|^10.0",
|
||||
"illuminate/support": "^7.0|^8.0|^9.0|^10.0",
|
||||
"php": "^7.2.5|^8.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"phpunit/phpunit": "7.*|8.*|9.*"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "v5.0.x-dev"
|
||||
},
|
||||
"laravel": {
|
||||
"providers": [
|
||||
"Kalnoy\\Nestedset\\NestedSetServiceProvider"
|
||||
]
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Kalnoy\\Nestedset\\": "src/"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Alexander Kalnoy",
|
||||
"email": "lazychaser@gmail.com"
|
||||
}
|
||||
],
|
||||
"description": "Nested Set Model for Laravel 5.7 and up",
|
||||
"keywords": [
|
||||
"database",
|
||||
"hierarchy",
|
||||
"laravel",
|
||||
"nested sets",
|
||||
"nsm"
|
||||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/lazychaser/laravel-nestedset/issues",
|
||||
"source": "https://github.com/lazychaser/laravel-nestedset/tree/v6.0.2"
|
||||
},
|
||||
"time": "2023-02-16T14:41:24+00:00"
|
||||
},
|
||||
{
|
||||
"name": "laravel/framework",
|
||||
"version": "v10.24.0",
|
||||
@@ -3096,6 +3231,74 @@
|
||||
],
|
||||
"time": "2023-04-15T23:01:58+00:00"
|
||||
},
|
||||
{
|
||||
"name": "spatie/laravel-googletagmanager",
|
||||
"version": "2.6.6",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/spatie/laravel-googletagmanager.git",
|
||||
"reference": "19f257e203c0a3547328f142acf31a99ad895378"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/spatie/laravel-googletagmanager/zipball/19f257e203c0a3547328f142acf31a99ad895378",
|
||||
"reference": "19f257e203c0a3547328f142acf31a99ad895378",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": ">=5.4.0"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "1.0-dev"
|
||||
},
|
||||
"laravel": {
|
||||
"providers": [
|
||||
"Spatie\\GoogleTagManager\\GoogleTagManagerServiceProvider"
|
||||
],
|
||||
"aliases": {
|
||||
"GoogleTagManager": "Spatie\\GoogleTagManager\\GoogleTagManagerFacade"
|
||||
}
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Spatie\\GoogleTagManager\\": "src"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Sebastian De Deyne",
|
||||
"email": "sebastian@spatie.be",
|
||||
"homepage": "https://spatie.be",
|
||||
"role": "Developer"
|
||||
}
|
||||
],
|
||||
"description": "Google Tag Manager integration for Laravel",
|
||||
"homepage": "https://github.com/spatie/laravel-googletagmanager",
|
||||
"keywords": [
|
||||
"Google Tag Manager",
|
||||
"laravel",
|
||||
"laravel-googletagmanager",
|
||||
"spatie"
|
||||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/spatie/laravel-googletagmanager/issues",
|
||||
"source": "https://github.com/spatie/laravel-googletagmanager/tree/2.6.6"
|
||||
},
|
||||
"funding": [
|
||||
{
|
||||
"url": "https://github.com/spatie",
|
||||
"type": "github"
|
||||
}
|
||||
],
|
||||
"time": "2021-12-15T10:28:22+00:00"
|
||||
},
|
||||
{
|
||||
"name": "symfony/console",
|
||||
"version": "v6.3.4",
|
||||
@@ -5713,6 +5916,212 @@
|
||||
],
|
||||
"time": "2023-09-14T14:10:09+00:00"
|
||||
},
|
||||
{
|
||||
"name": "doctrine/cache",
|
||||
"version": "2.2.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/doctrine/cache.git",
|
||||
"reference": "1ca8f21980e770095a31456042471a57bc4c68fb"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/doctrine/cache/zipball/1ca8f21980e770095a31456042471a57bc4c68fb",
|
||||
"reference": "1ca8f21980e770095a31456042471a57bc4c68fb",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": "~7.1 || ^8.0"
|
||||
},
|
||||
"conflict": {
|
||||
"doctrine/common": ">2.2,<2.4"
|
||||
},
|
||||
"require-dev": {
|
||||
"cache/integration-tests": "dev-master",
|
||||
"doctrine/coding-standard": "^9",
|
||||
"phpunit/phpunit": "^7.5 || ^8.5 || ^9.5",
|
||||
"psr/cache": "^1.0 || ^2.0 || ^3.0",
|
||||
"symfony/cache": "^4.4 || ^5.4 || ^6",
|
||||
"symfony/var-exporter": "^4.4 || ^5.4 || ^6"
|
||||
},
|
||||
"type": "library",
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Doctrine\\Common\\Cache\\": "lib/Doctrine/Common/Cache"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Guilherme Blanco",
|
||||
"email": "guilhermeblanco@gmail.com"
|
||||
},
|
||||
{
|
||||
"name": "Roman Borschel",
|
||||
"email": "roman@code-factory.org"
|
||||
},
|
||||
{
|
||||
"name": "Benjamin Eberlei",
|
||||
"email": "kontakt@beberlei.de"
|
||||
},
|
||||
{
|
||||
"name": "Jonathan Wage",
|
||||
"email": "jonwage@gmail.com"
|
||||
},
|
||||
{
|
||||
"name": "Johannes Schmitt",
|
||||
"email": "schmittjoh@gmail.com"
|
||||
}
|
||||
],
|
||||
"description": "PHP Doctrine Cache library is a popular cache implementation that supports many different drivers such as redis, memcache, apc, mongodb and others.",
|
||||
"homepage": "https://www.doctrine-project.org/projects/cache.html",
|
||||
"keywords": [
|
||||
"abstraction",
|
||||
"apcu",
|
||||
"cache",
|
||||
"caching",
|
||||
"couchdb",
|
||||
"memcached",
|
||||
"php",
|
||||
"redis",
|
||||
"xcache"
|
||||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/doctrine/cache/issues",
|
||||
"source": "https://github.com/doctrine/cache/tree/2.2.0"
|
||||
},
|
||||
"funding": [
|
||||
{
|
||||
"url": "https://www.doctrine-project.org/sponsorship.html",
|
||||
"type": "custom"
|
||||
},
|
||||
{
|
||||
"url": "https://www.patreon.com/phpdoctrine",
|
||||
"type": "patreon"
|
||||
},
|
||||
{
|
||||
"url": "https://tidelift.com/funding/github/packagist/doctrine%2Fcache",
|
||||
"type": "tidelift"
|
||||
}
|
||||
],
|
||||
"time": "2022-05-20T20:07:39+00:00"
|
||||
},
|
||||
{
|
||||
"name": "doctrine/dbal",
|
||||
"version": "3.6.6",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/doctrine/dbal.git",
|
||||
"reference": "63646ffd71d1676d2f747f871be31b7e921c7864"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/doctrine/dbal/zipball/63646ffd71d1676d2f747f871be31b7e921c7864",
|
||||
"reference": "63646ffd71d1676d2f747f871be31b7e921c7864",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"composer-runtime-api": "^2",
|
||||
"doctrine/cache": "^1.11|^2.0",
|
||||
"doctrine/deprecations": "^0.5.3|^1",
|
||||
"doctrine/event-manager": "^1|^2",
|
||||
"php": "^7.4 || ^8.0",
|
||||
"psr/cache": "^1|^2|^3",
|
||||
"psr/log": "^1|^2|^3"
|
||||
},
|
||||
"require-dev": {
|
||||
"doctrine/coding-standard": "12.0.0",
|
||||
"fig/log-test": "^1",
|
||||
"jetbrains/phpstorm-stubs": "2023.1",
|
||||
"phpstan/phpstan": "1.10.29",
|
||||
"phpstan/phpstan-strict-rules": "^1.5",
|
||||
"phpunit/phpunit": "9.6.9",
|
||||
"psalm/plugin-phpunit": "0.18.4",
|
||||
"slevomat/coding-standard": "8.13.1",
|
||||
"squizlabs/php_codesniffer": "3.7.2",
|
||||
"symfony/cache": "^5.4|^6.0",
|
||||
"symfony/console": "^4.4|^5.4|^6.0",
|
||||
"vimeo/psalm": "4.30.0"
|
||||
},
|
||||
"suggest": {
|
||||
"symfony/console": "For helpful console commands such as SQL execution and import of files."
|
||||
},
|
||||
"bin": [
|
||||
"bin/doctrine-dbal"
|
||||
],
|
||||
"type": "library",
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Doctrine\\DBAL\\": "src"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Guilherme Blanco",
|
||||
"email": "guilhermeblanco@gmail.com"
|
||||
},
|
||||
{
|
||||
"name": "Roman Borschel",
|
||||
"email": "roman@code-factory.org"
|
||||
},
|
||||
{
|
||||
"name": "Benjamin Eberlei",
|
||||
"email": "kontakt@beberlei.de"
|
||||
},
|
||||
{
|
||||
"name": "Jonathan Wage",
|
||||
"email": "jonwage@gmail.com"
|
||||
}
|
||||
],
|
||||
"description": "Powerful PHP database abstraction layer (DBAL) with many features for database schema introspection and management.",
|
||||
"homepage": "https://www.doctrine-project.org/projects/dbal.html",
|
||||
"keywords": [
|
||||
"abstraction",
|
||||
"database",
|
||||
"db2",
|
||||
"dbal",
|
||||
"mariadb",
|
||||
"mssql",
|
||||
"mysql",
|
||||
"oci8",
|
||||
"oracle",
|
||||
"pdo",
|
||||
"pgsql",
|
||||
"postgresql",
|
||||
"queryobject",
|
||||
"sasql",
|
||||
"sql",
|
||||
"sqlite",
|
||||
"sqlserver",
|
||||
"sqlsrv"
|
||||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/doctrine/dbal/issues",
|
||||
"source": "https://github.com/doctrine/dbal/tree/3.6.6"
|
||||
},
|
||||
"funding": [
|
||||
{
|
||||
"url": "https://www.doctrine-project.org/sponsorship.html",
|
||||
"type": "custom"
|
||||
},
|
||||
{
|
||||
"url": "https://www.patreon.com/phpdoctrine",
|
||||
"type": "patreon"
|
||||
},
|
||||
{
|
||||
"url": "https://tidelift.com/funding/github/packagist/doctrine%2Fdbal",
|
||||
"type": "tidelift"
|
||||
}
|
||||
],
|
||||
"time": "2023-08-17T05:38:17+00:00"
|
||||
},
|
||||
{
|
||||
"name": "doctrine/deprecations",
|
||||
"version": "v1.1.1",
|
||||
@@ -5760,6 +6169,97 @@
|
||||
},
|
||||
"time": "2023-06-03T09:27:29+00:00"
|
||||
},
|
||||
{
|
||||
"name": "doctrine/event-manager",
|
||||
"version": "2.0.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/doctrine/event-manager.git",
|
||||
"reference": "750671534e0241a7c50ea5b43f67e23eb5c96f32"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/doctrine/event-manager/zipball/750671534e0241a7c50ea5b43f67e23eb5c96f32",
|
||||
"reference": "750671534e0241a7c50ea5b43f67e23eb5c96f32",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": "^8.1"
|
||||
},
|
||||
"conflict": {
|
||||
"doctrine/common": "<2.9"
|
||||
},
|
||||
"require-dev": {
|
||||
"doctrine/coding-standard": "^10",
|
||||
"phpstan/phpstan": "^1.8.8",
|
||||
"phpunit/phpunit": "^9.5",
|
||||
"vimeo/psalm": "^4.28"
|
||||
},
|
||||
"type": "library",
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Doctrine\\Common\\": "src"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Guilherme Blanco",
|
||||
"email": "guilhermeblanco@gmail.com"
|
||||
},
|
||||
{
|
||||
"name": "Roman Borschel",
|
||||
"email": "roman@code-factory.org"
|
||||
},
|
||||
{
|
||||
"name": "Benjamin Eberlei",
|
||||
"email": "kontakt@beberlei.de"
|
||||
},
|
||||
{
|
||||
"name": "Jonathan Wage",
|
||||
"email": "jonwage@gmail.com"
|
||||
},
|
||||
{
|
||||
"name": "Johannes Schmitt",
|
||||
"email": "schmittjoh@gmail.com"
|
||||
},
|
||||
{
|
||||
"name": "Marco Pivetta",
|
||||
"email": "ocramius@gmail.com"
|
||||
}
|
||||
],
|
||||
"description": "The Doctrine Event Manager is a simple PHP event system that was built to be used with the various Doctrine projects.",
|
||||
"homepage": "https://www.doctrine-project.org/projects/event-manager.html",
|
||||
"keywords": [
|
||||
"event",
|
||||
"event dispatcher",
|
||||
"event manager",
|
||||
"event system",
|
||||
"events"
|
||||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/doctrine/event-manager/issues",
|
||||
"source": "https://github.com/doctrine/event-manager/tree/2.0.0"
|
||||
},
|
||||
"funding": [
|
||||
{
|
||||
"url": "https://www.doctrine-project.org/sponsorship.html",
|
||||
"type": "custom"
|
||||
},
|
||||
{
|
||||
"url": "https://www.patreon.com/phpdoctrine",
|
||||
"type": "patreon"
|
||||
},
|
||||
{
|
||||
"url": "https://tidelift.com/funding/github/packagist/doctrine%2Fevent-manager",
|
||||
"type": "tidelift"
|
||||
}
|
||||
],
|
||||
"time": "2022-10-12T20:59:15+00:00"
|
||||
},
|
||||
{
|
||||
"name": "fakerphp/faker",
|
||||
"version": "v1.23.0",
|
||||
@@ -7492,6 +7992,118 @@
|
||||
],
|
||||
"time": "2023-09-19T05:42:37+00:00"
|
||||
},
|
||||
{
|
||||
"name": "psr/cache",
|
||||
"version": "3.0.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/php-fig/cache.git",
|
||||
"reference": "aa5030cfa5405eccfdcb1083ce040c2cb8d253bf"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/php-fig/cache/zipball/aa5030cfa5405eccfdcb1083ce040c2cb8d253bf",
|
||||
"reference": "aa5030cfa5405eccfdcb1083ce040c2cb8d253bf",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": ">=8.0.0"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "1.0.x-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Psr\\Cache\\": "src/"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "PHP-FIG",
|
||||
"homepage": "https://www.php-fig.org/"
|
||||
}
|
||||
],
|
||||
"description": "Common interface for caching libraries",
|
||||
"keywords": [
|
||||
"cache",
|
||||
"psr",
|
||||
"psr-6"
|
||||
],
|
||||
"support": {
|
||||
"source": "https://github.com/php-fig/cache/tree/3.0.0"
|
||||
},
|
||||
"time": "2021-02-03T23:26:27+00:00"
|
||||
},
|
||||
{
|
||||
"name": "reliese/laravel",
|
||||
"version": "v1.2.3",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/reliese/laravel.git",
|
||||
"reference": "3e0d2e5054c6c4f815d72f22915b35e3ffe82858"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/reliese/laravel/zipball/3e0d2e5054c6c4f815d72f22915b35e3ffe82858",
|
||||
"reference": "3e0d2e5054c6c4f815d72f22915b35e3ffe82858",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"doctrine/dbal": ">=2.5",
|
||||
"illuminate/console": ">=5.1",
|
||||
"illuminate/contracts": ">=5.1",
|
||||
"illuminate/database": ">=5.1",
|
||||
"illuminate/filesystem": ">=5.1",
|
||||
"illuminate/support": ">=5.1",
|
||||
"php": "^7.3|^8.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"fzaninotto/faker": "~1.4",
|
||||
"mockery/mockery": ">=1.4",
|
||||
"phpunit/phpunit": "^9"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"laravel": {
|
||||
"providers": [
|
||||
"Reliese\\Coders\\CodersServiceProvider"
|
||||
]
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Reliese\\": "src/"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Cristian Llanos",
|
||||
"email": "cristianllanos@outlook.com"
|
||||
}
|
||||
],
|
||||
"description": "Reliese Components for Laravel Framework code generation.",
|
||||
"homepage": "http://cristianllanos.com",
|
||||
"keywords": [
|
||||
"laravel",
|
||||
"reliese"
|
||||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/reliese/laravel/issues",
|
||||
"source": "https://github.com/reliese/laravel"
|
||||
},
|
||||
"time": "2023-08-17T07:50:33+00:00"
|
||||
},
|
||||
{
|
||||
"name": "sebastian/cli-parser",
|
||||
"version": "2.0.0",
|
||||
|
||||
@@ -159,6 +159,7 @@
|
||||
/*
|
||||
* Package Service Providers...
|
||||
*/
|
||||
Artesaos\SEOTools\Providers\SEOToolsServiceProvider::class,
|
||||
|
||||
/*
|
||||
* Application Service Providers...
|
||||
@@ -182,7 +183,12 @@
|
||||
*/
|
||||
|
||||
'aliases' => Facade::defaultAliases()->merge([
|
||||
// 'Example' => App\Facades\Example::class,
|
||||
'SEOMeta' => Artesaos\SEOTools\Facades\SEOMeta::class,
|
||||
'OpenGraph' => Artesaos\SEOTools\Facades\OpenGraph::class,
|
||||
'Twitter' => Artesaos\SEOTools\Facades\TwitterCard::class,
|
||||
'JsonLd' => Artesaos\SEOTools\Facades\JsonLd::class,
|
||||
'JsonLdMulti' => Artesaos\SEOTools\Facades\JsonLdMulti::class,
|
||||
'SEO' => Artesaos\SEOTools\Facades\SEOTools::class,
|
||||
])->toArray(),
|
||||
|
||||
];
|
||||
|
||||
27
config/googletagmanager.php
Normal file
27
config/googletagmanager.php
Normal file
@@ -0,0 +1,27 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
* The Google Tag Manager id, should be a code that looks something like "gtm-xxxx".
|
||||
*/
|
||||
'id' => env('GOOGLE_TAG_MANAGER_ID', ''),
|
||||
|
||||
/*
|
||||
* Enable or disable script rendering. Useful for local development.
|
||||
*/
|
||||
'enabled' => env('GOOGLE_TAG_MANAGER_ENABLED', true),
|
||||
|
||||
/*
|
||||
* If you want to use some macro's you 'll probably store them
|
||||
* in a dedicated file. You can optionally define the path
|
||||
* to that file here and we will load it for you.
|
||||
*/
|
||||
'macroPath' => env('GOOGLE_TAG_MANAGER_MACRO_PATH', ''),
|
||||
|
||||
/*
|
||||
* The key under which data is saved to the session with flash.
|
||||
*/
|
||||
'sessionKey' => env('GOOGLE_TAG_MANAGER_SESSION_KEY', '_googleTagManager'),
|
||||
|
||||
];
|
||||
510
config/models.php
Normal file
510
config/models.php
Normal file
@@ -0,0 +1,510 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Configurations
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| In this section you may define the default configuration for each model
|
||||
| that will be generated from any database.
|
||||
|
|
||||
*/
|
||||
|
||||
'*' => [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Model Files Location
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| We need a location to store your new generated files. All files will be
|
||||
| placed within this directory. When you turn on base files, they will
|
||||
| be placed within a Base directory inside this location.
|
||||
|
|
||||
*/
|
||||
|
||||
'path' => app_path('Models'),
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Model Namespace
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Every generated model will belong to this namespace. It is suggested
|
||||
| that this namespace should follow PSR-4 convention and be very
|
||||
| similar to the path of your models defined above.
|
||||
|
|
||||
*/
|
||||
|
||||
'namespace' => 'App\Models',
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Parent Class
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| All Eloquent models should inherit from Eloquent Model class. However,
|
||||
| you can define a custom Eloquent model that suits your needs.
|
||||
| As an example one custom model has been added for you which
|
||||
| will allow you to create custom database castings.
|
||||
|
|
||||
*/
|
||||
|
||||
'parent' => Illuminate\Database\Eloquent\Model::class,
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Traits
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Sometimes you may want to append certain traits to all your models.
|
||||
| If that is what you need, you may list them bellow.
|
||||
| As an example we have a BitBooleans trait which will treat MySQL bit
|
||||
| data type as booleans. You might probably not need it, but it is
|
||||
| an example of how you can customize your models.
|
||||
|
|
||||
*/
|
||||
|
||||
'use' => [
|
||||
// Reliese\Database\Eloquent\BitBooleans::class,
|
||||
// Reliese\Database\Eloquent\BlamableBehavior::class,
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Model Connection
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If you wish your models had appended the connection from which they
|
||||
| were generated, you should set this value to true and your
|
||||
| models will have the connection property filled.
|
||||
|
|
||||
*/
|
||||
|
||||
'connection' => false,
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Timestamps
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If your tables have CREATED_AT and UPDATED_AT timestamps you may
|
||||
| enable them and your models will fill their values as needed.
|
||||
| You can also specify which fields should be treated as timestamps
|
||||
| in case you don't follow the naming convention Eloquent uses.
|
||||
| If your table doesn't have these fields, timestamps will be
|
||||
| disabled for your model.
|
||||
|
|
||||
*/
|
||||
|
||||
'timestamps' => true,
|
||||
|
||||
// 'timestamps' => [
|
||||
// 'enabled' => true,
|
||||
// 'fields' => [
|
||||
// 'CREATED_AT' => 'created_at',
|
||||
// 'UPDATED_AT' => 'updated_at',
|
||||
// ]
|
||||
// ],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Soft Deletes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If your tables support soft deletes with a DELETED_AT attribute,
|
||||
| you can enable them here. You can also specify which field
|
||||
| should be treated as a soft delete attribute in case you
|
||||
| don't follow the naming convention Eloquent uses.
|
||||
| If your table doesn't have this field, soft deletes will be
|
||||
| disabled for your model.
|
||||
|
|
||||
*/
|
||||
|
||||
'soft_deletes' => true,
|
||||
|
||||
// 'soft_deletes' => [
|
||||
// 'enabled' => true,
|
||||
// 'field' => 'deleted_at',
|
||||
// ],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Date Format
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may define your models' date format. The following format
|
||||
| is the default format Eloquent uses. You won't see it in your
|
||||
| models unless you change it to a more convenient value.
|
||||
|
|
||||
*/
|
||||
|
||||
'date_format' => 'Y-m-d H:i:s',
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Pagination
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may define how many models Eloquent should display when
|
||||
| paginating them. The default number is 15, so you might not
|
||||
| see this number in your models unless you change it.
|
||||
|
|
||||
*/
|
||||
|
||||
'per_page' => 15,
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Base Files
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| By default, your models will be generated in your models path, but
|
||||
| when you generate them again they will be replaced by new ones.
|
||||
| You may want to customize your models and, at the same time, be
|
||||
| able to generate them as your tables change. For that, you
|
||||
| can enable base files. These files will be replaced whenever
|
||||
| you generate them, but your customized files will not be touched.
|
||||
|
|
||||
*/
|
||||
|
||||
'base_files' => false,
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Snake Attributes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Eloquent treats your model attributes as snake cased attributes, but
|
||||
| if you have camel-cased fields in your database you can disable
|
||||
| that behaviour and use camel case attributes in your models.
|
||||
|
|
||||
*/
|
||||
|
||||
'snake_attributes' => true,
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Indent options
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| As default indention is done with tabs, but you can change it by setting
|
||||
| this to the amount of spaces you that you want to use for indentation.
|
||||
| Usually you will use 4 spaces instead of tabs.
|
||||
|
|
||||
*/
|
||||
|
||||
'indent_with_space' => 0,
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Qualified Table Names
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If some of your tables have cross-database relationships (probably in
|
||||
| MySQL), you can make sure your models take into account their
|
||||
| respective database schema.
|
||||
|
|
||||
| Can Either be NULL, FALSE or TRUE
|
||||
| TRUE: Schema name will be prepended on the table
|
||||
| FALSE:Table name will be set without schema name.
|
||||
| NULL: Table name will follow laravel pattern,
|
||||
| i.e. if class name(plural) matches table name, then table name will not be added
|
||||
*/
|
||||
|
||||
'qualified_tables' => false,
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Hidden Attributes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| When casting your models into arrays or json, the need to hide some
|
||||
| attributes sometimes arise. If your tables have some fields you
|
||||
| want to hide, you can define them bellow.
|
||||
| Some fields were defined for you.
|
||||
|
|
||||
*/
|
||||
|
||||
'hidden' => [
|
||||
'*secret*', '*password', '*token',
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Mass Assignment Guarded Attributes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| You may want to protect some fields from mass assignment. You can
|
||||
| define them bellow. Some fields were defined for you.
|
||||
| Your fillable attributes will be those which are not in the list
|
||||
| excluding your models' primary keys.
|
||||
|
|
||||
*/
|
||||
|
||||
'guarded' => [
|
||||
// 'created_by', 'updated_by'
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Casts
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| You may want to specify which of your table fields should be cast as
|
||||
| something other than a string. For instance, you may want a
|
||||
| text field be cast as an array or and object.
|
||||
|
|
||||
| You may define column patterns which will be cast using the value
|
||||
| assigned. We have defined some fields for you. Feel free to
|
||||
| modify them to fit your needs.
|
||||
|
|
||||
*/
|
||||
|
||||
'casts' => [
|
||||
'*_json' => 'json',
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Excluded Tables
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| When performing the generation of models you may want to skip some of
|
||||
| them, because you don't want a model for them or any other reason.
|
||||
| You can define those tables bellow. The migrations table was
|
||||
| filled for you, since you may not want a model for it.
|
||||
|
|
||||
*/
|
||||
|
||||
'except' => [
|
||||
'migrations',
|
||||
'failed_jobs',
|
||||
'password_resets',
|
||||
'personal_access_tokens',
|
||||
'password_reset_tokens',
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Specified Tables
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| You can specify specific tables. This will generate the models only
|
||||
| for selected tables, ignoring the rest.
|
||||
|
|
||||
*/
|
||||
|
||||
'only' => [
|
||||
// 'users',
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Table Prefix
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If you have a prefix on your table names but don't want it in the model
|
||||
| and relation names, specify it here.
|
||||
|
|
||||
*/
|
||||
|
||||
'table_prefix' => '',
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Lower table name before doing studly
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If tables names are capitalised using studly produces incorrect name
|
||||
| this can help fix it ie TABLE_NAME now becomes TableName
|
||||
|
|
||||
*/
|
||||
|
||||
'lower_table_name_first' => false,
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Model Names
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| By default the generator will create models with names that match your tables.
|
||||
| However, if you wish to manually override the naming, you can specify a mapping
|
||||
| here between table and model names.
|
||||
|
|
||||
| Example:
|
||||
| A table called 'billing_invoices' will generate a model called `BillingInvoice`,
|
||||
| but you'd prefer it to generate a model called 'Invoice'. Therefore, you'd add
|
||||
| the following array key and value:
|
||||
| 'billing_invoices' => 'Invoice',
|
||||
*/
|
||||
|
||||
'model_names' => [
|
||||
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Relation Name Strategy
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| How the relations should be named in your models.
|
||||
|
|
||||
| 'related' Use the related table as the relation name.
|
||||
| (post.author --> user.id)
|
||||
generates Post::user() and User::posts()
|
||||
|
|
||||
| 'foreign_key' Use the foreign key as the relation name.
|
||||
| This can help to provide more meaningful relationship names, and avoids naming conflicts
|
||||
| if you have more than one relationship between two tables.
|
||||
| (post.author_id --> user.id)
|
||||
| generates Post::author() and User::posts_where_author()
|
||||
| (post.editor_id --> user.id)
|
||||
| generates Post::editor() and User::posts_where_editor()
|
||||
| ID suffixes can be omitted from foreign keys.
|
||||
| (post.author --> user.id)
|
||||
| (post.editor --> user.id)
|
||||
| generates the same as above.
|
||||
| Where the foreign key matches the related table name, it behaves as per the 'related' strategy.
|
||||
| (post.user_id --> user.id)
|
||||
| generates Post::user() and User::posts()
|
||||
*/
|
||||
|
||||
'relation_name_strategy' => 'related',
|
||||
// 'relation_name_strategy' => 'foreign_key',
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Determines need or not to generate constants with properties names like
|
||||
|
|
||||
| ...
|
||||
| const AGE = 'age';
|
||||
| const USER_NAME = 'user_name';
|
||||
| ...
|
||||
|
|
||||
| that later can be used in QueryBuilder like
|
||||
|
|
||||
| ...
|
||||
| $builder->select([User::USER_NAME])->where(User::AGE, '<=', 18);
|
||||
| ...
|
||||
|
|
||||
| that helps to avoid typos in strings when typing field names and allows to use
|
||||
| code competition with available model's field names.
|
||||
*/
|
||||
'with_property_constants' => false,
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Disable Pluralization Name
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| You can disable pluralization tables and relations
|
||||
|
|
||||
*/
|
||||
'pluralize' => true,
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Disable Pluralization Except For Certain Tables
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| You can enable pluralization for certain tables
|
||||
|
|
||||
*/
|
||||
'override_pluralize_for' => [
|
||||
|
||||
],
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Move $fillable property to base files
|
||||
|--------------------------------------------------------------------------
|
||||
| When base_files is true you can set fillable_in_base_files to true
|
||||
| if you want the $fillable to be generated in base files
|
||||
|
|
||||
*/
|
||||
'fillable_in_base_files' => false,
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Generate return types for relation methods.
|
||||
|--------------------------------------------------------------------------
|
||||
| When enable_return_types is set to true, return type declarations are added
|
||||
| to all generated relation methods for your models.
|
||||
|
|
||||
| NOTE: This requires PHP 7.0 or later.
|
||||
|
|
||||
*/
|
||||
'enable_return_types' => false,
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Database Specifics
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| In this section you may define the default configuration for each model
|
||||
| that will be generated from a specific database. You can also nest
|
||||
| table specific configurations.
|
||||
| These values will override those defined in the section above.
|
||||
|
|
||||
*/
|
||||
|
||||
// 'shop' => [
|
||||
// 'path' => app_path(),
|
||||
// 'namespace' => 'App',
|
||||
// 'snake_attributes' => false,
|
||||
// 'qualified_tables' => true,
|
||||
// 'use' => [
|
||||
// Reliese\Database\Eloquent\BitBooleans::class,
|
||||
// ],
|
||||
// 'except' => ['migrations'],
|
||||
// 'only' => ['users'],
|
||||
// // Table Specifics Bellow:
|
||||
// 'user' => [
|
||||
// // Don't use any default trait
|
||||
// 'use' => [],
|
||||
// ]
|
||||
// ],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Connection Specifics
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| In this section you may define the default configuration for each model
|
||||
| that will be generated from a specific connection. You can also nest
|
||||
| database and table specific configurations.
|
||||
|
|
||||
| You may wish to use connection specific config for setting a parent
|
||||
| model with a read only setup, or enforcing a different set of rules
|
||||
| for a connection, e.g. using snake_case naming over CamelCase naming.
|
||||
|
|
||||
| This supports nesting with the following key configuration values, in
|
||||
| reverse precedence order (i.e. the last one found becomes the value).
|
||||
|
|
||||
| connections.{connection_name}.property
|
||||
| connections.{connection_name}.{database_name}.property
|
||||
| connections.{connection_name}.{table_name}.property
|
||||
| connections.{connection_name}.{database_name}.{table_name}.property
|
||||
|
|
||||
| These values will override those defined in the section above.
|
||||
|
|
||||
*/
|
||||
|
||||
// 'connections' => [
|
||||
// 'read_only_external' => [
|
||||
// 'parent' => \App\Models\ReadOnlyModel::class,
|
||||
// 'connection' => true,
|
||||
// 'users' => [
|
||||
// 'connection' => false,
|
||||
// ],
|
||||
// 'my_other_database' => [
|
||||
// 'password_resets' => [
|
||||
// 'connection' => false,
|
||||
// ]
|
||||
// ]
|
||||
// ],
|
||||
// ],
|
||||
];
|
||||
68
config/seotools.php
Normal file
68
config/seotools.php
Normal file
@@ -0,0 +1,68 @@
|
||||
<?php
|
||||
/**
|
||||
* @see https://github.com/artesaos/seotools
|
||||
*/
|
||||
|
||||
return [
|
||||
'meta' => [
|
||||
/*
|
||||
* The default configurations to be used by the meta generator.
|
||||
*/
|
||||
'defaults' => [
|
||||
'title' => "EchoScoop: Bite-sized world news", // set false to total remove
|
||||
'titleBefore' => false, // Put defaults.title before page title, like 'It's Over 9000! - Dashboard'
|
||||
'description' => 'Distilling world news into bite-sized scoops.', // set false to total remove
|
||||
'separator' => ' - ',
|
||||
'keywords' => [],
|
||||
'canonical' => false, // Set to null or 'full' to use Url::full(), set to 'current' to use Url::current(), set false to total remove
|
||||
'robots' => false, // Set to 'all', 'none' or any combination of index/noindex and follow/nofollow
|
||||
],
|
||||
/*
|
||||
* Webmaster tags are always added.
|
||||
*/
|
||||
'webmaster_tags' => [
|
||||
'google' => null,
|
||||
'bing' => null,
|
||||
'alexa' => null,
|
||||
'pinterest' => null,
|
||||
'yandex' => null,
|
||||
'norton' => null,
|
||||
],
|
||||
|
||||
'add_notranslate_class' => false,
|
||||
],
|
||||
'opengraph' => [
|
||||
/*
|
||||
* The default configurations to be used by the opengraph generator.
|
||||
*/
|
||||
'defaults' => [
|
||||
'title' => 'EchoScoop: Bite-sized world news', // set false to total remove
|
||||
'description' => 'Distilling world news into bite-sized scoops.', // set false to total remove
|
||||
'url' => false, // Set null for using Url::current(), set false to total remove
|
||||
'type' => false,
|
||||
'site_name' => false,
|
||||
'images' => [],
|
||||
],
|
||||
],
|
||||
'twitter' => [
|
||||
/*
|
||||
* The default values to be used by the twitter cards generator.
|
||||
*/
|
||||
'defaults' => [
|
||||
//'card' => 'summary',
|
||||
//'site' => '@LuizVinicius73',
|
||||
],
|
||||
],
|
||||
'json-ld' => [
|
||||
/*
|
||||
* The default configurations to be used by the json-ld generator.
|
||||
*/
|
||||
'defaults' => [
|
||||
'title' => 'EchoScoop: Bite-sized world news', // set false to total remove
|
||||
'description' => 'Distilling world news into bite-sized scoops.', // set false to total remove
|
||||
'url' => false, // Set to null or 'full' to use Url::full(), set to 'current' to use Url::current(), set false to total remove
|
||||
'type' => 'WebPage',
|
||||
'images' => [],
|
||||
],
|
||||
],
|
||||
];
|
||||
@@ -0,0 +1,32 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('categories', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('name');
|
||||
$table->string('slug')->nullable();
|
||||
$table->boolean('enabled')->default(true);
|
||||
$table->timestamps();
|
||||
$table->nestedSet();
|
||||
$table->index(['name', 'slug']);
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('categories');
|
||||
}
|
||||
};
|
||||
113
database/seeders/CategorySeeder.php
Normal file
113
database/seeders/CategorySeeder.php
Normal file
@@ -0,0 +1,113 @@
|
||||
<?php
|
||||
|
||||
namespace Database\Seeders;
|
||||
|
||||
use Illuminate\Database\Console\Seeds\WithoutModelEvents;
|
||||
use Illuminate\Database\Seeder;
|
||||
|
||||
use App\Models\Category;
|
||||
|
||||
class CategorySeeder extends Seeder
|
||||
{
|
||||
/**
|
||||
* Run the database seeds.
|
||||
*/
|
||||
public function run(): void
|
||||
{
|
||||
$categories = [
|
||||
['name' => 'Automotive'],
|
||||
[
|
||||
'name' => 'Business',
|
||||
'children' => [
|
||||
['name' => 'Trading'],
|
||||
['name' => 'Information Technology'],
|
||||
['name' => 'Marketing'],
|
||||
['name' => 'Office'],
|
||||
['name' => 'Telecommunications']
|
||||
]
|
||||
],
|
||||
[
|
||||
'name' => 'Entertainment',
|
||||
'children' => [
|
||||
['name' => 'Dating'],
|
||||
['name' => 'Film & Television'],
|
||||
['name' => 'Games & Toys'],
|
||||
['name' => 'Music and Video'],
|
||||
['name' => 'Adult Entertainment']
|
||||
]
|
||||
],
|
||||
['name' => 'Food & Drink'],
|
||||
[
|
||||
'name' => 'Hobbies & Gifts',
|
||||
'children' => [
|
||||
['name' => 'Collectibles'],
|
||||
['name' => 'Pets'],
|
||||
['name' => 'Photography'],
|
||||
['name' => 'Hunting & Fishing']
|
||||
]
|
||||
],
|
||||
[
|
||||
'name' => 'Education',
|
||||
'children' => [
|
||||
['name' => 'Languages']
|
||||
]
|
||||
],
|
||||
['name' => 'Law'],
|
||||
['name' => 'Politics'],
|
||||
[
|
||||
'name' => 'Shopping',
|
||||
'children' => [
|
||||
['name' => 'Home & Garden'],
|
||||
['name' => 'Clothing & Accessories'],
|
||||
['name' => 'Computer & Electronics']
|
||||
]
|
||||
],
|
||||
[
|
||||
'name' => 'Religion & Spirituality',
|
||||
'children' => [
|
||||
['name' => 'Holistic Health']
|
||||
]
|
||||
],
|
||||
['name' => 'Real Estate'],
|
||||
['name' => 'Social Networks'],
|
||||
[
|
||||
'name' => 'Society',
|
||||
'children' => [
|
||||
['name' => 'Family'],
|
||||
['name' => 'Wedding'],
|
||||
['name' => 'Immigration']
|
||||
]
|
||||
],
|
||||
[
|
||||
'name' => 'Wellness',
|
||||
'children' => [
|
||||
['name' => 'Health & Beauty'],
|
||||
['name' => 'Psychology & Psychotherapy']
|
||||
]
|
||||
],
|
||||
[
|
||||
'name' => 'Tips & Tricks',
|
||||
'children' => [
|
||||
['name' => 'How to']
|
||||
]
|
||||
],
|
||||
[
|
||||
'name' => 'Travel',
|
||||
'children' => [
|
||||
['name' => 'Holiday'],
|
||||
['name' => 'World Festivals'],
|
||||
['name' => 'Outdoors']
|
||||
]
|
||||
],
|
||||
];
|
||||
|
||||
|
||||
foreach ($categories as $category)
|
||||
{
|
||||
$node = Category::create($category);
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
18
dev.sh
Normal file
18
dev.sh
Normal file
@@ -0,0 +1,18 @@
|
||||
#!/bin/bash
|
||||
|
||||
# eval 'php artisan optimize:clear';
|
||||
# eval 'php artisan responsecache:clear';
|
||||
# eval 'php artisan opcache:clear';
|
||||
# eval 'php artisan ziggy:generate';
|
||||
eval 'blade-formatter --write resources/**/*.blade.php';
|
||||
eval './vendor/bin/pint';
|
||||
# eval 'npm run dev';
|
||||
|
||||
tmux \
|
||||
new-session 'npm run dev' \; \
|
||||
# split-window 'php artisan queue:work' \; \
|
||||
# split-window 'php artisan schedule:work' \; \
|
||||
# split-window 'php artisan horizon' \; \
|
||||
# new-window \; \
|
||||
# detach-client
|
||||
tmux a
|
||||
1113
package-lock.json
generated
Normal file
1113
package-lock.json
generated
Normal file
File diff suppressed because it is too large
Load Diff
10
package.json
10
package.json
@@ -8,6 +8,14 @@
|
||||
"devDependencies": {
|
||||
"axios": "^1.1.2",
|
||||
"laravel-vite-plugin": "^0.8.0",
|
||||
"vite": "^4.0.0"
|
||||
"path": "^0.12.7",
|
||||
"sass": "^1.68.0",
|
||||
"vite": "^4.0.0",
|
||||
"vite-plugin-compression": "^0.5.1"
|
||||
},
|
||||
"dependencies": {
|
||||
"bootstrap": "^5.3.2",
|
||||
"bootstrap-icons": "^1.11.1",
|
||||
"js-cookie": "^3.0.5"
|
||||
}
|
||||
}
|
||||
|
||||
9
prod.sh
Normal file
9
prod.sh
Normal file
@@ -0,0 +1,9 @@
|
||||
#!/bin/bash
|
||||
|
||||
# eval 'php artisan optimize:clear';
|
||||
# eval 'php artisan responsecache:clear';
|
||||
# eval 'php artisan opcache:clear';
|
||||
# eval 'APP_URL=https://echoscoop.com php artisan ziggy:generate';
|
||||
eval 'blade-formatter --write resources/**/*.blade.php';
|
||||
eval './vendor/bin/pint';
|
||||
eval 'npm run build';
|
||||
3
resources/css/app-front.css
Normal file
3
resources/css/app-front.css
Normal file
@@ -0,0 +1,3 @@
|
||||
.abc {
|
||||
color: "#000";
|
||||
}
|
||||
1
resources/js/app-front.js
Normal file
1
resources/js/app-front.js
Normal file
@@ -0,0 +1 @@
|
||||
import * as bootstrap from "~bootstrap";
|
||||
@@ -1 +0,0 @@
|
||||
import './bootstrap';
|
||||
322
resources/sass/_variables.scss
Normal file
322
resources/sass/_variables.scss
Normal file
@@ -0,0 +1,322 @@
|
||||
// Variables
|
||||
//
|
||||
// Variables should follow the `$component-state-property-size` formula for
|
||||
// consistent naming. Ex: $nav-link-disabled-color and $modal-content-box-shadow-xs.
|
||||
|
||||
// Color system
|
||||
|
||||
// scss-docs-start gray-color-variables
|
||||
$white: #fff;
|
||||
$gray-100: #f8f9fa;
|
||||
$gray-200: #e9ecef;
|
||||
$gray-300: #dee2e6;
|
||||
$gray-400: #ced4da;
|
||||
$gray-500: #adb5bd;
|
||||
$gray-600: #6c757d;
|
||||
$gray-700: #495057;
|
||||
$gray-800: #343a40;
|
||||
$gray-900: #212529;
|
||||
$black: #000;
|
||||
// scss-docs-end gray-color-variables
|
||||
|
||||
// fusv-disable
|
||||
// scss-docs-start gray-colors-map
|
||||
$grays: (
|
||||
"100": $gray-100,
|
||||
"200": $gray-200,
|
||||
"300": $gray-300,
|
||||
"400": $gray-400,
|
||||
"500": $gray-500,
|
||||
"600": $gray-600,
|
||||
"700": $gray-700,
|
||||
"800": $gray-800,
|
||||
"900": $gray-900,
|
||||
);
|
||||
// scss-docs-end gray-colors-map
|
||||
// fusv-enable
|
||||
|
||||
// scss-docs-start color-variables
|
||||
$blue: #0d6efd;
|
||||
$indigo: #6610f2;
|
||||
$purple: #6f42c1;
|
||||
$pink: #d63384;
|
||||
$red: #dc3545;
|
||||
$orange: #fd7e14;
|
||||
$yellow: #ffc107;
|
||||
$green: #198754;
|
||||
$teal: #20c997;
|
||||
$cyan: #0dcaf0;
|
||||
// scss-docs-end color-variables
|
||||
|
||||
// scss-docs-start colors-map
|
||||
$colors: (
|
||||
"blue": $blue,
|
||||
"indigo": $indigo,
|
||||
"purple": $purple,
|
||||
"pink": $pink,
|
||||
"red": $red,
|
||||
"orange": $orange,
|
||||
"yellow": $yellow,
|
||||
"green": $green,
|
||||
"teal": $teal,
|
||||
"cyan": $cyan,
|
||||
"black": $black,
|
||||
"white": $white,
|
||||
"gray": $gray-600,
|
||||
"gray-dark": $gray-800,
|
||||
);
|
||||
// scss-docs-end colors-map
|
||||
|
||||
// The contrast ratio to reach against white, to determine if color changes from "light" to "dark". Acceptable values for WCAG 2.0 are 3, 4.5 and 7.
|
||||
// See https://www.w3.org/TR/WCAG20/#visual-audio-contrast-contrast
|
||||
$min-contrast-ratio: 4.5;
|
||||
|
||||
// Customize the light and dark text colors for use in our color contrast function.
|
||||
$color-contrast-dark: $black;
|
||||
$color-contrast-light: $white;
|
||||
|
||||
// fusv-disable
|
||||
$blue-100: tint-color($blue, 80%);
|
||||
$blue-200: tint-color($blue, 60%);
|
||||
$blue-300: tint-color($blue, 40%);
|
||||
$blue-400: tint-color($blue, 20%);
|
||||
$blue-500: $blue;
|
||||
$blue-600: shade-color($blue, 20%);
|
||||
$blue-700: shade-color($blue, 40%);
|
||||
$blue-800: shade-color($blue, 60%);
|
||||
$blue-900: shade-color($blue, 80%);
|
||||
|
||||
$indigo-100: tint-color($indigo, 80%);
|
||||
$indigo-200: tint-color($indigo, 60%);
|
||||
$indigo-300: tint-color($indigo, 40%);
|
||||
$indigo-400: tint-color($indigo, 20%);
|
||||
$indigo-500: $indigo;
|
||||
$indigo-600: shade-color($indigo, 20%);
|
||||
$indigo-700: shade-color($indigo, 40%);
|
||||
$indigo-800: shade-color($indigo, 60%);
|
||||
$indigo-900: shade-color($indigo, 80%);
|
||||
|
||||
$purple-100: tint-color($purple, 80%);
|
||||
$purple-200: tint-color($purple, 60%);
|
||||
$purple-300: tint-color($purple, 40%);
|
||||
$purple-400: tint-color($purple, 20%);
|
||||
$purple-500: $purple;
|
||||
$purple-600: shade-color($purple, 20%);
|
||||
$purple-700: shade-color($purple, 40%);
|
||||
$purple-800: shade-color($purple, 60%);
|
||||
$purple-900: shade-color($purple, 80%);
|
||||
|
||||
$pink-100: tint-color($pink, 80%);
|
||||
$pink-200: tint-color($pink, 60%);
|
||||
$pink-300: tint-color($pink, 40%);
|
||||
$pink-400: tint-color($pink, 20%);
|
||||
$pink-500: $pink;
|
||||
$pink-600: shade-color($pink, 20%);
|
||||
$pink-700: shade-color($pink, 40%);
|
||||
$pink-800: shade-color($pink, 60%);
|
||||
$pink-900: shade-color($pink, 80%);
|
||||
|
||||
$red-100: tint-color($red, 80%);
|
||||
$red-200: tint-color($red, 60%);
|
||||
$red-300: tint-color($red, 40%);
|
||||
$red-400: tint-color($red, 20%);
|
||||
$red-500: $red;
|
||||
$red-600: shade-color($red, 20%);
|
||||
$red-700: shade-color($red, 40%);
|
||||
$red-800: shade-color($red, 60%);
|
||||
$red-900: shade-color($red, 80%);
|
||||
|
||||
$orange-100: tint-color($orange, 80%);
|
||||
$orange-200: tint-color($orange, 60%);
|
||||
$orange-300: tint-color($orange, 40%);
|
||||
$orange-400: tint-color($orange, 20%);
|
||||
$orange-500: $orange;
|
||||
$orange-600: shade-color($orange, 20%);
|
||||
$orange-700: shade-color($orange, 40%);
|
||||
$orange-800: shade-color($orange, 60%);
|
||||
$orange-900: shade-color($orange, 80%);
|
||||
|
||||
$yellow-100: tint-color($yellow, 80%);
|
||||
$yellow-200: tint-color($yellow, 60%);
|
||||
$yellow-300: tint-color($yellow, 40%);
|
||||
$yellow-400: tint-color($yellow, 20%);
|
||||
$yellow-500: $yellow;
|
||||
$yellow-600: shade-color($yellow, 20%);
|
||||
$yellow-700: shade-color($yellow, 40%);
|
||||
$yellow-800: shade-color($yellow, 60%);
|
||||
$yellow-900: shade-color($yellow, 80%);
|
||||
|
||||
$green-100: tint-color($green, 80%);
|
||||
$green-200: tint-color($green, 60%);
|
||||
$green-300: tint-color($green, 40%);
|
||||
$green-400: tint-color($green, 20%);
|
||||
$green-500: $green;
|
||||
$green-600: shade-color($green, 20%);
|
||||
$green-700: shade-color($green, 40%);
|
||||
$green-800: shade-color($green, 60%);
|
||||
$green-900: shade-color($green, 80%);
|
||||
|
||||
$teal-100: tint-color($teal, 80%);
|
||||
$teal-200: tint-color($teal, 60%);
|
||||
$teal-300: tint-color($teal, 40%);
|
||||
$teal-400: tint-color($teal, 20%);
|
||||
$teal-500: $teal;
|
||||
$teal-600: shade-color($teal, 20%);
|
||||
$teal-700: shade-color($teal, 40%);
|
||||
$teal-800: shade-color($teal, 60%);
|
||||
$teal-900: shade-color($teal, 80%);
|
||||
|
||||
$cyan-100: tint-color($cyan, 80%);
|
||||
$cyan-200: tint-color($cyan, 60%);
|
||||
$cyan-300: tint-color($cyan, 40%);
|
||||
$cyan-400: tint-color($cyan, 20%);
|
||||
$cyan-500: $cyan;
|
||||
$cyan-600: shade-color($cyan, 20%);
|
||||
$cyan-700: shade-color($cyan, 40%);
|
||||
$cyan-800: shade-color($cyan, 60%);
|
||||
$cyan-900: shade-color($cyan, 80%);
|
||||
|
||||
$blues: (
|
||||
"blue-100": $blue-100,
|
||||
"blue-200": $blue-200,
|
||||
"blue-300": $blue-300,
|
||||
"blue-400": $blue-400,
|
||||
"blue-500": $blue-500,
|
||||
"blue-600": $blue-600,
|
||||
"blue-700": $blue-700,
|
||||
"blue-800": $blue-800,
|
||||
"blue-900": $blue-900,
|
||||
);
|
||||
|
||||
$indigos: (
|
||||
"indigo-100": $indigo-100,
|
||||
"indigo-200": $indigo-200,
|
||||
"indigo-300": $indigo-300,
|
||||
"indigo-400": $indigo-400,
|
||||
"indigo-500": $indigo-500,
|
||||
"indigo-600": $indigo-600,
|
||||
"indigo-700": $indigo-700,
|
||||
"indigo-800": $indigo-800,
|
||||
"indigo-900": $indigo-900,
|
||||
);
|
||||
|
||||
$purples: (
|
||||
"purple-100": $purple-100,
|
||||
"purple-200": $purple-200,
|
||||
"purple-300": $purple-300,
|
||||
"purple-400": $purple-400,
|
||||
"purple-500": $purple-500,
|
||||
"purple-600": $purple-600,
|
||||
"purple-700": $purple-700,
|
||||
"purple-800": $purple-800,
|
||||
"purple-900": $purple-900,
|
||||
);
|
||||
|
||||
$pinks: (
|
||||
"pink-100": $pink-100,
|
||||
"pink-200": $pink-200,
|
||||
"pink-300": $pink-300,
|
||||
"pink-400": $pink-400,
|
||||
"pink-500": $pink-500,
|
||||
"pink-600": $pink-600,
|
||||
"pink-700": $pink-700,
|
||||
"pink-800": $pink-800,
|
||||
"pink-900": $pink-900,
|
||||
);
|
||||
|
||||
$reds: (
|
||||
"red-100": $red-100,
|
||||
"red-200": $red-200,
|
||||
"red-300": $red-300,
|
||||
"red-400": $red-400,
|
||||
"red-500": $red-500,
|
||||
"red-600": $red-600,
|
||||
"red-700": $red-700,
|
||||
"red-800": $red-800,
|
||||
"red-900": $red-900,
|
||||
);
|
||||
|
||||
$oranges: (
|
||||
"orange-100": $orange-100,
|
||||
"orange-200": $orange-200,
|
||||
"orange-300": $orange-300,
|
||||
"orange-400": $orange-400,
|
||||
"orange-500": $orange-500,
|
||||
"orange-600": $orange-600,
|
||||
"orange-700": $orange-700,
|
||||
"orange-800": $orange-800,
|
||||
"orange-900": $orange-900,
|
||||
);
|
||||
|
||||
$yellows: (
|
||||
"yellow-100": $yellow-100,
|
||||
"yellow-200": $yellow-200,
|
||||
"yellow-300": $yellow-300,
|
||||
"yellow-400": $yellow-400,
|
||||
"yellow-500": $yellow-500,
|
||||
"yellow-600": $yellow-600,
|
||||
"yellow-700": $yellow-700,
|
||||
"yellow-800": $yellow-800,
|
||||
"yellow-900": $yellow-900,
|
||||
);
|
||||
|
||||
$greens: (
|
||||
"green-100": $green-100,
|
||||
"green-200": $green-200,
|
||||
"green-300": $green-300,
|
||||
"green-400": $green-400,
|
||||
"green-500": $green-500,
|
||||
"green-600": $green-600,
|
||||
"green-700": $green-700,
|
||||
"green-800": $green-800,
|
||||
"green-900": $green-900,
|
||||
);
|
||||
|
||||
$teals: (
|
||||
"teal-100": $teal-100,
|
||||
"teal-200": $teal-200,
|
||||
"teal-300": $teal-300,
|
||||
"teal-400": $teal-400,
|
||||
"teal-500": $teal-500,
|
||||
"teal-600": $teal-600,
|
||||
"teal-700": $teal-700,
|
||||
"teal-800": $teal-800,
|
||||
"teal-900": $teal-900,
|
||||
);
|
||||
|
||||
$cyans: (
|
||||
"cyan-100": $cyan-100,
|
||||
"cyan-200": $cyan-200,
|
||||
"cyan-300": $cyan-300,
|
||||
"cyan-400": $cyan-400,
|
||||
"cyan-500": $cyan-500,
|
||||
"cyan-600": $cyan-600,
|
||||
"cyan-700": $cyan-700,
|
||||
"cyan-800": $cyan-800,
|
||||
"cyan-900": $cyan-900,
|
||||
);
|
||||
// fusv-enable
|
||||
|
||||
// scss-docs-start theme-color-variables
|
||||
$primary: $blue;
|
||||
$secondary: $gray-600;
|
||||
$success: $green;
|
||||
$info: $cyan;
|
||||
$warning: $yellow;
|
||||
$danger: $red;
|
||||
$light: $gray-100;
|
||||
$dark: $gray-900;
|
||||
// scss-docs-end theme-color-variables
|
||||
|
||||
// scss-docs-start theme-colors-map
|
||||
$theme-colors: (
|
||||
"primary": $primary,
|
||||
"secondary": $secondary,
|
||||
"success": $success,
|
||||
"info": $info,
|
||||
"warning": $warning,
|
||||
"danger": $danger,
|
||||
"light": $light,
|
||||
"dark": $dark,
|
||||
);
|
||||
// scss-docs-end theme-colors-map
|
||||
7
resources/sass/app-front.scss
Normal file
7
resources/sass/app-front.scss
Normal file
@@ -0,0 +1,7 @@
|
||||
@import "variables";
|
||||
|
||||
@import "~bootstrap/scss/bootstrap";
|
||||
|
||||
@import "~/bootstrap-icons/font/bootstrap-icons.css";
|
||||
|
||||
@import "../css/app-front.css";
|
||||
16
resources/views/front/layouts/app.blade.php
Normal file
16
resources/views/front/layouts/app.blade.php
Normal file
@@ -0,0 +1,16 @@
|
||||
<!DOCTYPE html>
|
||||
<html class="" lang="en">
|
||||
|
||||
@include('front.layouts.partials.head')
|
||||
|
||||
<body>
|
||||
@include('googletagmanager::body')
|
||||
<div id="app">
|
||||
@include('front.layouts.partials.nav')
|
||||
<main>
|
||||
@yield('content')
|
||||
</main>
|
||||
@include('front.layouts.partials.footer')
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
3
resources/views/front/layouts/partials/footer.blade.php
Normal file
3
resources/views/front/layouts/partials/footer.blade.php
Normal file
@@ -0,0 +1,3 @@
|
||||
<div class="container">
|
||||
<footer></footer>
|
||||
</div>
|
||||
20
resources/views/front/layouts/partials/head.blade.php
Normal file
20
resources/views/front/layouts/partials/head.blade.php
Normal file
@@ -0,0 +1,20 @@
|
||||
<meta charset="UTF-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
{!! SEOMeta::generate() !!}
|
||||
{!! OpenGraph::generate() !!}
|
||||
{!! Twitter::generate() !!}
|
||||
{!! JsonLdMulti::generate() !!}
|
||||
<meta property="fb:app_id" content="{{ config('seotools.fb_app_id') }}" />
|
||||
<meta name="csrf-token" content="{{ csrf_token() }}">
|
||||
|
||||
<link rel="dns-prefetch" href="//fonts.bunny.net">
|
||||
|
||||
<link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png">
|
||||
<link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png">
|
||||
<link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png">
|
||||
<link rel="manifest" href="/site.webmanifest">
|
||||
|
||||
@vite(['resources/sass/app-front.scss', 'resources/js/app-front.js'])
|
||||
{{-- @laravelPWA --}}
|
||||
@include('googletagmanager::head')
|
||||
22
resources/views/front/layouts/partials/nav.blade.php
Normal file
22
resources/views/front/layouts/partials/nav.blade.php
Normal file
@@ -0,0 +1,22 @@
|
||||
<div class="container">
|
||||
<header class="d-flex flex-wrap align-items-center justify-content-center justify-content-md-between py-3 mb-4 border-bottom">
|
||||
<a href="/" class="d-flex align-items-center col-md-3 mb-2 mb-md-0 text-dark text-decoration-none">
|
||||
<span class="fs-4 fw-bolder align-self-center">EchoScoop</span>
|
||||
</a>
|
||||
|
||||
<span>Breaking down news to bite-sized scoops.</span>
|
||||
|
||||
{{-- <ul class="nav col-12 col-md-auto mb-2 justify-content-center mb-md-0">
|
||||
<li><a href="#" class="nav-link px-2 link-secondary">Home</a></li>
|
||||
<li><a href="#" class="nav-link px-2 link-dark">Features</a></li>
|
||||
<li><a href="#" class="nav-link px-2 link-dark">Pricing</a></li>
|
||||
<li><a href="#" class="nav-link px-2 link-dark">FAQs</a></li>
|
||||
<li><a href="#" class="nav-link px-2 link-dark">About</a></li>
|
||||
</ul>
|
||||
|
||||
<div class="col-md-3 text-end">
|
||||
<button type="button" class="btn btn-outline-primary me-2">Login</button>
|
||||
<button type="button" class="btn btn-primary">Sign-up</button>
|
||||
</div> --}}
|
||||
</header>
|
||||
</div>
|
||||
4
resources/views/vendor/googletagmanager/body.blade.php
vendored
Normal file
4
resources/views/vendor/googletagmanager/body.blade.php
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
@if($enabled)
|
||||
<noscript><iframe src="https://www.googletagmanager.com/ns.html?id={{ $id }}"
|
||||
height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
|
||||
@endif
|
||||
16
resources/views/vendor/googletagmanager/head.blade.php
vendored
Normal file
16
resources/views/vendor/googletagmanager/head.blade.php
vendored
Normal file
@@ -0,0 +1,16 @@
|
||||
@if($enabled)
|
||||
<script>
|
||||
window.dataLayer = window.dataLayer || [];
|
||||
@unless(empty($dataLayer->toArray()))
|
||||
window.dataLayer.push({!! $dataLayer->toJson() !!});
|
||||
@endunless
|
||||
@foreach($pushData as $item)
|
||||
window.dataLayer.push({!! $item->toJson() !!});
|
||||
@endforeach
|
||||
</script>
|
||||
<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
|
||||
new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
|
||||
j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
|
||||
'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
|
||||
})(window,document,'script','dataLayer','{{ $id }}');</script>
|
||||
@endif
|
||||
2
resources/views/vendor/googletagmanager/script.blade.php
vendored
Normal file
2
resources/views/vendor/googletagmanager/script.blade.php
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
@include('googletagmanager::head')
|
||||
@include('googletagmanager::body')
|
||||
File diff suppressed because one or more lines are too long
@@ -14,5 +14,5 @@
|
||||
*/
|
||||
|
||||
Route::get('/', function () {
|
||||
return view('welcome');
|
||||
return response(view('welcome'), 404);
|
||||
});
|
||||
|
||||
@@ -1,11 +1,30 @@
|
||||
import { defineConfig } from 'vite';
|
||||
import laravel from 'laravel-vite-plugin';
|
||||
import { defineConfig } from "vite";
|
||||
import laravel from "laravel-vite-plugin";
|
||||
import path from "path";
|
||||
import viteCompression from "vite-plugin-compression";
|
||||
|
||||
export default defineConfig({
|
||||
export default defineConfig(({ mode }) => {
|
||||
return {
|
||||
esbuild: {
|
||||
drop: mode === "production" ? ["console", "debugger"] : [],
|
||||
},
|
||||
plugins: [
|
||||
viteCompression(),
|
||||
laravel({
|
||||
input: ['resources/css/app.css', 'resources/js/app.js'],
|
||||
input: [
|
||||
"resources/sass/app-front.scss",
|
||||
"resources/js/app-front.js",
|
||||
,
|
||||
],
|
||||
refresh: true,
|
||||
}),
|
||||
],
|
||||
resolve: {
|
||||
alias: {
|
||||
"@": path.resolve(__dirname, "./resources/js"),
|
||||
"~": path.resolve(__dirname, "node_modules"),
|
||||
"~bootstrap": path.resolve(__dirname, "node_modules/bootstrap"),
|
||||
},
|
||||
},
|
||||
};
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user