[Vtigercrm-developers] Add upload file to Task
alanslists at gmail.com
Wed Feb 26 10:34:18 GMT 2020
On 26/02/2020 09:52, Sukhdev Mohan wrote:
> Hi All,
> I need to create an upload for Task module. I’ve used the following code
> to add the field with UI type 69
> But I’m displaying an inout box instead of the input type file. How can I achieve it?
It isn't exactly trivial.
You'll need to examine how either the Documents module deals with it
(See the Documents class file and it's save_module method which
overrides CRMEntity; there is code in CRMEntity which makes UIType 69
save as setype "Image Attachment". (See Contacts and Products modules)
You might also want to look at UIType 61 which is used in ModComments
and Emails, depending on what you really need to do.
You might find it easier to simply add Project Tasks as a relation to
the Documents module...
More information about the vtigercrm-developers