phalcon volt engine with getters and setters

1.3k Views Asked by At

I want try this framework, but i have a problem. i am create a application via phalcon-dev-tools

phalcon project phalcon

after this i create table users with 2 field = id, login

then

 phalcon scaffold --table-name=users --get-set --force --template-engine=volt

Model with protected attribute with public methods - its okey

in volt {{ user.id }} return null, because its try to ger property id not method getId()

why?

ps. phalcon 1.2.1

1

There are 1 best solutions below

0
On

You could call: {{ user.getId() }} from Volt.

Are you expecting it to behave differently?