Merge pull request #200 from wjt/jquery

jqueryDayField: do nothing if <input type=date> supported
This commit is contained in:
Michael Snoyman 2012-01-10 02:02:10 -08:00
commit 5a6638ad18

View File

@ -84,13 +84,18 @@ jqueryDayField jds = Field
addScript' urlJqueryUiJs addScript' urlJqueryUiJs
addStylesheet' urlJqueryUiCss addStylesheet' urlJqueryUiCss
addJulius [JULIUS| addJulius [JULIUS|
$(function(){$("##{theId}").datepicker({ $(function(){
var i = $("##{theId}");
if (i.attr("type") != "date") {
i.datepicker({
dateFormat:'yy-mm-dd', dateFormat:'yy-mm-dd',
changeMonth:#{jsBool $ jdsChangeMonth jds}, changeMonth:#{jsBool $ jdsChangeMonth jds},
changeYear:#{jsBool $ jdsChangeYear jds}, changeYear:#{jsBool $ jdsChangeYear jds},
numberOfMonths:#{mos $ jdsNumberOfMonths jds}, numberOfMonths:#{mos $ jdsNumberOfMonths jds},
yearRange:"#{jdsYearRange jds}" yearRange:"#{jdsYearRange jds}"
})}); });
}
});
|] |]
} }
where where