feat: 任务审批逻辑修改及图审主图展示适配

pull/169/head
刘释隆 1 year ago
parent 1304f3365d
commit acd661ffd2

32
components.d.ts vendored

@ -10,17 +10,49 @@ declare module 'vue' {
Application: typeof import('./src/components/Application/Application.vue')['default']
BasicModal: typeof import('./src/components/Modal/BasicModal.vue')['default']
DataHeader: typeof import('./src/components/DataHeader/index.vue')['default']
NAvatar: typeof import('naive-ui')['NAvatar']
NBackTop: typeof import('naive-ui')['NBackTop']
NButton: typeof import('naive-ui')['NButton']
NCard: typeof import('naive-ui')['NCard']
NCheckbox: typeof import('naive-ui')['NCheckbox']
NCollapse: typeof import('naive-ui')['NCollapse']
NCollapseItem: typeof import('naive-ui')['NCollapseItem']
NConfigProvider: typeof import('naive-ui')['NConfigProvider']
NDatePicker: typeof import('naive-ui')['NDatePicker']
NDialogProvider: typeof import('naive-ui')['NDialogProvider']
NDivider: typeof import('naive-ui')['NDivider']
NDropdown: typeof import('naive-ui')['NDropdown']
NEllipsis: typeof import('naive-ui')['NEllipsis']
NEmpty: typeof import('naive-ui')['NEmpty']
NForm: typeof import('naive-ui')['NForm']
NFormItem: typeof import('naive-ui')['NFormItem']
NGi: typeof import('naive-ui')['NGi']
NGrid: typeof import('naive-ui')['NGrid']
NGridItem: typeof import('naive-ui')['NGridItem']
NImage: typeof import('naive-ui')['NImage']
NInput: typeof import('naive-ui')['NInput']
NMessageProvider: typeof import('naive-ui')['NMessageProvider']
NModal: typeof import('naive-ui')['NModal']
NNotificationProvider: typeof import('naive-ui')['NNotificationProvider']
NotPassed: typeof import('./src/components/NotPassed.vue')['default']
NPopconfirm: typeof import('naive-ui')['NPopconfirm']
NPopover: typeof import('naive-ui')['NPopover']
NPopselect: typeof import('naive-ui')['NPopselect']
NProgress: typeof import('naive-ui')['NProgress']
NScrollbar: typeof import('naive-ui')['NScrollbar']
NSelect: typeof import('naive-ui')['NSelect']
NSlider: typeof import('naive-ui')['NSlider']
NSpace: typeof import('naive-ui')['NSpace']
NSpin: typeof import('naive-ui')['NSpin']
NSwitch: typeof import('naive-ui')['NSwitch']
NTabPane: typeof import('naive-ui')['NTabPane']
NTabs: typeof import('naive-ui')['NTabs']
NTag: typeof import('naive-ui')['NTag']
NTimeline: typeof import('naive-ui')['NTimeline']
NTimelineItem: typeof import('naive-ui')['NTimelineItem']
NTooltip: typeof import('naive-ui')['NTooltip']
NUpload: typeof import('naive-ui')['NUpload']
NUploadDragger: typeof import('naive-ui')['NUploadDragger']
Quill: typeof import('./src/components/RichEditor/Quill.vue')['default']
Robot: typeof import('./src/components/Robot/index.vue')['default']
RouterLink: typeof import('vue-router')['RouterLink']

@ -163,11 +163,12 @@ function onCheckAllChange(value) {
function onCheckChange(checked: any, item: any) {
const index = selectIds.value.indexOf(item.id);
if (index == -1 && selectIds.value.length >= 6) {
item.checked = false;
message.error("自定义任务卡片字段一共勾选数量不能超过6个");
return;
}
// TODO
// if (index == -1 && selectIds.value.length >= 6) {
// item.checked = false;
// message.error("6");
// return;
// }
item.checked = checked;
const currentIndex = offList.value.findIndex((v) => v.id == item.id);
offList.value[currentIndex].checked = checked;
@ -355,6 +356,10 @@ function queryData(value, type) {
}
}
}
const moreThanSix = computed(() => {
return selectIds.value.length >= 6;
});
</script>
<template>
@ -411,7 +416,7 @@ function queryData(value, type) {
<n-checkbox
v-model:checked="item.checked"
:label="item.name"
:disabled="item.fix"
:disabled="item.fix || (!item.checked && moreThanSix)"
@update:checked="onCheckChange($event, item)"
/>
</div>

@ -905,7 +905,7 @@ defineExpose({
.left {
flex: 0.6;
background-size: 632px 346px;
background-size: auto 346px;
background-position: center;
background-repeat: no-repeat;

Loading…
Cancel
Save