get_categories(number){
return this.http.post( url, body, {headers: headers, withCredentials:true})
.map(t=> {
this.total = t.json();
return total;
}).share();
);
}
затем
this.get_category(1).subscribe(t=> {
this.callfunc();
});