Yet another DCT Date Picker Thread
I am trying to implement my first calendar date picker callout in a DCT and I'm close but it's not completely working yet. Another co-worker implemented a date picker in TagUI so I stole all that code for my DCT. It works in TagUI. I click on the callout button, the calendar widget appears, I click on a date and it closes the calendar widget and enters the date I picked in the format I want in the metadata capture field. Beautiful.
However, for my DCT, I am seeing the calendar widget pop up when I click on the callout button. That's a good thing. But when I click on a date, nothing happens. The calendar widget just stays there and nothing happens.
So I need some help figuring out why the widget doesn't close and send my selected date back to my DCT.
This is the code I have injected into the DCT:
<script language="javascript" src="/iw-cc/base/widget/calendar/calendar_init.js"></script>
IWEventRegistry.addItemHandler("/markets/sale_information/start_date", "onCallout", showCalendar);
function showCalendar(item) {
function DateCallBack(date) {item.setValue(formatDate(date, "MM/dd/yyyy"));};
var theCalendarWindow = fwShowCalendar("-callback", DateCallBack, "-initialdate", new Date().valueOf());
}
And here's the item definition:
<root-container name="markets" location="markets">
<container name="sale_information" location="sale_information" min="1" max="1">
<label>Sale Information</label>
<item name="start_date" pathid="start_date">
<label>Sale Start</label>
<description>Enter the date this sale will begin</description>
<text required="f" size="35">
<callout url="" label="select date"/>
</text>
</item>
</container>
</root-container>
Categories
- All Categories
- Cloud Editions
- 1 Thrust Services
- cat as link
- 1 Core SaaS Application development
- 10 Developer Announcements
- 15 General Questions
- 33.4K TeamSite
- 141 Application Governance & Archiving
- 15.2K Designing Analytics Reports
- 1K DevShare Downloads
- Core SaaS Applications
- nested parent
- 4.3K Developing Analytics Applications
- 8.8K Documentum Developer Forum
- Media Management developer
- 159 Transactional Content Processing (TCP)
- 1.7K Web Experience Management
- 55 Tempo Social
- 1 XM Fax