Change level query to correspond to the new api
parent
3d15e5a8d0
commit
5c339d53ba
@ -1,16 +1,17 @@
|
||||
import {Levellist} from 'src/app/models/levellist';
|
||||
|
||||
export class FriendInfo {
|
||||
levellist: Levellist = new Levellist();
|
||||
id: number;
|
||||
name: string;
|
||||
rankname: string;
|
||||
rankname = 'Rookie';
|
||||
profilePicture: string;
|
||||
|
||||
constructor(pId: number, pName: string, pLevel: number, pic: string) {
|
||||
this.id = pId;
|
||||
this.name = pName;
|
||||
this.rankname = this.levellist.getLevelName(pLevel);
|
||||
constructor(id: number, name: string, level: {name: string}, pic: string) {
|
||||
this.id = id;
|
||||
this.name = name;
|
||||
if (level) {
|
||||
this.rankname = level.name;
|
||||
}
|
||||
this.profilePicture = pic;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue