WIP: improve search #1
|
@ -75,7 +75,6 @@ export class Navbar extends Component<any, State> {
|
|||
}
|
||||
|
||||
searchChange(i: Navbar, event) {
|
||||
console.log("in searchChange");
|
||||
let searchParams: SearchParams = {
|
||||
q: event.target.value,
|
||||
page: 1,
|
||||
|
|
|
@ -31,7 +31,6 @@ export class Search extends Component<any, State> {
|
|||
}
|
||||
|
||||
componentDidMount() {
|
||||
console.log("comp did mount");
|
||||
this.state.searchParams = {
|
||||
page: Number(this.props.match.params.page),
|
||||
q: this.props.match.params.q,
|
||||
|
@ -44,7 +43,6 @@ export class Search extends Component<any, State> {
|
|||
|
||||
// Re-do search if the props have changed
|
||||
componentDidUpdate(lastProps: any) {
|
||||
console.log("comp did update");
|
||||
if (lastProps.match && lastProps.match.params !== this.props.match.params) {
|
||||
this.state.searchParams = {
|
||||
page: Number(this.props.match.params.page),
|
||||
|
@ -161,21 +159,11 @@ export class Search extends Component<any, State> {
|
|||
<table class="table table-fixed table-hover table-sm table-striped table-hover-purple table-padding">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="search-name-col">
|
||||
{this.sortLink("Name")}
|
||||
</th>
|
||||
<th class="text-right">
|
||||
{this.sortLink("Size")}
|
||||
</th>
|
||||
<th class="text-right">
|
||||
{this.sortLink("Seeders")}
|
||||
</th>
|
||||
<th class="text-right d-none d-md-table-cell">
|
||||
{this.sortLink("Leechers")}
|
||||
</th>
|
||||
<th class="text-right d-none d-md-table-cell">
|
||||
{this.sortLink("Scraped")}
|
||||
</th>
|
||||
<th class="search-name-col">{this.sortLink("Name")}</th>
|
||||
<th class="text-right">{this.sortLink("Size")}</th>
|
||||
<th class="text-right">{this.sortLink("Seeders")}</th>
|
||||
<th class="text-right d-none d-md-table-cell">{this.sortLink("Leechers")}</th>
|
||||
<th class="text-right d-none d-md-table-cell">{this.sortLink("Scraped")}</th>
|
||||
<th></th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
|
Loading…
Reference in New Issue