Advertisement
Guest User

Untitled

a guest
Sep 28th, 2017
85
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.63 KB | None | 0 0
  1. login(user:any) {
  2. console.log(user);
  3. const body = `username=${user.username}&password=${user.password}`;
  4. const headers = new Headers();
  5. headers.append('Content-Type', 'application/x-www-form-urlencoded');
  6. return this.apiService.post(this.url, body, headers);
  7. }
  8.  
  9. login(user:any) {
  10. console.log(user);
  11. const body = `username=${user.username}&password=${user.password}`;
  12. const headers = new Headers();
  13. headers.append('Content-Type', 'application/x-www-form-urlencoded');
  14. return this.apiService.post(this.url, body, headers);
  15. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement