Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import { HttpClient } from '@angular/common/http';
import { Observable } from 'rxjs';
import { environment } from '../../../../../../../environments/environment';
import { Project } from '../../../../../shared/models';
import { AzureAdB2CService } from '../../../../../login/services/azure.ad.b2c.service';

@Injectable({
providedIn: 'root',
Expand All @@ -12,7 +11,7 @@ export class ProjectService {
projects: Project[] = [];
url = `${environment.timeTrackerApiUrl}/projects`;

constructor(private http: HttpClient, private azureAdB2CService: AzureAdB2CService) {}
constructor(private http: HttpClient) {}

getProjects(): Observable<Project[]> {
return this.http.get<Project[]>(this.url);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ describe('CustomerService', () => {
{ name: 'aa', description: 'bb', tenant_id: 'cc', id: '1' },
{ name: 'xx', description: 'yy', tenant_id: 'zz', id: '2' },
];
const key = 'id';
const url = `${service.baseUrl}/1`;
service.deleteCustomer(customer[0].id).subscribe();
const getCustomerRequest = httpMock.expectOne(url);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,14 @@ import { HttpClient } from '@angular/common/http';

import { Observable } from 'rxjs';
import { environment } from './../../../../environments/environment';
import { AzureAdB2CService } from 'src/app/modules/login/services/azure.ad.b2c.service';

@Injectable({
providedIn: 'root',
})
export class CustomerService {
baseUrl = `${environment.timeTrackerApiUrl}/customers`;

constructor(private http: HttpClient, private service: AzureAdB2CService) {}
constructor(private http: HttpClient) {}

createCustomer(customerData): Observable<any> {
return this.http.post(this.baseUrl, customerData);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { createFeatureSelector, createSelector } from '@ngrx/store';
import { Customer } from 'src/app/modules/shared/models/customer.model';


import { CustomerState } from './customer-management.reducers';
export const getCustomerState = createFeatureSelector<CustomerState>('customers');
Expand Down