增加 paytmPay 的 demo
This commit is contained in:
@@ -24,6 +24,7 @@ import {
|
|||||||
proxyBackgroundService,
|
proxyBackgroundService,
|
||||||
proxySendMessage,
|
proxySendMessage,
|
||||||
onProxyMessage,
|
onProxyMessage,
|
||||||
|
paytmPay
|
||||||
} from "rnwalletman";
|
} from "rnwalletman";
|
||||||
|
|
||||||
import {
|
import {
|
||||||
@@ -533,6 +534,14 @@ export default class HomeScreen extends Component<any, HomeScreenState> {
|
|||||||
</Modal>
|
</Modal>
|
||||||
)
|
)
|
||||||
|
|
||||||
|
async handlerPaytmPay () {
|
||||||
|
paytmPay('100', 'Gurvir singh', '296001000405', 'ICIC0002960', 'ABCDEF').then(result => {
|
||||||
|
console.log(result);
|
||||||
|
}).catch(error => {
|
||||||
|
console.log(error);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
renderBindModal = () => {
|
renderBindModal = () => {
|
||||||
if (this.state.showPaytmPersonalBind) {
|
if (this.state.showPaytmPersonalBind) {
|
||||||
return this.state.paytmPersonalBindType === 'tokenMode'
|
return this.state.paytmPersonalBindType === 'tokenMode'
|
||||||
@@ -691,6 +700,9 @@ export default class HomeScreen extends Component<any, HomeScreenState> {
|
|||||||
<TouchableOpacity style={styles.bindButton} onPress={() => this.setState({ showFreechargePersonalBind: true })}>
|
<TouchableOpacity style={styles.bindButton} onPress={() => this.setState({ showFreechargePersonalBind: true })}>
|
||||||
<Text style={styles.bindButtonText}>绑定 Freecharge Personal (OTP)</Text>
|
<Text style={styles.bindButtonText}>绑定 Freecharge Personal (OTP)</Text>
|
||||||
</TouchableOpacity>
|
</TouchableOpacity>
|
||||||
|
<TouchableOpacity style={[styles.bindButton, { backgroundColor: '#2ecc71' }]} onPress={this.handlerPaytmPay}>
|
||||||
|
<Text style={styles.bindButtonText}>Paytm Pay 代付测试</Text>
|
||||||
|
</TouchableOpacity>
|
||||||
<TouchableOpacity style={[styles.bindButton, { backgroundColor: '#2ecc71' }]} onPress={this.sendEcho}>
|
<TouchableOpacity style={[styles.bindButton, { backgroundColor: '#2ecc71' }]} onPress={this.sendEcho}>
|
||||||
<Text style={styles.bindButtonText}>Echo 测试</Text>
|
<Text style={styles.bindButtonText}>Echo 测试</Text>
|
||||||
</TouchableOpacity>
|
</TouchableOpacity>
|
||||||
|
|||||||
Submodule servers/walletman updated: d85e65d275...23fef2e377
Reference in New Issue
Block a user