pay-password-keyboard.vue 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. <template>
  2. <u-popup :show="showPass" round borderRadius="12" :closeOnClickOverlay='true' @close="close" mode="center">
  3. <view class="payBox dffd">
  4. <view class="title">请输入支付密码</view>
  5. <!-- <view class="bold prosecond">333学豆</view> -->
  6. <view class="bb dffs type">
  7. <image src="/static/img/pro/payxd.png" mode=""></image>
  8. <text class="fontbase textgrey">学豆支付</text>
  9. </view>
  10. <view class="payText">
  11. <u-code-input :space="0" v-model='value' @finish="finish" dot hairline focus></u-code-input>
  12. </view>
  13. <navigator url="/pages/user/mine/userInfo" class="blue">忘记密码</navigator>
  14. </view>
  15. </u-popup>
  16. </template>
  17. <script>
  18. export default {
  19. props: {
  20. money: {
  21. type: Number,
  22. default: 0 //支付钱
  23. },
  24. showPass: {
  25. type: Boolean,
  26. default: false //显示支付
  27. }
  28. },
  29. data() {
  30. return {
  31. value: '',
  32. payType: 1 //显示支付
  33. };
  34. },
  35. methods: {
  36. finish(e) {
  37. console.log('输入结束,当前值为:' + e);
  38. this.$emit('getPass', this.value); //this.value为向父组件传递的数据
  39. this.value='';
  40. },
  41. close() {
  42. console.log(1);
  43. this.$emit('close');
  44. },
  45. }
  46. };
  47. </script>
  48. <style lang="scss">
  49. .payPop {
  50. }
  51. .payBox {
  52. width: 559rpx;
  53. // min-height: 65vh;
  54. justify-content: flex-start;
  55. align-items: center;
  56. padding: 30rpx;
  57. .title {
  58. width: 100%;
  59. text-align: center;
  60. font-size: 30rpx;
  61. }
  62. .prosecond {
  63. font-size: 42rpx;
  64. margin: 30rpx 0 40rpx;
  65. }
  66. .type {
  67. width: 100%;
  68. padding: 18rpx 23rpx;
  69. image {
  70. width: 41rpx;
  71. height: 41rpx;
  72. margin-right: 16rpx;
  73. }
  74. }
  75. .payText {
  76. margin: 30rpx 0;
  77. }
  78. .blue {
  79. color: #188be2;
  80. }
  81. }
  82. </style>