diff --git a/views/qcar2/main_page.php b/views/qcar2/main_page.php
index 1f657c7..0ba864a 100644
--- a/views/qcar2/main_page.php
+++ b/views/qcar2/main_page.php
@@ -59,7 +59,7 @@
-
+
@@ -393,16 +393,36 @@ $(document).ready(function()
}
$("#carin_query_tbody").html(tmp_str_array.join(''));
-
$("#carin_query_list").show();
+
+ // 若只找到一台, 直接跳到結果頁
+ if(idx == 0)
+ {
+ check_lpr(0);
+ }
}
});
});
+ // Custom: altob-keyaction
+ // ********************
+ $.extend($.keyboard.keyaction, {
+ accept : function(base) {
+ base.close(true); // same as base.accept();
+
+ // 直接 submit
+ $( "#fuzzy_search_lpr" ).submit();
+
+ return false; // return false prevents further processing
+ }
+ });
+
// Custom: altob-input
// ********************
$('#fuzzy_input').keyboard({
+ usePreview: false,
+
css : {
// input & preview styles
input : 'ui-widget-content ui-corner-all',
@@ -417,6 +437,17 @@ $(document).ready(function()
// used when disabling the decimal button {dec} when a decimal exists in the input area
buttonDisabled : 'ui-state-disabled'
},
+
+ position : {
+ // null (attach to input/textarea) or a jQuery object (attach elsewhere)
+ of : null,
+ my : 'center top',
+ at : 'center top',
+ // at2 is used when "usePreview" is false (centers keyboard at the bottom
+ // of the input/textarea)
+ at2: 'center bottom',
+ collision: 'flipfit flipfit'
+ },
display: {
'bksp' : '\u2190',
@@ -437,7 +468,10 @@ $(document).ready(function()
}
- });
+ }).addTyping({
+ showTyping: true,
+ delay: 250
+ });
// 定時自動更新頁面
(function autoReloadPage(){
diff --git a/views/qcar3/main_page.php b/views/qcar3/main_page.php
index 2df57a2..6caa05a 100644
--- a/views/qcar3/main_page.php
+++ b/views/qcar3/main_page.php
@@ -59,7 +59,7 @@
-
+
@@ -425,16 +425,36 @@ $(document).ready(function()
}
$("#carin_query_tbody").html(tmp_str_array.join(''));
-
$("#carin_query_list").show();
+
+ // 若只找到一台, 直接跳到結果頁
+ if(idx == 0)
+ {
+ check_lpr(0);
+ }
}
});
});
+ // Custom: altob-keyaction
+ // ********************
+ $.extend($.keyboard.keyaction, {
+ accept : function(base) {
+ base.close(true); // same as base.accept();
+
+ // 直接 submit
+ $( "#fuzzy_search_lpr" ).submit();
+
+ return false; // return false prevents further processing
+ }
+ });
+
// Custom: altob-input
// ********************
$('#fuzzy_input').keyboard({
+ usePreview: false,
+
css : {
// input & preview styles
input : 'ui-widget-content ui-corner-all',
@@ -449,6 +469,17 @@ $(document).ready(function()
// used when disabling the decimal button {dec} when a decimal exists in the input area
buttonDisabled : 'ui-state-disabled'
},
+
+ position : {
+ // null (attach to input/textarea) or a jQuery object (attach elsewhere)
+ of : null,
+ my : 'center top',
+ at : 'center top',
+ // at2 is used when "usePreview" is false (centers keyboard at the bottom
+ // of the input/textarea)
+ at2: 'center bottom',
+ collision: 'flipfit flipfit'
+ },
display: {
'bksp' : '\u2190',
@@ -469,7 +500,10 @@ $(document).ready(function()
}
- });
+ }).addTyping({
+ showTyping: true,
+ delay: 250
+ });
// 定時自動更新頁面
(function autoReloadPage(){