Skip to content

Commit 92fc39f

Browse files
authored
Merge pull request #58 from easeq/master
Added datetime picker, noResultsMessage row and other improvements
2 parents 276e7e0 + 33c5d66 commit 92fc39f

File tree

12 files changed

+1019
-125
lines changed

12 files changed

+1019
-125
lines changed

README.md

+13-11
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ import { reducer, epics } from '@flipbyte/redux-datatable';
5252
rowHeight: 50,
5353
editing: false,
5454
primaryKey: 'id',
55+
noResultsMessage: 'No row(s) found',
5556
routes: { // You can add other routes and handle them using custom actions.
5657
get: { // The route used to fetch data and it's params
5758
route: '/{your_route}',
@@ -350,17 +351,18 @@ const YourComponent = () =>
350351

351352
### Table config props
352353

353-
| Key | Type | Required | Default | Description |
354-
| ---------- | ------- | -------- | ------- | ------------------------------------------------------------------------------------------------ |
355-
| name | string | true | - | key in the row data whose value needs to be loaded for the column (does not have to be unique) |
356-
| height | integer | true | - | The maximum height of the table |
357-
| rowHeight | integer | true | - | The maximum height of each table body row |
358-
| routes | object | true | - | Routes definition to fetch data and other custom routes config for custom handling (Check below) |
359-
| components | object | true | - | All the components required for your table |
360-
| entity | object | false | - | [Normalizr](https://github.com/paularmstrong/normalizr) specification. Check below for details. |
361-
| layout | array | true | - | The layout of your table |
362-
| editing | boolean | false | false | Set the default state of the table to be in editing mode |
363-
| primaryKey | string | true | - | Set the primary key column of the table for actions like editing. |
354+
| Key | Type | Required | Default | Description |
355+
| ---------------- | ------- | -------- | ------- | ------------------------------------------------------------------------------------------------ |
356+
| name | string | true | - | key in the row data whose value needs to be loaded for the column (does not have to be unique) |
357+
| height | integer | true | - | The maximum height of the table |
358+
| rowHeight | integer | true | - | The maximum height of each table body row |
359+
| routes | object | true | - | Routes definition to fetch data and other custom routes config for custom handling (Check below) |
360+
| components | object | true | - | All the components required for your table |
361+
| entity | object | false | - | [Normalizr](https://github.com/paularmstrong/normalizr) specification. Check below for details. |
362+
| layout | array | true | - | The layout of your table |
363+
| editing | boolean | false | false | Set the default state of the table to be in editing mode |
364+
| primaryKey | string | true | - | Set the primary key column of the table for actions like editing. |
365+
| noResultsMessage | string | true | - | Set the message to be displayed when table is empty |
364366

365367
#### Routes object
366368

demo/src/schema/normalized.js

+1
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ export default {
2828
rowHeight: 50,
2929
editing: false,
3030
primaryKey: 'pageId',
31+
noResultsMessage: 'Empty results',
3132
routes: {
3233
get: {
3334
route: '/page',

package-lock.json

+96-39
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+4-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@flipbyte/redux-datatable",
3-
"version": "0.7.14",
3+
"version": "0.8.0",
44
"description": "React-Redux data table",
55
"main": "lib/index.js",
66
"module": "es/index.js",
@@ -30,21 +30,23 @@
3030
"reselect": "^4.0.0",
3131
"styled-components": "^4.3.2",
3232
"redux-observable": "^1.1.0",
33+
"moment": "^2.24.0",
3334
"redux-thunk": "^2.3.0"
3435
},
3536
"dependencies": {
3637
"element-resize-event": "^3.0.3",
3738
"normalizr": "^3.3.0",
3839
"object-assign-deep": "^0.4.0",
3940
"query-string": "^6.1.0",
40-
"react-pure-time": "^0.2.2",
41+
"react-datepicker": "^2.8.0",
4142
"react-redux-notify": "^4.1.1"
4243
},
4344
"devDependencies": {
4445
"axios": "^0.19.0",
4546
"axios-observable": "^1.1.1",
4647
"bootstrap": "^4.3.1",
4748
"lodash": ">=4.17.13",
49+
"moment": "^2.24.0",
4850
"nwb": "0.23.x",
4951
"path-to-regexp": "^3.0.0",
5052
"react": "^16.8.6",

0 commit comments

Comments
 (0)