wangmengwei 1 сар өмнө
parent
commit
71f0fa34f7

+ 12 - 4
src/views/project/boxlist.vue

@@ -1,7 +1,7 @@
 <template>
   <div>
     <block v-if="type=='xmgl'">
-      <div class="boxlist" v-for="ite in 5">
+      <div class="boxlist" v-for="ite in datalist">
         <div class="ltop flex ">
             <div class="check">
               <img src="@/assets/images/project/check.png"/>
@@ -104,6 +104,7 @@
 </template>
 
 <script>
+import { number } from 'echarts'
   export default{
     props: {
       info: {
@@ -113,13 +114,20 @@
       type: {
         type: String,
         default: ''
-      }
+      },
+	  datalist: {
+	    type: Number,
+	    default: null
+	  }
     },
     data() {
       return{
-
+        nghe:datalist
       }
-    }
+    },
+	created() {
+		console.log(this.nghe)
+	}
   }
 </script>
 

+ 13 - 5
src/views/project/list.vue

@@ -88,10 +88,6 @@
                 </span>
               </div>
               <!-- 列表数据 -->
-              <div class="blist">
-                <boxlist type="xmgl"></boxlist>
-              </div>
-
             </el-tab-pane>
             <el-tab-pane  name="second">
               <div slot="label" class="tab flexc">
@@ -132,6 +128,9 @@
             <el-button type="primary" plain   size="small">创建</el-button>
             <el-button type="success"  class="cbbtn" size="small">审核</el-button>
           </div>
+		  <div class="blist">
+		    <boxlist type="xmgl" :datalist="num"></boxlist>
+		  </div>
           <Pagination
             v-show="total>0"
             :total="total"
@@ -199,6 +198,7 @@ export default {
         ]
       },
 	  tableMaxHeight:380,
+	  num:5,
     value:'',
     options: [{
               value: '选项1',
@@ -233,7 +233,15 @@ export default {
       })
     },
     handleClick(){
-
+	 if(this.activeName == 'first'){
+		 this.num = 5
+	 }else if(this.activeName == 'second'){
+		 this.num = 4
+	 }else if(this.activeName == 'third'){
+		 this.num = 3
+	 }else if(this.activeName == 'fourth'){
+		 this.num = 2
+	 }
     },
     // 取消按钮
     cancel() {