Disable PDF export on live_table pages
PDF generation was failing in production. CSV export still works.
This commit is contained in:
parent
5e5663fbb1
commit
11a50bf2c2
4 changed files with 16 additions and 1 deletions
|
|
@ -6,6 +6,10 @@ defmodule MicrowavepropWeb.Admin.ContactEditLive do
|
||||||
alias Microwaveprop.Radio
|
alias Microwaveprop.Radio
|
||||||
alias Microwaveprop.Radio.EditNotifier
|
alias Microwaveprop.Radio.EditNotifier
|
||||||
|
|
||||||
|
def table_options do
|
||||||
|
%{exports: %{formats: [:csv]}}
|
||||||
|
end
|
||||||
|
|
||||||
def fields do
|
def fields do
|
||||||
[
|
[
|
||||||
id: %{label: "ID", hidden: true},
|
id: %{label: "ID", hidden: true},
|
||||||
|
|
|
||||||
|
|
@ -6,6 +6,10 @@ defmodule MicrowavepropWeb.BeaconLive.Index do
|
||||||
alias Microwaveprop.Beacons
|
alias Microwaveprop.Beacons
|
||||||
alias Microwaveprop.Beacons.Beacon
|
alias Microwaveprop.Beacons.Beacon
|
||||||
|
|
||||||
|
def table_options do
|
||||||
|
%{exports: %{formats: [:csv]}}
|
||||||
|
end
|
||||||
|
|
||||||
def fields do
|
def fields do
|
||||||
[
|
[
|
||||||
id: %{label: "ID", hidden: true},
|
id: %{label: "ID", hidden: true},
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,10 @@ defmodule MicrowavepropWeb.ContactLive.Index do
|
||||||
use LiveTable.LiveResource, schema: Microwaveprop.Radio.Contact
|
use LiveTable.LiveResource, schema: Microwaveprop.Radio.Contact
|
||||||
|
|
||||||
def table_options do
|
def table_options do
|
||||||
%{sorting: %{default_sort: [inserted_at: :desc]}}
|
%{
|
||||||
|
sorting: %{default_sort: [inserted_at: :desc]},
|
||||||
|
exports: %{formats: [:csv]}
|
||||||
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
def fields do
|
def fields do
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,10 @@ defmodule MicrowavepropWeb.UserManagementLive.Index do
|
||||||
|
|
||||||
alias Microwaveprop.Accounts
|
alias Microwaveprop.Accounts
|
||||||
|
|
||||||
|
def table_options do
|
||||||
|
%{exports: %{formats: [:csv]}}
|
||||||
|
end
|
||||||
|
|
||||||
@impl true
|
@impl true
|
||||||
def mount(_params, _session, socket) do
|
def mount(_params, _session, socket) do
|
||||||
{:ok, assign(socket, :page_title, "Users")}
|
{:ok, assign(socket, :page_title, "Users")}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue