diff --git a/app/persistence/fabric/CRUDService.js b/app/persistence/fabric/CRUDService.js index 1d1829079..0368f0b9e 100644 --- a/app/persistence/fabric/CRUDService.js +++ b/app/persistence/fabric/CRUDService.js @@ -210,7 +210,7 @@ class CRUDService { await this.sql.updateBySql( `update chaincodes set txcount =txcount+1 where channel_genesis_hash='${ transaction.channel_genesis_hash - }'` + }' and name='${transaction.chaincodename}'` ); await this.sql.updateBySql( `update channel set trans =trans+1 where channel_genesis_hash='${ diff --git a/client/test/specs/chaincode_view.js b/client/test/specs/chaincode_view.js index 7a5321317..c96778c3c 100644 --- a/client/test/specs/chaincode_view.js +++ b/client/test/specs/chaincode_view.js @@ -38,7 +38,7 @@ describe('Explorer chaincode view', () => { var ccTxCount = browser.$( '#root > div > div > div > div > div > div > div > div.rt-table > div.rt-tbody > div > div > div:nth-child(4)' ); - ccTxCount.getText().should.be.equal('5'); + ccTxCount.getText().should.be.equal('1'); var ccChName = browser.$( '#root > div > div > div > div > div > div > div > div.rt-table > div.rt-tbody > div > div > div:nth-child(2)'