-
-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Importing via CSV error 500 #847
Comments
Is the Not Found error being triggered by the import, or by something else? |
by the import I believe. I renamed the log file right before I clicked submit so I could get a clean log. |
I can't begin to know where the 404 not found is coming from, but the other error is solved here: #822 |
I saw that string as well and modified the file suggested. I then receive On Mon, Jun 15, 2015 at 12:26 PM, snipe [email protected] wrote:
Craig Johnson CESA5 - Your Education Solutions Partner Notice: This email and any attachments may contain confidential |
What do you see when when you go to yoursite.com/api/hardware/list? (Please make sure debug is set to true in |
I have made the change. Problem still exists. It looks like the Notes field On Mon, Jun 15, 2015 at 12:39 PM, snipe [email protected] wrote:
Craig Johnson CESA5 - Your Education Solutions Partner Notice: This email and any attachments may contain confidential |
Also, with the Notes added to the UserControllers.php file, I can not On Mon, Jun 15, 2015 at 12:51 PM, Craig Johnson [email protected] wrote:
Craig Johnson CESA5 - Your Education Solutions Partner Notice: This email and any attachments may contain confidential |
I have asked you what you see when you go to the API url with debug mode set to true. |
I get this when I click on "People" syntax error, unexpected "notes" On Mon, Jun 15, 2015 at 1:04 PM, snipe [email protected] wrote:
Craig Johnson CESA5 - Your Education Solutions Partner Notice: This email and any attachments may contain confidential |
Can you show me that chunk of code that you have? |
$pass = On Mon, Jun 15, 2015 at 1:09 PM, snipe [email protected] wrote:
Craig Johnson CESA5 - Your Education Solutions Partner Notice: This email and any attachments may contain confidential |
You're missing a comma after Should be:
|
That did it You are AWESOME! On Mon, Jun 15, 2015 at 1:12 PM, snipe [email protected] wrote:
Craig Johnson CESA5 - Your Education Solutions Partner Notice: This email and any attachments may contain confidential |
We receive this error when trying to import users via CSV
Log file
[2015-06-15 15:46:39] production.ERROR: exception 'Symfony\Component\HttpKernel\Exception\NotFoundHttpException' in C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Routing\RouteCollection.php:148
Stack trace:
#0 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Routing\Router.php(1054): Illuminate\Routing\RouteCollection->match(Object(Illuminate\Http\Request))
#1 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Routing\Router.php(1022): Illuminate\Routing\Router->findRoute(Object(Illuminate\Http\Request))
#2 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Routing\Router.php(1001): Illuminate\Routing\Router->dispatchToRoute(Object(Illuminate\Http\Request))
#3 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Foundation\Application.php(775): Illuminate\Routing\Router->dispatch(Object(Illuminate\Http\Request))
#4 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Foundation\Application.php(745): Illuminate\Foundation\Application->dispatch(Object(Illuminate\Http\Request))
#5 C:\inetpub\wwwroot\snipe-it\vendor\barryvdh\laravel-debugbar\src\Middleware\Stack.php(34): Illuminate\Foundation\Application->handle(Object(Illuminate\Http\Request), 1, true)
#6 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Session\Middleware.php(72): Barryvdh\Debugbar\Middleware\Stack->handle(Object(Illuminate\Http\Request), 1, true)
#7 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Cookie\Queue.php(47): Illuminate\Session\Middleware->handle(Object(Illuminate\Http\Request), 1, true)
#8 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Cookie\Guard.php(51): Illuminate\Cookie\Queue->handle(Object(Illuminate\Http\Request), 1, true)
#9 C:\inetpub\wwwroot\snipe-it\vendor\stack\builder\src\Stack\StackedHttpKernel.php(23): Illuminate\Cookie\Guard->handle(Object(Illuminate\Http\Request), 1, true)
#10 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Foundation\Application.php(641): Stack\StackedHttpKernel->handle(Object(Illuminate\Http\Request))
#11 C:\inetpub\wwwroot\snipe-it\public\index.php(49): Illuminate\Foundation\Application->run()
#12 {main} [] []
[2015-06-15 15:47:59] production.ERROR: exception 'PDOException' with message 'SQLSTATE[HY000]: General error: 1364 Field 'notes' doesn't have a default value' in C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Database\Connection.php:369
Stack trace:
#0 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Database\Connection.php(369): PDOStatement->execute(Array)
#1 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Database\Connection.php(617): Illuminate\Database\Connection->Illuminate\Database{closure}(Object(Illuminate\Database\MySqlConnection), 'insert into
us...', Array) #2 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Database\Connection.php(581): Illuminate\Database\Connection->runQueryCallback('insert into
us...', Array, Object(Closure))#3 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Database\Connection.php(370): Illuminate\Database\Connection->run('insert into
us...', Array, Object(Closure)) #4 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Database\Connection.php(327): Illuminate\Database\Connection->statement('insert into
us...', Array)#5 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Database\Query\Builder.php(1894): Illuminate\Database\Connection->insert('insert into `us...', Array)
#6 C:\inetpub\wwwroot\snipe-it\app\controllers\admin\UsersController.php(645): Illuminate\Database\Query\Builder->insert(Array)
#7 C:\inetpub\wwwroot\snipe-it\vendor\league\csv\src\Reader.php(76): Controllers\Admin\UsersController->Controllers\Admin{closure}(Array, 1, Object(LimitIterator))
#8 C:\inetpub\wwwroot\snipe-it\app\controllers\admin\UsersController.php(678): League\Csv\Reader->each(Object(Closure))
#9 [internal function]: Controllers\Admin\UsersController->postImport()
#10 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Routing\Controller.php(231): call_user_func_array(Array, Array)
#11 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Routing\ControllerDispatcher.php(93): Illuminate\Routing\Controller->callAction('postImport', Array)
#12 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Routing\ControllerDispatcher.php(62): Illuminate\Routing\ControllerDispatcher->call(Object(Controllers\Admin\UsersController), Object(Illuminate\Routing\Route), 'postImport')
#13 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Routing\Router.php(967): Illuminate\Routing\ControllerDispatcher->dispatch(Object(Illuminate\Routing\Route), Object(Illuminate\Http\Request), 'Controllers\Adm...', 'postImport')
#14 [internal function]: Illuminate\Routing\Router->Illuminate\Routing{closure}()
#15 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Routing\Route.php(109): call_user_func_array(Object(Closure), Array)
#16 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Routing\Router.php(1033): Illuminate\Routing\Route->run(Object(Illuminate\Http\Request))
#17 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Routing\Router.php(1001): Illuminate\Routing\Router->dispatchToRoute(Object(Illuminate\Http\Request))
#18 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Foundation\Application.php(775): Illuminate\Routing\Router->dispatch(Object(Illuminate\Http\Request))
#19 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Foundation\Application.php(745): Illuminate\Foundation\Application->dispatch(Object(Illuminate\Http\Request))
#20 C:\inetpub\wwwroot\snipe-it\vendor\barryvdh\laravel-debugbar\src\Middleware\Stack.php(34): Illuminate\Foundation\Application->handle(Object(Illuminate\Http\Request), 1, true)
#21 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Session\Middleware.php(72): Barryvdh\Debugbar\Middleware\Stack->handle(Object(Illuminate\Http\Request), 1, true)
#22 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Cookie\Queue.php(47): Illuminate\Session\Middleware->handle(Object(Illuminate\Http\Request), 1, true)
#23 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Cookie\Guard.php(51): Illuminate\Cookie\Queue->handle(Object(Illuminate\Http\Request), 1, true)
#24 C:\inetpub\wwwroot\snipe-it\vendor\stack\builder\src\Stack\StackedHttpKernel.php(23): Illuminate\Cookie\Guard->handle(Object(Illuminate\Http\Request), 1, true)
#25 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Foundation\Application.php(641): Stack\StackedHttpKernel->handle(Object(Illuminate\Http\Request))
#26 C:\inetpub\wwwroot\snipe-it\public\index.php(49): Illuminate\Foundation\Application->run()
#27 {main}
Next exception 'Illuminate\Database\QueryException' with message 'SQLSTATE[HY000]: General error: 1364 Field 'notes' doesn't have a default value (SQL: insert into
users
(first_name
,last_name
,email
,password
,activated
,permissions
) values (Test, Testlastname, [email protected], rN4KZLtH03, 1, {"user":1}))' in C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Database\Connection.php:625Stack trace:
#0 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Database\Connection.php(581): Illuminate\Database\Connection->runQueryCallback('insert into
us...', Array, Object(Closure)) #1 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Database\Connection.php(370): Illuminate\Database\Connection->run('insert into
us...', Array, Object(Closure))#2 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Database\Connection.php(327): Illuminate\Database\Connection->statement('insert into
us...', Array) #3 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Database\Query\Builder.php(1894): Illuminate\Database\Connection->insert('insert into
us...', Array)#4 C:\inetpub\wwwroot\snipe-it\app\controllers\admin\UsersController.php(645): Illuminate\Database\Query\Builder->insert(Array)
#5 C:\inetpub\wwwroot\snipe-it\vendor\league\csv\src\Reader.php(76): Controllers\Admin\UsersController->Controllers\Admin{closure}(Array, 1, Object(LimitIterator))
#6 C:\inetpub\wwwroot\snipe-it\app\controllers\admin\UsersController.php(678): League\Csv\Reader->each(Object(Closure))
#7 [internal function]: Controllers\Admin\UsersController->postImport()
#8 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Routing\Controller.php(231): call_user_func_array(Array, Array)
#9 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Routing\ControllerDispatcher.php(93): Illuminate\Routing\Controller->callAction('postImport', Array)
#10 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Routing\ControllerDispatcher.php(62): Illuminate\Routing\ControllerDispatcher->call(Object(Controllers\Admin\UsersController), Object(Illuminate\Routing\Route), 'postImport')
#11 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Routing\Router.php(967): Illuminate\Routing\ControllerDispatcher->dispatch(Object(Illuminate\Routing\Route), Object(Illuminate\Http\Request), 'Controllers\Adm...', 'postImport')
#12 [internal function]: Illuminate\Routing\Router->Illuminate\Routing{closure}()
#13 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Routing\Route.php(109): call_user_func_array(Object(Closure), Array)
#14 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Routing\Router.php(1033): Illuminate\Routing\Route->run(Object(Illuminate\Http\Request))
#15 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Routing\Router.php(1001): Illuminate\Routing\Router->dispatchToRoute(Object(Illuminate\Http\Request))
#16 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Foundation\Application.php(775): Illuminate\Routing\Router->dispatch(Object(Illuminate\Http\Request))
#17 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Foundation\Application.php(745): Illuminate\Foundation\Application->dispatch(Object(Illuminate\Http\Request))
#18 C:\inetpub\wwwroot\snipe-it\vendor\barryvdh\laravel-debugbar\src\Middleware\Stack.php(34): Illuminate\Foundation\Application->handle(Object(Illuminate\Http\Request), 1, true)
#19 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Session\Middleware.php(72): Barryvdh\Debugbar\Middleware\Stack->handle(Object(Illuminate\Http\Request), 1, true)
#20 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Cookie\Queue.php(47): Illuminate\Session\Middleware->handle(Object(Illuminate\Http\Request), 1, true)
#21 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Cookie\Guard.php(51): Illuminate\Cookie\Queue->handle(Object(Illuminate\Http\Request), 1, true)
#22 C:\inetpub\wwwroot\snipe-it\vendor\stack\builder\src\Stack\StackedHttpKernel.php(23): Illuminate\Cookie\Guard->handle(Object(Illuminate\Http\Request), 1, true)
#23 C:\inetpub\wwwroot\snipe-it\vendor\laravel\framework\src\Illuminate\Foundation\Application.php(641): Stack\StackedHttpKernel->handle(Object(Illuminate\Http\Request))
#24 C:\inetpub\wwwroot\snipe-it\public\index.php(49): Illuminate\Foundation\Application->run()
#25 {main} [] []
The text was updated successfully, but these errors were encountered: