Skip to content

Commit

Permalink
updated readme
Browse files Browse the repository at this point in the history
added revisionable migrate command to order migration file
  • Loading branch information
Trexology committed Aug 2, 2016
1 parent 492a7c1 commit 2e44d1e
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 8 deletions.
15 changes: 7 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,6 @@ Basic Ordering Package for Laravel 5+

composer require trexology/laravel-order:2.*

# Upgrade Guide
• This package uses [VentureCraft/revisionable](https://github.com/VentureCraft/revisionable/) to track order changes

• Remove the old migration file '2015_12_02_150448_create_orderLogs_table.php'

• Column `line_item_id` in `Orderitems` table has been changed from integer to string for greater flexibility (version 1 user have to change the column type manually)

After installation,go to `config/app.php` under `providers` section to add the following:

Trexology\LaravelOrder\LaravelOrderServiceProvider::class
Expand All @@ -26,7 +19,6 @@ and under "aliases" add:
publish the migration and config files with the commands:

php artisan vendor:publish
php artisan migrate --path=vendor/venturecraft/revisionable/src/migrations

Edit additional settings at `config/order.php`

Expand All @@ -49,6 +41,13 @@ Edit additional settings at `config/order.php`
];
```

# Upgrade Guide from 1.*
• This package uses [VentureCraft/revisionable](https://github.com/VentureCraft/revisionable/) to track order changes

• Remove the old migration file '2015_12_02_150448_create_orderLogs_table.php'

• Column `line_item_id` in `Orderitems` table has been changed from integer to string for greater flexibility (version 1 user have to change the column type manually)

# Usage

## Create a new order
Expand Down
3 changes: 3 additions & 0 deletions migrations/2015_07_25_101746_create_orders_table.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
use Illuminate\Support\Facades\Artisan;

class CreateOrdersTable extends Migration {

Expand All @@ -12,6 +13,8 @@ class CreateOrdersTable extends Migration {
*/
public function up()
{
Artisan::call('migrate', ["--force"=> true, "--path"=> "vendor/venturecraft/revisionable/src/migrations" ]);

Schema::create('orders', function(Blueprint $table)
{
$table->increments('id');
Expand Down

0 comments on commit 2e44d1e

Please sign in to comment.