@@ -85,4 +84,4 @@ let PieceListToolbarOrderWidget = React.createClass({
}
});
-export default PieceListToolbarOrderWidget;
\ No newline at end of file
+export default PieceListToolbarOrderWidget;
diff --git a/js/components/ascribe_table/table_item_acl_filtered.js b/js/components/ascribe_table/table_item_acl_filtered.js
index 22a28130..9ca91bcf 100644
--- a/js/components/ascribe_table/table_item_acl_filtered.js
+++ b/js/components/ascribe_table/table_item_acl_filtered.js
@@ -3,15 +3,15 @@
import React from 'react';
-let TableItemAclFiltered = React.createClass({
+const TableItemAclFiltered = React.createClass({
propTypes: {
content: React.PropTypes.object,
- notifications: React.PropTypes.string
+ notifications: React.PropTypes.array
},
render() {
- var availableAcls = ['acl_consign', 'acl_loan', 'acl_transfer', 'acl_view', 'acl_share', 'acl_unshare', 'acl_delete'];
- if (this.props.notifications && this.props.notifications.length > 0){
+ const availableAcls = ['acl_consign', 'acl_loan', 'acl_transfer', 'acl_view', 'acl_share', 'acl_unshare', 'acl_delete'];
+ if (this.props.notifications && this.props.notifications.length) {
return (
{this.props.notifications[0].action_str}
@@ -19,15 +19,14 @@ let TableItemAclFiltered = React.createClass({
);
}
- let filteredAcls = Object.keys(this.props.content).filter((key) => {
- return availableAcls.indexOf(key) > -1 && this.props.content[key];
- });
-
- filteredAcls = filteredAcls.map((acl) => acl.split('acl_')[1]);
+ const filteredAcls = Object.keys(this.props.content)
+ .filter((key) => availableAcls.indexOf(key) > -1 && this.props.content[key])
+ .map((acl) => acl.split('acl_')[1])
+ .join('/');
return (
- {filteredAcls.join('/')}
+ {filteredAcls}
);
}