angular in memory web api login curd exmpal

Solutions on MaxInterview for angular in memory web api login curd exmpal by the best coders in the world

showing results for - "angular in memory web api login curd exmpal"
Roberta
20 Aug 2019
1@Injectable({
2  providedIn: 'root'
3})
4export class DataService implements InMemoryDbService{
5
6  constructor() { }
7  createDb(){
8
9   let  policies =  [
10    {  id:  1,  num:  'PO1', amount: 1000, userId: 1, clientId: 1, description: 'Insurance policy number PO1' },
11    {  id:  2,  num:  'PO2', amount: 2000, userId: 1, clientId: 2, description: 'Insurance policy number PO2' },
12    {  id:  3,  num:  'PO3', amount: 3000, userId: 1, clientId: 3, description: 'Insurance policy number PO3' },
13    {  id:  4,  num:  'PO4', amount: 4000, userId: 1, clientId: 4, description: 'Insurance policy number PO4' }
14   ];
15
16   return {policies};
17
18  }
19}
20