Module Apotomo::Rails::ViewHelper
In: lib/apotomo/rails/view_helper.rb

url_for_event

  = url_for_event(:paginate, :page => 2)
  #=> http://apotomo.de/mouse/process_event_request?type=paginate&source=mouse&page=2

widget_id

  = widget_id
  #=> :mouse

children

  - children.each do |kid|
    = render_widget kid

Methods

Public Instance methods

Returns the app JavaScript generator.

Creates a form that submits itself via an iFrame and executes the response in the parent window. This is needed to upload files via AJAX.

Better call form_to_event :multipart => true and stay forward-compatible.

Wraps your widget content in a div. See widget_tag.

Wraps your widget content in a tag tag and sets the id. Feel free to pass additional html options.

  - widget_tag :span do
    %p I'm wrapped

will render

  <span id="mouse">
    <p>I'm wrapped</p>
  </span>

Note that you can set the id and other options manually.

  - widget_tag :div, id: "comments", class: "yellow"

[Validate]