We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I tried to create a .xlsx.axlsx template but I get this error message:
Missing template item_refs/index, application/index with {:locale=>[:fr], :formats=>[:xlsx], :handlers=>[:erb, :builder, :raw, :ruby, :slim, :jbuilder, :coffee]}
My controller is like so:
def index @item_refs = ItemRef.filtered_by(params[:q]).order(sort_order).first(10) respond_to do |format| format.html format.js format.xlsx { render :xlsx => "index", filename: 'items.xlsx' } end end
And this is my view (index.xlsx.axlsx):
ItemRef.to_xlsx package: xlsx_package
xlsx_package.workbook.worksheets.first.tap do |sheet| sheet.add_row ["First Column", "Second", "Third"] sheet.add_row [1, 2, 3] sheet.add_row [' preserving whitespace'] end
Am I doing something wrong? Thanks.
The text was updated successfully, but these errors were encountered:
@ndemoreau Looks like you are having an issue with axlsx_rails, not acts_as_xlsx. It isn't finding the template. Have you solved your problem?
Sorry, something went wrong.
No branches or pull requests
I tried to create a .xlsx.axlsx template but I get this error message:
Missing template item_refs/index, application/index with {:locale=>[:fr], :formats=>[:xlsx], :handlers=>[:erb, :builder, :raw, :ruby, :slim, :jbuilder, :coffee]}
My controller is like so:
def index
@item_refs = ItemRef.filtered_by(params[:q]).order(sort_order).first(10)
respond_to do |format|
format.html
format.js
format.xlsx { render :xlsx => "index", filename: 'items.xlsx'
}
end
end
And this is my view (index.xlsx.axlsx):
ItemRef.to_xlsx package: xlsx_package
xlsx_package.workbook.worksheets.first.tap do |sheet|
sheet.add_row ["First Column", "Second", "Third"]
sheet.add_row [1, 2, 3]
sheet.add_row [' preserving whitespace']
end
Am I doing something wrong? Thanks.
The text was updated successfully, but these errors were encountered: