|
|
|
import { Component, OnInit } from '@angular/core';
|
|
|
|
import { Observable, fromEvent } from 'rxjs';
|
|
|
|
import { debounceTime } from 'rxjs/operators';
|
|
|
|
@Component({
|
|
|
|
selector: 'app-histories',
|
|
|
|
templateUrl: './histories.component.html',
|
|
|
|
styleUrls: ['./histories.component.scss']
|
|
|
|
})
|
|
|
|
export class HistoriesComponent implements OnInit {
|
|
|
|
|
|
|
|
constructor() { }
|
|
|
|
tableSpin = false
|
|
|
|
list = [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]
|
|
|
|
|
|
|
|
tableScrollHeight
|
|
|
|
ngOnInit(): void {
|
|
|
|
this.tableScrollHeight = (document.getElementById('tablebox').clientHeight - 42) + 'px'
|
|
|
|
// 页面监听
|
|
|
|
fromEvent(window, 'resize').pipe(debounceTime(100)).subscribe((event) => {
|
|
|
|
this.tableScrollHeight = (document.getElementById('tablebox').clientHeight - 42) + 'px'
|
|
|
|
});
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
dispose() {
|
|
|
|
console.log('处置')
|
|
|
|
}
|
|
|
|
}
|