-
3 Feb 2011 8:02 AM #1
Ext.form.ux.touch.CalendarPicker
Ext.form.ux.touch.CalendarPicker
Simple calendar to use instead of the default date picker. This is my first shot at creating a custom control so I'm sure there will be better ways of doing things, any additions are welcome since it still needs a little bit of work, fixing up the style on the form field display. Anybody with more experience on styling let me know on how to fix the gray box and text alignment.
Git - https://github.com/ecanas/Ext.form.u...CalendarPicker
Demo - http://www.ordersinseconds.com/calendarpicker/
Here are some pics of how it looks iphone:

and ipad:

-
11 Feb 2011 10:19 PM #2
Nice to see that you developed a calendar
,
I have posted this as Feature Request some months ago and status is open. So we could expect some thing from Sencha Guys
http://www.sencha.com/forum/showthre...-functionality
Hope you could do more based on that .
-
4 Mar 2011 6:56 AM #3
hey!
hey!
Would you mind if I take your example and create a time picker?
-
4 Mar 2011 6:57 AM #4
Not at all you can reuse any of the code to fit your needs.
-
4 Mar 2011 7:00 AM #5
the Cherry on top
the Cherry on top
I think you should change the next flow:
user searches for a date-> user touches the day -> date has been picked->date window is closed
to
user searches for a date-> user touches the day -> date has been picked-> user has a visual feedback that date was picked -> user clicks on a confirm button
this is how it works in most calenders
Cheers- you did a wonderful job
-
8 Mar 2011 7:18 PM #6
Hi "cd.Canas":
I am trying to implement your code. I have a issue on that. Could you check, and give me some ideas.
I have two panels into the “Ext.extend(Ext.Panel, {...}”
Sample code:
When value of “value” is changed, I want to refresh “WeeklyTimesheet” panel. How do I do that?Code:var WeeklyTimesheetFrame = Ext.extend(Ext.Panel, { title: 'Timesheet', iconCls: 'time', fullscreen: true, items: [{ xtype: "fieldset", title: "Weekly Timesheet", items: [{ xtype: "calendarpickerfield", label: "Date", dateFormat: 'd-m-Y', Value: new Date(), }, [WeeklyTimesheet] ] });
-
9 Mar 2011 6:38 AM #7
the calendar picker has an Event for when the value changes. So you need to add a listerner for "select" search for the following lines of code
Code:initComponent: function() { this.addEvents('select'); ..... .... onPickerChange: function(picker, value) { this.setValue(value); this.fireEvent('select', this, this.getValue()); }, ...
-
9 Mar 2011 3:48 PM #8
Thanks for your reply. Could you please give details, how to add a listeners for "select" search? It will be appreciated.
-
22 Mar 2011 4:12 PM #9
I have a following code:
How do I get value into the "ChangingDate" variable?Code:var WeeklyTimesheetFrame = Ext.extend(Ext.Panel, { title: 'Timesheet', iconCls: 'time', fullscreen: true, items: [{ xtype: "fieldset", title: "Weekly Timesheet", items: [{ xtype: "calendarpickerfield", label: "Date", dateFormat: 'd-m-Y', value: new Date(), // Here is the date value listeners: { render: function () { var ChangingDate = ??? // How do I get changing date? alert(ChangingDate); } } //~Riaz-23rd11 }] } ] }); Ext.reg("jsWeeklyTimeSheetList", WeeklyTimesheetFrame);
-
22 Mar 2011 5:42 PM #10
If you are using my calendar picker code, then you need to listen for select see code below
See the sample on the previous post where I call this.fireEvent('select', this, this.getValue());Code:var WeeklyTimesheetFrame = Ext.extend(Ext.Panel, { title: 'Timesheet', iconCls: 'time', fullscreen: true, items: [{ xtype: "fieldset", title: "Weekly Timesheet", items: [{ xtype: "calendarpickerfield", label: "Date", dateFormat: 'd-m-Y', value: new Date(), // Here is the date value listeners: { select: function (picker, value) { var ChangingDate = value; // How do I get changing date? alert(ChangingDate); } } //~Riaz-23rd11 }] } ] }); Ext.reg("jsWeeklyTimeSheetList", WeeklyTimesheetFrame);
Similar Threads
-
XTemplate + Touch form controls
By Bucs in forum Sencha Touch 1.x: DiscussionReplies: 7Last Post: 14 Sep 2011, 9:55 AM -
Using standard form elements with Sencha Touch
By zenmity in forum Sencha Touch 1.x: DiscussionReplies: 1Last Post: 20 Jan 2011, 4:02 PM -
Form fields validation in Sencha Touch
By Yazla in forum Sencha Touch 1.x: DiscussionReplies: 0Last Post: 9 Dec 2010, 3:32 AM -
Submitting a form using Sencha Touch
By Rakesh Pai in forum Sencha Touch 1.x: DiscussionReplies: 10Last Post: 2 Dec 2010, 12:56 AM -
Submitting a Form in Sencha Touch
By vaughanhale in forum Sencha Touch 1.x: DiscussionReplies: 3Last Post: 27 Jul 2010, 11:20 PM


Reply With Quote