Jump to content
Froxlor Forum
  • 0

Database layout for 1.0


pirast

Question

Just watched the 1.0 screencast regarding creating the HelloWorld-module. I have a question to the structure of the database as observed in this screencast: I noticed that in the table frx_modules, 'installed' can be yes/no and activated can be on/off. This is not very consistent in my opinion, maybe it would be better to use 0 and 1 to point the activation/installation out? Thanks!

Link to comment
Share on other sites

7 answers to this question

Recommended Posts

What's the difference? What does using "yes/no" instead of "0/1" have to do with consistency? We tried to use "speaking variables", means:

 

A module is installed: yes | no

The module's activation status: on | off

Link to comment
Share on other sites

That'd make more sense if the column was called "activation_status", but even then it's confusing. The database is there to store data, not to give it any meaning. Perhaps a better way would be to provide setActivationStatus and/or setActivated methods in the model class.

Link to comment
Share on other sites

A module is installed: yes | no

The module's activation status: on | off

 

Well its not that clear. The identifiers of the fields are "activated" and "installed".

 

A third person may also think "A module is installed: yes | no". So yes, the variables are speaking, but not very clearly.

 

Just by looking at the field identifier its not possible to say if yes/no or on/off is required currently.

Link to comment
Share on other sites

"a third person" will not even see this.

 

This layout describes the backend! What is shown on the frontent is something completely different.

 

Sorry, i'm closing this (in my opinion unnecessary) discussion. If you don't like it - don't use it

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.



×
×
  • Create New...