Sha256: 9d931d7afcb8617b0a31d1404a2249ad752decf1444a302beb91be553ccbba08

Contents?: true

Size: 417 Bytes

Versions: 3

Compression:

Stored size: 417 Bytes

Contents

module Main
  class SimpleHttpController < Volt::HttpController
    def index
      render text: 'this is just some text'
    end

    def show
      render text: "You had me at #{store._simple_http_tests.first._name}"
    end

    def upload
      uploaded = params._file._tempfile
      File.open('tmp/uploaded_file', 'wb') { |f| f.write(uploaded.read) }
      render text: 'Thanks for uploading'
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
volt-0.9.3.pre2 spec/apps/kitchen_sink/app/main/controllers/server/simple_http_controller.rb
volt-0.9.3.pre1 spec/apps/kitchen_sink/app/main/controllers/server/simple_http_controller.rb
volt-0.9.2 spec/apps/kitchen_sink/app/main/controllers/server/simple_http_controller.rb