A few questions:
Say I want a "clients" table created that holds additional user data, like "lastPayment" or "deadlineDate".
Since the tables "users" and "user_attributes" already exist, i don’t think i need to define those in the schema, but how do i reference the relationships in the model?
instead of extends="xPDOSimpleObject", should the object show extends="modUser"?
Would i need to write a plugin to add rows to the clients table when new users are created, or will that be taken care of automatically?
thanks!
-
MODX Staff
- 10,725 Posts
You could do this without modifying the schema and simply using plugins, but the recommended approach for Revolution is going to involve extending the modUser class, so you can add relationships and modify behavior in the data "model" layer. You could still use plugins, but it wouldn’t be required to get your custom data saved.
We’re working on a tutorial on how to do this (modxcms.com is using this technique with our Crowd identity service via SOAP) as well as working on how to allow extensions to the user management UI in this regard.
Just a little more patience as we refine the implementation based on our experiences...
@OpenGeek
I know you are busy but do you have any idea how long.
I have been thinking of a form with dropdown fields for creating the db XML Schema.
Then using dbGenerator for creating tables and then models and maps.
I was wondering how you would be able to create the XML part or the file for the dependencies.
And if more than one table is required also with dependencies.
DEVELOPMENT ENV:- Ubuntu 12.04 | MODx Revolution 2.2.8 | LAMP 2i Apache 2.2.22 | Php 5.3.10 | Mysql 5.5.31 MySQL client version: 5.5.31
Any timing of when RC-3 is coming out?
SHould we start now with RC-2 or wait for RC-3??
Website: www.mercologia.com
MODX Revo Tutorials: www.modxperience.com
MODX Professional Partner
Thanks Jason... [thumb up]
Website: www.mercologia.com
MODX Revo Tutorials: www.modxperience.com
MODX Professional Partner