Skip to content

Class: AttachmentEntryProxy

AttachmentEntryProxy is a developer-facing interface that provides access to an item of the Attachment control in the OnPress event. In addition, it provides access to the IAttachmentEntryProxy interface.

Hierarchy

Implements

Summary

Constructors

Properties

Class Properties

Inherited Properties

Accessors

Class Accessors

None in this class.

Inherited Accessors

Methods

Class Methods

Inherited Methods

Constructors

constructor

+ new AttachmentEntryProxy(context: IContext): AttachmentEntryProxy

Overrides ClientAPI.constructor

Parameters:

Name Type
context IContext

Returns: AttachmentEntryProxy

Properties

Protected _row

_row: any

Methods

createAttachmentEntry

createAttachmentEntry(attachmentPath: string, entitySet: string, property: string, readLink: string, service: string, encodeURI: boolean): any

Implementation of IAttachmentEntryProxy

Create an object for attachment entry Note: This function is for iOS & Android only

Parameters:

Name Type Default Description
attachmentPath string - the path for the attachment file
entitySet string - entity set name
property string - the property of the entity set
readLink string - readlink string
service string - service name
encodeURI boolean true whether the URI need to be encoded, default value is true

Returns: any

an object with all information for the attachment entry or undefined if the attachment is invalid


getIndex

getIndex(): number

Implementation of IAttachmentEntryProxy

Get index

Returns: number


getPageProxy

getPageProxy(): IPageProxy

Implementation of IAttachmentEntryProxy

Returns: IPageProxy

the Page, which the control belongs to


getParent

getParent(): IAttachmentFormCellProxy

Implementation of IAttachmentEntryProxy

This method returns AttachmentFormCell proxy

Returns: IAttachmentFormCellProxy


getValue

getValue(): any

Implementation of IAttachmentEntryProxy

Get item value (Read-Only). The value is in accordance with the interface IAttachment definition.

Returns: any

the value of the item


open

open(): any

Implementation of IAttachmentEntryProxy

Open the item of the specified attachment

Returns: any


setValue

setValue(value: any, notify?: boolean): any

Implementation of IAttachmentEntryProxy

Set the new value in the item. The value should be generated from: FormCellControlProxy.createAttachmentEntry() or AttachmentEntryProxy.createAttachmentEntry()

Parameters:

Name Type Description
value any value to be set
notify? boolean whether to send the notification

Returns: any

this - allows chaining