Przeglądaj źródła

fix: 公共组件bug修改

jcq 2 tygodni temu
rodzic
commit
720309c7c5

+ 4 - 4
src/components/JCollapse/index.vue

@@ -11,12 +11,12 @@
 					</div>
 				</div>
 			</template>
-			<div v-if="item.ips" class="">
-				<div v-if="item.ips.length && typeof item.ips[0] === 'object'">
-					<div v-for="ip in item.ips" :key="ip.id" class="m-2 float-left" style="color: #646464; font-size: 14px">{{ ip.value }}</div>
+			<div v-if="item.list" class="">
+				<div v-if="item.list.length && typeof item.list[0] === 'object'">
+					<div v-for="ip in item.list" :key="ip.id" class="m-2 float-left" style="color: #646464; font-size: 14px">{{ ip.value }}</div>
 				</div>
 				<div v-else>
-					<div v-for="ip in item.ips" :key="ip" class="m-2 float-left" style="color: #646464; font-size: 14px">{{ ip }}</div>
+					<div v-for="ip in item.list" :key="ip" class="m-2 float-left" style="color: #646464; font-size: 14px">{{ ip }}</div>
 				</div>
 			</div>
 			<slot v-else></slot>

+ 4 - 4
src/views/marketing/config/index.vue

@@ -227,17 +227,17 @@ const data = ref([
 	{
 		title: '分组1',
 		id: '1',
-		ips: ['192.168.1.1', '192.168.1.2', '192.168.1.3', '192.168.1.4'],
+		list: ['192.168.1.1', '192.168.1.2', '192.168.1.3', '192.168.1.4'],
 	},
 	{
 		title: '分组2',
 		id: '2',
-		ips: ['192.168.1.1', '192.168.1.2', '192.168.1.3', '192.168.1.4'],
+		list: ['192.168.1.1', '192.168.1.2', '192.168.1.3', '192.168.1.4'],
 	},
 	{
 		title: '分组3',
 		id: '3',
-		ips: ['192.168.1.1', '192.168.1.2', '192.168.1.3', '192.168.1.4'],
+		list: ['192.168.1.1', '192.168.1.2', '192.168.1.3', '192.168.1.4'],
 	},
 ]);
 const whiteList = ref([{ label: '站大' }, { label: '站而' }, { label: '站撒' }, { label: '站爱' }]);
@@ -274,7 +274,7 @@ onMounted(() => {
 			console.log(item);
 			return {
 				title: item.groupName,
-				ips: item.domains.map((items :any) => {
+				list: item.domains.map((items :any) => {
 					return{
 						id:items.id,
 						value:items.domain