The Redzone Leagues website got a fresh coat of varnish today. The goal of the new layout is to provide new and existing users with information that is not only easier to find, but also presented in a cleaner, more polished fashion.
Like always, if you have feedback we’d love to hear from you!
The conditional cache plugin has been updated to be compatible with Rails 1.2.4. If you’re still using a previous version of Rails, there is no need to upgrade the plugin.
This plugin allows all options of the Ajax.InPlaceEditor control to be set. This will also work with the new rewrite of the control, which is currently in the scriptaculous trunk.
This plugin replaces the current rails version of in_place_editor and is drop-in compatible.
Quick summary (more details at the url above)…
Missing options such as onFailure can now be specified…
Along with the existing user roles (league administrator, statistician, scheduler), we’ve now added a new user role for forum moderation. Any user assigned to this role has the ability to edit and delete users forum messages.
Previously a user had to be assigned the league administrator role to have the same abilities, which gave a user full control over all of the websites functions, which is not necessarily a safe option.
We’ve now added baseball to the list of sports supported by Redzone.
We currently have 3 variations set up, hardball, softball and slo-pitch; so if you have a baseball team, get your league up and running with Redzone today for FREE!
I recently had to deploy a Rails application for a client to a Joyent Accelerator. Paul Ingles has released a Capistrano recipe which helps automate this. I recommend using it.
But even with the recipe, I ran into a couple of snags. The first was with the the myprivateip script that Joyent tells you to use, and the second was Solaris’ ln.
myprivateip
There is a script /opt/csw/bin/myprivateip which is referenced in the mongrel_cluster.yml file they make available. I’d link to the page, but for some reason their how-to pages are all broken today.
Well that script didn’t return anything. It’s supposed to return an ip address.
Which is just a fancy way to get 127.0.0.1. The mypublicip script seemed to be ok. After fixing that, you’ll want to rerun the cap setup task.
ln
Well I’m not the only one with this problem. Jamie’s blog post helped me get past a problem I was having with Capistrano not updating the symbolic link for the current release. Turns out you’ll want to use the GNU version of ln. On the box I was on though, GNUln was gln and not ln like in Jamie’s setup, so I took a slightly different approach in order to fix the problem. I created a bin folder in my user’s directory and then put a link to gln like so:
1
ln -s /opt/csw/bin/gln ~/bin/ln
Next, I put my ~/bin a the front of my path. To do so, I edited .bashrc and .bash_profile (since they both had PATH environment stuff set), but that didn’t solve my problem. There was also an environment file inside the ~/.ssh folder, which gets loaded when you run stuff via ssh, which is what Capistrano does of course. So I added ~/bin to the PATH in that file so it looks something like:
1
PATH=~/bin:/usr/sbin:/usr/bin:<chopped the rest out>
Some other people have replaced a few Capistrano tasks to use gln instead of ln, but that seems sorta nutty to me.
I’ve just added TimeZone support to our Redzone Leagues application and have read a few blog posts about setting up TimeZone’s in rails. One popular article on the subject is found here.
One issue that I came across while I was adding TimeZone support to our app, is that I have time fields in many places in the database that have been created with the local time zone, not UTC, which most articles on the subject seem to assume are already in the database. All of the timestamp fields in my database have no time zone support, which the rails migrations create by default (at least using Postgresql, not sure about MySql, etc.)
The common pattern you’ll see in the articles is similar to this…
1
user.tz.utc_to_local(time)
This assumes the time passed in is already in UTC format, but mine aren’t, they’re in central time.
My solution is to convert the local time to UTC first and then go with the normal conversion used above.
So the time from the database is first converted from the local time to UTC (with the local_to_utc call) and then to the time zone associated with the user (with the utc_to_local call).
I added a default method to the TimeZone class that represents the default time zone used in the app.
12345
classTimeZonedefself.defaultself["Central Time (US & Canada)"]endend
Now I can leave my database timestamps as is and still achieve the proper conversions for each user.
Location management has just been made easier with integrated Google maps.
You no longer need to upload an image for your fields, locations, etc. Enter the address of the location and we’ll find it for you (with the help of Google of course).
By clicking on map markers you can view the locations name, address and any other associated information.
You can find out more about the new location manager on the features page.
If you have comments, suggestions on this feature, please post a message in our forums, we’d love to hear from you.
To find out more about the image gallery, check out our features page
Player Listing
The player listing allows you to view all registered players in the league. A search field is provided in order to easily find a particular player. From the listing, you can preview the users profile picture (if they have one) and click a link to view their full history of stats and teams.
An administrator can enable this feature, but making it visible in the ‘Menus’ section of the admin dashboard.
Printer Friendly Schedules
Schedules can now be displayed in a more printer friendly manner. Simply display the schedule you want to print and press the printer icon located in the top right of the page to load the printer friendly version.