...
|
...
|
@@ -36,22 +36,6 @@ export default class BankCard extends Component { |
|
|
this.subscription.remove();
|
|
|
}
|
|
|
|
|
|
getCardNo(){
|
|
|
let cardNo = this.props.bankCardInfo.bankCardNo;
|
|
|
if (cardNo && cardNo.length > 11){
|
|
|
let sub = cardNo.substring(11);
|
|
|
let cardNoNew = sub.substring(0, 1) + " ";
|
|
|
for (var i = 1; i < sub.length; i++) {
|
|
|
cardNoNew += sub[i];
|
|
|
if (i%4 === 0){
|
|
|
cardNoNew += " ";
|
|
|
}
|
|
|
}
|
|
|
cardNo = cardNoNew;
|
|
|
}
|
|
|
return cardNo;
|
|
|
}
|
|
|
|
|
|
checkInfo(){
|
|
|
|
|
|
let name = this.state.name;
|
...
|
...
|
@@ -94,7 +78,6 @@ export default class BankCard extends Component { |
|
|
<TextInput
|
|
|
ref="nameInput"
|
|
|
style={[styles.wordText, {width: 200, color: '#444444'}]}
|
|
|
maxLength={4}
|
|
|
placeholder="请输入持卡人姓名"
|
|
|
placeholderTextColor='#b0b0b0'
|
|
|
underlineColorAndroid='transparent'
|
...
|
...
|
@@ -104,7 +87,7 @@ export default class BankCard extends Component { |
|
|
<View style={styles.inputView}>
|
|
|
<Text style={[styles.wordText, {width: 76, color: '#444444'}]}>身份证号</Text>
|
|
|
<TextInput
|
|
|
ref="nameInput"
|
|
|
ref="idInput"
|
|
|
style={[styles.wordText, {width: 200, color: '#444444'}]}
|
|
|
maxLength={18}
|
|
|
placeholder="请输入身份证号"
|
...
|
...
|
@@ -130,7 +113,7 @@ export default class BankCard extends Component { |
|
|
<View style={styles.inputView}>
|
|
|
<Text style={[styles.wordText, {width: 76, color: '#444444'}]}>银行卡号</Text>
|
|
|
<TextInput
|
|
|
ref="nameInput"
|
|
|
ref="cardInput"
|
|
|
style={[styles.wordText, {width: 200, color: '#444444'}]}
|
|
|
maxLength={19}
|
|
|
placeholder="请输入银行卡号"
|
...
|
...
|
@@ -187,10 +170,10 @@ export default class BankCard extends Component { |
|
|
<View style={styles.contentContainer}>
|
|
|
<Text style={[styles.bankText, {marginTop: 20, marginLeft: 20}]}>{bankCardInfo.bankName}</Text>
|
|
|
<View style={styles.infoView}>
|
|
|
<Text style={[styles.bankText, {height: 29, paddingTop: 2, fontSize: 24, textAlign: 'center'}]}>**** </Text>
|
|
|
<Text style={[styles.bankText, {height: 29, paddingTop: 2, fontSize: 24, textAlign: 'center'}]}>**** </Text>
|
|
|
<Text style={[styles.bankText, {height: 29, paddingTop: 2, fontSize: 24, textAlign: 'center'}]}>***</Text>
|
|
|
<Text style={[styles.bankText, {fontSize: 24, textAlign: 'center'}]}>{this.getCardNo()}</Text>
|
|
|
<Text style={[styles.bankText, {height: 29, paddingTop: 2, marginRight: 20, fontSize: 24, textAlign: 'center'}]}>****</Text>
|
|
|
<Text style={[styles.bankText, {height: 29, paddingTop: 2, marginRight: 20, fontSize: 24, textAlign: 'center'}]}>****</Text>
|
|
|
<Text style={[styles.bankText, {height: 29, paddingTop: 2, marginRight: 20, fontSize: 24, textAlign: 'center'}]}>****</Text>
|
|
|
<Text style={[styles.bankText, {fontSize: 24, textAlign: 'center'}]}>{bankCardInfo.bankCardNo}</Text>
|
|
|
</View>
|
|
|
<Text style={[styles.wordText, {marginTop: 20, marginLeft: 20}]}>持卡人:{bankCardInfo.name}</Text>
|
|
|
</View>
|
...
|
...
|
@@ -198,8 +181,7 @@ export default class BankCard extends Component { |
|
|
<TouchableOpacity activeOpacity={0.5} onPress={() => {
|
|
|
Linking.openURL('tel:400-889-9646')
|
|
|
}}>
|
|
|
<Text style={[styles.wordText, {color: '#D0021B', marginTop: 7}]}>400-889-9646</Text>
|
|
|
<View style={{height: 1, backgroundColor: '#D0021B', width: 89, marginTop: -4}}/>
|
|
|
<Text style={[styles.wordText, {color: '#D0021B', marginTop: 7, textDecorationLine: 'underline'}]}>400-889-9646</Text>
|
|
|
</TouchableOpacity>
|
|
|
</View>
|
|
|
: this.renderUnBind()
|
...
|
...
|
|