Brandon Nicholls

RESCOI-1126: Using autobind decorator

......@@ -8,5 +8,6 @@
"test": {
"plugins": ["rewire"]
}
}
},
"plugins": ["transform-decorators-legacy"]
}
......
......@@ -18,6 +18,7 @@
import styles from './style';
import React from 'react';
import { autobind } from 'core-decorators';
import DeclarationSummary from '../declaration-summary';
import {getDispositionTypeString} from '../../../../stores/config-store';
import { ROLES } from '../../../../../../coi-constants';
......@@ -27,16 +28,8 @@ import {AdminActions} from '../../../../actions/admin-actions';
import PopOver from '../../../pop-over';
import {flagIsOn} from '../../../../feature-flags';
@autobind
export default class ProjectDeclarationsSummary extends React.Component {
constructor() {
super();
this.getCommentCount = this.getCommentCount.bind(this);
this.wasRespondedTo = this.wasRespondedTo.bind(this);
this.onProjectDispositionChanged = this.onProjectDispositionChanged.bind(this);
this.onSetAllAdminRelationships = this.onSetAllAdminRelationships.bind(this);
this.onSetAllRecommendedDispositions = this.onSetAllRecommendedDispositions.bind(this);
}
onSetAllAdminRelationships(dispositionTypeCd) {
const allDeclarationIds = this.props.declarations.map(d => d.id);
AdminActions.setAllAdminRelationships([
......
......@@ -49,6 +49,7 @@
"classnames": "2.2.5",
"cookie-parser": "1.4.3",
"cookies-js": "1.2.2",
"core-decorators": "0.15.0",
"debug": "2.3.3",
"draft-js": "0.9.1",
"express": "4.14.0",
......@@ -79,6 +80,7 @@
"babel-eslint": "7.0.0",
"babel-loader": "6.2.5",
"babel-plugin-rewire": "1.0.0",
"babel-plugin-transform-decorators-legacy": "1.3.4",
"css-loader": "0.25.0",
"css-modules-require-hook": "4.0.5",
"enzyme": "2.4.1",
......