v0.1.5 Add the first support for create user account

This commit is contained in:
Victor
2021-06-09 11:13:12 +02:00
parent d0e2900941
commit b0fd4d4320
5 changed files with 17 additions and 13 deletions
+2 -2
View File
@@ -1,5 +1,5 @@
<?php
require "../../bootstrap.php";
$createUser = User::Create(['name' => "Victor", 'password' => password_hash('1234', PASSWORD_DEFAULT)]);
use Backend\Model\User;
$createUser = User::Create(['name' => "admin", 'password' => password_hash('aA123456&', PASSWORD_DEFAULT), 'permission' => 0]);
echo "User was created";
+1
View File
@@ -6,6 +6,7 @@ use Illuminate\Database\Capsule\Manager as Capsule;
Capsule::schema()->create('users', function ($table) {
$table->increments('id');
$table->string('name');
$table->integer('permission');
$table->longtext('password');
$table->longtext('remember_token');
$table->timestamps();