sortable
(optional)- Boolean value indicates whether user can sort master records
defaultSort
(optional)- Accept default sort as
[key, 1/-1]
- Accept default sort as
limits
(optional)- Accepts array of numbers to show as limit for pagination
routes
(optional)- Accepts key-value pair of routes to be used for API calls, see
Routes_Input
section below
- Accepts key-value pair of routes to be used for API calls, see
loader
(optional)- Accepts
JSX
element to be show when data is loading
- Accepts
explicitForm
(optional)- Boolean value indicates use of external form if true
permissions
(optional)- Accepts key-value pair for permissions for user to list, create, update, delete, etc. see
Permissions
section below
- Accepts key-value pair for permissions for user to list, create, update, delete, etc. see
t(CODE)
(optional)- Accepts function to show texts in internationalized version
preConfirmDelete({ row })
(optional)- Callback to execute before calling delete API
columns
(optional)- Accepts array of columns to show from data, Data will includes Actions to
edit
/delete
(when not specified false foractions
) - Defaults columns are for
Name
,Code
,Active
and actions - columns accepts array of value in
ColumnSchema
pattern, seeColumnSchema
section below
- Accepts array of columns to show from data, Data will includes Actions to
actions
(optional)- Accepts
false
or object inTableActions
format, seeTableActions
section below - false | TableActionTypes
- Accepts
- Accepts Object with key as
ACTION_TYPES
and value as funcion - Function provides avails parameters
module
=> current modulemaster
id
=> id of record, in case of update/delete
- Function need following parameters in return
url
=> relative url like/admin/masters/update
method
=> HTTP method like GET, POST, etc.
- Allows providing following permissions for Master/SubMaster
list
=> Can user see datasequencing
=> Can user change item sequenceadd
=> Can user add new recordupdate
=> Can user update recordpartialUpdate
=> Can user do partial update like change inisActive
destroy
=> Can user delete record
Header
=> string or react elementaccessor
=> string to access data value from objectid
(optional) => unique idsortable
(optional) => boolean value indicates, if user can sort columnrefetchOnUpdate
(optional) => Flag to refetch list when update happens by callingonUpdate(data)
Cell
(optional) =>({ row, onUpdate }) => JSX.Element
row
is record currently accessingonUpdate(data)
callback function to execute to perform update
showUpdate
=> boolean value indicates whether user can update datashowDelete
=> boolean value indicates whether user can delete dataatFirst
=> boolean value indicates whether TableActions should be shown at first
ADD
=> Adding RecordUPDATE
=> Updating RecordDELETE
=> Deleting Record''
=> Nothing selected
label
(optional) => Label for Inputaccessor
=> string represending key to access in dataInput
(optional) => (props: InputRenderProps) => JSX.Element- See
InputRenderProps
below
- See
validations
(optional) => Supported Validations from react-hook-formeditable
(optional) => boolean value indicating whether input is editableonInput
(optional) =>(e: React.ChangeEvent<HTMLInputElement>) => void
- React onInput event
type
(optional) => "text" | "number" | "select" | "checkbox" | "textarea"options
(optional) => Array of{ value: string; label: string }
for selectdefaultValue
(optional) =>string
|number
|boolean
placeholder
(optional) => string
field
=> set of properties fromreact-hook-form
fielderror
=> string indicating error in inputsetError
=>(msg: string) => void
- To set error manually in input
_id
=> stringuri
=> string representing URL relative to backend apinm
=> stringtype
=> string