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

为什么要把id值设置到code中去 #4

Open
sun2008mt opened this issue Sep 9, 2017 · 1 comment
Open

为什么要把id值设置到code中去 #4

sun2008mt opened this issue Sep 9, 2017 · 1 comment

Comments

@sun2008mt
Copy link

请求的城市数据中并没有code的数据,不过对应数据表的litepal实体类中新建了code属性,并且在设置值的时候是将id的值传入了code属性中,是因为litepal的实体类中id属性是默认保留的么?

@thevangit
Copy link

我认为id是对应数据库中的行数,是数据库都默认需要创建的,不是对应json中的id。code才是对应着json中的id。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants