diff --git a/composer.lock b/composer.lock index 4c154f3..08c219f 100644 --- a/composer.lock +++ b/composer.lock @@ -130,16 +130,16 @@ }, { "name": "barryvdh/laravel-debugbar", - "version": "v2.4.0", + "version": "v2.4.1", "source": { "type": "git", "url": "https://github.com/barryvdh/laravel-debugbar.git", - "reference": "de15d00a74696db62e1b4782474c27ed0c4fc763" + "reference": "af98b3a4ccac9364f2145fae974ff3392ec402b1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/barryvdh/laravel-debugbar/zipball/de15d00a74696db62e1b4782474c27ed0c4fc763", - "reference": "de15d00a74696db62e1b4782474c27ed0c4fc763", + "url": "https://api.github.com/repos/barryvdh/laravel-debugbar/zipball/af98b3a4ccac9364f2145fae974ff3392ec402b1", + "reference": "af98b3a4ccac9364f2145fae974ff3392ec402b1", "shasum": "" }, "require": { @@ -188,7 +188,7 @@ "profiler", "webprofiler" ], - "time": "2017-06-01T17:46:08+00:00" + "time": "2017-06-14T07:44:44+00:00" }, { "name": "barryvdh/laravel-dompdf", @@ -520,16 +520,16 @@ }, { "name": "intervention/image", - "version": "2.3.13", + "version": "2.4.0", "source": { "type": "git", "url": "https://github.com/Intervention/image.git", - "reference": "15a517f052ee15d373ffa145c9642d5fec7ddf5c" + "reference": "322a4ade249467179c50a3e50eda8760ff3af2a3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Intervention/image/zipball/15a517f052ee15d373ffa145c9642d5fec7ddf5c", - "reference": "15a517f052ee15d373ffa145c9642d5fec7ddf5c", + "url": "https://api.github.com/repos/Intervention/image/zipball/322a4ade249467179c50a3e50eda8760ff3af2a3", + "reference": "322a4ade249467179c50a3e50eda8760ff3af2a3", "shasum": "" }, "require": { @@ -539,7 +539,7 @@ }, "require-dev": { "mockery/mockery": "~0.9.2", - "phpunit/phpunit": "3.*" + "phpunit/phpunit": "^4.8 || ^5.7" }, "suggest": { "ext-gd": "to use GD library based image processing.", @@ -550,6 +550,14 @@ "extra": { "branch-alias": { "dev-master": "2.3-dev" + }, + "laravel": { + "providers": [ + "Intervention\\Image\\ImageServiceProvider" + ], + "aliases": { + "Image": "Intervention\\Image\\Facades\\Image" + } } }, "autoload": { @@ -564,8 +572,8 @@ "authors": [ { "name": "Oliver Vogel", - "email": "oliver@olivervogel.net", - "homepage": "http://olivervogel.net/" + "email": "oliver@olivervogel.com", + "homepage": "http://olivervogel.com/" } ], "description": "Image handling and manipulation library with support for Laravel integration", @@ -578,7 +586,7 @@ "thumbnail", "watermark" ], - "time": "2017-04-23T18:45:36+00:00" + "time": "2017-07-03T15:50:40+00:00" }, { "name": "jakub-onderka/php-console-color", @@ -1144,16 +1152,16 @@ }, { "name": "maatwebsite/excel", - "version": "2.1.17", + "version": "2.1.19", "source": { "type": "git", "url": "https://github.com/Maatwebsite/Laravel-Excel.git", - "reference": "14d5abf8e20563c80dd074fd7c8cf1c05bf51f1d" + "reference": "f4535ac21968f6086438e098cdf289b350aa993c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Maatwebsite/Laravel-Excel/zipball/14d5abf8e20563c80dd074fd7c8cf1c05bf51f1d", - "reference": "14d5abf8e20563c80dd074fd7c8cf1c05bf51f1d", + "url": "https://api.github.com/repos/Maatwebsite/Laravel-Excel/zipball/f4535ac21968f6086438e098cdf289b350aa993c", + "reference": "f4535ac21968f6086438e098cdf289b350aa993c", "shasum": "" }, "require": { @@ -1180,6 +1188,16 @@ "illuminate/view": "5.0.*|5.1.*|5.2.*|5.3.*|5.4.*" }, "type": "library", + "extra": { + "laravel": { + "providers": [ + "Maatwebsite\\Excel\\ExcelServiceProvider" + ], + "aliases": { + "Excel": "Maatwebsite\\Excel\\Facades\\Excel" + } + } + }, "autoload": { "classmap": [ "src/Maatwebsite/Excel" @@ -1208,7 +1226,7 @@ "import", "laravel" ], - "time": "2017-04-04T18:28:12+00:00" + "time": "2017-07-02T07:00:56+00:00" }, { "name": "maximebf/debugbar", @@ -1273,16 +1291,16 @@ }, { "name": "monolog/monolog", - "version": "1.22.1", + "version": "1.23.0", "source": { "type": "git", "url": "https://github.com/Seldaek/monolog.git", - "reference": "1e044bc4b34e91743943479f1be7a1d5eb93add0" + "reference": "fd8c787753b3a2ad11bc60c063cff1358a32a3b4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Seldaek/monolog/zipball/1e044bc4b34e91743943479f1be7a1d5eb93add0", - "reference": "1e044bc4b34e91743943479f1be7a1d5eb93add0", + "url": "https://api.github.com/repos/Seldaek/monolog/zipball/fd8c787753b3a2ad11bc60c063cff1358a32a3b4", + "reference": "fd8c787753b3a2ad11bc60c063cff1358a32a3b4", "shasum": "" }, "require": { @@ -1303,7 +1321,7 @@ "phpunit/phpunit-mock-objects": "2.3.0", "ruflin/elastica": ">=0.90 <3.0", "sentry/sentry": "^0.13", - "swiftmailer/swiftmailer": "~5.3" + "swiftmailer/swiftmailer": "^5.3|^6.0" }, "suggest": { "aws/aws-sdk-php": "Allow sending log messages to AWS services like DynamoDB", @@ -1347,7 +1365,7 @@ "logging", "psr-3" ], - "time": "2017-03-13T07:08:03+00:00" + "time": "2017-06-19T01:22:40+00:00" }, { "name": "mtdowling/cron-expression", @@ -1448,16 +1466,16 @@ }, { "name": "nikic/php-parser", - "version": "v3.0.5", + "version": "v3.0.6", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "2b9e2f71b722f7c53918ab0c25f7646c2013f17d" + "reference": "0808939f81c1347a3c8a82a5925385a08074b0f1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/2b9e2f71b722f7c53918ab0c25f7646c2013f17d", - "reference": "2b9e2f71b722f7c53918ab0c25f7646c2013f17d", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/0808939f81c1347a3c8a82a5925385a08074b0f1", + "reference": "0808939f81c1347a3c8a82a5925385a08074b0f1", "shasum": "" }, "require": { @@ -1495,7 +1513,7 @@ "parser", "php" ], - "time": "2017-03-05T18:23:57+00:00" + "time": "2017-06-28T20:53:48+00:00" }, { "name": "paragonie/random_compat", @@ -1769,16 +1787,16 @@ }, { "name": "psy/psysh", - "version": "v0.8.5", + "version": "v0.8.9", "source": { "type": "git", "url": "https://github.com/bobthecow/psysh.git", - "reference": "38a9d21406597a0440690eafbcb0222f528c8ac6" + "reference": "58a31cc4404c8f632d8c557bc72056af2d3a83db" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/bobthecow/psysh/zipball/38a9d21406597a0440690eafbcb0222f528c8ac6", - "reference": "38a9d21406597a0440690eafbcb0222f528c8ac6", + "url": "https://api.github.com/repos/bobthecow/psysh/zipball/58a31cc4404c8f632d8c557bc72056af2d3a83db", + "reference": "58a31cc4404c8f632d8c557bc72056af2d3a83db", "shasum": "" }, "require": { @@ -1808,7 +1826,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-develop": "0.9.x-dev" + "dev-develop": "0.8.x-dev" } }, "autoload": { @@ -1838,7 +1856,7 @@ "interactive", "shell" ], - "time": "2017-05-17T06:49:19+00:00" + "time": "2017-07-06T14:53:52+00:00" }, { "name": "ramsey/uuid", @@ -2207,16 +2225,16 @@ }, { "name": "symfony/event-dispatcher", - "version": "v3.3.0", + "version": "v3.3.5", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher.git", - "reference": "a9f8b02b0ef07302eca92cd4bba73200b7980e9c" + "reference": "67535f1e3fd662bdc68d7ba317c93eecd973617e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/a9f8b02b0ef07302eca92cd4bba73200b7980e9c", - "reference": "a9f8b02b0ef07302eca92cd4bba73200b7980e9c", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/67535f1e3fd662bdc68d7ba317c93eecd973617e", + "reference": "67535f1e3fd662bdc68d7ba317c93eecd973617e", "shasum": "" }, "require": { @@ -2266,7 +2284,7 @@ ], "description": "Symfony EventDispatcher Component", "homepage": "https://symfony.com", - "time": "2017-05-04T12:23:07+00:00" + "time": "2017-06-09T14:53:08+00:00" }, { "name": "symfony/finder", @@ -2454,16 +2472,16 @@ }, { "name": "symfony/polyfill-mbstring", - "version": "v1.3.0", + "version": "v1.4.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "e79d363049d1c2128f133a2667e4f4190904f7f4" + "reference": "f29dca382a6485c3cbe6379f0c61230167681937" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/e79d363049d1c2128f133a2667e4f4190904f7f4", - "reference": "e79d363049d1c2128f133a2667e4f4190904f7f4", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/f29dca382a6485c3cbe6379f0c61230167681937", + "reference": "f29dca382a6485c3cbe6379f0c61230167681937", "shasum": "" }, "require": { @@ -2475,7 +2493,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.3-dev" + "dev-master": "1.4-dev" } }, "autoload": { @@ -2509,20 +2527,20 @@ "portable", "shim" ], - "time": "2016-11-14T01:06:16+00:00" + "time": "2017-06-09T14:24:12+00:00" }, { "name": "symfony/polyfill-php56", - "version": "v1.3.0", + "version": "v1.4.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php56.git", - "reference": "1dd42b9b89556f18092f3d1ada22cb05ac85383c" + "reference": "bc0b7d6cb36b10cfabb170a3e359944a95174929" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php56/zipball/1dd42b9b89556f18092f3d1ada22cb05ac85383c", - "reference": "1dd42b9b89556f18092f3d1ada22cb05ac85383c", + "url": "https://api.github.com/repos/symfony/polyfill-php56/zipball/bc0b7d6cb36b10cfabb170a3e359944a95174929", + "reference": "bc0b7d6cb36b10cfabb170a3e359944a95174929", "shasum": "" }, "require": { @@ -2532,7 +2550,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.3-dev" + "dev-master": "1.4-dev" } }, "autoload": { @@ -2565,20 +2583,20 @@ "portable", "shim" ], - "time": "2016-11-14T01:06:16+00:00" + "time": "2017-06-09T08:25:21+00:00" }, { "name": "symfony/polyfill-util", - "version": "v1.3.0", + "version": "v1.4.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-util.git", - "reference": "746bce0fca664ac0a575e465f65c6643faddf7fb" + "reference": "ebccbde4aad410f6438d86d7d261c6b4d2b9a51d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-util/zipball/746bce0fca664ac0a575e465f65c6643faddf7fb", - "reference": "746bce0fca664ac0a575e465f65c6643faddf7fb", + "url": "https://api.github.com/repos/symfony/polyfill-util/zipball/ebccbde4aad410f6438d86d7d261c6b4d2b9a51d", + "reference": "ebccbde4aad410f6438d86d7d261c6b4d2b9a51d", "shasum": "" }, "require": { @@ -2587,7 +2605,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.3-dev" + "dev-master": "1.4-dev" } }, "autoload": { @@ -2617,7 +2635,7 @@ "polyfill", "shim" ], - "time": "2016-11-14T01:06:16+00:00" + "time": "2017-06-09T08:25:21+00:00" }, { "name": "symfony/process", @@ -3169,12 +3187,12 @@ "version": "0.9.9", "source": { "type": "git", - "url": "https://github.com/padraic/mockery.git", + "url": "https://github.com/mockery/mockery.git", "reference": "6fdb61243844dc924071d3404bb23994ea0b6856" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/padraic/mockery/zipball/6fdb61243844dc924071d3404bb23994ea0b6856", + "url": "https://api.github.com/repos/mockery/mockery/zipball/6fdb61243844dc924071d3404bb23994ea0b6856", "reference": "6fdb61243844dc924071d3404bb23994ea0b6856", "shasum": "" }, @@ -3327,22 +3345,22 @@ }, { "name": "phpdocumentor/reflection-docblock", - "version": "3.1.1", + "version": "3.2.0", "source": { "type": "git", "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", - "reference": "8331b5efe816ae05461b7ca1e721c01b46bafb3e" + "reference": "46f7e8bb075036c92695b15a1ddb6971c751e585" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/8331b5efe816ae05461b7ca1e721c01b46bafb3e", - "reference": "8331b5efe816ae05461b7ca1e721c01b46bafb3e", + "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/46f7e8bb075036c92695b15a1ddb6971c751e585", + "reference": "46f7e8bb075036c92695b15a1ddb6971c751e585", "shasum": "" }, "require": { "php": ">=5.5", "phpdocumentor/reflection-common": "^1.0@dev", - "phpdocumentor/type-resolver": "^0.2.0", + "phpdocumentor/type-resolver": "^0.4.0", "webmozart/assert": "^1.0" }, "require-dev": { @@ -3368,24 +3386,24 @@ } ], "description": "With this component, a library can provide support for annotations via DocBlocks or otherwise retrieve information that is embedded in a DocBlock.", - "time": "2016-09-30T07:12:33+00:00" + "time": "2017-07-15T11:38:20+00:00" }, { "name": "phpdocumentor/type-resolver", - "version": "0.2.1", + "version": "0.4.0", "source": { "type": "git", "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "e224fb2ea2fba6d3ad6fdaef91cd09a172155ccb" + "reference": "9c977708995954784726e25d0cd1dddf4e65b0f7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/e224fb2ea2fba6d3ad6fdaef91cd09a172155ccb", - "reference": "e224fb2ea2fba6d3ad6fdaef91cd09a172155ccb", + "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/9c977708995954784726e25d0cd1dddf4e65b0f7", + "reference": "9c977708995954784726e25d0cd1dddf4e65b0f7", "shasum": "" }, "require": { - "php": ">=5.5", + "php": "^5.5 || ^7.0", "phpdocumentor/reflection-common": "^1.0" }, "require-dev": { @@ -3415,7 +3433,7 @@ "email": "me@mikevanriel.com" } ], - "time": "2016-11-25T06:54:22+00:00" + "time": "2017-07-14T14:27:02+00:00" }, { "name": "phpspec/prophecy", @@ -3731,16 +3749,16 @@ }, { "name": "phpunit/phpunit", - "version": "5.7.20", + "version": "5.7.21", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "3cb94a5f8c07a03c8b7527ed7468a2926203f58b" + "reference": "3b91adfb64264ddec5a2dee9851f354aa66327db" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/3cb94a5f8c07a03c8b7527ed7468a2926203f58b", - "reference": "3cb94a5f8c07a03c8b7527ed7468a2926203f58b", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/3b91adfb64264ddec5a2dee9851f354aa66327db", + "reference": "3b91adfb64264ddec5a2dee9851f354aa66327db", "shasum": "" }, "require": { @@ -3809,20 +3827,20 @@ "testing", "xunit" ], - "time": "2017-05-22T07:42:55+00:00" + "time": "2017-06-21T08:11:54+00:00" }, { "name": "phpunit/phpunit-mock-objects", - "version": "3.4.3", + "version": "3.4.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit-mock-objects.git", - "reference": "3ab72b65b39b491e0c011e2e09bb2206c2aa8e24" + "reference": "a23b761686d50a560cc56233b9ecf49597cc9118" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/3ab72b65b39b491e0c011e2e09bb2206c2aa8e24", - "reference": "3ab72b65b39b491e0c011e2e09bb2206c2aa8e24", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/a23b761686d50a560cc56233b9ecf49597cc9118", + "reference": "a23b761686d50a560cc56233b9ecf49597cc9118", "shasum": "" }, "require": { @@ -3868,7 +3886,7 @@ "mock", "xunit" ], - "time": "2016-12-08T20:27:08+00:00" + "time": "2017-06-30T09:13:00+00:00" }, { "name": "sebastian/code-unit-reverse-lookup", @@ -4441,16 +4459,16 @@ }, { "name": "symfony/yaml", - "version": "v3.3.0", + "version": "v3.3.5", "source": { "type": "git", "url": "https://github.com/symfony/yaml.git", - "reference": "885db865f6b2b918404a1fae28f9ac640f71f994" + "reference": "1f93a8d19b8241617f5074a123e282575b821df8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/yaml/zipball/885db865f6b2b918404a1fae28f9ac640f71f994", - "reference": "885db865f6b2b918404a1fae28f9ac640f71f994", + "url": "https://api.github.com/repos/symfony/yaml/zipball/1f93a8d19b8241617f5074a123e282575b821df8", + "reference": "1f93a8d19b8241617f5074a123e282575b821df8", "shasum": "" }, "require": { @@ -4492,7 +4510,7 @@ ], "description": "Symfony Yaml Component", "homepage": "https://symfony.com", - "time": "2017-05-28T10:56:20+00:00" + "time": "2017-06-15T12:58:50+00:00" }, { "name": "webmozart/assert", diff --git a/database/migrations/2014_10_12_000000_create_users_table.php b/database/migrations/2014_10_12_000000_create_users_table.php index 72c82b4..0b916fe 100644 --- a/database/migrations/2014_10_12_000000_create_users_table.php +++ b/database/migrations/2014_10_12_000000_create_users_table.php @@ -12,14 +12,15 @@ class CreateUsersTable extends Migration */ public function up() { - Schema::create('users', function (Blueprint $table) { + Schema::create('users', function (Blueprint $table) + { $table->increments('id'); $table->string('name'); $table->string('username', 60)->unique(); $table->string('email')->unique(); $table->string('password', 60); $table->rememberToken(); - $table->softDeletes(); + $table->string('api_token')->nullable(); $table->timestamps(); }); } diff --git a/database/migrations/2014_10_12_100000_create_password_resets_table.php b/database/migrations/2014_10_12_100000_create_password_resets_table.php index 00057f9..c22bc74 100644 --- a/database/migrations/2014_10_12_100000_create_password_resets_table.php +++ b/database/migrations/2014_10_12_100000_create_password_resets_table.php @@ -12,7 +12,8 @@ class CreatePasswordResetsTable extends Migration */ public function up() { - Schema::create('password_resets', function (Blueprint $table) { + Schema::create('password_resets', function (Blueprint $table) + { $table->string('email')->index(); $table->string('token')->index(); $table->timestamp('created_at'); diff --git a/database/migrations/2015_07_14_131409_create_site_options_table.php b/database/migrations/2015_07_14_131409_create_site_options_table.php index 34b4837..562727e 100644 --- a/database/migrations/2015_07_14_131409_create_site_options_table.php +++ b/database/migrations/2015_07_14_131409_create_site_options_table.php @@ -12,7 +12,8 @@ class CreateSiteOptionsTable extends Migration */ public function up() { - Schema::create('site_options', function (Blueprint $table) { + Schema::create('site_options', function (Blueprint $table) + { $table->increments('id'); $table->string('key', 60)->index(); $table->string('value'); diff --git a/database/migrations/2015_08_12_205415_create_roles_permissions_table.php b/database/migrations/2015_08_12_205415_create_roles_permissions_table.php index bf9dd09..22f9646 100644 --- a/database/migrations/2015_08_12_205415_create_roles_permissions_table.php +++ b/database/migrations/2015_08_12_205415_create_roles_permissions_table.php @@ -12,9 +12,10 @@ class CreateRolesPermissionsTable extends Migration */ public function up() { - Schema::create('roles_permissions', function (Blueprint $table) { + Schema::create('roles_permissions', function (Blueprint $table) + { $table->increments('id'); - $table->tinyInteger('type')->unsigned()->index()->default(1); + $table->boolean('type')->unsigned()->index()->default(1); $table->string('name', 60); $table->string('label', 60); }); diff --git a/database/migrations/2016_03_04_020423_create_user_role_permission_table.php b/database/migrations/2016_03_04_020423_create_user_role_permission_table.php index b53f671..a0e9fe6 100644 --- a/database/migrations/2016_03_04_020423_create_user_role_permission_table.php +++ b/database/migrations/2016_03_04_020423_create_user_role_permission_table.php @@ -12,7 +12,8 @@ class CreateUserRolePermissionTable extends Migration */ public function up() { - Schema::create('user_role_permission', function (Blueprint $table) { + Schema::create('user_role_permission', function (Blueprint $table) + { $table->unsignedInteger('role_id'); $table->unsignedInteger('permission_id'); }); diff --git a/database/migrations/2016_03_04_030804_create_site_references_table.php b/database/migrations/2016_03_04_030804_create_site_references_table.php index 425e020..c12654b 100644 --- a/database/migrations/2016_03_04_030804_create_site_references_table.php +++ b/database/migrations/2016_03_04_030804_create_site_references_table.php @@ -12,7 +12,8 @@ class CreateSiteReferencesTable extends Migration */ public function up() { - Schema::create('site_references', function (Blueprint $table) { + Schema::create('site_references', function (Blueprint $table) + { $table->increments('id'); $table->string('cat', 20); $table->char('code', 1); diff --git a/database/migrations/2016_03_05_083739_create_role_user_table.php b/database/migrations/2016_03_05_083739_create_role_user_table.php index 1ed2892..fcf3ad7 100644 --- a/database/migrations/2016_03_05_083739_create_role_user_table.php +++ b/database/migrations/2016_03_05_083739_create_role_user_table.php @@ -12,7 +12,8 @@ class CreateRoleUserTable extends Migration */ public function up() { - Schema::create('role_user', function (Blueprint $table) { + Schema::create('role_user', function (Blueprint $table) + { $table->unsignedInteger('user_id')->index(); $table->unsignedInteger('role_id')->index(); }); diff --git a/database/migrations/2016_07_06_110052_create_projects_table.php b/database/migrations/2016_07_06_110052_create_projects_table.php new file mode 100644 index 0000000..01900b5 --- /dev/null +++ b/database/migrations/2016_07_06_110052_create_projects_table.php @@ -0,0 +1,43 @@ +increments('id'); + $table->string('name', 60); + $table->string('description')->nullable(); + $table->date('proposal_date')->nullable(); + $table->date('start_date')->nullable(); + $table->date('end_date')->nullable(); + $table->integer('project_value')->unsigned(); + $table->integer('proposal_value')->unsigned()->nullable(); + $table->boolean('status_id')->default(1)->comment('1: planned, 2: on progress, 3: done, 4: closed, 5: canceled, 6: on hold '); + $table->integer('customer_id')->unsigned(); + $table->integer('owner_id')->unsigned(); + $table->timestamps(); + }); + } + + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::drop('projects'); + } + +} diff --git a/database/migrations/2016_07_08_182606_create_subscriptions_table.php b/database/migrations/2016_07_08_182606_create_subscriptions_table.php new file mode 100644 index 0000000..c232626 --- /dev/null +++ b/database/migrations/2016_07_08_182606_create_subscriptions_table.php @@ -0,0 +1,46 @@ +increments('id'); + $table->integer('project_id')->unsigned(); + $table->integer('customer_id')->unsigned(); + $table->integer('vendor_id')->unsigned(); + $table->string('domain_name', 60); + $table->string('epp_code', 60)->nullable(); + $table->integer('domain_price')->unsigned(); + $table->string('hosting_capacity', 60)->nullable(); + $table->boolean('status_id')->default(1); + $table->integer('hosting_price')->unsigned()->nullable(); + $table->date('start_date')->nullable(); + $table->date('due_date')->nullable(); + $table->string('remark')->nullable(); + $table->timestamps(); + $table->unique(['domain_name','epp_code'], 'domain_name_epp_code'); + }); + } + + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::drop('subscriptions'); + } + +} diff --git a/database/migrations/2016_07_09_093439_create_features_table.php b/database/migrations/2016_07_09_093439_create_features_table.php new file mode 100644 index 0000000..cb7a43e --- /dev/null +++ b/database/migrations/2016_07_09_093439_create_features_table.php @@ -0,0 +1,40 @@ +increments('id'); + $table->integer('project_id')->unsigned(); + $table->string('name', 60); + $table->string('description')->nullable(); + $table->integer('worker_id')->unsigned()->nullable(); + $table->integer('price')->unsigned()->default(0); + $table->boolean('type_id')->default(1)->comment('1: main, 2: additional'); + $table->boolean('position')->default(0); + $table->timestamps(); + }); + } + + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::drop('features'); + } + +} diff --git a/database/migrations/2016_07_09_142833_create_tasks_table.php b/database/migrations/2016_07_09_142833_create_tasks_table.php new file mode 100644 index 0000000..2d8049b --- /dev/null +++ b/database/migrations/2016_07_09_142833_create_tasks_table.php @@ -0,0 +1,39 @@ +increments('id'); + $table->integer('feature_id')->unsigned(); + $table->string('name', 60); + $table->string('description')->nullable(); + $table->boolean('progress')->default(0); + $table->string('route_name')->nullable(); + $table->boolean('position')->default(0); + $table->timestamps(); + }); + } + + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::drop('tasks'); + } + +} diff --git a/database/migrations/2016_11_15_151228_create_payments_table.php b/database/migrations/2016_11_15_151228_create_payments_table.php new file mode 100644 index 0000000..7baf30f --- /dev/null +++ b/database/migrations/2016_11_15_151228_create_payments_table.php @@ -0,0 +1,41 @@ +increments('id'); + $table->integer('project_id')->unsigned(); + $table->integer('amount')->unsigned(); + $table->boolean('type_id')->default(1)->comment('1:project, 2: add_feature, 3:maintenance'); + $table->boolean('in_out')->default(1)->comment('0: out, 1: in'); + $table->date('date'); + $table->string('description'); + $table->integer('customer_id')->unsigned(); + $table->integer('owner_id')->unsigned(); + $table->timestamps(); + }); + } + + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::drop('payments'); + } + +} diff --git a/database/migrations/2016_11_25_145359_create_user_events_table.php b/database/migrations/2016_11_25_145359_create_user_events_table.php new file mode 100644 index 0000000..c00bc5f --- /dev/null +++ b/database/migrations/2016_11_25_145359_create_user_events_table.php @@ -0,0 +1,40 @@ +increments('id'); + $table->integer('user_id')->unsigned(); + $table->integer('project_id')->unsigned()->nullable(); + $table->string('title', 60); + $table->string('body')->nullable(); + $table->dateTime('start')->nullable(); + $table->dateTime('end')->nullable(); + $table->boolean('is_allday')->default(0); + $table->timestamps(); + }); + } + + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::drop('user_events'); + } + +} diff --git a/database/seeds/UserRolesPermissionsTableSeeder.php b/database/seeds/UserRolesPermissionsTableSeeder.php index 5533c00..8ea8334 100644 --- a/database/seeds/UserRolesPermissionsTableSeeder.php +++ b/database/seeds/UserRolesPermissionsTableSeeder.php @@ -16,11 +16,17 @@ class UserRolesPermissionsTableSeeder extends Seeder DB::table($this->tableToSeed)->truncate(); DB::table($this->tableToSeed)->insert([ ['type' => 0, 'name' => 'admin', 'label' => 'Admin'], - ['type' => 0, 'name' => 'member', 'label' => 'Member'], + ['type' => 0, 'name' => 'customer', 'label' => 'Customer'], + ['type' => 0, 'name' => 'worker', 'label' => 'Worker'], + ['type' => 0, 'name' => 'vendor', 'label' => 'Vendor'], ['type' => 1, 'name' => 'manage_users', 'label' => 'Manage Users'], ['type' => 1, 'name' => 'manage_role_permissions', 'label' => 'Manage Users Role\'s Permission'], ['type' => 1, 'name' => 'manage_backups', 'label' => 'Manage Database Backups'], ['type' => 1, 'name' => 'manage_options', 'label' => 'Manage Site Options'], + ['type' => 1, 'name' => 'manage_projects', 'label' => 'Manage Projects'], + ['type' => 1, 'name' => 'manage_payments', 'label' => 'Manage Payments'], + ['type' => 1, 'name' => 'manage_subscriptions', 'label' => 'Manage Subscriptions'], + ['type' => 1, 'name' => 'see_reports', 'label' => 'See Reports'], ]); } } diff --git a/tests/api/ApiManageProjectsTest.php b/tests/api/ApiManageProjectsTest.php index bf7af8f..4a584f2 100644 --- a/tests/api/ApiManageProjectsTest.php +++ b/tests/api/ApiManageProjectsTest.php @@ -8,6 +8,8 @@ use Illuminate\Foundation\Testing\WithoutMiddleware; class ApiManageProjectsTest extends TestCase { + use DatabaseTransactions; + /** @test */ public function user_can_get_project_lists() {