Git Product home page Git Product logo

radiant-bookings's Introduction

Bookings

Bookings is a Radiant Extension that provides a SOAP connection to a Resmark reservation server and displays a list of locations, associated activities, start/end dates, and number of guests in an “Expedia”-like widget for booking trips. Form values in the widget are submitted to the Resmark reservation server, and the user is directed to the organization’s reservation server to complete the transaction.

Features

  • Populates a select box of all available locations
  • Selecting a location populates a select box of activities for that location via AJAX
  • Field for start date, end date, and number of guests
  • Submitting the form takes the user to the Resmark reservation system to complete the transaction

On first load, the SOAP response will be cached to a file at db/getLocationsForUrl.xml. This cache will live for 24 hours before being recreated. The cached response speeds up load time, and ensures that a user will be presented with search options even if the Resmark server is unresponsive.

Requirements

How to Use

Install the extension:


  git clone git://github.com/scullygroup/radiant-bookings.git vender/extensions/bookings

Run the migration and update tasks:


  rake radiant:extensions:bookings:migrate
  rake radiant:extensions:bookings:update

Insert the following near the top of your environment.rb file:


  USERNAME = 'myresmarkusername'
  PASSWORD = '123abc123abc123abc123abc'
  HOST = 'reservations.mydomain.com'

Note that you must have a valid username and password for accessing the Resmark Web Services.

Be sure to reference the required javascripts and stylesheets in your layout:


  <link rel="stylesheet" type="text/css" href="http://jquery-ui.googlecode.com/svn/tags/latest/themes/base/jquery.ui.all.css" />
  <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js" type="text/javascript"></script>
  <script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.7.2/jquery-ui.min.js" type="text/javascript"></script>
  <script src="/javascripts/jrails.js" type="text/javascript"></script>
  <script src="http://jqueryui.com/latest/ui/ui.datepicker.js" type="text/javascript"></script>
  <script src="/javascripts/bookings.js" type="text/javascript"></script>

Wherever you want to place the booking widget, insert the following radius tag:


  <r:bookings />

Copyright © 2009 Scully Group, released under the MIT License

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.