lifanagju_citu hace 1 año
padre
commit
f6d7440346
Se han modificado 1 ficheros con 3 adiciones y 2 borrados
  1. 3 2
      src/components/areaTree/recursive.vue

+ 3 - 2
src/components/areaTree/recursive.vue

@@ -2,9 +2,9 @@
   <div>
     <span class="mr-5" v-if="currentRowType > 2">不限</span>
     <span v-for="(item, index) in props.items" :key="item.id">
-      <span v-if="index < 15" class="mr-5" @click="handleClick(item)">{{ item.name }}</span>
+      <span v-if="index < num" class="mr-6" style="line-height: 32px;" @click="handleClick(item)">{{ item.name }}</span>
     </span>
-    <span v-if="props.items?.length >= 15" @click="handleClick(props.items, 'other')">其他</span>
+    <span v-if="props.items?.length >= num" @click="handleClick(props.items, 'other')">其他</span>
     <recursive v-if="children" :items="children"></recursive>
   </div>
 </template>
@@ -14,6 +14,7 @@ import recursive from './recursive'
 defineOptions({ name:'common-components-areaTree-recursive'})
 
 const props = defineProps({items: Object})
+const num = 15
 let children = ref('')
 let currentRowType = ref(0)
 if (props.items && props.items.length) {