Making WordPress.org


Ignore:
Timestamp:
12/17/2018 07:34:12 AM (7 years ago)
Author:
vedjain
Message:

WCPT Application Tracker: Multiple changes in rendering of application status report, see desc.

  1. Add customRender option to allow specifying different render logic in application tracker report.
  2. Send timestamp for lastUpdated column instead of humanize_time_diff. Move logic for humanize_time_diff to frontend, because its a very simple logic, and would make a easy fix for #2501
  3. Use customRender option to display X time ago instead of absolute timestamp.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordcamp.org/public_html/wp-content/plugins/wcpt/javascript/tracker/source/components/filterable-table/table.jsx

    r3814 r7976  
    1010        sortOrder       : PropTypes.oneOf( [ 'asc', 'desc' ] ),
    1111        handleSortEvent : PropTypes.func.isRequired,
     12        customRender    : PropTypes.object,
    1213    },
    1314
     
    2223    render : function() {
    2324        const rows = this.props.rows.map( function( row, index ) {
    24             return <TableRow columns={ this.props.columns } row={ row } key={ index } />;
     25            return (
     26                <TableRow
     27                    columns      = { this.props.columns }
     28                    row          = { row }
     29                    key          = { index }
     30                    customRender = { this.props.customRender }
     31                />
     32            );
    2533        }.bind( this ) );
    2634
Note: See TracChangeset for help on using the changeset viewer.