Skip to content
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

Scaffolding with Webtools #1477

Closed
AndrewMarkUK opened this issue Nov 19, 2020 · 2 comments
Closed

Scaffolding with Webtools #1477

AndrewMarkUK opened this issue Nov 19, 2020 · 2 comments
Assignees
Milestone

Comments

@AndrewMarkUK
Copy link

When I navigate to the view in the browser I get this:

Fatal error: Uncaught Error: Call to a member function getRecordId() on array in C:\xampp\htdocs\tennisClub\app\views\account_management\search.phtml:67 Stack trace: #0 [internal function]: unknown() phalcon/cphalcon#1 [internal function]: Phalcon\Mvc\View\Engine\Php->render('C:\xampp\htdocs...', Array, true) phalcon/cphalcon#2 [internal function]: Phalcon\Mvc\View->engineRender(Array, 'account_managem...', true) phalcon/cphalcon#3 [internal function]: Phalcon\Mvc\View->processRender('account_managem...', 'search', Array) phalcon/cphalcon#4 [internal function]: Phalcon\Mvc\View->render('account_managem...', 'search') phalcon/cphalcon#5 C:\xampp\htdocs\tennisClub\public\index.php(43): Phalcon\Mvc\Application->handle('/account_manage...') phalcon/cphalcon#6 {main} thrown in C:\xampp\htdocs\tennisClub\app\views\account_management\search.phtml on line 67

Here is line 67: (First record in the foreach)

getRecordId(); ?>

Thing is, If I change it to It outputs

Why does the scaffolder output it this way and if it is correct that it does so, any idea why I wuld then get this error?

@BeMySlaveDarlin
Copy link
Contributor

BeMySlaveDarlin commented Mar 21, 2021

  • Checked on clean project with table having field record_id as pk.
  • Created scaffolding for table with --get-set option.
  • Issue doesn't reproduces, but its legit there is no trailing semicolon after getters in search page view inside foreach.

Anyways added trailing semicolons as you said it fixed your issue.

@Jeckerson
Copy link
Member

Fixed in #1493

@Jeckerson Jeckerson mentioned this issue Mar 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants