zhengyiming
2025-02-20 703c46d17731d1b437509f326c050d1d36838f74
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
<template>
  <LoadingLayout>
    <AppScrollContainer>
      <GridView
        :chunkSize="3"
        :gutter="16"
        rowGap
        :tableData="[{}, {}, {}, {}]"
        class="pay-setting-list"
      >
        <template #item="{ item, index }">
          <div class="pay-setting-item">
            <div class="pay-setting-item-title-wrapper">
              <div class="pay-setting-item-title">平安银行</div>
              <FieldSwitch
                v-model="status"
                active-text="已开启"
                inactive-text="已关闭"
                :before-change="() => setStatus(row)"
              />
            </div>
            <div class="pay-setting-content">
              <div class="pay-setting-content-item">
                <div class="pay-setting-content-item-label">支付通道:</div>
                <div class="pay-setting-content-item-text">银行</div>
              </div>
              <div class="pay-setting-content-item">
                <div class="pay-setting-content-item-label">户名:</div>
                <div class="pay-setting-content-item-text">宁波创胜信息技术服务有限公司</div>
              </div>
              <div class="pay-setting-content-item">
                <div class="pay-setting-content-item-label">户号:</div>
                <div class="pay-setting-content-item-text">190384930249</div>
              </div>
            </div>
            <div class="pay-setting-btn-wrapper">
              <el-text v-if="index === 1" type="primary">已配置</el-text>
              <el-text v-else>未配置</el-text>
            </div>
          </div>
        </template>
      </GridView>
    </AppScrollContainer>
  </LoadingLayout>
</template>
 
<script setup lang="ts">
import { LoadingLayout, AppScrollContainer, FieldSwitch } from '@bole-core/components';
 
defineOptions({
  name: 'PaySetting',
});
 
const status = ref(true);
 
function setStatus(row: any) {
  return true;
}
</script>
 
<style lang="scss" scoped>
@use '@/style/common.scss' as *;
 
.pay-setting-item {
  position: relative;
  padding: 26px;
  height: 196px;
  border: 1px solid #e1e1e1;
  border-radius: 8px;
  background: #ffffff;
  box-sizing: border-box;
 
  .pay-setting-item-title-wrapper {
    display: flex;
    align-items: center;
    margin-bottom: 22px;
 
    .pay-setting-item-title {
      min-width: 0;
      font-size: 14px;
      font-weight: bold;
      color: getCssVar('text-color', 'primary');
      flex: 1;
      line-height: 19px;
      @include utils-ellipsis;
    }
 
    :deep(.el-switch) {
      height: auto;
    }
  }
 
  .pay-setting-content {
    .pay-setting-content-item {
      display: flex;
      align-items: center;
      margin-bottom: 16px;
      font-size: 14px;
      font-weight: 400;
      line-height: 20px;
 
      &:last-child {
        margin-bottom: 0;
      }
 
      .pay-setting-content-item-label {
        width: 90px;
        text-align: right;
        color: getCssVar('text-color', 'regular');
      }
 
      .pay-setting-content-item-text {
        flex: 1;
        min-width: 0;
        color: getCssVar('text-color', 'primary');
        @include utils-ellipsis;
      }
    }
  }
 
  .pay-setting-btn-wrapper {
    position: absolute;
    right: 26px;
    bottom: 26px;
  }
}
</style>