没有任何数据可供显示
开源项目社区 | 当前位置 : |
|
www.trustie.net/open_source_projects | 主页 > 开源项目社区 > sponger |
sponger
|
0 | 0 | 11 |
贡献者 | 讨论 | 代码提交 |
Sponger now works with rails 2.1!Sponger is a simple plug-in for creating and modifying calendars, events, and calendar widgets with the Spongecell API. This will easily allow you to create any sort of application or web site that uses events. Sponger is built on top ActiveResource which is included in Rails 2.0. ActiveResource can be used outside of rails if you copy out the ActiveResource libraries from the rails project.
Sponger is developed inside of the Spongewolf project located at: http://github.com/ckhsponge/spongewolf
Git Spongewolf (Sponger is located in the vendor/plugins directory):
git clone git://github.com/ckhsponge/spongewolfSvn Sponger:
svn export http://sponger.googlecode.com/svn/trunk/plugins/spongerThe Sponger portion of the project is mirrored at google code for script/plugin compatibility and for using their forums.
Add Sponger to an existing rails appruby script/plugin install http://sponger.googlecode.com/svn/trunk/plugins/spongerAdd Sponger to a new rails appGetting a rails app set up to use Sponger for event management is easy! Below are some steps for creating a rails app that displays a web page with a list of events from the site http://remindblast.com.
1. Create the rails appMake sure you have rails 2.0 or later installed. If you're not sure then run:
gem install railsTo generate your rails app, run the following command:
rails sponger_test2. Install the pluginChange directory into sponger_test and run:
ruby script/plugin install http://sponger.googlecode.com/svn/trunk/plugins/sponger3. Generate a controller for your appChange directory into sponger_test and run:
ruby script/generate controller sponger4. Add a method to your controllerEdit the file app/controller/sponger_controller.rb and the following method:
#gets all events from 2008-04-15 that were created from remindblast.com
def events
@events = Sponger::Event.find(:all,:params=>{:calendar_id=>137619,:start_time=>Date.new(2008,04,15)})
end5. Add a viewCreate the file app/views/sponger/events.rhtml and paste the following into it:
6. Start your serverruby script/server start7. Check the resultsPoint your browser at http://localhost:3000/sponger/events. You should see a list of events that were created as reminders. Done!