mirror of
https://github.com/getrebuild/rebuild.git
synced 2024-09-20 23:45:55 +08:00
fix sql and via
This commit is contained in:
parent
4c4a36df56
commit
d95dc2a9bb
|
@ -177,7 +177,7 @@ public class ReferenceSearchController extends EntityController {
|
|||
private List<Object> resultSearch(String sqlWhere, Entity entity, int maxResults) {
|
||||
Field nameField = entity.getNameField();
|
||||
|
||||
String sql = MessageFormat.format("select {0},{1} from {2} where {3}",
|
||||
String sql = MessageFormat.format("select {0},{1} from {2} where ({3})",
|
||||
entity.getPrimaryField().getName(), nameField.getName(), entity.getName(), sqlWhere);
|
||||
|
||||
if (!sqlWhere.contains(" order by ")) {
|
||||
|
|
|
@ -555,7 +555,7 @@ const RbListCommon = {
|
|||
})
|
||||
|
||||
// via 过滤
|
||||
const via = $urlp('via', location.hash)
|
||||
const via = $urlp('via') || $urlp('via', location.hash)
|
||||
if (via) {
|
||||
wpc.protocolFilter = `via:${via}`
|
||||
const $cleanVia = $(`<div class="badge filter-badge">${$L('当前数据已过滤')}<a class="close" title="${$L('查看全部数据')}">×</a></div>`).appendTo('.dataTables_filter')
|
||||
|
|
Loading…
Reference in a new issue