queryTjAccount.vue 1.98 KB
<template xmlns:el-col="http://www.w3.org/1999/html">
  <div>
    <br/>
    <el-table
      :data="queryTjAccount"
      border
      style="width: 100%"
      :header-cell-style="{background: 'deepskyblue', color: 'snow'}">
      <el-table-column
        prop="login_name"
        label="账号名称"
        min-width="2">
      </el-table-column>
      <el-table-column
        prop="password"
        label="密码"
        min-width="2">
      </el-table-column>
    </el-table>
  </div>
</template>

<script>
  export default {
    data() {
      return {
        login_name: this.$route.query.login_name,
        province_code: this.$route.query.province_code,
        city_code: this.$route.query.city_code,
        team_code: this.$route.query.team_code,
        location_code: this.$route.query.location_code,
        five_code: this.$route.query.five_code,
        queryTjAccount: []
      }
    },
    mounted() {
      this.activity()
    },
    methods: {
      activity() {
        const loading = this.$loading({
          lock: true,
          text: '加载中...',
          spinner: 'el-icon-loading',
          background: 'rgba(0, 0, 0, 0.7)'
        });
        let config = {
          headers: {
            'Content-Type': 'application/x-www-form-urlencoded'
          }
        }
        this.$http.get('/tool/queryTjAccount?'+this.$qs.stringify({
          login_name: this.login_name,
          province_code: this.province_code,
          city_code: this.city_code,
          team_code: this.team_code,
          location_code: this.location_code,
          five_code: this.five_code
        }),config).then((res)=>{
          console.log(res.data)
          this.queryTjAccount=res.data
          loading.close();
        }).catch(error=>{
          console.log(error);
          loading.close();
          this.$message({
            showClose: true,
            message: '服务器处理失败,请核对参数!',
            type: 'error'
          });
        })
      }
    }
  }
</script>