It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

cannot override browser default for date picker Edited

Ngoc Tuan Lam Oct 09, 2017

I try to add an AUI date picker following this : 

https://docs.atlassian.com/aui/latest/docs/date-picker.html

 

I try to add 

AJS.$(document).ready(function() {
AJS.$('#demo-range-always').datePicker({'overrideBrowserDefault': true});
});

 

However , the it gets error when deploy : 

aui-datepicker.js:1619 Uncaught TypeError: Cannot read property 'msie' of undefined
at Datepicker._generateHTML (aui-datepicker.js:1619)
at Datepicker._updateDatepicker (aui-datepicker.js:730)
at Datepicker._inlineDatepicker (aui-datepicker.js:299)
at Datepicker._attachDatepicker (aui-datepicker.js:183)
at HTMLDivElement.<anonymous> (aui-datepicker.js:1855)
at Function.each (jquery-1.12.4.js:370)
at jQuery.fn.init.each (jquery-1.12.4.js:137)
at jQuery.fn.init.__601fc554d291439a8ef8bcac7fc51f19.$.fn.datepicker (aui-datepicker.js:1851)
at initCalendar (aui-datepicker.js:2036)
at aui-datepicker.js:2173

 

I also try to add in atlassian-plugin.xml

<web-resource key="date-picker" name="Date Picker">
<dependency>com.atlassian.auiplugin:aui-date-picker</dependency>
</web-resource>

 and in the velocity file

$webResourceManager.requireResource("com.adsk.jira.tryThis:date-picker")
<script src="//aui-cdn.atlassian.com/aui-adg/6.0.8/js/aui-experimental.js"></script>
<script src="//aui-cdn.atlassian.com/aui-adg/6.0.8/js/aui-datepicker.js"></script>

 

but no help.

 

1 answer

0 votes
Ngoc Tuan Lam Oct 12, 2017

anyone experience this before ????

Suggest an answer

Log in or Sign up to answer
This widget could not be displayed.
This widget could not be displayed.
Community showcase
Posted in United States

Topic Tuesday: Agile

Another week, another Topic Tuesday!  Agile has been on my mind a lot lately because I've seen good implementations and bad implementations, but now as a Jira admin it matters more to me whether...

14 views 0 0
View post

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you