feat: 优化协作管理路径
This commit is contained in:
parent
e8e2a9ab2c
commit
f82de45a03
1
web/components.d.ts
vendored
1
web/components.d.ts
vendored
@ -46,6 +46,7 @@ declare module 'vue' {
|
||||
IEpCheck: typeof import('~icons/ep/check')['default']
|
||||
IEpCirclePlus: typeof import('~icons/ep/circle-plus')['default']
|
||||
IEpClose: typeof import('~icons/ep/close')['default']
|
||||
IEpConnection: typeof import('~icons/ep/connection')['default']
|
||||
IEpCopyDocument: typeof import('~icons/ep/copy-document')['default']
|
||||
IEpDelete: typeof import('~icons/ep/delete')['default']
|
||||
IEpIphone: typeof import('~icons/ep/iphone')['default']
|
||||
|
@ -43,10 +43,13 @@
|
||||
import { computed, ref, shallowRef, onMounted, watch } from 'vue'
|
||||
import { ElMessage } from 'element-plus'
|
||||
import 'element-plus/theme-chalk/src/message.scss'
|
||||
import MemberSelect from './MemberSelect.vue'
|
||||
|
||||
import { getPermissionList, getCollaborator, saveCollaborator } from '@/management/api/space'
|
||||
import { type IMember, SurveyPermissions } from '@/management/utils/types/workSpace'
|
||||
import { CODE_MAP } from '@/management/api/base'
|
||||
|
||||
import MemberSelect from './MemberSelect.vue'
|
||||
|
||||
const emit = defineEmits(['on-close-codify', 'onFocus', 'change', 'blur'])
|
||||
const props = withDefaults(
|
||||
defineProps<{
|
@ -1,32 +0,0 @@
|
||||
<template>
|
||||
<slot name="content" :onCooper="onCooper"></slot>
|
||||
<CooperModify :modifyId="cooperId" :visible="cooperModify" @on-close-codify="onCooperClose" />
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import { ref } from 'vue'
|
||||
import 'element-plus/theme-chalk/src/message.scss'
|
||||
import CooperModify from '@/management/pages/list/components/CooperModify.vue';
|
||||
import { useRoute } from 'vue-router';
|
||||
|
||||
defineSlots<{
|
||||
content: (scope: { onCooper: () => void }) => any
|
||||
}>();
|
||||
|
||||
const route = useRoute()
|
||||
const surveyId = route.params?.id as string;
|
||||
const cooperModify = ref<boolean>(false);
|
||||
const cooperId = ref<string>('');
|
||||
|
||||
const onCooper = (): void => {
|
||||
cooperId.value = surveyId;
|
||||
cooperModify.value = true;
|
||||
};
|
||||
|
||||
const onCooperClose = (): void => {
|
||||
cooperModify.value = false;
|
||||
};
|
||||
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
|
||||
</style>
|
@ -8,14 +8,7 @@
|
||||
<NavPanel></NavPanel>
|
||||
</div>
|
||||
<div class="right-group">
|
||||
<CooperationPanel>
|
||||
<template #content="{ onCooper }">
|
||||
<div class="btn" @click="onCooper">
|
||||
<i-ep-connection class="view-icon" :size="20" />
|
||||
<span class="btn-txt">协作</span>
|
||||
</div>
|
||||
</template>
|
||||
</CooperationPanel>
|
||||
<CooperationPanel></CooperationPanel>
|
||||
<PreviewPanel></PreviewPanel>
|
||||
<HistoryPanel></HistoryPanel>
|
||||
<SavePanel></SavePanel>
|
||||
@ -35,18 +28,12 @@ import HistoryPanel from '../modules/contentModule/HistoryPanel.vue'
|
||||
import PreviewPanel from '../modules/contentModule/PreviewPanel.vue'
|
||||
import SavePanel from '../modules/contentModule/SavePanel.vue'
|
||||
import PublishPanel from '../modules/contentModule/PublishPanel.vue'
|
||||
import CooperationPanel from './CooperationPanel.vue';
|
||||
import CooperationPanel from '../modules/contentModule/CooperationPanel.vue'
|
||||
|
||||
const store = useStore()
|
||||
const title = computed(() => _get(store.state, 'edit.schema.metaData.title'))
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
@import url('@/management/styles/edit-btn.scss');
|
||||
.view-icon {
|
||||
font-size: 20px;
|
||||
height: 29px;
|
||||
line-height: 29px;
|
||||
}
|
||||
.nav {
|
||||
width: 100%;
|
||||
height: 56px;
|
||||
|
@ -0,0 +1,35 @@
|
||||
<template>
|
||||
<div class="btn" @click="onCooper">
|
||||
<i-ep-connection class="view-icon" :size="20" />
|
||||
<span class="btn-txt">协作</span>
|
||||
</div>
|
||||
<CooperModify :modifyId="cooperId" :visible="cooperModify" @on-close-codify="onCooperClose" />
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import { ref } from 'vue'
|
||||
import { useRoute } from 'vue-router'
|
||||
import 'element-plus/theme-chalk/src/message.scss'
|
||||
|
||||
import CooperModify from '@/management/components/CooperModify/ModifyDialog.vue'
|
||||
|
||||
defineSlots<{
|
||||
content: (scope: { onCooper: () => void }) => any
|
||||
}>()
|
||||
|
||||
const route = useRoute()
|
||||
const surveyId = route.params?.id as string
|
||||
const cooperModify = ref<boolean>(false)
|
||||
const cooperId = ref<string>('')
|
||||
|
||||
const onCooper = (): void => {
|
||||
cooperId.value = surveyId
|
||||
cooperModify.value = true
|
||||
}
|
||||
|
||||
const onCooperClose = (): void => {
|
||||
cooperModify.value = false
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
@import url('@/management/styles/edit-btn.scss');
|
||||
</style>
|
@ -87,12 +87,6 @@ const closedDialog = () => {
|
||||
margin-left: 75px;
|
||||
}
|
||||
|
||||
.view-icon {
|
||||
font-size: 20px;
|
||||
height: 29px;
|
||||
line-height: 29px;
|
||||
}
|
||||
|
||||
.preview-tab {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
@ -120,6 +120,7 @@ import 'moment/locale/zh-cn'
|
||||
moment.locale('zh-cn')
|
||||
|
||||
import EmptyIndex from '@/management/components/EmptyIndex.vue'
|
||||
import CooperModify from '@/management/components/CooperModify/ModifyDialog.vue'
|
||||
import { CODE_MAP } from '@/management/api/base'
|
||||
import { QOP_MAP } from '@/management/utils/constant.ts'
|
||||
import { deleteSurvey } from '@/management/api/survey'
|
||||
@ -130,7 +131,6 @@ import ToolBar from './ToolBar.vue'
|
||||
import TextSearch from './TextSearch.vue'
|
||||
import TextSelect from './TextSelect.vue'
|
||||
import TextButton from './TextButton.vue'
|
||||
import CooperModify from './CooperModify.vue'
|
||||
import { SurveyPermissions } from '@/management/utils/types/workSpace'
|
||||
|
||||
import {
|
||||
|
@ -48,10 +48,12 @@ import { useStore } from 'vuex'
|
||||
import { pick as _pick } from 'lodash-es'
|
||||
import { ElMessage } from 'element-plus'
|
||||
import 'element-plus/theme-chalk/src/message.scss'
|
||||
|
||||
import { QOP_MAP } from '@/management/utils/constant'
|
||||
import MemberSelect from './MemberSelect.vue'
|
||||
import { type IMember, type IWorkspace, UserRole } from '@/management/utils/types/workSpace'
|
||||
|
||||
import MemberSelect from '@/management/components/CooperModify/MemberSelect.vue'
|
||||
|
||||
const store = useStore()
|
||||
const emit = defineEmits(['on-close-codify', 'onFocus', 'change', 'blur'])
|
||||
const props = defineProps({
|
||||
|
@ -15,4 +15,10 @@
|
||||
.btn-txt {
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
.view-icon {
|
||||
font-size: 20px;
|
||||
height: 29px;
|
||||
line-height: 29px;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user