質問

I need some guidance on Lithium Framework:

  1. Is there any code generators? E.g. CLI model generator? Is there any documentation on this topic?
  2. What are naming conventions for models? Some tutorials and pieces of documentation say that a name should be plural but in "manual\working-with-data\relationships.wiki" names are singular.
  3. How to name transitional tables (models)? "Posts", "Tags" and ... PostTags?

Thank you in advance!

役に立ちましたか?

解決

Lithium has a cli tool. It's called 'li3' and you can find it under the lithium/console directory. It creates models, views, tests, and what not. As for naming your models and tables, plural names are the convention. Posts, Tags, and PostTags as you mentioned -- although there is no HABTM support in li3.

You should checkout the manual available at http://li3.me/docs/manual. It's official documentation source, and is based off the more up-to-date li3 manual repository at https://github.com/UnionOfRAD/manual.

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top