Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@33cn/game-cashier-react

Package Overview
Dependencies
Maintainers
8
Versions
77
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@33cn/game-cashier-react - npm Package Compare versions

Comparing version 1.9.16 to 1.10.1

64

lib/components/recharge/recharge.js

@@ -13,3 +13,3 @@ import * as tslib_1 from "tslib";

import { mainnetURL } from '../../api/config';
import { signTxGroup, signTx } from '@33cn/wallet-api';
import { signTxGroup, signTx, configPrivCache } from '@33cn/wallet-api';
import { sendTransaction } from '../../api/chain33API';

@@ -202,3 +202,3 @@ import { RWStep } from '../../Cashier';

React.createElement("p", { className: "tip" }, this.props.address)),
rwState.step === RWStep.unStart ?
rwState.step !== RWStep.unStart ?
React.createElement(React.Fragment, null,

@@ -274,26 +274,30 @@ React.createElement("div", { className: "recharge-count" },

this.setState({ loading: true });
if (!(this.props.type === 'recharge')) return [3 /*break*/, 11];
if (!(this.props.type === 'recharge')) return [3 /*break*/, 12];
_a.label = 1;
case 1:
_a.trys.push([1, 9, , 10]);
_a.trys.push([1, 10, , 11]);
return [4 /*yield*/, configPrivCache(1)];
case 2:
_a.sent();
return [4 /*yield*/, toParacross(mainnetURL, +this.state.amount, false)];
case 2:
case 3:
tx1 = _a.sent();
return [4 /*yield*/, signTx(tx1, 'title', '')];
case 3:
case 4:
signedTx1 = _a.sent();
return [4 /*yield*/, rechargeParaStep1(this.props.gameNodeURL, +this.state.amount, this.props.address)];
case 4:
case 5:
tx2 = _a.sent();
return [4 /*yield*/, signTx(tx2, '', '')];
case 5:
case 6:
signedTx2 = _a.sent();
return [4 /*yield*/, rechargeParaStep2(this.props.gameNodeURL, +this.state.amount, this.props.contractAddr, this.props.contractName)];
case 6:
case 7:
tx3 = _a.sent();
return [4 /*yield*/, signTxGroup(tx3, this.props.exercerName)];
case 7:
case 8:
signedTx3 = _a.sent();
configPrivCache(-1);
return [4 /*yield*/, sendTransaction(signedTx1, mainnetURL)];
case 8:
case 9:
hash1 = _a.sent();

@@ -313,4 +317,4 @@ insertTransaction({

});
return [3 /*break*/, 10];
case 9:
return [3 /*break*/, 11];
case 10:
e_1 = _a.sent();

@@ -325,27 +329,31 @@ if (!isComponentUnmount) {

}
return [3 /*break*/, 10];
case 10: return [3 /*break*/, 20];
case 11:
_a.trys.push([11, 19, , 20]);
return [3 /*break*/, 11];
case 11: return [3 /*break*/, 22];
case 12:
_a.trys.push([12, 21, , 22]);
return [4 /*yield*/, configPrivCache(1)];
case 13:
_a.sent();
return [4 /*yield*/, withdrawParaStep1(this.props.gameNodeURL, +this.state.amount, this.props.contractAddr, this.props.contractName)];
case 12:
case 14:
tx1 = _a.sent();
return [4 /*yield*/, signTxGroup(tx1, this.props.exercerName)]; // 'user.p.game.none'
case 13:
case 15:
signedTx1 = _a.sent() // 'user.p.game.none'
;
return [4 /*yield*/, withdrawParaStep2(this.props.gameNodeURL, +this.state.amount, this.props.address)];
case 14:
case 16:
tx2 = _a.sent();
return [4 /*yield*/, signTx(tx2, '', '')];
case 15:
case 17:
signedTx2 = _a.sent();
return [4 /*yield*/, toParacross(mainnetURL, +this.state.amount, true)];
case 16:
case 18:
tx3 = _a.sent();
return [4 /*yield*/, signTx(tx3, '', '')];
case 17:
case 19:
signedTx3 = _a.sent();
configPrivCache(-1);
return [4 /*yield*/, sendTransaction(signedTx1, this.props.gameNodeURL)];
case 18:
case 20:
hash1 = _a.sent();

@@ -365,4 +373,4 @@ insertTransaction({

});
return [3 /*break*/, 20];
case 19:
return [3 /*break*/, 22];
case 21:
e_2 = _a.sent();

@@ -377,4 +385,4 @@ if (!isComponentUnmount) {

}
return [3 /*break*/, 20];
case 20: return [2 /*return*/];
return [3 /*break*/, 22];
case 22: return [2 /*return*/];
}

@@ -381,0 +389,0 @@ });

@@ -11,6 +11,6 @@ /* import './index.css';

.then(res => console.log('queryTransactionGroup', res)); */
import Vconsole from 'vconsole';
var res = new Vconsole();
console.log(res);
// import Vconsole from 'vconsole';
// const res = new Vconsole();
// console.log(res);
ReactDOM.render(React.createElement(App, null), document.getElementById('root'));
//# sourceMappingURL=index.js.map
{
"name": "@33cn/game-cashier-react",
"version": "1.9.16",
"version": "1.10.1",
"main": "lib/Cashier.js",

@@ -9,3 +9,4 @@ "publishConfig": {

"dependencies": {
"@33cn/wallet-api": "^1.3.0",
"@33cn/game-cashier-react": "^1.9.16",
"@33cn/wallet-api": "^1.3.2",
"antd": "^3.16.6",

@@ -12,0 +13,0 @@ "rc-dialog": "^7.3.0",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc