Skip to content

Commit

Permalink
bugFixes for the release
Browse files Browse the repository at this point in the history
Signed-off-by: deekshithvarma256 <deekshithvarma256@gmail.com>
  • Loading branch information
deekshithvarma256 authored and ArchanaArige committed Jun 12, 2023
1 parent c0de903 commit c21628b
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 14 deletions.
2 changes: 1 addition & 1 deletion app/passport/local-login.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export const localLoginStrategy = function(platform) {
network: reqUser.network
};

const token = await jwtSignAsync(payload, config.jwt.secret, {
const token: any = await jwtSignAsync(payload, config.jwt.secret, {
expiresIn: config.jwt.expiresIn
});
const data = {
Expand Down
2 changes: 1 addition & 1 deletion client/src/components/Lists/Chaincodes.js
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ export class Chaincodes extends Component {
defaultPageSize={5}
filterable
minRows={0}
showPagination={chaincodeList.length >= 5}
showPagination={chaincodeList?.length >= 5}
/>
<Dialog
open={dialogOpen}
Expand Down
23 changes: 11 additions & 12 deletions client/src/components/Lists/Transactions.js
Original file line number Diff line number Diff line change
Expand Up @@ -126,11 +126,11 @@ export class Transactions extends Component {
getTransaction('ChannelNotSpecified', this.props.transactionId);
this.setState({ directLinkSearchResultsFlag: true });
}
const { transactionList } = this.props;
// const { transactionList } = this.props;
const selection = {};
transactionList.forEach(element => {
selection[element.blocknum] = false;
});
// transactionList.forEach(element => {
// selection[element.blocknum] = false;
// });
const opts = [];
this.props.transactionByOrg.forEach(val => {
opts.push({ label: val.creator_msp_id, value: val.creator_msp_id });
Expand All @@ -139,22 +139,21 @@ export class Transactions extends Component {
this.handleSearch();
}

componentWillReceiveProps(nextProps) {
componentDidUpdate(prevProps,prevState) {
if (
this.state.search &&
nextProps.currentChannel !== this.props.currentChannel
this.props.currentChannel !== prevProps.currentChannel
) {
if (this.interval !== undefined) {
clearInterval(this.interval);
}
this.interval = setInterval(() => {
this.searchTransactionList(nextProps.currentChannel);
this.searchTransactionList(this.props.currentChannel);
}, 60000);
this.searchTransactionList(nextProps.currentChannel);
this.searchTransactionList(this.props.currentChannel);
}
}
componentDidUpdate(prevProps,prevState) {
if(prevState.page!=this.state.page || prevState.rowsPerPage!=this.state.rowsPerPage || this.state.searchClick){
this.setState({ searchClick: false });
this.handleSearch();
}
}
Expand Down Expand Up @@ -226,7 +225,7 @@ export class Transactions extends Component {
this.searchTransactionList();
}, 60000);
await this.searchTransactionList();
this.setState({ search: true, searchClick: false });
this.setState({ search: true });
if (this.props.transactionId) {
this.setState({ directLinkSearchResultsFlag: false });
const { getTransaction } = this.props;
Expand Down Expand Up @@ -436,7 +435,7 @@ export class Transactions extends Component {
className={classes.searchButton}
color="success"
disabled={this.state.err || (!this.state.from != !this.state.to)}
onClick={async () => {
onClick={() => {
this.setState({page:0, searchClick:true, queryFlag: true, defaultQuery: false })
}}
>
Expand Down
1 change: 1 addition & 0 deletions client/src/state/redux/tables/operations.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ const chaincodeList = channel => dispatch =>
);
} else if (resp.status === 400) {
dispatch(actions.getErroMessage(resp.error));
} else {
dispatch(actions.getChaincodeList(resp));
}
})
Expand Down
1 change: 1 addition & 0 deletions client/src/state/redux/tables/selectors.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ export const chaincodeMetaDataSelector = state =>state.tables.chaincodeMetaData.
export const transactionSelector = state => state.tables.transaction.transaction;
export const transactionListSelector = state => state.tables.transactionList.rows;
export const transactionListSearchSelector = state => state.tables.transactionListSearch.rows;
export const transactionListTotalPagesSelector = state =>state.tables.transactionList.noOfpages;
export const transactionListSearchTotalPagesSelector = state => state.tables.transactionListSearch.noOfpages;
export const transactionListSearchPageParamSelector = state => state.tables.transactionListSearch.pageParams;
export const transactionListSearchQuerySelector = state => state.tables.transactionListSearch.query;
Expand Down

0 comments on commit c21628b

Please sign in to comment.