mirror of
https://github.com/yldio/copilot.git
synced 2024-12-30 22:00:06 +02:00
fix projects unconected test
This commit is contained in:
parent
3d50f4201d
commit
b29433c2e0
@ -14,7 +14,6 @@ const buttonStyle = {
|
||||
};
|
||||
|
||||
const People = (props) => {
|
||||
|
||||
const {
|
||||
UI = {},
|
||||
handleToggle,
|
||||
|
@ -25,14 +25,11 @@ const {
|
||||
projectRemoveMember,
|
||||
} = actions;
|
||||
|
||||
const People = (props) => {
|
||||
|
||||
return (
|
||||
<Section {...props}>
|
||||
<PeopleSection {...props} />
|
||||
</Section>
|
||||
);
|
||||
};
|
||||
const People = (props) => (
|
||||
<Section {...props}>
|
||||
<PeopleSection {...props} />
|
||||
</Section>
|
||||
);
|
||||
|
||||
const mapStateToProps = (state, {
|
||||
params = {}
|
||||
|
@ -26,8 +26,7 @@ const {
|
||||
const Projects = (props) => {
|
||||
const {
|
||||
org = {},
|
||||
projects = [],
|
||||
router
|
||||
projects = []
|
||||
} = props;
|
||||
|
||||
const empty = projects.length ? null : (
|
||||
@ -45,15 +44,12 @@ const Projects = (props) => {
|
||||
</li>
|
||||
));
|
||||
|
||||
const onCreateProject = (evt) =>
|
||||
router.transitionTo(`/${org.id}/new-project`);
|
||||
|
||||
return (
|
||||
<div>
|
||||
{empty}
|
||||
<Row>
|
||||
<Column xs={12}>
|
||||
<Button onClick={onCreateProject}>
|
||||
<Button href={`/${org.id}/new-project`}>
|
||||
<FormattedMessage id='create-new' />
|
||||
</Button>
|
||||
</Column>
|
||||
@ -69,8 +65,7 @@ const Projects = (props) => {
|
||||
|
||||
Projects.propTypes = {
|
||||
org: PropTypes.org,
|
||||
projects: React.PropTypes.arrayOf(PropTypes.project),
|
||||
router: React.PropTypes.object
|
||||
projects: React.PropTypes.arrayOf(PropTypes.project)
|
||||
};
|
||||
|
||||
const mapStateToProps = (state, {
|
||||
@ -79,8 +74,7 @@ const mapStateToProps = (state, {
|
||||
}
|
||||
}) => ({
|
||||
org: orgByIdSelector(match.params.org)(state),
|
||||
projects: projectsByOrgIdSelector(match.params.org)(state),
|
||||
router: state.app.router
|
||||
projects: projectsByOrgIdSelector(match.params.org)(state)
|
||||
});
|
||||
|
||||
module.exports = connect(
|
||||
|
Loading…
Reference in New Issue
Block a user