mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-31 17:38:48 +00:00
#580 fix activiti task list http calls
This commit is contained in:
@@ -18,6 +18,7 @@ module.exports = function (config) {
|
||||
{pattern: 'node_modules/ng2-alfresco-core/dist/**/*.js', included: false, served: true, watched: false},
|
||||
{pattern: 'node_modules/ng2-alfresco-datatable/dist/**/*.js', included: false, served: true, watched: false},
|
||||
{pattern: 'node_modules/ng2-translate/**/*.js', included: false, served: true, watched: false},
|
||||
{pattern: 'node_modules/alfresco-js-api/dist/alfresco-js-api.js', included: true, watched: false},
|
||||
|
||||
{pattern: 'karma-test-shim.js', included: true, watched: true},
|
||||
|
||||
|
@@ -48,7 +48,7 @@ describe('ActivitiFilters', () => {
|
||||
});
|
||||
|
||||
beforeEach(() => {
|
||||
let activitiService = new ActivitiTaskListService(null, null);
|
||||
let activitiService = new ActivitiTaskListService(null, null, null);
|
||||
filterList = new ActivitiFilters(null, null, activitiService);
|
||||
});
|
||||
|
||||
|
@@ -64,7 +64,7 @@ describe('ActivitiTaskList', () => {
|
||||
});
|
||||
|
||||
beforeEach(() => {
|
||||
let activitiSerevice = new ActivitiTaskListService(null, null);
|
||||
let activitiSerevice = new ActivitiTaskListService(null, null, null);
|
||||
taskList = new ActivitiTaskList(null, null, activitiSerevice);
|
||||
});
|
||||
|
||||
|
@@ -19,6 +19,7 @@ import { Injectable } from '@angular/core';
|
||||
import { AlfrescoSettingsService } from 'ng2-alfresco-core';
|
||||
import { Http, Headers, RequestOptions, Response } from '@angular/http';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { AlfrescoAuthenticationService } from 'ng2-alfresco-core';
|
||||
import { FilterModel } from '../models/filter.model';
|
||||
import { FilterParamsModel } from '../models/filter.model';
|
||||
import { Comment } from '../models/comment.model';
|
||||
@@ -29,7 +30,9 @@ import { TaskDetailsModel } from '../models/task-details.model';
|
||||
@Injectable()
|
||||
export class ActivitiTaskListService {
|
||||
|
||||
constructor(private http: Http, public alfrescoSettingsService: AlfrescoSettingsService) {
|
||||
constructor(private http: Http,
|
||||
public alfrescoSettingsService: AlfrescoSettingsService,
|
||||
private authService: AlfrescoAuthenticationService) {
|
||||
}
|
||||
|
||||
|
||||
@@ -249,7 +252,8 @@ export class ActivitiTaskListService {
|
||||
private getHeaders(): Headers {
|
||||
return new Headers({
|
||||
'Accept': 'application/json',
|
||||
'Content-Type': 'application/json'
|
||||
'Content-Type': 'application/json',
|
||||
'Authorization': this.authService.getTicket('BPM')
|
||||
});
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user