This commit is contained in:
Jonas Winkler 2020-11-08 17:11:18 +01:00
parent 4acea53fae
commit e81f7e0430

View File

@ -20,7 +20,7 @@ export class LogsComponent implements OnInit {
}
reload() {
this.logService.list(1, 50, null, {'level__gte': this.level}).subscribe(result => this.logs = result.results)
this.logService.list(1, 50, 'created', 'des', {'level__gte': this.level}).subscribe(result => this.logs = result.results)
}
getLevelText(level: number) {
@ -32,7 +32,7 @@ export class LogsComponent implements OnInit {
if (this.logs.length > 0) {
lastCreated = this.logs[this.logs.length-1].created
}
this.logService.list(1, 25, null, {'created__lt': lastCreated, 'level__gte': this.level}).subscribe(result => {
this.logService.list(1, 25, 'created', 'des', {'created__lt': lastCreated, 'level__gte': this.level}).subscribe(result => {
this.logs.push(...result.results)
})
}