Here goes with the CalendarHelper

I am working on a way to create standard tasks – yesterday i devised the Periodic Table of Cleaning with which i am extremly pleased! :D Next i have to figure a way to automatically create it all – providing AJAX realtime feedback so that the user knows something is happening and hopefully doesn’t interrupt it by clicking somewhere else!

Today i discovered that the signup process is a little bit slow – and that’s just creating one team and one list! I really should provide some feedback there too.

Today’s big enhancement is the CalendarHelper! It’s a lovely popup floating Javascript/DHTML calendar for choosing dates. Source code here and Ruby on Rails plugin here – and now i just hope it’s going to work for everybody! You can still type in the text box incase you have Javascript disabled.

As usual, if you have any problems with anything on the site, please let me know! I have backups so if the CalendarHelper causes any problems we can easily go back to the standard Ruby on Rails dropdown boxes.

One more thing: the Person model now has some checking that you’ve entered a valid login id and email address. I was a little bit nervous that you could easily create a login id with spaces, commas, question marks … well anything you like really! Fortunately people are familiar enough with creating login ids that nobody thought to try, lol!

If you want to know exactly what’s allowed and what isn’t – and if you can read regular expressions (i only just began to get the hang of them today!) here’s the code:

validates_format_of :login, :with => /^[\w-]+$/

validates_format_of :email, :with => /^([^\s]+)((?:[-a-z0-9]+\.)+[a-z]{2,})$/i

Comments are closed.