Blame view

src/components/fee/aOwnerDetailAccount.vue 2.17 KB
a42b3256   wuxw   HC小区管理系统前段vue版正在开发中
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
  <template>
    <div class="account-container">
      <el-table :data="accounts" border>
        <el-table-column prop="acctId" :label="$t('adminRoomFee.accountId')" align="center" />
        <el-table-column prop="acctName" :label="$t('adminRoomFee.accountName')" align="center" />
        <el-table-column prop="link" :label="$t('adminRoomFee.phone')" align="center" />
        <el-table-column prop="acctTypeName" :label="$t('adminRoomFee.accountType')" align="center" />
        <el-table-column prop="amount" :label="$t('adminRoomFee.accountAmount')" align="center" />
        <el-table-column prop="createTime" :label="$t('adminRoomFee.createTime')" align="center" />
        <el-table-column :label="$t('common.operation')" align="center" width="150">
          <template slot-scope="scope">
            <el-button size="mini" @click="toDetail(scope.row)">
              {{ $t('adminRoomFee.accountDetail') }}
            </el-button>
          </template>
        </el-table-column>
      </el-table>
  
      <el-pagination
        :current-page="page.current"
        :page-size="page.size"
        :total="page.total"
        layout="total, sizes, prev, pager, next, jumper"
        @size-change="handleSizeChange"
        @current-change="handleCurrentChange"
      />
    </div>
  </template>
  
  <script>
  import { queryAdminOwnerAccount } from '@/api/fee/adminRoomFeeApi'
  
  export default {
    name: 'AOwnerDetailAccount',
f6a81350   wuxw   运营 业主详情开发完成
35
  
a42b3256   wuxw   HC小区管理系统前段vue版正在开发中
36
37
38
39
40
41
42
43
44
45
46
    data() {
      return {
        accounts: [],
        page: {
          current: 1,
          size: 10,
          total: 0
        }
      }
    },
    methods: {
f6a81350   wuxw   运营 业主详情开发完成
47
48
      open(params) {
        this.ownerId = params.ownerId
a42b3256   wuxw   HC小区管理系统前段vue版正在开发中
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
        this.page.current = 1
        this.loadData()
      },
      loadData() {
        const params = {
          ownerId: this.ownerId,
          page: this.page.current,
          row: this.page.size
        }
        
        queryAdminOwnerAccount(params).then(res => {
          this.accounts = res.data
          this.page.total = res.records
        })
      },
      toDetail(account) {
        this.$router.push(`/views/account/adminAccountDetail?acctId=${account.acctId}`)
      },
      handleSizeChange(val) {
        this.page.size = val
        this.loadData()
      },
      handleCurrentChange(val) {
        this.page.current = val
        this.loadData()
      }
    }
  }
  </script>