Merge branch 'al'

pull/1/head
刘释隆 1 year ago
commit e659049ff0

@ -105,7 +105,7 @@ export default defineComponent({
.replace({
name: 'Login',
query: {
redirect: route.fullPath,
// redirect: route.fullPath,
},
})
.finally(() => location.reload())

@ -590,6 +590,9 @@ const indeterminate = computed(() => {
--n-padding-top: 0px;
--n-padding-bottom: 12px;
}
.left-wrap {
border: 1px solid #cbd3de;
}
::v-deep(.n-card > .n-card-header .n-card-header__main) {
font-weight: lighter !important;
font-size: 14px;
@ -601,8 +604,8 @@ const indeterminate = computed(() => {
::v-deep(.n-button--info-type) {
background: #507afd !important;
}
.left-wrap {
border: 1px solid #cbd3de;
::v-deep(.n-button--default-type){
border: 1px solid #cad2dd !important;
}
// ::v-deep(.n-card__content){
// padding: 20px 24px 0 24px !important;

@ -90,12 +90,12 @@ function close() {
<div class="subtitle">探索更多功能</div>
</div>
</div>
<img class="item-footer" src="../../assets/images/login/footer.png" alt="" />
</div>
<n-modal v-model:show="show" :mask-closable="false">
<Login v-if="ifLogin" @close="close" @forget="ifLogin = !ifLogin" />
<Forget v-else @close="close" @forget="ifLogin = !ifLogin" />
</n-modal>
<img class="item-footer" src="../../assets/images/login/footer.png" alt="" />
</div>
</template>
@ -105,6 +105,8 @@ function close() {
background-repeat: no-repeat;
background-size: cover;
height: 56.25rem;
position: absolute;
width: 100%;
.f-c-c {
display: flex;

@ -128,15 +128,23 @@ const selectIds = ref<string[]>([]);
function onCheckAllChange(value) {
const ids: string[] = [];
for (const item of offList.value) {
if (!item.fix) {
item.checked = value;
ids.push(item.id);
}
}
selectIds.value = value ? ids : [];
console.log(offList.value,'offList')
if (value) {
offList.value.map((v) => {
if (!v.checked) {
onList.value.push(v);
}
});
} else {
onList.value = [];
}
}
function onCheckChange(checked: any, item: any) {
@ -277,6 +285,16 @@ onMounted(async () => {
console.log(offList.value, "offList.value");
console.log(useList, "useList");
});
const indeterminate = computed(() => {
let baseNum = 0;
offList.value.map((v) => {
if (v.fix) {
baseNum += 1;
}
});
return onList.value.length > 0 && offList.value.length - baseNum > onList.value.length;
});
</script>
<template>
@ -311,11 +329,12 @@ onMounted(async () => {
</template>
</n-input>
<div class="draggable-ul">
<div class="draggable-li">
<div class="draggable-li" :class="{ checkAll: indeterminate }">
<n-checkbox
v-model:checked="checkAll"
label="全部"
@update:checked="onCheckAllChange"
:indeterminate="indeterminate"
/>
</div>
<div class="content">
@ -347,7 +366,7 @@ onMounted(async () => {
:bordered="false"
>
<template #header-extra>
<span class="textbtnStyle" @click="clearDragSource"></span>
<span class="textbtnStyle" @click="clearDragSource"></span>
</template>
<div>
<n-input placeholder="搜索关键字">
@ -377,11 +396,11 @@ onMounted(async () => {
:class="{ fix: item.fix }"
class="cursor-move draggable-item"
>
<SvgIcon name="drag" size="24" />
<SvgIcon name="drag" size="14" />
<span class="ml-2">{{ item.name }}</span>
<SvgIcon
v-if="!item.fix"
size="16px"
size="16"
style="display: block; margin-left: auto; cursor: pointer"
name="clear"
@click="removeHandler(item.id)"
@ -396,7 +415,7 @@ onMounted(async () => {
<template #footer>
<div class="wrapper-footer">
<n-button type="info" @click="handleSumbit"> </n-button>
<n-button secondary style="margin-left: 15px" @click="closeModal">
<n-button secondary style="margin-left: 15px;" @click="closeModal">
取消
</n-button>
</div>
@ -417,6 +436,7 @@ onMounted(async () => {
}
&-bar {
background-color: #e8e8e8;
width: 100%;
margin-top: 20px;
}
@ -430,7 +450,9 @@ onMounted(async () => {
font-weight: bold;
position: relative;
color: #333333;
font-size: 14px;
background: #f8f8f8;
&:before {
background-color: #1980ff;
content: "";
@ -482,7 +504,7 @@ onMounted(async () => {
color: #333;
display: flex;
align-items: center;
border-bottom: 1px solid #E8E8E8;
border-bottom: 1px solid #e8e8e8;
}
.disable-check {
@ -504,5 +526,30 @@ onMounted(async () => {
::v-deep(.n-scrollbar) {
border-top: none !important;
}
::v-deep(.checkAll .n-checkbox.n-checkbox--indeterminate .n-checkbox-box) {
background: none;
border: none;
}
::v-deep(.checkAll .n-checkbox-box__border) {
border: 1px solid #e8e8e8 !important;
}
::v-deep(.checkAll .n-checkbox-icon) {
border: 3px solid #fff;
background: #1980ff;
}
::v-deep(.checkAll .n-checkbox-icon svg) {
display: none !important;
}
::v-deep(.n-card > .n-card-header .n-card-header__main) {
font-weight: lighter !important;
font-size: 14px;
color: #666666;
}
::v-deep(.n-button--info-type) {
background: #507afd !important;
}
::v-deep(.n-button--default-type){
border: 1px solid #cad2dd !important;
}
</style>

Loading…
Cancel
Save