var tmpl=`
  <div>
    <slot name="header">
    <h3>{{title}}</h3>
    </slot>
    <div v-if="!noline" style="width:100%;border:1px solid #eee"></div>
    <el-row  :gutter="gutter" style="margin-top:5px;">
      <el-col  :xs="span" :sm="span" :md="span" :lg="span" :xl="span" v-for="item in datasrc">
          <el-card class="box-card" :style="styleFunc(item)" shadow="hover">
            <slot name="content" :item="item">slot name content placeholder</slot>
          </el-card>
      </el-col>
    </el-row>
  </div>
`
module.exports=
`{
   template:'${tmpl}',
   props:['datasrc',"cardminheight","title","gutter","margintop","xspan","noline"],
   data:function(){
     return {
       span:this.xspan?Number(this.xspan):6,
     };
   },
   mounted:function(){

   },
   methods:{
     rowclick:function(r){
       console.log(r);
       this.$emit("rowclick",r);
     },
     moreclick:function(id){
       this.$emit("moreclick",id);
     },
     styleFunc:function(item){
       return {
         "min-height":this.cardminheight,
         "border-radius":"0px",
         "border":"1px solid #eee",
         "margin-top":this.margintop,
         "text-align":"center"
       };
     },
   },
   vname:"gsb-flowlayout"
}`
