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