📅  最后修改于: 2022-03-11 15:04:09.945000             🧑  作者: Mango
const getResults = (options) => {
let query = knex('table');
if (options.where) {
query = query.where('franchisee_name', 'like', '%jackmarker%');
}
if (options.other) {
query = query.where('company', 'like', '%marker%');
}
return query.select();
};