Browse Source

让模拟考试任何人都能进去

zhangyujun 3 years ago
parent
commit
c8d9b9ee5e
1 changed files with 4 additions and 3 deletions
  1. 4 3
      src/views/home/children/test/components/sujectOne.vue

+ 4 - 3
src/views/home/children/test/components/sujectOne.vue

@@ -3,14 +3,14 @@
 		<div v-for="(testObj, index) in testList" :key="index">
 			<div class="test-choose">
 				<div class="min">
-					<div class="icon-box" v-for="(item, index) in testObj.left" :key="index" @click="push(item.route)">
+					<div class="icon-box" v-for="(item, _index) in testObj.left" :key="_index" @click="push(item.route)">
 						<m-icon :type="item.icon" isSvg />
 						<span>{{ item.name }}</span>
 					</div>
 				</div>
 				<div class="max">
-					<div class="icon-box" v-for="(item, index) in testObj.center" :key="index" @click="centerClick(item, index)">
-						<m-icon :type="item.icon" isSvg />
+					<div class="icon-box" v-for="(item, _index) in testObj.center" @click="centerClick(item, index)" :key="_index" >
+						<m-icon  :type="item.icon" isSvg />
 						<span>{{ item.name }}</span>
 					</div>
 				</div>
@@ -35,6 +35,7 @@ const {
 	router: { push },
 } = new RouterBus();
 const centerClick = (item: any, index: number) => {
+	console.log(index)
 	switch (index) {
 		case 0:
 			vipClick(item, index);