Neues Laravel-Projekt aufsetzen

25.01.2017 | Laravel | Laravelpanel

Download + Project Setup

composer create-project --prefer-dist laravel/laravel blog

 Panel + Migrations

composer config repositories.repo-name vcs "https://github.com/jamisonvalenta/Laravel-4-Generators.git"
composer require --dev "way/generators:dev-feature/laravel-five-stable" "xethron/migrations-generator"

composer.json sollte dann so aussehen:


composer install 
{
    "name": "laravel/laravel",
    "description": "The Laravel Framework.",
    "keywords": ["framework", "laravel"],
    "license": "MIT",
    "type": "project",
    "require": {
        "php": ">=5.6.4",
        "laravel/framework": "5.3.*",
	"serverfireteam/panel": "1.5.*"	
    },
    "require-dev": {
        "fzaninotto/faker": "~1.4",
        "mockery/mockery": "0.9.*",
        "phpunit/phpunit": "~5.0",
        "symfony/css-selector": "3.1.*",
        "symfony/dom-crawler": "3.1.*",
        "way/generators": "dev-feature/laravel-five-stable",
        "xethron/migrations-generator": "^2.0"
    },
    "autoload": {
        "classmap": [
            "database"
        ],
        "psr-4": {
            "blog\\": "app/"
        }
    },
    "autoload-dev": {
        "classmap": [
            "tests/TestCase.php"
        ]
    },
    "scripts": {
        "post-root-package-install": [
            "php -r \"file_exists('.env') || copy('.env.example', '.env');\""
        ],
        "post-create-project-cmd": [
            "php artisan key:generate"
        ],
        "post-install-cmd": [
            "Illuminate\\Foundation\\ComposerScripts::postInstall",
            "php artisan optimize"
        ],
        "post-update-cmd": [
            "Illuminate\\Foundation\\ComposerScripts::postUpdate",
            "php artisan optimize"
        ]
    },
    "config": {
        "preferred-install": "dist"
    },
    "repositories": {
        "repo-name": {
            "type": "vcs",
            "url": "https://github.com/jamisonvalenta/Laravel-4-Generators.git"
        }
    }
}


composer install

Scaffolding Backend / Panel

php artisan panel:install

Auto-Migrate Tables

php artisan migrate:generate blog_posts,blog_categories,blog_posts_categories

Auto-Create CRUD-Backend

php artisan panel:crud blog_posts
php artisan panel:crud blog_categories

Start App-Development

php artisan make:controller BlogController

...

 

 

 

Analyse

Entwurf

Development

Launch