Welcome Guest, Not a member yet? Register   Sign In
CodeExtinguisher (Formerly jTaby) version 1.4 Released!
#31

[eluser]Majd Taby[/eluser]
Hey BeingDefined,
You’ll be glad to know that that feature is included in the new version along with a bunch of new features

Haha for example:
In the new version, there are two plugins called ManyToMany and OneToMany which are...self explanatory. By convention, if you define a manytomany relationship in controller A, the table that's associated with controller A doesn't contain any information about that relationship.

So yes, each plugin can define its own behaviour for:

preInsert
postInsert
preEdit
postEdit
preDelete
postDelete

and they all have callbacks for the following:

prepForDb - Prepares the given value for the database.
prepForDisplay - Think of it as a __toString() function
prepForDelete - Any special handling that needs to take place.
getFieldName - Returns the name of the field in the table

Most importantly, if any of the callbacks return NULL, then they are omitted from processing. So the ManyToMany plugin returns NULL for getFieldName.
Another nice thing, is that the codexadmin library has a new public member variable called active_id that holds the id of w/e the id of the record of interest is.

As far as the date of release, everything is done, I just have a few minor bugs here and there and some extra testing to do. Checkout this thread if you're interested in helping Smile




Theme © iAndrew 2016 - Forum software by © MyBB