daily pastebin goal
50%
SHARE
TWEET

Untitled

a guest Dec 10th, 2018 55 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. export const ORDER_COLUMNS = [
  2.   { name: 'orderNumber', title: 'Order', width: '10%',  type: 'string' },
  3.   { name: 'orderType', title: 'Type', width: '10%',  type: 'string' }
  4. ];
  5.  
  6. class OrderGridControl extends React.Component {
  7.   constructor(props) {
  8.     super(props);
  9.     this.state = {
  10.         orderColumns: ORDER_COLUMNS
  11.     };
  12.   }
  13.   ...
  14.  
  15. }
  16.  
  17. export default OrderGridControl;
  18.    
  19. import {OrderGridControl, ORDER_COLUMNS} from 'component/order-grid-control';
  20.  
  21. class OrderQueryPage extends React.Component {
  22.       constructor(props) {
  23.     super(props);
  24.     this.state = {
  25.         orderColumns: ORDER_COLUMNS
  26.     };
  27.     console.info(this.state.orderColumns);
  28.   }
  29.  
  30.   ...
  31.  
  32.   render() {
  33.     return (
  34.       <div>
  35.         <PropertyGrid gridSetup={this.state.orderColumns} />
  36.       </div>
  37.     );
  38.   }
  39. }
  40.    
  41. import OrderGridControl, { ORDER_COLUMNS } from 'component/order-grid-control';
  42.    
  43. import GridControl, { ORDER_COLUMNS } from 'component/order-grid-control';
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top