This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Преобразование Oracle строки с интервалов в строку со временем в формате ISO-8601 (для java класса Duration) | |
* @param oracleInterval строка в формате +83 18:47:29.000000, которую возвращает функция NUMTODSINTERVAL | |
* @return строка в формате ISO-8601 | |
*/ | |
private String getDurationISO8601(String oracleInterval){ | |
String result=null; | |
if (oracleInterval!=null){ | |
Pattern regex = Pattern.compile("([+-])?(\\d+)\\s(\\d+):(\\d+):(\\d+)\\.\\d+"); | |
Matcher regexMatcher = regex.matcher(oracleInterval); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
div.onkeyup = function(e) { | |
var target = e.srcElement; | |
var keyCode = ('which' in event) ? e.which : e.keyCode; | |
var maxLength = parseInt(target.attributes["maxlength"].value, 10); | |
var position = target.selectionStart; | |
var myLength = target.value.length; | |
// если достигли при вводе макс длины и это не кнопки влево\вправо и курсор в конце строки и нажали вправо | |
if ((myLength >= maxLength && keyCode!==37 && keyCode!==39) || (position===myLength && keyCode===39)) { | |
var next = target; | |
// берем след элемент |