为了在带有资产管道的grails 2.4.4中使用jquery-ui插件,我应该采取哪些步骤?
我所做的是: 我添加了
compile "org.grails.plugins:jquery-ui:1.10.4"
BuildConfig.groovy中的
还补充道:
//= require jquery-ui/js/jquery-ui-1.10.4.custom.min
//= require js/jquery-ui-1.10.4.custom
在application.js
中和
*= require themes/ui-lightness/jquery-ui-1.10.4.custom
在application.css
中我在gsp页面中添加了所需的脚本:
<script type="text/javascript">
$(document).ready(function()
{
$("#datepicker").datepicker({dateFormat: 'yy/mm/dd'});
})
</script>
我想要完成的是在gsp中添加日期选择器。我还应该做些什么才能让它发挥作用?
据我所知,我检查了观察源: 内幕:
<link rel="stylesheet" href="/NTSuite_Web/assets/application.css?compile=false">
<link rel="stylesheet" href="/NTSuite_Web/assets/bootstrap.css?compile=false">
<link rel="stylesheet" href="/NTSuite_Web/assets/themes/ui-lightness/jquery-ui-1.10.4.custom.css?compile=false">
<script type="text/javascript">
$(document).ready(function()
{
$("#datepicker").datepicker({dateFormat: 'yy/mm/dd'});
})
</script>
<script type="text/javascript">
function doSubmit(val){
document.getElementById('openMode').value=val;
document.party.submit();
}
</script>
身体:
<script src="/NTSuite_Web/assets/jquery/jquery-1.11.1.js?compile=false" type="text/javascript"></script>
<script src="/NTSuite_Web/assets/jquery.js?compile=false" type="text/javascript"></script>
<script src="/NTSuite_Web/assets/application.js?compile=false" type="text/javascript"></script>
<script src="/NTSuite_Web/assets/bootstrap-affix.js?compile=false" type="text/javascript"></script>
<script src="/NTSuite_Web/assets/bootstrap-alert.js?compile=false" type="text/javascript"></script>
<script src="/NTSuite_Web/assets/bootstrap-button.js?compile=false" type="text/javascript"></script>
<script src="/NTSuite_Web/assets/bootstrap-carousel.js?compile=false" type="text/javascript"></script>
<script src="/NTSuite_Web/assets/bootstrap-collapse.js?compile=false" type="text/javascript"></script>
<script src="/NTSuite_Web/assets/bootstrap-dropdown.js?compile=false" type="text/javascript"></script>
<script src="/NTSuite_Web/assets/bootstrap-modal.js?compile=false" type="text/javascript"></script>
<script src="/NTSuite_Web/assets/bootstrap-tooltip.js?compile=false" type="text/javascript"></script>
<script src="/NTSuite_Web/assets/bootstrap-popover.js?compile=false" type="text/javascript"></script>
<script src="/NTSuite_Web/assets/bootstrap-scrollspy.js?compile=false" type="text/javascript"></script>
<script src="/NTSuite_Web/assets/bootstrap-tab.js?compile=false" type="text/javascript"></script><script src="/NTSuite_Web/assets/bootstrap-transition.js?compile=false" type="text/javascript"></script>
<script src="/NTSuite_Web/assets/bootstrap.js?compile=false" type="text/javascript"></script>
<script src="/NTSuite_Web/assets/js/jquery-ui-1.10.4.custom.js?compile=false" type="text/javascript"></script>
我的约会选择器:
<input type="text" id="datepicker">
我已经完成了所有这些而没有理解整个过程,如果我能用正确的程序得到答案,那就太棒了。