diff --git a/docs/README.md b/docs/README.md index 483c3c04de..209f88526a 100644 --- a/docs/README.md +++ b/docs/README.md @@ -57,14 +57,6 @@ for more information about installing and using the source code. ### Services - [*Analytics service](../ng2-components/ng2-activiti-analytics/src/services/analytics.service.ts) - -### Widgets - -- [*Checkbox widget](../ng2-components/ng2-activiti-analytics/src/components/widgets/checkbox/checkbox.widget.ts) -- [*Date range widget](../ng2-components/ng2-activiti-analytics/src/components/widgets/date-range/date-range.widget.ts) -- [*Dropdown widget](../ng2-components/ng2-activiti-analytics/src/components/widgets/dropdown/dropdown.widget.ts) -- [*Duration widget](../ng2-components/ng2-activiti-analytics/src/components/widgets/duration/duration.widget.ts) -- [*Number widget](../ng2-components/ng2-activiti-analytics/src/components/widgets/number/number.widget.ts) [(Back to Contents)](#contents) @@ -120,26 +112,6 @@ for more information about installing and using the source code. ### Widgets - [Content widget](content.widget.md) -- [*Amount widget](../ng2-components/ng2-activiti-form/src/components/widgets/amount/amount.widget.ts) -- [*Attach widget](../ng2-components/ng2-activiti-form/src/components/widgets/attach/attach.widget.ts) -- [*Checkbox widget](../ng2-components/ng2-activiti-form/src/components/widgets/checkbox/checkbox.widget.ts) -- [*Container widget](../ng2-components/ng2-activiti-form/src/components/widgets/container/container.widget.ts) -- [*Date widget](../ng2-components/ng2-activiti-form/src/components/widgets/date/date.widget.ts) -- [*Display text widget](../ng2-components/ng2-activiti-form/src/components/widgets/display-text/display-text.widget.ts) -- [*Document widget](../ng2-components/ng2-activiti-form/src/components/widgets/document/document.widget.ts) -- [*Dropdown widget](../ng2-components/ng2-activiti-form/src/components/widgets/dropdown/dropdown.widget.ts) -- [*Dynamic table widget](../ng2-components/ng2-activiti-form/src/components/widgets/dynamic-table/dynamic-table.widget.ts) -- [*Functional group widget](../ng2-components/ng2-activiti-form/src/components/widgets/functional-group/functional-group.widget.ts) -- [*Hyperlink widget](../ng2-components/ng2-activiti-form/src/components/widgets/hyperlink/hyperlink.widget.ts) -- [*Multiline text widget](../ng2-components/ng2-activiti-form/src/components/widgets/multiline-text/multiline-text.widget.ts) -- [*Number widget](../ng2-components/ng2-activiti-form/src/components/widgets/number/number.widget.ts) -- [*People widget](../ng2-components/ng2-activiti-form/src/components/widgets/people/people.widget.ts) -- [*Radio buttons widget](../ng2-components/ng2-activiti-form/src/components/widgets/radio-buttons/radio-buttons.widget.ts) -- [*Tabs widget](../ng2-components/ng2-activiti-form/src/components/widgets/tabs/tabs.widget.ts) -- [*Text widget](../ng2-components/ng2-activiti-form/src/components/widgets/text/text.widget.ts) -- [*Typeahead widget](../ng2-components/ng2-activiti-form/src/components/widgets/typeahead/typeahead.widget.ts) -- [*Unknown widget](../ng2-components/ng2-activiti-form/src/components/widgets/unknown/unknown.widget.ts) -- [*Upload widget](../ng2-components/ng2-activiti-form/src/components/widgets/upload/upload.widget.ts) ### Other classes and interfaces @@ -276,6 +248,7 @@ for more information about installing and using the source code. ### Services - [Alfresco api service](alfresco-api.service.md) +- [Alfresco content service](alfresco-content.service.md) - [App config service](app-config.service.md) - [Apps process service](apps-process.service.md) - [Auth guard bpm service](auth-guard-bpm.service.md) @@ -284,9 +257,11 @@ for more information about installing and using the source code. - [Authentication service](authentication.service.md) - [Card view update service](card-view-update.service.md) - [Comment process service](comment-process.service.md) +- [Content service](content.service.md) - [Cookie service](cookie.service.md) - [Deleted nodes api service](deleted-nodes-api.service.md) - [Discovery api service](discovery-api.service.md) +- [Favorites api service](favorites-api.service.md) - [Highlight transform service](highlight-transform.service.md) - [Log service](log.service.md) - [Nodes api service](nodes-api.service.md) @@ -295,19 +270,14 @@ for more information about installing and using the source code. - [People content service](people-content.service.md) - [People process service](people-process.service.md) - [Renditions service](renditions.service.md) +- [Search api service](search-api.service.md) +- [Shared links api service](shared-links-api.service.md) - [Sites api service](sites-api.service.md) - [Storage service](storage.service.md) - [Thumbnail service](thumbnail.service.md) - [Translation service](translation.service.md) - [Upload service](upload.service.md) - [User preferences service](user-preferences.service.md) -- [*Alfresco content service](../ng2-components/ng2-alfresco-core/src/services/alfresco-content.service.ts) -- [*Content service](../ng2-components/ng2-alfresco-core/src/services/content.service.ts) -- [*Favorites api service](../ng2-components/ng2-alfresco-core/src/services/favorites-api.service.ts) -- [*Search api service](../ng2-components/ng2-alfresco-core/src/services/search-api.service.ts) -- [*Search service](../ng2-components/ng2-alfresco-core/src/services/search.service.ts) -- [*Shared links api service](../ng2-components/ng2-alfresco-core/src/services/shared-links-api.service.ts) -- [*Translate loader service](../ng2-components/ng2-alfresco-core/src/services/translate-loader.service.ts) [(Back to Contents)](#contents) @@ -502,19 +472,6 @@ for more information about installing and using the source code. ### Components - [Viewer component](viewer.component.md) -- [*ImgViewer component](../ng2-components/ng2-alfresco-viewer/src/components/imgViewer.component.ts) -- [*MediaPlayer component](../ng2-components/ng2-alfresco-viewer/src/components/mediaPlayer.component.ts) -- [*PdfViewer component](../ng2-components/ng2-alfresco-viewer/src/components/pdfViewer.component.ts) -- [*TxtViewer component](../ng2-components/ng2-alfresco-viewer/src/components/txtViewer.component.ts) -- [*Unknown format component](../ng2-components/ng2-alfresco-viewer/src/components/unknown-format/unknown-format.component.ts) -- [*Viewer more actions component](../ng2-components/ng2-alfresco-viewer/src/components/viewer-more-actions.component.ts) -- [*Viewer open with component](../ng2-components/ng2-alfresco-viewer/src/components/viewer-open-with.component.ts) -- [*Viewer sidebar component](../ng2-components/ng2-alfresco-viewer/src/components/viewer-sidebar.component.ts) -- [*Viewer toolbar component](../ng2-components/ng2-alfresco-viewer/src/components/viewer-toolbar.component.ts) - -### Directives - -- [*Viewer extension directive](../ng2-components/ng2-alfresco-viewer/src/directives/viewer-extension.directive.ts) [(Back to Contents)](#contents) diff --git a/docs/alfresco-content.service.md b/docs/alfresco-content.service.md new file mode 100644 index 0000000000..3cf973ca2c --- /dev/null +++ b/docs/alfresco-content.service.md @@ -0,0 +1,53 @@ +# Alfresco Content service + +Gets URLs and access info and creates folders in Content Services. + +## Methods + +`getDocumentThumbnailUrl(nodeId: any, attachment?: boolean, ticket?: string): string`
+Gets a thumbnail URL for a node. + +`getContentUrl(nodeId: any, attachment?: boolean, ticket?: string): string`
+Gets the URL for a node's content. + +`getNodeContent(nodeId: string): Observable`
+Gets a node's content. + +`createFolder(relativePath: string, name: string, parentId?: string): Observable`
+Creates a folder. + +`hasPermission(node: any, permission: PermissionsEnum|string): boolean`
+Checks if the user has the specified permissions for `node`. + +`hasAllowableOperations(node: any): boolean `
+Checks if the the node has the `allowableOperations` property. + +## Details + +The methods that take a `node` parameter can receive the node as either a node ID string +or as a [MinimalNode](document-library.model.md) object. You can obtain the `ticket` string, +if you need it, from the [Authentication service](authentication.service.md). If +`attachment` is false then the content can be viewed in the browser but not downloaded; the +default value of true allows a download to take place. + +The `createFolder` method adds a folder with a given `name` within the folder at `parentId`, +if supplied. You can use the well-known names "-my-" , "-shared-" or "-root-" as the `parentId`. +The `relativePath` will create a sequence of folders within `parentId` with `name` as the last +element but you can use an empty string to make the folder a direct child of `parentId`. + +The `hasPermission` method reports whether the node has the specified permission. (The +[Permissions](https://github.com/Alfresco/alfresco-ng2-components/blob/development/ng2-components/ng2-alfresco-core/src/models/permissions.enum.ts) +enum contains the values `DELETE`, `UPDATE`, `CREATE`, `UPDATEPERMISSIONS`, `NOT_DELETE`, +`NOT_UPDATE`, `NOT_CREATE` and `NOT_UPDATEPERMISSIONS`. + +See the +[Alfresco JS API](https://github.com/Alfresco/alfresco-js-api/tree/master/src/alfresco-core-rest-api) +for more information about the low-level REST API that these methods are based on. + + + + + + + + diff --git a/docs/content.service.md b/docs/content.service.md new file mode 100644 index 0000000000..ad9a55a5c3 --- /dev/null +++ b/docs/content.service.md @@ -0,0 +1,59 @@ +# Content service + +Accesses app-generated data objects via URLs and file downloads. + +## Methods + +`downloadBlob(blob: Blob, fileName: string): void`
+Starts downloading the data in `blob` to a named file. + +`downloadData(data: any, fileName: string): void`
+Starts downloading a data object to a named file. + +`downloadJSON(json: any, fileName): void`
+Starts downloading of JSON data to a named file. + +`createTrustedUrl(blob: Blob): string`
+Creates a trusted URL to access the data in `blob`. + +## Details + +Use the Content service to deliver data to the user from `Blob` objects. + +The [Blob](https://developer.mozilla.org/en-US/docs/Web/API/Blob) class +(implemented in the browser, not ADF) represents an array of bytes that you can +use to construct and store data in any binary format you choose. +The user can access a Blob either by downloading the byte array as a file or in +some cases by viewing it directly in the browser via a special URL that references +the Blob. For example, you could use the Blob interface to construct an image in the +[PNG format](https://en.wikipedia.org/wiki/Portable_Network_Graphics). Since +PNG is a format the browser can display, you could use the Blob's URL in an +<img> element to view the image within the page. Alternatively, you could let +the user download it as a PNG file. + +The `downloadBlob` method starts a download of the Blob data to the `filename` +within the user's downloads folder. The other `downloadXXX` methods do the same +but first convert the supplied data to a Blob before downloading; see the +[Blob reference page](https://developer.mozilla.org/en-US/docs/Web/API/Blob) +for details of how a Blob's contents are assembled from the constructor arguments. + +Use `createdTrustedUrl` to generate a URL string for a Blob. The URL refers to +the Blob as though it were a file but it is actually an object stored in memory, +so it does not persist across browser sessions. This URL can be used much like any +other, so you could use it for the `src` attribute of an <img> element or the +`href` of a download link. Note that while the URL is 'trusted', the data it contains +is not necessarily trustworthy unless you can vouch for it yourself; be careful that +the data doesn't expose your app to +[Cross Site Scripting](https://en.wikipedia.org/wiki/Cross-site_scripting) +attacks. + + + +## See also + +- [Cookie service](cookie.service.md) +- [Storage service](storage.service.md) + + + + diff --git a/docs/cookie.service.md b/docs/cookie.service.md index 567747959c..159e11e340 100644 --- a/docs/cookie.service.md +++ b/docs/cookie.service.md @@ -25,5 +25,6 @@ beyond this size. ## See also +- [Content service](content.service.md) - [Storage service](storage.service.md) \ No newline at end of file diff --git a/docs/favorites-api.service.md b/docs/favorites-api.service.md new file mode 100644 index 0000000000..3660e8c227 --- /dev/null +++ b/docs/favorites-api.service.md @@ -0,0 +1,27 @@ +# Favorites Api service + +Gets a list of items a user has marked as their favorites. + +## Methods + +`getFavorites(personId: string, options?: any): Observable`
+Gets the favorites for a user. + +## Details + +Process Services allows users to mark items as "favorites". These are typically +items that are important or frequently used. + +Use `getFavorites` to find a user's favorite items. You could use this, for example, +to create a menu for the user to access their favorites quickly rather than by +navigating or searching. Using "-me-" for the `personId` indicates that the target +person is the currently logged-in user. + +You can specify a number of `options` to modify the search further. See the +[Alfresco JS API page](https://github.com/Alfresco/alfresco-js-api/blob/master/src/alfresco-core-rest-api/docs/FavoritesApi.md#getfavorites) +for `getFavorites` for more information. + + + + + \ No newline at end of file diff --git a/docs/search-api.service.md b/docs/search-api.service.md new file mode 100644 index 0000000000..784c8c3d25 --- /dev/null +++ b/docs/search-api.service.md @@ -0,0 +1,19 @@ +# Search Api service + +Accesses the Content Services Search API. + +## Methods + +`search(query: any): Observable`
+Searches the repository. + +## Details + +See the +[Alfresco JS API](https://github.com/Alfresco/alfresco-js-api/blob/master/src/alfresco-search-rest-api/docs/SearchApi.md#search) +for the format of the query and returned data. + + + + + \ No newline at end of file diff --git a/docs/seeAlsoGraph.json b/docs/seeAlsoGraph.json index 98bad6fb65..7e984c6123 100644 --- a/docs/seeAlsoGraph.json +++ b/docs/seeAlsoGraph.json @@ -23,9 +23,9 @@ "comment-process.model": [], "comment-process.service": ["comment-process.model"], "content-action.component": ["document-list.component", "document-actions.service", "folder-actions.service"], - "content.widget": [], + "content.service": ["cookie.service", "storage.service"], "context-menu.directive": [], - "cookie.service": [], + "cookie.service": ["content.service"], "create-process-attachment.component": [], "create-task-attachment.component": [], "data-column.component": ["document-list.component", "datatable.component", "task-list.component"], diff --git a/docs/shared-links-api.service.md b/docs/shared-links-api.service.md new file mode 100644 index 0000000000..59fac0115a --- /dev/null +++ b/docs/shared-links-api.service.md @@ -0,0 +1,25 @@ +# Shared Links Api service + +Finds shared links to Content Services items. + +## Methods + +`getSharedLinks(options: any = {}): Observable`
+Gets shared links available to the current user. + +## Details + +Content Services allows users to generate URLs that can be shared with +other people, even if they don't have a Content Services account. These +URLs are known as *shared links*. + +Use `getSharedLinks` to find all the shared links that are available to +the current user. You can supply a number of `options` to refine the +search; see the +[Alfresco JS API](https://github.com/Alfresco/alfresco-js-api/blob/master/src/alfresco-core-rest-api/docs/SharedlinksApi.md#findsharedlinks) +for more information. + + + + + \ No newline at end of file diff --git a/docs/storage.service.md b/docs/storage.service.md index eb1f9fc7a1..04c14e13d4 100644 --- a/docs/storage.service.md +++ b/docs/storage.service.md @@ -37,4 +37,5 @@ used instead. ## See also - [Cookie service](cookie.service.md) +- [Content service](content.service.md) \ No newline at end of file diff --git a/docs/undocStoplist.json b/docs/undocStoplist.json index 596644a068..17e124d603 100644 --- a/docs/undocStoplist.json +++ b/docs/undocStoplist.json @@ -11,11 +11,17 @@ "loading-template", "no-content-template", "card-view-content-proxy", - "login-footer.directive", - "login-header.directive", + "login-footer\\.directive", + "login-header\\.directive", "no-task-detail-template", "diagram", "raphael", "context-menu", - "alfresco-settings" + "alfresco-settings", + "\\.widget", + "[vV]iewer", + "translate-loader", + "search\\.service", + "mediaPlayer", + "unknown-format" ] \ No newline at end of file