diff --git a/src/views/task/modal/CustomFieldModal.vue b/src/views/task/modal/CustomFieldModal.vue index 2a73eaf..abbb000 100644 --- a/src/views/task/modal/CustomFieldModal.vue +++ b/src/views/task/modal/CustomFieldModal.vue @@ -333,7 +333,20 @@ function queryData(value, type) { } } } +function zhidingfun(item){ +let obj = item; +let newarr= onShowList.value +// 先检查并移除对象是否已经存在于数组中 +let index = newarr.indexOf(obj); +if (index !== -1) { + newarr.splice(index, 1); +} + +// 使用 unshift 方法将对象放到数组的第一位 +newarr.unshift(obj); + onShowList.value=newarr +} const moreThanSix = computed(() => { return selectIds.value.length >= 6 }) @@ -432,7 +445,6 @@ const moreThanSix = computed(() => { :class="{ fix: item.fix }" class="cursor-move draggable-item" > - {{ item.name }} @@ -453,6 +465,20 @@ const moreThanSix = computed(() => { > {{ item.name }} +
+ + + 置顶 + +
{ color: gainsboro; } } - +.zhiding{ + display: none; +} + .draggable-item:hover { + .zhiding{ + display: block; +}} ::v-deep(.n-card.n-card--content-segmented > .n-card__content:not(:first-child)) { border: 0px; }