You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

108 lines
1.9 KiB

10 months ago
  1. <template>
  2. <u-popup :show="show" @close="close" @open="open">
  3. <view class="list">
  4. <view class="item" @click.stop="select(item)" v-for="(item,index) in list" :key="index">
  5. <view class="Bank-of-deposit">
  6. <view>{{ item.title }}</view>
  7. <view class="icon">
  8. {{ item.name }}
  9. </view>
  10. </view>
  11. <view class="cart-number">
  12. {{ item.no }}
  13. </view>
  14. </view>
  15. <view class="add" @click="toBankCart()">
  16. <u-icon name="plus" size="20"></u-icon>
  17. <view class="text">
  18. {{ $t('page.bankCart.add-bank-card') }}
  19. </view>
  20. </view>
  21. </view>
  22. </u-popup>
  23. </template>
  24. <script>
  25. export default {
  26. name: "bankCartSelect",
  27. props: {
  28. show: {
  29. default: false,
  30. type: Boolean
  31. },
  32. list: {
  33. default: false,
  34. type: Array
  35. },
  36. },
  37. data() {
  38. return {
  39. };
  40. },
  41. methods: {
  42. open() {},
  43. close() {
  44. this.$emit('close')
  45. },
  46. select(item) {
  47. this.$emit('select', item)
  48. this.$emit('close')
  49. },
  50. toBankCart(){
  51. uni.navigateTo({
  52. url: '/pages/user/bankCart/editBankCart?type=1'
  53. })
  54. }
  55. }
  56. }
  57. </script>
  58. <style lang="scss" scoped>
  59. .list {
  60. height: 60vh;
  61. overflow-x: auto;
  62. margin: 10px 0;
  63. .item {
  64. background-color: #ED762F;
  65. border-radius: 10px;
  66. margin: 10px;
  67. box-sizing: border-box;
  68. color: #fff;
  69. box-shadow: 1px 1px 1px 1px #00000021;
  70. padding: 10px;
  71. .Bank-of-deposit {
  72. border-bottom: 1px solid #ffffff99;
  73. padding: 10px 20px;
  74. display: flex;
  75. justify-content: space-between;
  76. .icon {}
  77. }
  78. .cart-number {
  79. text-align: center;
  80. font-size: 40rpx;
  81. padding: 20px;
  82. }
  83. }
  84. .add {
  85. padding: 30px 20px;
  86. margin-top: 25px;
  87. background-color: #fff;
  88. color: #000;
  89. display: flex;
  90. align-items: center;
  91. border-radius: 10px;
  92. margin: 10px;
  93. box-sizing: border-box;
  94. box-shadow: 1px 1px 1px #00000021 , -1px -1px 1px #00000021;
  95. .text {
  96. padding-left: 10px;
  97. }
  98. }
  99. }
  100. </style>