Ivan - Update error debugging csv import [skip ci]

This commit is contained in:
ivan 2017-03-04 18:42:17 -03:00
parent 8c138b481c
commit 661e9c396b
1 changed files with 2 additions and 2 deletions

View File

@ -238,14 +238,14 @@ class AdminPanelAdvancedSettings extends React.Component {
.then((result) => this.setState({ .then((result) => this.setState({
messageType: 'success', messageType: 'success',
messageTitle: i18n('SUCCESS_IMPORTING_CSV_DESCRIPTION'), messageTitle: i18n('SUCCESS_IMPORTING_CSV_DESCRIPTION'),
messageContent: ( messageContent: (result.data.length) ? (
<div> <div>
{i18n('ERRORS_FOUND')} {i18n('ERRORS_FOUND')}
<ul> <ul>
{result.data.map((error) => <li>{error}</li>)} {result.data.map((error) => <li>{error}</li>)}
</ul> </ul>
</div> </div>
) ) : null
})) }))
.catch(() => this.setState({messageType: 'error', messageTitle: null, messageContent: i18n('INVALID_FILE')})); .catch(() => this.setState({messageType: 'error', messageTitle: null, messageContent: i18n('INVALID_FILE')}));
} }