The text below is selected, press Ctrl+C to copy to your clipboard. (⌘+C on Mac) No line numbers will be copied.
Guest
Asdasd
By Guest on 22nd January 2018 09:49:29 AM | Syntax: JAVASCRIPT | Views: 164



New paste | Download | Show/Hide line no. | Copy text to clipboard
  1. renderActionsList() {
  2.     let list = [
  3.       { key: 'assignCourier', comp: <SendOrderAction/> },
  4.       { key: 'routes', comp: <RoutesAction/> },
  5.       { key: 'showAllRoutesOnMap', comp: <ShowAllRoutesOnMap/> },
  6.       { key: 'showAllNavigationsOnMap', comp: <ShowAllNavigationsOnMap/> }
  7.     ];
  8.  
  9.     let anotherClass = " appListControlBtns";
  10.  
  11.     return list.map((item, index) => {
  12.       if (!API.isUserPermitted(Meteor.userId(), 'applications', item.key).hasAccess)
  13.         return (<div key={ index }></div>);
  14.       return (
  15.         <div key={ index } className={ item.key + anotherClass}>
  16.            { item.comp }
  17.         </div>
  18.       );
  19.     });
  20.   }



  • Recent Pastes
  • 123123
    2 days 18 hours 54 mins 14 secs ago
  • Halo 2 PC
    5 days 22 hours 39 mins 2 secs ago
  • Yo
    6 days 8 hours 47 mins 20 secs ago
  • Ferry
    6 days 9 hours 18 mins 10 secs ago
  • Arrow e01
    1 week 8 hours 22 mins and 27 secs ago