好像提示Add subgroup
,Add rule
,Delete rule
都很難在jqGrid的代碼編碼。如何定位按鈕的工具提示中的jqGrid高級搜索對話框
inputAddSubgroup = $("<input type='button' value='+ {}' title='Add subgroup' class='add-group'/>");
如何本地化它們?
好像提示Add subgroup
,Add rule
,Delete rule
都很難在jqGrid的代碼編碼。如何定位按鈕的工具提示中的jqGrid高級搜索對話框
inputAddSubgroup = $("<input type='button' value='+ {}' title='Add subgroup' class='add-group'/>");
如何本地化它們?
我貼到我的trirand詳細suggestion並提醒託尼兩次關於這個問題以後。
此外,我在the answer描述的解決方法,它允許自定義高級搜索對話框
原演示的簡單的修改進行以下new demo
我用以下代碼
$.extend($.jgrid.search, {
multipleSearch: true,
multipleGroup: true,
recreateFilter: true,
closeOnEscape: true,
closeAfterSearch: true,
overlay: 0,
afterRedraw: function() {
$('input.add-rule',this).button().val('Add new rule')
.attr('title', 'My Add new rule tooltip');
$('input.add-group',this).button().val('Add new group or rules')
.attr('title', 'My new group or rules tooltip');
$('input.delete-rule',this).button().val('Delete rule')
.attr('title', 'My Delete rule tooltip');
$('input.delete-group',this).button().val('Delete group')
.attr('title', 'My Delete group tooltip');
$(this).find("table.group:not(:first)").css({
borderWidth: "1px",
borderStyle: "dashed"
});
}
});
我在組中添加了額外的邊框,因爲我發現有幫助。
你可以jQuery的再次使用,例如:$('select the button').attr('title', 'New localized title')
非常感謝。如果搜索對話框包含可能的行,則底行和搜索按鈕不可見。如何強制垂直滾動條出現在這種情況下?在我的應用程序邊框中,沒有在高級搜索對話框中輸入和選擇註釋。我沒有看到在CSS文件中禁用任何邊框。什麼可能會導致這種情況,並允許啓用邊界? – Andrus 2012-04-08 15:03:57
如果在搜索對話框中添加了很多行,垂直滾動條會自動出現。但是,如果高級搜索對話框打開,滾動條不會出現,底部規則和按鈕不可訪問。 – Andrus 2012-04-08 15:27:02