<template>
  <div>
    <el-radio-group v-model="tabPosition" size="mini" style="margin-bottom: 30px;">
      <el-radio-button label="giftCard">储值卡记录</el-radio-button>
      <el-radio-button label="literCard">升数卡记录</el-radio-button>
    </el-radio-group>
    <div v-if="tabPosition=='giftCard'">
      <el-table ref="tables" v-loading="loading" :data="list">
        <el-table-column prop="date" label="所属油站"/>
        <el-table-column prop="date" label="变动账户"/>
        <el-table-column prop="date" label="类型"/>
        <el-table-column label="详细信息">
          <el-table-column prop="name" label="变动金额"/>
          <el-table-column prop="address" label="变动前余额"/>
          <el-table-column prop="address" label="变动后余额"/>
        </el-table-column>
        <el-table-column prop="date" label="订单号"/>
        <el-table-column prop="date" label="描述"/>
        <el-table-column prop="date" label="变动时间"/>
      </el-table>

      <pagination
        :total="total"
        :page.sync="queryParams.page"
        :limit.sync="queryParams.pageSize"
        @pagination="getList"
      />
    </div>
    <div v-else>
      <el-table ref="tables" v-loading="loading" :data="list">
        <el-table-column label="所属油站" prop="id" align="center"/>
        <el-table-column label="变动账户" align="center"/>
        <el-table-column label="类型" align="center" prop="userNo"/>
        <el-table-column label="变动升数" align="center" prop="name" />
        <el-table-column label="订单号" align="center" prop="balance"/>
        <el-table-column label="描述" align="center" prop="balance"/>
        <el-table-column label="变动时间" align="center" prop="point"/>
      </el-table>

      <pagination
        :total="total"
        :page.sync="queryParams.page"
        :limit.sync="queryParams.pageSize"
        @pagination="getList"
      />
    </div>
  </div>
</template>

<script>
export default {
  props:["pUserId"],
  data(){
    return {
      tabPosition: 'giftCard',
      userId:"",
      loading:false,
      list:[],
      total:0,
      queryParams:{
        page:1,
        pageSize:10,
      }
    }
  },
  created() {
    this.userId = this.pUserId;
  },
  methods:{
    getList(){

    }
  }
}
</script>

<style lang="scss" scoped>

</style>
