mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ADF-1769] Added JSDocs to services (#2937)
* [ADF-1769] Added JSDocs to services * Removed JSDoc return directives from doc comments
This commit is contained in:
committed by
Eugenio Romano
parent
b3955b3f6c
commit
68ded23c9a
@@ -2,6 +2,19 @@
|
||||
|
||||
Implements the folder menu actions for the Document List component.
|
||||
|
||||
## Methods
|
||||
|
||||
- `getHandler(key: string): ContentActionHandler`
|
||||
Gets the handler function for an action.
|
||||
- `key` - Identifier for the action
|
||||
- `setHandler(key: string, handler: ContentActionHandler): boolean`
|
||||
Sets a new handler function for an action.
|
||||
- `key` - Identifier for the action
|
||||
- `handler` - The new handler function
|
||||
- `canExecuteAction(obj: any): boolean`
|
||||
Checks if an action is available for a particular item.
|
||||
- `obj` - Item to check
|
||||
|
||||
## Details
|
||||
|
||||
This service implements the built-in actions that can be applied to a folder
|
||||
|
@@ -4,14 +4,19 @@ Maps an APS form field type string onto the corresponding form widget component
|
||||
|
||||
## Methods
|
||||
|
||||
`getComponentTypeResolver(fieldType: string, defaultValue: Type<{}> = UnknownWidgetComponent): ComponentTypeResolver`<br/>
|
||||
Gets the currently active ComponentTypeResolver function for a field type.
|
||||
|
||||
`setComponentTypeResolver(fieldType: string, resolver: ComponentTypeResolver, override: boolean = false)`<br/>
|
||||
Sets or optionally replaces a ComponentTypeResolver function for a field type.
|
||||
|
||||
`resolveComponentType(field: FormFieldModel, defaultValue: Type<{}> = UnknownWidgetComponent): Type<{}>`<br/>
|
||||
Finds the component type that is needed to render a form field.
|
||||
- `getComponentTypeResolver(type: string, defaultValue: Type<{}> = this.defaultValue): DynamicComponentResolveFunction`
|
||||
Gets the currently active ComponentTypeResolver function for a field type.
|
||||
- `type` - The type whose resolver you want
|
||||
- `defaultValue` - Default type returned for types that are not yet mapped
|
||||
- `setComponentTypeResolver(type: string, resolver: DynamicComponentResolveFunction, override: boolean = false)`
|
||||
Sets or optionally replaces a ComponentTypeResolver function for a field type.
|
||||
- `type` - The type whose resolver you want to set
|
||||
- `resolver` - The new resolver function
|
||||
- `override` - The new resolver will only replace an existing one if this parameter is true
|
||||
- `resolveComponentType(model: DynamicComponentModel, defaultValue: Type<{}> = this.defaultValue): Type<{}>`
|
||||
Finds the component type that is needed to render a form field.
|
||||
- `model` - \[Form field model](form-field.model.md) for the field to render
|
||||
- `defaultValue` - Default type returned for field types that are not yet mapped.
|
||||
|
||||
## Details
|
||||
|
||||
|
@@ -46,26 +46,108 @@ class MyComponent {
|
||||
|
||||
### Methods
|
||||
|
||||
| Name | Params | Returns | Description |
|
||||
| ---- | ------ | ------- | ----------- |
|
||||
| createFormFromANode | (formName: string) | Observable\\<any> | Create a Form with a fields for each metadata properties |
|
||||
| createForm | (formName: string) | Observable\\<any> | Create a Form |
|
||||
| addFieldsToAForm | (formId: string, formModel: FormDefinitionModel) | Observable\\<any> | Add Fileds to A form |
|
||||
| searchFrom | (name: string) | Observable\\<any> | Search For A Form by name |
|
||||
| getForms | n/a | Observable\\<any> | Get All the forms |
|
||||
| getProcessDefinitions | n/a | Observable\\<any> | Get Process Definitions |
|
||||
| getTasks | n/a | Observable\\<any> | Get All the Tasks |
|
||||
| getTask | (taskId: string) | Observable\\<any> | Get Task |
|
||||
| saveTaskForm | (taskId: string, formValues: FormValues) | Observable\\<any> | Save Task Form |
|
||||
| completeTaskForm | (taskId: string, formValues: FormValues, outcome?: string) | Observable\\<any> | Complete Task Form |
|
||||
| getTaskForm | (taskId: string) | Observable\\<any> | Get Form related to a taskId |
|
||||
| getFormDefinitionById | (formId: string) | Observable\\<any> | Get Form Definition |
|
||||
| getFormDefinitionByName | (name: string) | Observable\\<any> | Returns form definition by a given name. |
|
||||
| getStartFormInstance | (processId: string) | Observable\\<any> | Get start form instance for a given processId |
|
||||
| getStartFormDefinition | (processId: string) | Observable\\<any> | Get start form definition for a given process |
|
||||
| getRestFieldValues | (taskId: string, field: string) | Observable\\<any> | |
|
||||
| getRestFieldValuesByProcessId | (processDefinitionId: string, field: string) | Observable\\<any> | |
|
||||
| getRestFieldValuesColumnByProcessId | (processDefinitionId: string, field: string, column?: string) | Observable\\<any> | |
|
||||
| getRestFieldValuesColumn | (taskId: string, field: string, column?: string) | Observable\\<any> | |
|
||||
| getWorkflowGroups\\ | (filter: string, groupId?: string) | Observable\\<GroupModel\[]> | |
|
||||
| getWorkflowUsers\\ | (filter: string, groupId?: string) | Observable\\<GroupUserModel\[]> | |
|
||||
- `parseForm(json: any, data?: FormValues, readOnly: boolean = false): FormModel`
|
||||
Parses JSON data to create a corresponding Form model.
|
||||
- `json` - JSON to create the form
|
||||
- `data` - (Optional) Values for the form fields
|
||||
- `readOnly` - Should the form fields be read-only?
|
||||
- `createFormFromANode(formName: string): Observable<any>`
|
||||
Create a Form with a field for each metadata property.
|
||||
- `formName` - Name of the new form
|
||||
- `createForm(formName: string): Observable<any>`
|
||||
Create a Form.
|
||||
- `formName` - Name of the new form
|
||||
- `saveForm(formId: string, formModel: FormDefinitionModel): Observable<any>`
|
||||
Saves a form.
|
||||
- `formId` - ID of the form to save
|
||||
- `formModel` - Model data for the form
|
||||
- `addFieldsToAForm(formId: string, formModel: FormDefinitionModel): Observable<any>`
|
||||
|
||||
- `formId` - ID of the form
|
||||
- `formModel` - Form definition
|
||||
- `searchFrom(name: string): Observable<any>`
|
||||
Search for a form by name.
|
||||
- `name` - The form name to search for
|
||||
- `getForms(): Observable<any>`
|
||||
Gets all the forms.
|
||||
|
||||
- `getProcessDefinitions(): Observable<any>`
|
||||
Get Process Definitions
|
||||
|
||||
- `getProcessVarablesById(processInstanceId: string): Observable<any[]>`
|
||||
Get instance variables for a process.
|
||||
- `processInstanceId` - ID of the target process
|
||||
- `getTasks(): Observable<any>`
|
||||
Gets all the tasks.
|
||||
|
||||
- `getTask(taskId: string): Observable<any>`
|
||||
Gets a task.
|
||||
- `taskId` - Task Id
|
||||
- `saveTaskForm(taskId: string, formValues: FormValues): Observable<any>`
|
||||
Save Task Form.
|
||||
- `taskId` - Task Id
|
||||
- `formValues` - Form Values
|
||||
- `completeTaskForm(taskId: string, formValues: FormValues, outcome?: string): Observable<any>`
|
||||
Complete Task Form
|
||||
- `taskId` - Task Id
|
||||
- `formValues` - Form Values
|
||||
- `outcome` - (Optional) Form Outcome
|
||||
- `getTaskForm(taskId: string): Observable<any>`
|
||||
Get Form related to a taskId
|
||||
- `taskId` - Task Id
|
||||
- `getFormDefinitionById(formId: string): Observable<any>`
|
||||
Get Form Definition
|
||||
- `formId` - Form Id
|
||||
- `getFormDefinitionByName(name: string): Observable<any>`
|
||||
Returns form definition with a given name.
|
||||
- `name` - The form name
|
||||
- `getStartFormInstance(processId: string): Observable<any>`
|
||||
Get start form instance for a given processId
|
||||
- `processId` - Process definition ID
|
||||
- `getProcessIntance(processId: string): Observable<any>`
|
||||
Gets a process instance.
|
||||
- `processId` - ID of the process to get
|
||||
- `getStartFormDefinition(processId: string): Observable<any>`
|
||||
Get start form definition for a given process
|
||||
- `processId` - Process definition ID
|
||||
- `getRestFieldValues(taskId: string, field: string): Observable<any>`
|
||||
Gets values of fields populated by a REST backend.
|
||||
- `taskId` - Task identifier
|
||||
- `field` - Field identifier
|
||||
- `getRestFieldValuesByProcessId(processDefinitionId: string, field: string): Observable<any>`
|
||||
Gets values of fields populated by a REST backend using a process ID.
|
||||
- `processDefinitionId` - Process identifier
|
||||
- `field` - Field identifier
|
||||
- `getRestFieldValuesColumnByProcessId(processDefinitionId: string, field: string, column?: string): Observable<any>`
|
||||
Gets column values of fields populated by a REST backend using a process ID.
|
||||
- `processDefinitionId` - Process identifier
|
||||
- `field` - Field identifier
|
||||
- `column` - (Optional) Column identifier
|
||||
- `getRestFieldValuesColumn(taskId: string, field: string, column?: string): Observable<any>`
|
||||
Gets column values of fields populated by a REST backend.
|
||||
- `taskId` - Task identifier
|
||||
- `field` - Field identifier
|
||||
- `column` - (Optional) Column identifier
|
||||
- `getUserProfileImageApi(userId: number): string`
|
||||
Returns a URL for the profile picture of a user.
|
||||
- `userId` - ID of the target user
|
||||
- `getWorkflowUsers(filter: string, groupId?: string): Observable<UserProcessModel[]>`
|
||||
Gets a list of workflow users.
|
||||
- `filter` - Filter to select specific users
|
||||
- `groupId` - (Optional) Group ID for the search
|
||||
- `getWorkflowGroups(filter: string, groupId?: string): Observable<GroupModel[]>`
|
||||
Gets a list of groups in a workflow.
|
||||
- `filter` - Filter to select specific groups
|
||||
- `groupId` - (Optional) Group ID for the search
|
||||
- `getFormId(res: any): string`
|
||||
Gets the ID of a form.
|
||||
- `res` - Object representing a form
|
||||
- `toJson(res: any): any`
|
||||
Creates a JSON representation of form data.
|
||||
- `res` - Object representing form data
|
||||
- `toJsonArray(res: any): any`
|
||||
Creates a JSON array representation of form data.
|
||||
- `res` - Object representing form data
|
||||
- `handleError(error: any): Observable<any>`
|
||||
Reports an error message.
|
||||
- `error` - Data object with optional \`message\` and \`status\` fields for the error
|
||||
|
@@ -4,8 +4,11 @@ Adds HTML to a string to highlight chosen sections.
|
||||
|
||||
## Methods
|
||||
|
||||
`public highlight(text: string, search: string, wrapperClass: string = 'highlight'): HightlightTransformResult`<br/>
|
||||
Searches for `search` string(s) within `text` and highlights all occurrences.
|
||||
- `highlight(text: string, search: string, wrapperClass: string = 'highlight'): HightlightTransformResult`
|
||||
Searches for `search` string(s) within `text` and highlights all occurrences.
|
||||
- `text` - Text to search within
|
||||
- `search` - Text pattern to search for
|
||||
- `wrapperClass` - CSS class used to provide highlighting style
|
||||
|
||||
## Details
|
||||
|
||||
|
@@ -4,26 +4,39 @@ Accesses and manipulates ACS document nodes using their node IDs.
|
||||
|
||||
## Methods
|
||||
|
||||
`getNode(nodeId: string, options: any = {}): Observable<MinimalNodeEntryEntity>`<br/>
|
||||
Gets the stored information about a node.
|
||||
|
||||
`getNodeChildren(nodeId: string, options: any = {}): Observable<NodePaging>`<br/>
|
||||
Gets the items contained in a folder node.
|
||||
|
||||
`createNode(parentNodeId: string, nodeBody: any, options: any = {}): Observable<MinimalNodeEntryEntity>`<br/>
|
||||
Creates a new document node inside a folder.
|
||||
|
||||
`createFolder(parentNodeId: string, nodeBody: any, options: any = {}): Observable<MinimalNodeEntryEntity>`<br/>
|
||||
Creates a new folder node inside a parent folder.
|
||||
|
||||
`updateNode(nodeId: string, nodeBody: any, options: any = {}): Observable<MinimalNodeEntryEntity>`<br/>
|
||||
Updates the information about a node.
|
||||
|
||||
`deleteNode(nodeId: string, options: any = {}): Observable<void>`<br/>
|
||||
Moves a node to the "trashcan".
|
||||
|
||||
`restoreNode(nodeId: string): Observable<MinimalNodeEntryEntity>`<br/>
|
||||
Restores a node previously moved to the "trashcan".
|
||||
- `getNode(nodeId: string, options: any = {}): Observable<MinimalNodeEntryEntity>`
|
||||
Gets the stored information about a node.
|
||||
- `nodeId` - ID of the target node
|
||||
- `options` - Optional parameters supported by JSAPI
|
||||
- `getNodeChildren(nodeId: string, options: any = {}): Observable<NodePaging>`
|
||||
Gets the items contained in a folder node.
|
||||
- `nodeId` - ID of the target node
|
||||
- `options` - Optional parameters supported by JSAPI
|
||||
- `createNode(parentNodeId: string, nodeBody: any, options: any = {}): Observable<MinimalNodeEntryEntity>`
|
||||
Creates a new document node inside a folder.
|
||||
- `parentNodeId` - ID of the parent folder node
|
||||
- `nodeBody` - Data for the new node
|
||||
- `options` - Optional parameters supported by JSAPI
|
||||
- `createFolder(parentNodeId: string, nodeBody: any, options: any = {}): Observable<MinimalNodeEntryEntity>`
|
||||
Creates a new folder node inside a parent folder.
|
||||
- `parentNodeId` - ID of the parent folder node
|
||||
- `nodeBody` - Data for the new folder
|
||||
- `options` - Optional parameters supported by JSAPI
|
||||
- `updateNode(nodeId: string, nodeBody: any, options: any = {}): Observable<MinimalNodeEntryEntity>`
|
||||
Updates the information about a node.
|
||||
- `nodeId` - ID of the target node
|
||||
- `nodeBody` - New data for the node
|
||||
- `options` - Optional parameters supported by JSAPI
|
||||
- `deleteNode(nodeId: string, options: any = {}): Observable<void>`
|
||||
Moves a node to the trashcan.
|
||||
- `nodeId` - ID of the target node
|
||||
- `options` - Optional parameters supported by JSAPI
|
||||
- `restoreNode(nodeId: string): Observable<MinimalNodeEntryEntity>`
|
||||
Restores a node previously moved to the trashcan.
|
||||
- `nodeId` - ID of the node to restore
|
||||
- `handleError(error: any): Observable<any>`
|
||||
Reports an error.
|
||||
- `error` - Object representing the error
|
||||
|
||||
## Details
|
||||
|
||||
|
Reference in New Issue
Block a user