mirror of
https://github.com/Alfresco/alfresco-content-app.git
synced 2025-07-24 17:31:52 +00:00
[ACA-1635][ACA-1636] update favoritesApi and nodesApi to use alfresco-js-api-node (#564)
* refactor favoritesApi and nodesApi to use alfresco-js-api-node * remove node-rest-client
This commit is contained in:
committed by
Cilibiu Bogdan
parent
213c2deedc
commit
86a90d33e2
@@ -23,7 +23,7 @@
|
||||
* along with Alfresco. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import { RepoClientAuth, RepoClientConfig } from './repo-client-models';
|
||||
import { RepoClientAuth } from './repo-client-models';
|
||||
|
||||
import { PeopleApi } from './apis/people/people-api';
|
||||
import { NodesApi } from './apis/nodes/nodes-api';
|
||||
@@ -36,8 +36,7 @@ import { SearchApi } from './apis/search/search-api';
|
||||
export class RepoClient {
|
||||
constructor(
|
||||
private username: string = RepoClientAuth.DEFAULT_USERNAME,
|
||||
private password: string = RepoClientAuth.DEFAULT_PASSWORD,
|
||||
private config?: RepoClientConfig
|
||||
private password: string = RepoClientAuth.DEFAULT_PASSWORD
|
||||
) {}
|
||||
|
||||
private get auth(): RepoClientAuth {
|
||||
@@ -50,7 +49,7 @@ export class RepoClient {
|
||||
}
|
||||
|
||||
get nodes() {
|
||||
return new NodesApi(this.auth, this.config);
|
||||
return new NodesApi(this.auth.username, this.auth.password);
|
||||
}
|
||||
|
||||
get sites() {
|
||||
@@ -58,7 +57,7 @@ export class RepoClient {
|
||||
}
|
||||
|
||||
get favorites() {
|
||||
return new FavoritesApi(this.auth, this.config);
|
||||
return new FavoritesApi(this.auth.username, this.auth.password);
|
||||
}
|
||||
|
||||
get shared() {
|
||||
|
Reference in New Issue
Block a user