/**@jsx React.DOM*/ /* global conjur, React, jQuery */ (function(conjur, React, $) { 'use strict'; var OwnedResourcesBox = conjur.views.OwnedResourcesBox, Search = conjur.views.mixins.Search; var DashboardSearchForm = React.createClass({ mixins: [Search], render: function() { return ( ); } }); var DashboardFrequent = React.createClass({ getInitialState: function() { return {resources: [], loaded: false}; }, componentWillMount: function() { $.get('/api/authz/' + conjur.app.configuration.account + '/resources?owner=' + encodeURIComponent(conjur.app.userId), function(data) { var filteredData = data.filter(function(item) { // assets of 'secret' kind are internal return item.id.split(':')[1] !== 'secret'; }); this.setState({resources: filteredData, loaded: true}); }.bind(this)); }, render: function() { var content; if (this.state.loaded) { content = ( ); } else { content = ( Loading... ); } return (

Owned assets

{content}
); } }); this.Dashboard = React.createClass({ render: function() { var AuditTable = window.AuditTable; return (
); } }); }).bind(conjur.views) ( conjur, React, jQuery );