<template>
  <el-card class="test-card">
    <div slot="header" class="clearfix test-card-header">
      <span>入驻品牌机构</span>
      <a class="pull-right" style="color: rgba(0, 118, 203, 1); cursor: pointer" @click="goToMoreAgency()">more>></a>
    </div>
    <div style="height: 96px">
      <el-row :gutter="15">
        <el-col v-for="item in residentAgencyList" :key="item.id" :span="6" style="height: 50px">
          <img :src="item.agencyPhoto" :alt="item.evaluationAgencyName" style="width: 100%;height: 100%; cursor: pointer;" @click="goToDetail(item.userId)"/>
        </el-col>
      </el-row>
    </div>
  </el-card>
</template>

<script>
  export default {
    name: "BrandCard",
    props:['residentAgencyList'],
    methods:{
        goToMoreAgency(){
            this.$router.push({
                name: 'AgencyResidentList',
            });
        },
        goToDetail(userId) {
            this.$router.push({
                name: 'AgencyDetail',
                params: {id: userId, type: 1}
            })
        },
    }
  }
</script>

<style lang="less">

</style>
