mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ADF-1586] Added auth guard docs (#2624)
This commit is contained in:
committed by
Eugenio Romano
parent
3b15bde49b
commit
75ddc6636e
@@ -112,8 +112,8 @@ for more information about installing and using the source code.
|
||||
|
||||
- [Form rendering service](form-rendering.service.md)
|
||||
- [Form service](form.service.md)
|
||||
- [Node service](node.service.md)
|
||||
- [*Activiti alfresco service](../ng2-components/ng2-activiti-form/src/services/activiti-alfresco.service.ts)
|
||||
- [*Node service](../ng2-components/ng2-activiti-form/src/services/node.service.ts)
|
||||
- [*Process content service](../ng2-components/ng2-activiti-form/src/services/process-content.service.ts)
|
||||
- [*Widget visibility service](../ng2-components/ng2-activiti-form/src/services/widget-visibility.service.ts)
|
||||
|
||||
@@ -278,6 +278,9 @@ for more information about installing and using the source code.
|
||||
- [Alfresco api service](alfresco-api.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)
|
||||
- [Auth guard ecm service](auth-guard-ecm.service.md)
|
||||
- [Auth guard service](auth-guard.service.md)
|
||||
- [Authentication service](authentication.service.md)
|
||||
- [Card view update service](card-view-update.service.md)
|
||||
- [Comment process service](comment-process.service.md)
|
||||
@@ -299,9 +302,6 @@ for more information about installing and using the source code.
|
||||
- [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)
|
||||
- [*Auth guard bpm service](../ng2-components/ng2-alfresco-core/src/services/auth-guard-bpm.service.ts)
|
||||
- [*Auth guard ecm service](../ng2-components/ng2-alfresco-core/src/services/auth-guard-ecm.service.ts)
|
||||
- [*Auth guard service](../ng2-components/ng2-alfresco-core/src/services/auth-guard.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)
|
||||
@@ -326,6 +326,10 @@ for more information about installing and using the source code.
|
||||
- [*Date cell component](../ng2-components/ng2-alfresco-datatable/src/components/datatable/date-cell.component.ts)
|
||||
- [*Filesize cell component](../ng2-components/ng2-alfresco-datatable/src/components/datatable/filesize-cell.component.ts)
|
||||
- [*Location cell component](../ng2-components/ng2-alfresco-datatable/src/components/datatable/location-cell.component.ts)
|
||||
|
||||
### Directives
|
||||
|
||||
- [*No permission template directive](../ng2-components/ng2-alfresco-datatable/src/directives/no-permission-template.directive.ts)
|
||||
<!-- ng2-alfresco-datatable end -->
|
||||
|
||||
### Other classes and interfaces
|
||||
@@ -353,6 +357,10 @@ for more information about installing and using the source code.
|
||||
- [*Content node selector component](../ng2-components/ng2-alfresco-documentlist/src/components/content-node-selector/content-node-selector.component.ts)
|
||||
- [*Version upload component](../ng2-components/ng2-alfresco-documentlist/src/components/version-manager/version-upload.component.ts)
|
||||
|
||||
### Directives
|
||||
|
||||
- [*No permission content directive](../ng2-components/ng2-alfresco-documentlist/src/components/no-permission/no-permission-content.directive.ts)
|
||||
|
||||
### Models
|
||||
|
||||
- [Document library model](document-library.model.md)
|
||||
|
43
docs/auth-guard-bpm.service.md
Normal file
43
docs/auth-guard-bpm.service.md
Normal file
@@ -0,0 +1,43 @@
|
||||
# Auth Guard Bpm service
|
||||
|
||||
Adds authentication with Process Services to a route within the app.
|
||||
|
||||
## Details
|
||||
|
||||
The Auth Guard Bpm service implements an Angular
|
||||
[route guard](https://angular.io/guide/router#milestone-5-route-guards)
|
||||
to check the user is logged into Process Services. This is typically used with the
|
||||
`canActivate` guard check in the route definition:
|
||||
|
||||
```ts
|
||||
const appRoutes: Routes = [
|
||||
...
|
||||
{
|
||||
path: 'examplepath',
|
||||
component: ExampleComponent,
|
||||
canActivate: [ AuthGuardBpm ] // <- Requires authentication for this route.
|
||||
},
|
||||
...
|
||||
]
|
||||
```
|
||||
|
||||
If the user now clicks on a link or button that follows this route, they will be prompted
|
||||
to log in before proceeding.
|
||||
|
||||
This service only accepts authentication with APS but you can use the
|
||||
[Auth Guard Ecm service](auth-guard-ecm.service.md) to authenticate
|
||||
against ACS or the [Auth Guard service](auth-guard.service.md) to authenticate against
|
||||
either ACS or APS. See the
|
||||
[ADF custom page tutorial](https://community.alfresco.com/docs/DOC-6628-adf-105-creating-custom-pages-and-components)
|
||||
for worked examples of all three guards.
|
||||
|
||||
<!-- Don't edit the See also section. Edit seeAlsoGraph.json and run config/generateSeeAlso.js -->
|
||||
<!-- seealso start -->
|
||||
## See also
|
||||
|
||||
- [Auth guard ecm service](auth-guard-ecm.service.md)
|
||||
- [Auth guard service](auth-guard.service.md)
|
||||
<!-- seealso end -->
|
||||
|
||||
|
||||
|
43
docs/auth-guard-ecm.service.md
Normal file
43
docs/auth-guard-ecm.service.md
Normal file
@@ -0,0 +1,43 @@
|
||||
# Auth Guard Ecm service
|
||||
|
||||
Adds authentication with Content Services to a route within the app.
|
||||
|
||||
## Details
|
||||
|
||||
The Auth Guard Bpm service implements an Angular
|
||||
[route guard](https://angular.io/guide/router#milestone-5-route-guards)
|
||||
to check the user is logged into Process Services. This is typically used with the
|
||||
`canActivate` guard check in the route definition:
|
||||
|
||||
```ts
|
||||
const appRoutes: Routes = [
|
||||
...
|
||||
{
|
||||
path: 'examplepath',
|
||||
component: ExampleComponent,
|
||||
canActivate: [ AuthGuardBpm ] // <- Requires authentication for this route.
|
||||
},
|
||||
...
|
||||
]
|
||||
```
|
||||
|
||||
If the user now clicks on a link or button that follows this route, they will be prompted
|
||||
to log in before proceeding.
|
||||
|
||||
This service only accepts authentication with ACS but you can use the
|
||||
[Auth Guard Bpm service](auth-guard-bpm.service.md) to authenticate
|
||||
against APS or the [Auth Guard service](auth-guard.service.md) to authenticate against
|
||||
either APS or ACS. See the
|
||||
[ADF custom page tutorial](https://community.alfresco.com/docs/DOC-6628-adf-105-creating-custom-pages-and-components)
|
||||
for worked examples of all three guards.
|
||||
|
||||
<!-- Don't edit the See also section. Edit seeAlsoGraph.json and run config/generateSeeAlso.js -->
|
||||
<!-- seealso start -->
|
||||
## See also
|
||||
|
||||
- [Auth guard service](auth-guard.service.md)
|
||||
- [Auth guard bpm service](auth-guard-bpm.service.md)
|
||||
<!-- seealso end -->
|
||||
|
||||
|
||||
|
44
docs/auth-guard.service.md
Normal file
44
docs/auth-guard.service.md
Normal file
@@ -0,0 +1,44 @@
|
||||
# Auth Guard service
|
||||
|
||||
Adds authentication to a route within the app.
|
||||
|
||||
## Details
|
||||
|
||||
The Auth Guard service implements an Angular
|
||||
[route guard](https://angular.io/guide/router#milestone-5-route-guards)
|
||||
to check the user is logged in. This is typically used with the
|
||||
`canActivate` guard check in the route definition:
|
||||
|
||||
```ts
|
||||
const appRoutes: Routes = [
|
||||
...
|
||||
{
|
||||
path: 'examplepath',
|
||||
component: ExampleComponent,
|
||||
canActivate: [ AuthGuard ] // <- Requires authentication for this route.
|
||||
},
|
||||
...
|
||||
]
|
||||
```
|
||||
|
||||
If the user now clicks on a link or button that follows this route, they will be prompted
|
||||
to log in before proceeding.
|
||||
|
||||
This service will accept authentication with either APS or ACS as valid and is thus suitable for
|
||||
menu pages and other content that doesn't make use of APS or ACS features. Use the
|
||||
[Auth Guard Bpm service](auth-guard-bpm.service.md) and
|
||||
[Auth Guard Ecm service](auth-guard-ecm.service.md) to authenticate
|
||||
against APS or ACS, respectively. See the
|
||||
[ADF custom page tutorial](https://community.alfresco.com/docs/DOC-6628-adf-105-creating-custom-pages-and-components)
|
||||
for worked examples of all three guards.
|
||||
|
||||
<!-- Don't edit the See also section. Edit seeAlsoGraph.json and run config/generateSeeAlso.js -->
|
||||
<!-- seealso start -->
|
||||
## See also
|
||||
|
||||
- [Auth guard bpm service](auth-guard-bpm.service.md)
|
||||
- [Auth guard ecm service](auth-guard-ecm.service.md)
|
||||
<!-- seealso end -->
|
||||
|
||||
|
||||
|
@@ -756,7 +756,6 @@ That will give the following output:
|
||||

|
||||
<!-- Don't edit the See also section. Edit seeAlsoGraph.json and run config/generateSeeAlso.js -->
|
||||
<!-- seealso start -->
|
||||
|
||||
## See also
|
||||
|
||||
- [Datatable component](datatable.component.md)
|
||||
|
@@ -9,6 +9,9 @@
|
||||
"app-config.service": [],
|
||||
"apps-list.component": [],
|
||||
"apps-process.service": ["filter.model"],
|
||||
"auth-guard.service": ["auth-guard-bpm.service", "auth-guard-ecm.service"],
|
||||
"auth-guard-bpm.service": ["auth-guard-ecm.service"],
|
||||
"auth-guard-ecm.service": [],
|
||||
"authentication.service": [],
|
||||
"breadcrumb.component": ["document-list.component"],
|
||||
"bpm-user.model": ["bpm-user.service", "ecm-user.model", "people-process.service"],
|
||||
|
Reference in New Issue
Block a user