diff --git a/src/components/BallotProxyCard.jsx b/src/components/BallotProxyCard.jsx
index 1d76098..43e3191 100644
--- a/src/components/BallotProxyCard.jsx
+++ b/src/components/BallotProxyCard.jsx
@@ -209,9 +209,24 @@ export class BallotProxyCard extends React.Component {
this.getIsFinalized();
}
+ hideCard = () => {
+ let { commonStore } = this.props;
+ let hideCard = commonStore.isActiveFilter && this.isFinalized;
+ if (commonStore.searchTerm) {
+ if (commonStore.searchTerm.length == 0) return hideCard;
+ if (String(this.proposedAddress).toLowerCase().includes(commonStore.searchTerm)) return (hideCard && false);
+ if (String(this.contractType).toLowerCase().includes(commonStore.searchTerm)) return (hideCard && false);
+ if (String(this.creator).toLowerCase().includes(commonStore.searchTerm)) return (hideCard && false);
+ } else {
+ return hideCard;
+ }
+
+ return true;
+ }
+
render () {
const { commonStore, contractsStore, ballotStore } = this.props;
- let ballotClass = (commonStore.filtered && this.isFinalized) ? "ballots-i display-none" : "ballots-i";
+ let ballotClass = this.hideCard() ? "ballots-i display-none" : "ballots-i";
return (
diff --git a/src/contracts/addresses.js b/src/contracts/addresses.js
index a0a18a6..195af0c 100644
--- a/src/contracts/addresses.js
+++ b/src/contracts/addresses.js
@@ -1,9 +1,9 @@
module.exports = {
- KEYS_MANAGER_ADDRESS: '0xfc90125492e58dbfe80c0bfb6a2a759c4f703ca8',
- VOTING_TO_CHANGE_KEYS_ADDRESS: '0x49df4ec19243263e5db22da5865b4f482b8323a0',
- VOTING_TO_CHANGE_MIN_THRESHOLD: '0x8829ebe113535826e8af17ed51f83755f675789a',
- VOTING_TO_CHANGE_PROXY: '0x6b728399b41a38d4109f7af2213d4cc31ca87812',
- METADATA_ADDRESS: '0xcBB2912666c7e8023B7ec78B6842702eB26336aC',
- POA_ADDRESS: '0x8bf38d4764929064f2d4d3a56520a76ab3df415b',
- BALLOTS_STORAGE_ADDRESS: '0x0d7590c7aedf1e7e85fc9a1ee88f6f17d3ba762f'
+ KEYS_MANAGER_ADDRESS: '0x0e4a78ba651fcf2058e1326e16fc9160553ca467',
+ VOTING_TO_CHANGE_KEYS_ADDRESS: '0x534165101c5eec16c4a18102b98b8a903644e513',
+ VOTING_TO_CHANGE_MIN_THRESHOLD: '0xf7ee04d7e85ecf98ad62f96b0a40ab82de1eb0e3',
+ VOTING_TO_CHANGE_PROXY: '0x13d3c35d9947d77c677a648b9916998c4393622f',
+ METADATA_ADDRESS: '0x1ada723e24f414a72bac6a127f4b2a8d91dfec38',
+ POA_ADDRESS: '0xf472e0e43570b9afaab67089615080cf7c20018d',
+ BALLOTS_STORAGE_ADDRESS: '0x886cc61ef0ec40300378104eb547c2e86117b819'
}
\ No newline at end of file
diff --git a/src/stores/CommonStore.js b/src/stores/CommonStore.js
index 816959f..e8929b1 100644
--- a/src/stores/CommonStore.js
+++ b/src/stores/CommonStore.js
@@ -3,12 +3,12 @@ import { observable, action } from 'mobx';
class CommonStore {
@observable loading;
@observable rootPath;
- @observable filtered;
+ @observable isActiveFilter;
@observable searchTerm;
constructor() {
this.loading = false;
- this.filtered = false;
+ this.isActiveFilter = false;
this.rootPath = '/poa-dapps-voting'
}