Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import { Injectable } from '@angular/core';
- import { Http, Headers, Response, RequestOptions, } from '@angular/http';
- @Injectable()
- export class RoleService {
- headers = new Headers({"Content-Type": "application/json"});
- options = new RequestOptions({ headers: this.headers });
- constructor(private http: Http) { }
- getRoleList(data) {
- return this.http.post('http://192.168.10.178:9080/role/getRole', data, this.options)
- .toPromise()
- .then(res => res.json().data)
- .then(data => { return data; });
- }}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement