[Vtigercrm-developers] add custom field with uitype 10 field to calendar events module
alanslists at gmail.com
Thu Oct 8 07:45:08 GMT 2015
On 08/10/15 05:45, Preexo wrote:
> Has anyone come up with a working procedure to this by now or should we
> maybe start adding the bits and pieces to create a full working procedure.
> The goal is:
> Add a custom field with uitype 10 to the calendar events module.
The vtiger Calendar module is so non-standard it hurts ;-)
It is much improved in vtiger version 6 than v5 but it still requires a
fair bit of hacking. Too much of the Calendar module, and its relations,
have hardcoded assumptions.
If you want to relate Events and Tasks with another module you must add
your module name to the vtiger_ws_referencetype table, e.g.
> INSERT INTO vtiger_ws_referencetype(fieldtypeid,type) VALUES(34,$MODULENAME)
(This assumes that UIType 66 has a fieldtypeid of 34 in
vtiger_ws_fieldtype - do check)
Then you can use the standard vtlib setRelatedList() function to create
the related list in your target module using the get_activities function
These two things will add your module to the picklist of modules in the
Related To block of Events and Tasks. The other bit will create the
related list of activities in your Module's Detail View.
More information about the vtigercrm-developers