mirror of
https://github.com/aspnet/JavaScriptServices.git
synced 2025-12-23 01:58:29 +00:00
Add example of server and client validation for React
This commit is contained in:
63
samples/react/ReactGrid/ReactApp/data/columnMeta.jsx
Normal file
63
samples/react/ReactGrid/ReactApp/data/columnMeta.jsx
Normal file
@@ -0,0 +1,63 @@
|
||||
import React from 'react';
|
||||
import { Link } from 'react-router';
|
||||
|
||||
class RowActionsComponent extends React.Component {
|
||||
render() {
|
||||
return <Link to={'/edit/' + this.props.rowData.id}>Edit</Link>;
|
||||
}
|
||||
}
|
||||
|
||||
var columnMeta = [
|
||||
{
|
||||
"columnName": "id",
|
||||
"order": 1,
|
||||
"locked": false,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"columnName": "name",
|
||||
"order": 2,
|
||||
"locked": false,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"columnName": "city",
|
||||
"order": 3,
|
||||
"locked": false,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"columnName": "state",
|
||||
"order": 4,
|
||||
"locked": false,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"columnName": "country",
|
||||
"order": 5,
|
||||
"locked": false,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"columnName": "company",
|
||||
"order": 6,
|
||||
"locked": false,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"columnName": "favoriteNumber",
|
||||
"order": 7,
|
||||
"locked": false,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"columnName": "actions",
|
||||
"order": 8,
|
||||
"locked": true,
|
||||
"visible": true,
|
||||
"customComponent": RowActionsComponent
|
||||
}
|
||||
];
|
||||
|
||||
export var columnMeta;
|
||||
|
||||
Reference in New Issue
Block a user