Documentation for class attachment (inherits from file):


Properties:

name type default params representant foreign foreign_prop position
id CO_INTEGER SEQUENCE READONLY=1;HIDDEN=1 0 0
version CO_INTEGER 0 READONLY=1;HIDDEN=1 0 0
deleted CO_INTEGER 0 READONLY=1;HIDDEN=1 0 0
inherits_acl CO_INTEGER 1 HIDDEN=1;READONLY=1 0 50
filename CO_STRING '' 1 200

Methods:


method getPath
description: returns partial path to attachment object
parameters:

par_area
type CO_STRING

par_class
type CO_STRING

par_id
type CO_INTEGER


method showUploadForm
description: generates client interface to perform file upload
parameters:

par_area
type CO_STRING

par_class
type CO_STRING

par_id
type CO_INTEGER


method create
description: overrides generic::create method, creates attachment object, clones acl and saves file
parameters:

par_area
type CO_STRING

par_class
type CO_STRING

par_id
type CO_INTEGER

callback
type CO_STRING

create_params
description: this is array of additional parameters that we can pass to target class to create object
type CO_ARRAY_OF_STRINGS

dont_set_acl
description: If this param is set to 1 we do not set ACL for __PERMISSION_CHANGE_ACL for created object
type CO_INTEGER


method uploadFile
description: this is executed by client upload form, calls insertCatalogItem
parameters:

par_area
type CO_STRING

par_class
type CO_STRING

par_id
type CO_INTEGER