13 Posts
dr
9 years ago
3
Topic

Hi Everyone,

I've created a basic plugin that is essentially copy-and-modify of a current one.  But I'm really running into a wall trying to do something more complex.  I can't find any information on some basic design of the event model I need for planning. Specifically:

- What are the conditions for each SEBLOD event to fire?

- What order do they fire in?

- I don't see any standard Joomla content events handled in the plugins?  Are they not registered for them?  If they are how do they fit into the event order?

- What can be expected in the parameters to the SEBLOD event handlers?

- What does the return value do?

I tried treating them like Joomla events but didn't get very far.  I see a lot of SEBLOD plugins being written, so I expected to find this information somewhere.  Is there any reference for this?

I'm even struggling to create a list of events!  Here are most of the ones I found currently being used:

onCCK_FieldConstruct( $type, &$data = array() )

static onCCK_FieldConstruct_TypeContent( &$field, $style, $data = array() )

static onCCK_FieldConstruct_TypeForm( &$field, $style, $data = array() )

static onCCK_FieldConstruct_SearchSearch( &$field, $style, $data = array() )

static onCCK_FieldConstruct_SearchOrder( &$field, $style, $data = array() )

static onCCK_FieldConstruct_SearchContent( &$field, $style, $data = array() )

onCCK_FieldPrepareContent( &$field, $value = '', &$config = array() )

onCCK_FieldPrepareForm( &$field, $value = '', &$config = array(), $inherit = array(), $return = false )

onCCK_FieldPrepareForm_Validation( &$field, $id, &$config = array(), $rules = false )

onCCK_FieldPrepareSearch( &$field, $value = '', &$config = array(), $inherit = array(), $return = false )

onCCK_FieldPrepareStore( &$field, $value = '', &$config = array(), $inherit = array(), $return = false )

static onCCK_FieldRenderContent( $field, &$config = array() )

static onCCK_FieldRenderForm( $field, &$config = array() )

static onCCK_FieldAfterStore( $process, &$fields, &$storages, &$config = array() )

static onCCK_FieldBeforeRenderForm( $process, &$fields, &$storages, &$config = array() )

But there are more g_ versions then this in the JCckPluginField base class - presumably these are some sort of default implementations?

If there is no information publicly available, could anyone help out with a few lines on the above for each event? I don't need much.  Even pointing me to the code that creates the plugins and manages the lifecycle would help.  I haven't been able to find that.

Any help much appreciated!

Thanks,

-dr

Get a Book for SEBLOD
9 years ago
0
Level 1

Hello dr,

at this time there is no manual on how to construc a SEBLOD plugin.


For developing plugins you can use the developper addon.

It will construct for you the structure of your plugin depending on the type of plugin you need.

In the plugin created by this addon you will have all events available, and their name speak for themselves.

By dumping variables in events you can see each properties available.


Best regards.

Lionel

13 Posts
dr
9 years ago
0
Level 1

Hi Lionel,

Thanks for the reply. The developer addon helps but it's frustrating to be second guessing how SEBLOD events are ordered with form submissions, DB access, and Joomla events when things go wrong.

What about the return value?  How would one redirect to another page after submission but before any database queries where done in a List & search form?

Thanks,

-dr

9 years ago
0
Level 1

Hi dr,

if you need some more formation on SEBLOD framework, I advise you to  have a look at our support offers.


Best regards.

Lionel

Get a VIP membership