Sha256: ddcc0ef00d6b56fc276e56d1ae3de2cde7c73b8a5ee83bd8887d9ecb9afa87ae
Contents?: true
Size: 523 Bytes
Versions: 2
Compression:
Stored size: 523 Bytes
Contents
class UsersController < ApplicationController respond_to :xlsx, :html # GET /users # GET /users.json def index @users = User.all respond_to do |format| format.html # index.html.erb format.xlsx end end def show @user = User.find(params[:id]) respond_with(@user) do |format| format.xlsx { render "respond_with.xlsx.axlsx" } end end def send_instructions @user = User.find(params[:user_id]) @user.send_instructions render plain: "Email sent" end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
axlsx_rails-0.5.1 | spec/dummy_5/app/controllers/users_controller.rb |
axlsx_rails-0.5.0 | spec/dummy_5/app/controllers/users_controller.rb |