refactoring
This commit is contained in:
@@ -14,7 +14,7 @@ class BatchCodeTableInitializer {
|
|||||||
})
|
})
|
||||||
.then(json => {
|
.then(json => {
|
||||||
this.#setTableRows(batchCodeTable, json.data);
|
this.#setTableRows(batchCodeTable, json.data);
|
||||||
this.#makeCompanyColumnFilterable(batchCodeTable);
|
this.#makeCompanyColumnSearchable(batchCodeTable);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@@ -142,8 +142,8 @@ class BatchCodeTableInitializer {
|
|||||||
.draw();
|
.draw();
|
||||||
}
|
}
|
||||||
|
|
||||||
#makeCompanyColumnFilterable(batchCodeTable) {
|
#makeCompanyColumnSearchable(batchCodeTable) {
|
||||||
const companyColumnFilter = new ColumnSearch(batchCodeTable.column(this.#getColumnIndex('Company')));
|
const companyColumnSearch = new ColumnSearch(batchCodeTable.column(this.#getColumnIndex('Company')));
|
||||||
companyColumnFilter.columnContentUpdated();
|
companyColumnSearch.columnContentUpdated();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
// adapted from https://datatables.net/examples/api/multi_filter_select.html
|
// adapted from https://datatables.net/examples/api/multi_filter_select.html
|
||||||
// FK-TODO: rename to ColumnFilter
|
|
||||||
class ColumnSearch {
|
class ColumnSearch {
|
||||||
|
|
||||||
#column;
|
#column;
|
||||||
|
|||||||
Reference in New Issue
Block a user