ow
This commit is contained in:
1 parent
75dc6fc980
commit
808042cf72
20 files changed
+484
-510
No files matched your search
@@ -39,7 +39,7 @@
|
||||
|
||||
<template v-else-if="isVideo(record.OrderKey)">
|
||||
<div class="video-thumb">
|
||||
<img :src="record.FormattedPic.replace('.m3u8', '.png')" :title="record.OrgFileName" />
|
||||
<img :src="record.FormattedPic" :title="record.OrgFileName" />
|
||||
<div class="play-overlay">
|
||||
<PlayCircleOutlined />
|
||||
</div>
|
||||
@@ -87,7 +87,7 @@
|
||||
<FileOutlined style="color: #8c8c8c" />
|
||||
</template>
|
||||
</div>
|
||||
<div class="list-name" :title="record.OrgFileName">{{ record.OrgFileName }}</div>
|
||||
<div :title="record.OrgFileName"><span class="list-name" >{{ record.OrgFileName }}</span></div>
|
||||
<div class="list-size">{{ formatSize(record.FileSize) }}</div>
|
||||
<div class="list-date">{{ formatDate(record.CreatedDatetime) }}</div>
|
||||
</div>
|
||||
@@ -209,11 +209,7 @@ const formatDate = (date: any) => {
|
||||
"-" +
|
||||
String(d.getMonth() + 1).padStart(2, "0") +
|
||||
"-" +
|
||||
String(d.getDate()).padStart(2, "0") +
|
||||
" " +
|
||||
String(d.getHours()).padStart(2, "0") +
|
||||
":" +
|
||||
String(d.getMinutes()).padStart(2, "0")
|
||||
String(d.getDate()).padStart(2, "0")
|
||||
);
|
||||
};
|
||||
</script>
|
||||
@@ -396,10 +392,11 @@ const formatDate = (date: any) => {
|
||||
}
|
||||
|
||||
.list-name {
|
||||
flex: 1;
|
||||
display: inline-block;
|
||||
max-width: 14ch; /* 6个字符宽度,ch 按字符计算 */
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.list-size,
|
||||
|
||||
@@ -75,7 +75,7 @@
|
||||
<template v-else-if="isVideo(record.OrderKey)">
|
||||
<div class="video-thumb">
|
||||
<img
|
||||
:src="record.FormattedPic.replace('.m3u8', '.png')"
|
||||
:src="record.FormattedPic"
|
||||
:title="record.OrgFileName"
|
||||
/>
|
||||
<div class="play-overlay">
|
||||
|
||||
@@ -1,89 +1,111 @@
|
||||
<template>
|
||||
<div class="operator-station">
|
||||
<div class="operator-group main-actions">
|
||||
<a-tooltip title="新增文件夹">
|
||||
<a-button type="primary" v-if="canCreate" :icon="h(FolderAddOutlined)"
|
||||
@click="$emit('create-folder')">新增</a-button>
|
||||
</a-tooltip>
|
||||
<a-tooltip title="上传文件">
|
||||
<a-button type="primary" v-if="canCreate" :icon="h(UploadOutlined)" @click="triggerUpload">上传</a-button>
|
||||
</a-tooltip>
|
||||
</div>
|
||||
|
||||
<a-divider type="vertical" v-if="hasSelection" />
|
||||
|
||||
<div class="operator-group selection-actions" v-if="hasSelection">
|
||||
<template v-if="!isDirectorySelected && isSingleItem">
|
||||
<a-tooltip title="下载">
|
||||
<a-button type="text" :icon="h(DownloadOutlined)" :disabled="!canAmend" @click="onDownload" >下载</a-button>
|
||||
</a-tooltip>
|
||||
|
||||
<a-tooltip title="共享">
|
||||
<a-button type="text" :icon="h(ShareAltOutlined)" @click="onShare">共享</a-button>
|
||||
</a-tooltip>
|
||||
|
||||
<a-tooltip :title="publishTooltip">
|
||||
<a-button type="text" :icon="h(NotificationOutlined)" @click="onPublish" >{{ publishTooltip }}</a-button>
|
||||
</a-tooltip>
|
||||
|
||||
<a-tooltip :title="previewTooltip">
|
||||
<a-button type="text" :icon="h(UnorderedListOutlined)" @click="onViewPreview" >{{ previewTooltip }}</a-button>
|
||||
</a-tooltip>
|
||||
|
||||
<template v-if="isSingleVideo">
|
||||
<a-tooltip title="播放">
|
||||
<a-button type="text" :icon="h(PlayCircleOutlined, { style: { color: 'red' } })" @click="onPlayVideo" >播放</a-button>
|
||||
</a-tooltip>
|
||||
</template>
|
||||
|
||||
<template v-if="isSingleAudio">
|
||||
<a-tooltip v-if="selectedItem.IsPlay != 'Y'" title="播放">
|
||||
<a-button type="text" :icon="h(PlayCircleOutlined, { style: { color: 'red' } })" @click="onPlayAudio" >播放</a-button>
|
||||
</a-tooltip>
|
||||
<a-tooltip v-else-if="selectedItem.IsPause != 'Y'" title="暂停">
|
||||
<a-button type="text" :icon="h(PauseCircleOutlined)" @click="onPauseAudio" >暂停</a-button>
|
||||
</a-tooltip>
|
||||
<a-tooltip v-else title="继续">
|
||||
<a-button type="text" :icon="h(PlayCircleOutlined, { style: { color: 'red' } })" @click="onContinueAudio" >继续</a-button>
|
||||
</a-tooltip>
|
||||
</template>
|
||||
</template>
|
||||
</div>
|
||||
|
||||
<a-divider type="vertical" v-if="hasSelection" />
|
||||
|
||||
<div class="operator-group more-actions" v-if="hasSelection">
|
||||
<a-dropdown>
|
||||
<a-button>
|
||||
<a-row :wrap="false">
|
||||
<a-col flex="auto">
|
||||
<a-row>
|
||||
<a-col flex="400px">
|
||||
<a-row justify="start">
|
||||
<a-col :span="3" style="margin-left: 8px">
|
||||
<a-tooltip title="新建文件夹">
|
||||
<a-button v-if="canCreate" class="nav-btn" :icon="h(FolderAddOutlined)"
|
||||
@click="$emit('create-folder')"></a-button>
|
||||
</a-tooltip>
|
||||
</a-col>
|
||||
<a-col :span="3">
|
||||
<a-tooltip title="上传文件">
|
||||
<a-button v-if="canCreate" :icon="h(UploadOutlined)" type="primary" class="nav-btn"
|
||||
@click="triggerUpload">
|
||||
</a-button> </a-tooltip></a-col>
|
||||
<a-col :span="3" v-if="!isDirectorySelected && isSingleItem">
|
||||
<a-tooltip title="下载">
|
||||
<a-button class="nav-btn" :icon="h(DownloadOutlined)" :disabled="!canAmend"
|
||||
@click="onDownload"></a-button>
|
||||
</a-tooltip>
|
||||
</a-col>
|
||||
<a-col :span="3" v-if="!isDirectorySelected && isSingleItem">
|
||||
<a-tooltip title="共享">
|
||||
<a-button class="nav-btn" :icon="h(ShareAltOutlined)" @click="onShare"></a-button>
|
||||
</a-tooltip>
|
||||
</a-col>
|
||||
<a-col :span="3" v-if="!isDirectorySelected && isSingleItem">
|
||||
<a-tooltip :title="publishTooltip">
|
||||
<a-button class="nav-btn" :icon="h(NotificationOutlined)" @click="onPublish"></a-button>
|
||||
</a-tooltip>
|
||||
</a-col>
|
||||
<a-col :span="3" v-if="!isDirectorySelected && isSingleItem">
|
||||
<a-tooltip :title="previewTooltip">
|
||||
<a-button class="nav-btn" @click="onViewPreview"><cust-icon-font size="16"
|
||||
type="icon-qingbaojiankong" /></a-button>
|
||||
</a-tooltip>
|
||||
</a-col>
|
||||
<a-col :span="3" v-if="!isDirectorySelected && isSingleItem && isSingleVideo">
|
||||
<a-tooltip title="播放">
|
||||
<a-button class="nav-btn" @click="onPlayVideo"><cust-icon-font size="16"
|
||||
type="icon-foldervideo" /></a-button>
|
||||
</a-tooltip>
|
||||
</a-col>
|
||||
<a-col :span="3" v-if="!isDirectorySelected && isSingleItem && isSingleAudio" style="margin-left: 4px">
|
||||
<a-tooltip v-if="selectedItem.IsPlay != 'Y'" title="播放">
|
||||
<a-button class="nav-btn" :icon="h(PlayCircleOutlined, { style: { color: 'red' } })"
|
||||
@click="onPlayAudio"></a-button>
|
||||
</a-tooltip>
|
||||
<a-tooltip v-else-if="selectedItem.IsPause != 'Y'" title="暂停">
|
||||
<a-button class="nav-btn" :icon="h(PauseCircleOutlined)" @click="onPauseAudio"></a-button>
|
||||
</a-tooltip>
|
||||
<a-tooltip v-else title="继续">
|
||||
<a-button class="nav-btn" :icon="h(PlayCircleOutlined, { style: { color: 'red' } })"
|
||||
@click="onContinueAudio"></a-button>
|
||||
</a-tooltip>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-col>
|
||||
<a-col :span="8" flex="none">
|
||||
<a-dropdown >
|
||||
<a-button style="margin-right: 8px; width:100px;" class="nav-btn">
|
||||
更多
|
||||
<DownOutlined />
|
||||
</a-button>
|
||||
<template #overlay>
|
||||
<a-menu>
|
||||
<a-menu-item key="preview" v-if="isImage(selectedOrderKey) && isSingleItem" :disabled="!canAmend" @click="$emit('preview', selectedItems)">
|
||||
<a-menu v-if="isSingleItem">
|
||||
<a-menu-item key="preview" v-if="isImage(selectedOrderKey) && isSingleItem" :disabled="!canAmend"
|
||||
@click="$emit('preview', selectedItems)">
|
||||
<EyeOutlined /> 预览
|
||||
</a-menu-item>
|
||||
<a-menu-item key="rename" v-if="isSingleItem" :disabled="!canAmend" @click="$emit('rename', selectedItems)">
|
||||
<EditOutlined /> 重命名
|
||||
</a-menu-item>
|
||||
<a-menu-divider />
|
||||
<a-menu-item key="move" v-if="isSingleItem" :disabled="!canView" @click="$emit('move', selectedItems)">
|
||||
<ScissorOutlined /> 移动
|
||||
</a-menu-item>
|
||||
<a-menu-divider />
|
||||
<a-menu-item key="delete":disabled="!canDelete" @click="$emit('delete', selectedItems)">
|
||||
<a-menu-item key="delete" :disabled="!canDelete" @click="$emit('delete', selectedItems)">
|
||||
<DeleteOutlined /> 删除
|
||||
</a-menu-item>
|
||||
</a-menu>
|
||||
<a-menu v-else-if="hasSelection">
|
||||
<a-menu-item key="delete" :disabled="!canDelete" @click="$emit('delete', selectedItems)">
|
||||
<DeleteOutlined /> 删除
|
||||
</a-menu-item>
|
||||
</a-menu>
|
||||
</template>
|
||||
</a-dropdown>
|
||||
</div>
|
||||
|
||||
<div style="display: none">
|
||||
<a-upload v-if="canCreate" v-model:file-list="fileList" name="file" :before-upload="onBeforeUpload"
|
||||
:headers="headers" :show-upload-list="false" :action="uploadUrl" ref="uploadRef">
|
||||
</a-col>
|
||||
</a-row>
|
||||
<div style="display: none">
|
||||
<a-upload
|
||||
v-if="canCreate"
|
||||
v-model:file-list="fileList"
|
||||
name="file"
|
||||
:before-upload="onBeforeUpload"
|
||||
:headers="headers"
|
||||
:show-upload-list="false"
|
||||
:action="uploadUrl"
|
||||
ref="uploadRef"
|
||||
>
|
||||
</a-upload>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
@@ -230,28 +252,21 @@ const onContinueAudio = () => {
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.operator-station {
|
||||
.nav-btn {
|
||||
width: 28px;
|
||||
height: 26px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
padding: 6px 12px;
|
||||
background: #fafafa;
|
||||
border-bottom: 1px solid #e8e8e8;
|
||||
gap: 8px;
|
||||
flex-wrap: wrap;
|
||||
justify-content: center;
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
.operator-group {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 4px;
|
||||
.nav-btn:hover:not(:disabled) {
|
||||
background: #e6f4ff;
|
||||
color: #1677ff;
|
||||
}
|
||||
|
||||
.main-actions :deep(.ant-btn) {
|
||||
height: 32px;
|
||||
}
|
||||
|
||||
.selection-actions :deep(.ant-btn) {
|
||||
padding: 4px 8px;
|
||||
font-size: 16px;
|
||||
.nav-btn:disabled {
|
||||
color: #bfbfbf;
|
||||
}
|
||||
</style>
|
||||
@@ -1,53 +1,54 @@
|
||||
<template>
|
||||
<div class="operator-station">
|
||||
<div class="operator-group selection-actions" v-if="hasSelection">
|
||||
<template v-if="true">
|
||||
<a-tooltip title="下载" v-if="!isDirectorySelected && isSingleItem">
|
||||
<a-button type="text" :icon="h(DownloadOutlined)" :disabled="!canAmend"
|
||||
@click="onDownload">下载</a-button>
|
||||
</a-tooltip>
|
||||
<a-row :wrap="false">
|
||||
<a-col flex="auto">
|
||||
<a-row>
|
||||
<a-col flex="300px">
|
||||
<a-row justify="start">
|
||||
<a-col :span="3" style="margin-left: 8px">
|
||||
<a-tooltip title="还原">
|
||||
<a-button class="nav-btn" :icon="h(UndoOutlined)" style="color:green;"
|
||||
:disabled="!hasSelection" @click="$emit('restore', selectedItems)"></a-button>
|
||||
</a-tooltip>
|
||||
</a-col>
|
||||
<a-col :span="3">
|
||||
<a-tooltip title="下载">
|
||||
<a-button class="nav-btn" :icon="h(DownloadOutlined)" :disabled="!hasSelection || isDirectorySelected || !isSingleItem"
|
||||
@click="onDownload"></a-button>
|
||||
</a-tooltip>
|
||||
</a-col>
|
||||
<a-col :span="3" v-if="hasSelection">
|
||||
<a-tooltip title="删除">
|
||||
<a-button class="nav-btn" :icon="h(DeleteOutlined)" style="color:red;"
|
||||
:disabled="!canCreate" @click="$emit('delete', selectedItems)"></a-button>
|
||||
</a-tooltip>
|
||||
</a-col>
|
||||
<a-col :span="3" v-if="!isDirectorySelected && isSingleItem && isSingleVideo">
|
||||
<a-tooltip title="播放">
|
||||
<a-button class="nav-btn" @click="onPlayVideo"><cust-icon-font size="16"
|
||||
type="icon-foldervideo" /></a-button>
|
||||
</a-tooltip>
|
||||
</a-col>
|
||||
<a-col :span="3" v-if="!isDirectorySelected && isSingleItem && isSingleAudio">
|
||||
<a-tooltip v-if="selectedItem.IsPlay != 'Y'" title="播放">
|
||||
<a-button class="nav-btn" :icon="h(PlayCircleOutlined, { style: { color: 'red' } })"
|
||||
@click="onPlayAudio"></a-button>
|
||||
</a-tooltip>
|
||||
<a-tooltip v-else-if="selectedItem.IsPause != 'Y'" title="暂停">
|
||||
<a-button type="text" :icon="h(PauseCircleOutlined)" @click="onPauseAudio">暂停</a-button>
|
||||
</a-tooltip>
|
||||
<a-tooltip v-else title="继续">
|
||||
<a-button type="text" :icon="h(PlayCircleOutlined, { style: { color: 'red' } })"
|
||||
@click="onContinueAudio">继续</a-button>
|
||||
</a-tooltip>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-col>
|
||||
<a-col :span="2" flex="none">
|
||||
|
||||
<a-tooltip title="还原" >
|
||||
<a-button type="text" :icon="h(UndoOutlined)" :disabled="!canDelete"
|
||||
@click="$emit('restore', selectedItems)" >还原</a-button>
|
||||
</a-tooltip>
|
||||
|
||||
<a-tooltip title="删除">
|
||||
<a-button type="text" :icon="h(DeleteOutlined)" :disabled="!canCreate"
|
||||
@click="$emit('delete', selectedItems)">彻底删除</a-button>
|
||||
</a-tooltip>
|
||||
|
||||
<template v-if="isSingleVideo">
|
||||
<a-tooltip title="播放">
|
||||
<a-button type="text" :icon="h(PlayCircleOutlined, { style: { color: 'red' } })"
|
||||
@click="onPlayVideo">播放</a-button>
|
||||
</a-tooltip>
|
||||
</template>
|
||||
|
||||
<template v-if="isSingleAudio">
|
||||
<a-tooltip v-if="selectedItem.IsPlay != 'Y'" title="播放">
|
||||
<a-button type="text" :icon="h(PlayCircleOutlined, { style: { color: 'red' } })"
|
||||
@click="onPlayAudio">播放</a-button>
|
||||
</a-tooltip>
|
||||
<a-tooltip v-else-if="selectedItem.IsPause != 'Y'" title="暂停">
|
||||
<a-button type="text" :icon="h(PauseCircleOutlined)" @click="onPauseAudio">暂停</a-button>
|
||||
</a-tooltip>
|
||||
<a-tooltip v-else title="继续">
|
||||
<a-button type="text" :icon="h(PlayCircleOutlined, { style: { color: 'red' } })"
|
||||
@click="onContinueAudio">继续</a-button>
|
||||
</a-tooltip>
|
||||
</template>
|
||||
</template>
|
||||
</div>
|
||||
|
||||
<a-divider type="vertical" v-if="hasSelection" />
|
||||
|
||||
<div style="display: none">
|
||||
<a-upload v-if="canCreate" v-model:file-list="fileList" name="file" :before-upload="onBeforeUpload"
|
||||
:headers="headers" :show-upload-list="false" :action="uploadUrl" ref="uploadRef">
|
||||
</a-upload>
|
||||
</div>
|
||||
</div>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
@@ -196,28 +197,21 @@ const onContinueAudio = () => {
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.operator-station {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
padding: 6px 12px;
|
||||
background: #fafafa;
|
||||
border-bottom: 1px solid #e8e8e8;
|
||||
gap: 8px;
|
||||
flex-wrap: wrap;
|
||||
.nav-btn {
|
||||
width: 28px;
|
||||
height: 26px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
.operator-group {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 4px;
|
||||
.nav-btn:hover:not(:disabled) {
|
||||
background: #e6f4ff;
|
||||
color: #1677ff;
|
||||
}
|
||||
|
||||
.main-actions :deep(.ant-btn) {
|
||||
height: 32px;
|
||||
}
|
||||
|
||||
.selection-actions :deep(.ant-btn) {
|
||||
padding: 4px 8px;
|
||||
font-size: 16px;
|
||||
.nav-btn:disabled {
|
||||
color: #bfbfbf;
|
||||
}
|
||||
</style>
|
||||
@@ -1,94 +1,61 @@
|
||||
<template>
|
||||
<div class="operator-station">
|
||||
<div class="operator-group main-actions" v-if="!isDirectoryTop">
|
||||
<a-tooltip title="新增文件夹">
|
||||
<a-button
|
||||
type="primary"
|
||||
v-if="canCreate"
|
||||
:icon="h(FolderAddOutlined)"
|
||||
@click="$emit('create-folder')"
|
||||
>新增</a-button
|
||||
>
|
||||
</a-tooltip>
|
||||
</div>
|
||||
<a-row :wrap="false">
|
||||
<a-col flex="auto">
|
||||
<a-row>
|
||||
<a-col flex="300px">
|
||||
<a-row justify="start">
|
||||
<a-col :span="3" style="margin-left: 8px">
|
||||
<a-tooltip title="新建文件夹">
|
||||
<a-button class="nav-btn" v-if="canCreate" :icon="h(FolderAddOutlined)" :disabled="isDirectoryTop"
|
||||
@click="$emit('create-folder')"></a-button>
|
||||
</a-tooltip>
|
||||
</a-col>
|
||||
<a-col :span="3" v-if="!isDirectorySelected && isSingleItem">
|
||||
<a-tooltip title="下载">
|
||||
<a-button class="nav-btn" :icon="h(DownloadOutlined)"
|
||||
:disabled="!hasSelection || isDirectorySelected || !isSingleItem" @click="onDownload"></a-button>
|
||||
</a-tooltip>
|
||||
</a-col>
|
||||
<a-col :span="3" v-if="hasSelection">
|
||||
<a-tooltip title="删除">
|
||||
<a-button class="nav-btn" :icon="h(DeleteOutlined)" style="color:red;"
|
||||
@click="$emit('delete', selectedItems)"></a-button>
|
||||
</a-tooltip>
|
||||
</a-col>
|
||||
<a-col :span="3" v-if="!isDirectorySelected && isSingleItem && isSingleVideo">
|
||||
<a-tooltip title="播放">
|
||||
<a-button class="nav-btn" @click="onPlayVideo"><cust-icon-font size="16"
|
||||
type="icon-foldervideo" /></a-button>
|
||||
</a-tooltip>
|
||||
</a-col>
|
||||
<a-col :span="3" v-if="!isDirectorySelected && isSingleItem && isSingleAudio">
|
||||
<a-tooltip v-if="selectedItem.IsPlay != 'Y'" title="播放">
|
||||
<a-button class="nav-btn" :icon="h(PlayCircleOutlined, { style: { color: 'red' } })"
|
||||
@click="onPlayAudio"></a-button>
|
||||
</a-tooltip>
|
||||
<a-tooltip v-else-if="selectedItem.IsPause != 'Y'" title="暂停">
|
||||
<a-button class="nav-btn" :icon="h(PauseCircleOutlined)" @click="onPauseAudio"></a-button>
|
||||
</a-tooltip>
|
||||
<a-tooltip v-else title="继续">
|
||||
<a-button class="nav-btn" :icon="h(PlayCircleOutlined, { style: { color: 'red' } })"
|
||||
@click="onContinueAudio"></a-button>
|
||||
</a-tooltip>
|
||||
</a-col>
|
||||
<a-col :span="3" v-if="isDirectorySelected">
|
||||
<a-tooltip :title="favorite">
|
||||
<a-button style="width:100px;" class="nav-btn" :icon="h(ShareAltOutlined)"
|
||||
@click="$emit('set-share-folder')">{{ favorite }}</a-button>
|
||||
</a-tooltip>
|
||||
</a-col>
|
||||
|
||||
<a-divider type="vertical" v-if="hasSelection" />
|
||||
</a-row>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-col>
|
||||
<a-col :span="2" flex="none">
|
||||
|
||||
<div class="operator-group selection-actions" v-if="hasSelection">
|
||||
<template v-if="!isDirectorySelected && isSingleItem">
|
||||
<a-tooltip title="下载">
|
||||
<a-button
|
||||
type="text"
|
||||
:icon="h(DownloadOutlined)"
|
||||
:disabled="!canAmend"
|
||||
@click="onDownload"
|
||||
>下载</a-button
|
||||
>
|
||||
</a-tooltip>
|
||||
|
||||
<template v-if="isSingleVideo">
|
||||
<a-tooltip title="播放">
|
||||
<a-button
|
||||
type="text"
|
||||
:icon="h(PlayCircleOutlined, { style: { color: 'red' } })"
|
||||
@click="onPlayVideo"
|
||||
>播放</a-button
|
||||
>
|
||||
</a-tooltip>
|
||||
</template>
|
||||
|
||||
<template v-if="isSingleAudio">
|
||||
<a-tooltip v-if="selectedItem.IsPlay != 'Y'" title="播放">
|
||||
<a-button
|
||||
type="text"
|
||||
:icon="h(PlayCircleOutlined, { style: { color: 'red' } })"
|
||||
@click="onPlayAudio"
|
||||
>播放</a-button
|
||||
>
|
||||
</a-tooltip>
|
||||
<a-tooltip v-else-if="selectedItem.IsPause != 'Y'" title="暂停">
|
||||
<a-button
|
||||
type="text"
|
||||
:icon="h(PauseCircleOutlined)"
|
||||
@click="onPauseAudio"
|
||||
>暂停</a-button
|
||||
>
|
||||
</a-tooltip>
|
||||
<a-tooltip v-else title="继续">
|
||||
<a-button
|
||||
type="text"
|
||||
:icon="h(PlayCircleOutlined, { style: { color: 'red' } })"
|
||||
@click="onContinueAudio"
|
||||
>继续</a-button
|
||||
>
|
||||
</a-tooltip>
|
||||
</template>
|
||||
</template>
|
||||
<template v-else-if="isDirectorySelected">
|
||||
<a-tooltip :title="favorite">
|
||||
<a-button type="text" :icon="h(ShareAltOutlined)" @click="$emit('set-share-folder')"
|
||||
>{{favorite}}</a-button
|
||||
>
|
||||
</a-tooltip>
|
||||
</template>
|
||||
</div>
|
||||
|
||||
<a-divider type="vertical" v-if="hasSelection" />
|
||||
|
||||
<div style="display: none">
|
||||
<a-upload
|
||||
v-if="canCreate"
|
||||
v-model:file-list="fileList"
|
||||
name="file"
|
||||
:before-upload="onBeforeUpload"
|
||||
:headers="headers"
|
||||
:show-upload-list="false"
|
||||
:action="uploadUrl"
|
||||
ref="uploadRef"
|
||||
>
|
||||
</a-upload>
|
||||
</div>
|
||||
</div>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
></a-col>
|
||||
</a-row>
|
||||
</a-col>
|
||||
<a-col :xs="0" :sm="0" :lg="10" flex="auto">
|
||||
<a-col :xs="0" :sm="0" :lg="20" flex="auto">
|
||||
<div
|
||||
class="toolbar-center"
|
||||
style="margin-top: 5px; margin-left: 10px"
|
||||
|
||||
@@ -142,6 +142,16 @@ class DmsFileService{
|
||||
)
|
||||
};
|
||||
|
||||
async DeleteFamilyDmsFolder(data: FamilyDmsFileViewEntity) {
|
||||
return request<any>(
|
||||
{
|
||||
url: "/DmsFile/DeleteFamilyDmsFolder",
|
||||
method: "post",
|
||||
data,
|
||||
}
|
||||
)
|
||||
};
|
||||
|
||||
async CreateFamilyDmsFolder(data: FamilyDmsFileViewEntity) {
|
||||
return request<any>(
|
||||
{
|
||||
|
||||
@@ -211,7 +211,7 @@ const currentSearchCriteria = ref<DmsFileSearchCriteria>(
|
||||
|
||||
const keys = ref<DmsFileUploadDeleteLogViewDisplayData[]>([]);
|
||||
const dmsFolderModal = ref<boolean>(false);
|
||||
const dmsFolderTitle = ref<string>("新增文件夹");
|
||||
const dmsFolderTitle = ref<string>("新建文件夹");
|
||||
const dmsFolderIsRename = ref<boolean>(false);
|
||||
const dmsFolderIsMove = ref<boolean>(false);
|
||||
const entity = ref<DmsFileEntity>(new DmsFileEntity());
|
||||
@@ -1036,7 +1036,7 @@ const handleSelectPublishVideo = async () => {
|
||||
};
|
||||
|
||||
const onGoTop = () => {
|
||||
pathStack.value = [{ value: rootPath.value, displayName: "我的文件" }];
|
||||
pathStack.value = [{ value: rootPath.value, displayName: "我的云盘" }];
|
||||
onSearchByFilePath(rootPath.value);
|
||||
};
|
||||
|
||||
|
||||
@@ -1,100 +1,40 @@
|
||||
<template>
|
||||
<a-spin size="large" :spinning="loading" :tip="spinTip">
|
||||
<div class="dms-file-enquiry">
|
||||
<Toolbar
|
||||
:path-stack="pathStack"
|
||||
:root-path="rootPath"
|
||||
:loading="loading"
|
||||
@go-top="onGoTop"
|
||||
@go-back="onGoBack"
|
||||
@refresh="onReSearch"
|
||||
@search="onSearchByName"
|
||||
@breadcrumb-click="onBreadcrumbClick"
|
||||
/>
|
||||
<Toolbar :path-stack="pathStack" :root-path="rootPath" :loading="loading" @go-top="onGoTop" @go-back="onGoBack"
|
||||
@refresh="onReSearch" @search="onSearchByName" @breadcrumb-click="onBreadcrumbClick" />
|
||||
|
||||
<OperatorStation
|
||||
:selected-items="keys"
|
||||
:upload-url="uploadUrl"
|
||||
:headers="headers"
|
||||
:can-create="canCreate"
|
||||
:can-amend="canAmend"
|
||||
:can-delete="canDelete"
|
||||
:can-view="canView"
|
||||
@create-folder="onCreate"
|
||||
@before-upload="beforeUpload"
|
||||
@download="onDownloadSelected"
|
||||
@share="onShareSelected"
|
||||
@publish="onPublishSelected"
|
||||
@view-preview="onViewPreviewSelected"
|
||||
@play-video="onUrlVideoPlayItem"
|
||||
@play-audio="onPlayAudioItem"
|
||||
@pause-audio="onPauseAudio"
|
||||
@continue-audio="onContinueAudio"
|
||||
@preview="onPreviewSelected"
|
||||
@rename="onAmendSelected"
|
||||
@move="onMoveSelected"
|
||||
@delete="onDeleteSelected"
|
||||
/>
|
||||
<OperatorStation :selected-items="keys" :upload-url="uploadUrl" :headers="headers" :can-create="canCreate"
|
||||
:can-amend="canAmend" :can-delete="canDelete" :can-view="canView" @create-folder="onCreate"
|
||||
@before-upload="beforeUpload" @download="onDownloadSelected" @share="onShareSelected"
|
||||
@publish="onPublishSelected" @view-preview="onViewPreviewSelected" @play-video="onUrlVideoPlayItem"
|
||||
@play-audio="onPlayAudioItem" @pause-audio="onPauseAudio" @continue-audio="onContinueAudio"
|
||||
@preview="onPreviewSelected" @rename="onAmendSelected" @move="onMoveSelected" @delete="onDeleteSelected" />
|
||||
|
||||
<MyComputer
|
||||
:datas="datas"
|
||||
v-model:selected-keys="keys"
|
||||
@select-change="onSelectChange"
|
||||
@open-folder="onOpenFolder"
|
||||
@open-file="onOpenFile"
|
||||
@preview-image="onPreviewOrgFile"
|
||||
/>
|
||||
<MyComputer :datas="datas" v-model:selected-keys="keys" @select-change="onSelectChange"
|
||||
@open-folder="onOpenFolder" @open-file="onOpenFile" @preview-image="onPreviewOrgFile" />
|
||||
</div>
|
||||
|
||||
<a-image
|
||||
:width="1024"
|
||||
:style="{ display: 'none' }"
|
||||
:preview="{
|
||||
visible,
|
||||
onVisibleChange: setPicVisible,
|
||||
}"
|
||||
:src="imageSrc"
|
||||
/>
|
||||
<dmsFolder @on-submit="onReload"></dmsFolder>
|
||||
<a-image :width="1024" :style="{ display: 'none' }" :preview="{
|
||||
visible,
|
||||
onVisibleChange: setPicVisible,
|
||||
}" :src="imageSrc" />
|
||||
<dmsFolder @on-submit="onReload" @submit-start="loading = true" @submit-end="loading = false"></dmsFolder>
|
||||
<videoPlay></videoPlay>
|
||||
<dragModal
|
||||
v-model:open="showModalShare"
|
||||
width="60%"
|
||||
title="分享管理查询"
|
||||
:mask-closable="false"
|
||||
:fullscreen="width < 640"
|
||||
@ok="handleSelectShare"
|
||||
>
|
||||
<dragModal v-model:open="showModalShare" width="60%" title="分享管理查询" :mask-closable="false" :fullscreen="width < 640"
|
||||
@ok="handleSelectShare">
|
||||
<DmsFileShareModal ref="shareEnquiry"></DmsFileShareModal>
|
||||
</dragModal>
|
||||
<dragModal
|
||||
v-model:open="showModalPublishPhoto"
|
||||
width="60%"
|
||||
title="相册专辑查询"
|
||||
:mask-closable="false"
|
||||
:fullscreen="width < 640"
|
||||
@ok="handleSelectPublishPhoto"
|
||||
>
|
||||
<dragModal v-model:open="showModalPublishPhoto" width="60%" title="相册专辑查询" :mask-closable="false"
|
||||
:fullscreen="width < 640" @ok="handleSelectPublishPhoto">
|
||||
<PublishPhotoEnquiry ref="publishPhotoEnquiry"></PublishPhotoEnquiry>
|
||||
</dragModal>
|
||||
<dragModal
|
||||
v-model:open="showModalPublishAudio"
|
||||
width="60%"
|
||||
title="音乐专辑查询"
|
||||
:mask-closable="false"
|
||||
:fullscreen="width < 640"
|
||||
@ok="handleSelectPublishAudio"
|
||||
>
|
||||
<dragModal v-model:open="showModalPublishAudio" width="60%" title="音乐专辑查询" :mask-closable="false"
|
||||
:fullscreen="width < 640" @ok="handleSelectPublishAudio">
|
||||
<PublishAudioEnquiry ref="publishAudioEnquiry"></PublishAudioEnquiry>
|
||||
</dragModal>
|
||||
<dragModal
|
||||
v-model:open="showModalPublishVideo"
|
||||
width="60%"
|
||||
title="影视专辑查询"
|
||||
:mask-closable="false"
|
||||
:fullscreen="width < 640"
|
||||
@ok="handleSelectPublishVideo"
|
||||
>
|
||||
<dragModal v-model:open="showModalPublishVideo" width="60%" title="影视专辑查询" :mask-closable="false"
|
||||
:fullscreen="width < 640" @ok="handleSelectPublishVideo">
|
||||
<PublishVideoEnquiry ref="publishVideoEnquiry"></PublishVideoEnquiry>
|
||||
</dragModal>
|
||||
</a-spin>
|
||||
@@ -202,7 +142,7 @@ const currentSearchCriteria = ref<DmsFileSearchCriteria>(
|
||||
|
||||
const keys = ref<DmsFileUploadViewDisplayData[]>([]);
|
||||
const dmsFolderModal = ref<boolean>(false);
|
||||
const dmsFolderTitle = ref<string>("新增文件夹");
|
||||
const dmsFolderTitle = ref<string>("新建文件夹");
|
||||
const dmsFolderIsRename = ref<boolean>(false);
|
||||
const dmsFolderIsMove = ref<boolean>(false);
|
||||
const entity = ref<DmsFileEntity>(new DmsFileEntity());
|
||||
@@ -371,12 +311,12 @@ const uploadChunk = async (
|
||||
fileName,
|
||||
chunks[index - 1],
|
||||
uid +
|
||||
"-" +
|
||||
index.toString() +
|
||||
"-" +
|
||||
chunks.length.toString() +
|
||||
"." +
|
||||
fileExtension,
|
||||
"-" +
|
||||
index.toString() +
|
||||
"-" +
|
||||
chunks.length.toString() +
|
||||
"." +
|
||||
fileExtension,
|
||||
);
|
||||
|
||||
if (process.env.NODE_ENV === "development") {
|
||||
@@ -410,7 +350,7 @@ const uploadChunk = async (
|
||||
}
|
||||
};
|
||||
|
||||
const CHUNK_SIZE = 100 * 1024 * 1024;
|
||||
const CHUNK_SIZE = 1 * 1024 * 1024;
|
||||
|
||||
const splitFile = (file: any) => {
|
||||
const chunks: Blob[] = [];
|
||||
@@ -761,16 +701,24 @@ const onMove = () => {
|
||||
};
|
||||
|
||||
const onDelete = async () => {
|
||||
for (let i = 0; i < keys.value.length; i++) {
|
||||
await dmsFileService.Delete(keys.value[i].FileId);
|
||||
}
|
||||
try {
|
||||
loading.value = true;
|
||||
for (let i = 0; i < keys.value.length; i++) {
|
||||
await dmsFileService.Delete(keys.value[i].FileId);
|
||||
}
|
||||
|
||||
notification.info({
|
||||
message: "系统提示:",
|
||||
description: "记录删除成功",
|
||||
placement: "topRight",
|
||||
});
|
||||
onReload();
|
||||
notification.info({
|
||||
message: "系统提示:",
|
||||
description: "记录删除成功",
|
||||
placement: "topRight",
|
||||
});
|
||||
} catch (error) {
|
||||
|
||||
}
|
||||
finally {
|
||||
loading.value = false;
|
||||
onReload();
|
||||
}
|
||||
};
|
||||
|
||||
const setBindOptionValue = (
|
||||
@@ -1022,7 +970,7 @@ const handleSelectPublishVideo = async () => {
|
||||
};
|
||||
|
||||
const onGoTop = () => {
|
||||
pathStack.value = [{ value: rootPath.value, displayName: "我的文件" }];
|
||||
pathStack.value = [{ value: rootPath.value, displayName: "我的云盘" }];
|
||||
onSearchByFilePath(rootPath.value);
|
||||
};
|
||||
|
||||
|
||||
@@ -72,7 +72,7 @@ import {
|
||||
FolderOutlined
|
||||
} from "@ant-design/icons-vue";
|
||||
|
||||
const emit = defineEmits(['onSubmit']);
|
||||
const emit = defineEmits(['onSubmit','submit-start','submit-end']);
|
||||
|
||||
const yesNoPolicy = ref<SelectOption[]>([]);
|
||||
|
||||
@@ -81,7 +81,6 @@ onBeforeMount(async () => {
|
||||
})
|
||||
|
||||
const modal = reactive({
|
||||
loading: false,
|
||||
showModal: false,
|
||||
FilePathValue: '',
|
||||
Notice: '',
|
||||
@@ -92,7 +91,7 @@ const modal = reactive({
|
||||
const formRef = ref();
|
||||
|
||||
const dmsFolderModal = inject<boolean>("dmsFolderModal");
|
||||
const title = ref(inject<string>("dmsFolderTitle", '新增文件夹'));
|
||||
const title = ref(inject<string>("dmsFolderTitle", '新建文件夹'));
|
||||
const isRename = ref(inject<boolean>("dmsFolderIsRename", false));
|
||||
const isMove = ref(inject<boolean>("dmsFolderIsMove", false));
|
||||
const isFamilyGroup = ref(inject<boolean>("dmsFolderIsFamilyGroup", false));
|
||||
@@ -220,7 +219,8 @@ const rules: Record<string, Rule[]> = {
|
||||
|
||||
const handleSubmit = async () => {
|
||||
try {
|
||||
modal.loading = true;
|
||||
emit('submit-start')
|
||||
modal.showModal = false;
|
||||
formRef.value
|
||||
.validate()
|
||||
.then(async () => {
|
||||
@@ -245,7 +245,7 @@ const handleSubmit = async () => {
|
||||
modal.data.FilePath = modal.FilePathValue;
|
||||
await dmsFileService.CreateDmsFolder(modal.data);
|
||||
}
|
||||
|
||||
|
||||
notification.info({
|
||||
message: '系统提示:',
|
||||
description: '记录修改成功',
|
||||
@@ -258,7 +258,7 @@ const handleSubmit = async () => {
|
||||
});
|
||||
} catch (error) {
|
||||
} finally {
|
||||
modal.loading = false;
|
||||
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -1,102 +1,41 @@
|
||||
<template>
|
||||
<a-spin size="large" :spinning="loading" :tip="spinTip">
|
||||
<div class="dms-file-enquiry">
|
||||
<Toolbar
|
||||
:path-stack="pathStack"
|
||||
:root-path="rootPath"
|
||||
:loading="loading"
|
||||
@go-top="onGoTop"
|
||||
@go-back="onGoBack"
|
||||
@refresh="onReSearch"
|
||||
@search="onSearchByName"
|
||||
@breadcrumb-click="onBreadcrumbClick"
|
||||
/>
|
||||
<Toolbar :path-stack="pathStack" :root-path="rootPath" :loading="loading" @go-top="onGoTop" @go-back="onGoBack"
|
||||
@refresh="onReSearch" @search="onSearchByName" @breadcrumb-click="onBreadcrumbClick" />
|
||||
|
||||
<OperatorStationFamily
|
||||
:selected-items="keys"
|
||||
:path-stack="pathStack"
|
||||
:upload-url="uploadUrl"
|
||||
:headers="headers"
|
||||
:can-create="canCreate"
|
||||
:can-amend="canAmend"
|
||||
:can-delete="canDelete"
|
||||
:can-view="canView"
|
||||
@create-folder="onCreate"
|
||||
@set-share-folder="onShareFolder"
|
||||
@before-upload="beforeUpload"
|
||||
@download="onDownloadSelected"
|
||||
@share="onShareSelected"
|
||||
@publish="onPublishSelected"
|
||||
@view-preview="onViewPreviewSelected"
|
||||
@play-video="onUrlVideoPlayItem"
|
||||
@play-audio="onPlayAudioItem"
|
||||
@pause-audio="onPauseAudio"
|
||||
@continue-audio="onContinueAudio"
|
||||
@preview="onPreviewSelected"
|
||||
@rename="onAmendSelected"
|
||||
@move="onMoveSelected"
|
||||
@delete="onDeleteSelected"
|
||||
/>
|
||||
<OperatorStationFamily :selected-items="keys" :path-stack="pathStack" :upload-url="uploadUrl" :headers="headers"
|
||||
:can-create="canCreate" :can-amend="canAmend" :can-delete="canDelete" :can-view="canView"
|
||||
@create-folder="onCreate" @set-share-folder="onShareFolder" @before-upload="beforeUpload"
|
||||
@download="onDownloadSelected" @share="onShareSelected" @publish="onPublishSelected"
|
||||
@view-preview="onViewPreviewSelected" @play-video="onUrlVideoPlayItem" @play-audio="onPlayAudioItem"
|
||||
@pause-audio="onPauseAudio" @continue-audio="onContinueAudio" @preview="onPreviewSelected"
|
||||
@rename="onAmendSelected" @move="onMoveSelected" @delete="onDeleteSelected" />
|
||||
|
||||
<MyComputerFamily
|
||||
:datas="datas"
|
||||
v-model:selected-keys="keys"
|
||||
@select-change="onSelectChange"
|
||||
@open-folder="onOpenFolder"
|
||||
@open-file="onOpenFile"
|
||||
@preview-image="onPreviewOrgFile"
|
||||
/>
|
||||
<MyComputerFamily :datas="datas" v-model:selected-keys="keys" @select-change="onSelectChange"
|
||||
@open-folder="onOpenFolder" @open-file="onOpenFile" @preview-image="onPreviewOrgFile" />
|
||||
</div>
|
||||
|
||||
<a-image
|
||||
:width="1024"
|
||||
:style="{ display: 'none' }"
|
||||
:preview="{
|
||||
visible,
|
||||
onVisibleChange: setPicVisible,
|
||||
}"
|
||||
:src="imageSrc"
|
||||
/>
|
||||
<dmsFolder @on-submit="onReload"></dmsFolder>
|
||||
<a-image :width="1024" :style="{ display: 'none' }" :preview="{
|
||||
visible,
|
||||
onVisibleChange: setPicVisible,
|
||||
}" :src="imageSrc" />
|
||||
<dmsFolder @on-submit="onReload" @submit-start="loading = true" @submit-end="loading = false"></dmsFolder>
|
||||
<videoPlay></videoPlay>
|
||||
<dragModal
|
||||
v-model:open="showModalShare"
|
||||
width="60%"
|
||||
title="分享管理查询"
|
||||
:mask-closable="false"
|
||||
:fullscreen="width < 640"
|
||||
@ok="handleSelectShare"
|
||||
>
|
||||
<dragModal v-model:open="showModalShare" width="60%" title="分享管理查询" :mask-closable="false" :fullscreen="width < 640"
|
||||
@ok="handleSelectShare">
|
||||
<DmsFileShareModal ref="shareEnquiry"></DmsFileShareModal>
|
||||
</dragModal>
|
||||
<dragModal
|
||||
v-model:open="showModalPublishPhoto"
|
||||
width="60%"
|
||||
title="相册专辑查询"
|
||||
:mask-closable="false"
|
||||
:fullscreen="width < 640"
|
||||
@ok="handleSelectPublishPhoto"
|
||||
>
|
||||
<dragModal v-model:open="showModalPublishPhoto" width="60%" title="相册专辑查询" :mask-closable="false"
|
||||
:fullscreen="width < 640" @ok="handleSelectPublishPhoto">
|
||||
<PublishPhotoEnquiry ref="publishPhotoEnquiry"></PublishPhotoEnquiry>
|
||||
</dragModal>
|
||||
<dragModal
|
||||
v-model:open="showModalPublishAudio"
|
||||
width="60%"
|
||||
title="音乐专辑查询"
|
||||
:mask-closable="false"
|
||||
:fullscreen="width < 640"
|
||||
@ok="handleSelectPublishAudio"
|
||||
>
|
||||
<dragModal v-model:open="showModalPublishAudio" width="60%" title="音乐专辑查询" :mask-closable="false"
|
||||
:fullscreen="width < 640" @ok="handleSelectPublishAudio">
|
||||
<PublishAudioEnquiry ref="publishAudioEnquiry"></PublishAudioEnquiry>
|
||||
</dragModal>
|
||||
<dragModal
|
||||
v-model:open="showModalPublishVideo"
|
||||
width="60%"
|
||||
title="影视专辑查询"
|
||||
:mask-closable="false"
|
||||
:fullscreen="width < 640"
|
||||
@ok="handleSelectPublishVideo"
|
||||
>
|
||||
<dragModal v-model:open="showModalPublishVideo" width="60%" title="影视专辑查询" :mask-closable="false"
|
||||
:fullscreen="width < 640" @ok="handleSelectPublishVideo">
|
||||
<PublishVideoEnquiry ref="publishVideoEnquiry"></PublishVideoEnquiry>
|
||||
</dragModal>
|
||||
</a-spin>
|
||||
@@ -345,7 +284,7 @@ onMounted(async () => {
|
||||
rootPath.value = "";
|
||||
|
||||
pathStack.value = [{ value: rootPath.value, displayName: "我的云盘" }];
|
||||
|
||||
|
||||
onSearchByFilePath(rootPath.value);
|
||||
});
|
||||
|
||||
@@ -384,12 +323,12 @@ const uploadChunk = async (
|
||||
fileName,
|
||||
chunks[index - 1],
|
||||
uid +
|
||||
"-" +
|
||||
index.toString() +
|
||||
"-" +
|
||||
chunks.length.toString() +
|
||||
"." +
|
||||
fileExtension,
|
||||
"-" +
|
||||
index.toString() +
|
||||
"-" +
|
||||
chunks.length.toString() +
|
||||
"." +
|
||||
fileExtension,
|
||||
);
|
||||
|
||||
if (process.env.NODE_ENV === "development") {
|
||||
@@ -721,7 +660,8 @@ const setPicVisible = (value: boolean): void => {
|
||||
};
|
||||
|
||||
const onCreate = () => {
|
||||
dmsFolderTitle.value = "新增文件夹";
|
||||
|
||||
dmsFolderTitle.value = "新建文件夹";
|
||||
dmsFolderIsRename.value = false;
|
||||
dmsFolderIsMove.value = false;
|
||||
dmsFolderModal.value = true;
|
||||
@@ -730,17 +670,17 @@ const onCreate = () => {
|
||||
let bindOption: BindOption = bindOptions.value.filter(
|
||||
(x) => x.BindValue == FamilyDmsFileViewEntity.DB_FILE_PATH,
|
||||
)[0];
|
||||
|
||||
entity.value.FilePath = bindOption.SelectOptions.filter(
|
||||
(x) => x.BindValue == bindOption.Value,
|
||||
)[0].DisplayName;
|
||||
entity.value.OrgFileName = bindOption.Value;
|
||||
|
||||
previousFilePath.value = unref(currFilePath.value);
|
||||
currFilePath.value = bindOption.Value;
|
||||
|
||||
};
|
||||
|
||||
const onShareFolder = () => {
|
||||
|
||||
if (keys.value.length == 0) return;
|
||||
if (
|
||||
keys.value[0].FavoriteIndc == "N" &&
|
||||
@@ -753,25 +693,40 @@ const onShareFolder = () => {
|
||||
};
|
||||
|
||||
const onDeleteFamilyFolderFavorite = async (folderName: string) => {
|
||||
FamilyGroupService.DeleteFamilyFolderFavorite(folderName).then(() => {
|
||||
notification.info({
|
||||
message: "系统提示:",
|
||||
description: "分享成功移除",
|
||||
placement: "topRight",
|
||||
try {
|
||||
loading.value = true;
|
||||
await FamilyGroupService.DeleteFamilyFolderFavorite(folderName).then(async () => {
|
||||
notification.info({
|
||||
message: "系统提示:",
|
||||
description: "分享成功移除",
|
||||
placement: "topRight",
|
||||
});
|
||||
await onReload();
|
||||
});
|
||||
onReload();
|
||||
});
|
||||
} catch (error) {
|
||||
|
||||
}
|
||||
finally {
|
||||
loading.value = false;
|
||||
}
|
||||
};
|
||||
|
||||
const onInsertFamilyFolderFavorite = async (folderName: string) => {
|
||||
FamilyGroupService.InsertFamilyFolderFavorite(folderName).then(() => {
|
||||
notification.info({
|
||||
message: "系统提示:",
|
||||
description: "分享成功加入",
|
||||
placement: "topRight",
|
||||
try {
|
||||
loading.value = true;
|
||||
await FamilyGroupService.InsertFamilyFolderFavorite(folderName).then(async () => {
|
||||
notification.info({
|
||||
message: "系统提示:",
|
||||
description: "分享成功加入",
|
||||
placement: "topRight",
|
||||
});
|
||||
await onReload();
|
||||
});
|
||||
onReload();
|
||||
});
|
||||
} catch (error) {
|
||||
|
||||
} finally {
|
||||
loading.value = false;
|
||||
}
|
||||
};
|
||||
|
||||
const onAmend = () => {
|
||||
@@ -815,16 +770,28 @@ const onMove = () => {
|
||||
};
|
||||
|
||||
const onDelete = async () => {
|
||||
for (let i = 0; i < keys.value.length; i++) {
|
||||
await dmsFileService.Delete(keys.value[i].FileId);
|
||||
try {
|
||||
loading.value = true;
|
||||
|
||||
for (let i = 0; i < keys.value.length; i++) {
|
||||
await dmsFileService.DeleteFamilyDmsFolder(keys.value[i]);
|
||||
}
|
||||
|
||||
notification.info({
|
||||
message: "系统提示:",
|
||||
description: "记录删除成功",
|
||||
placement: "topRight",
|
||||
});
|
||||
|
||||
await onReload();
|
||||
|
||||
} catch (error) {
|
||||
|
||||
}
|
||||
finally {
|
||||
loading.value = false;
|
||||
}
|
||||
|
||||
notification.info({
|
||||
message: "系统提示:",
|
||||
description: "记录删除成功",
|
||||
placement: "topRight",
|
||||
});
|
||||
onReload();
|
||||
};
|
||||
|
||||
const setBindOptionValue = (
|
||||
@@ -865,11 +832,13 @@ const initBindOption = async (familyName: string) => {
|
||||
} else {
|
||||
currentFamilyName.value = rootPath.value = rps[0].BindValue;
|
||||
}
|
||||
fps = await dmsFileService.FindFamilyDmsFoldersByFamilyName(
|
||||
currentFamilyName.value,
|
||||
);
|
||||
for (const item of rps) {
|
||||
const res = await dmsFileService.FindFamilyDmsFoldersByFamilyName(
|
||||
item.BindValue,
|
||||
);
|
||||
fps.push(...res);
|
||||
}
|
||||
}
|
||||
|
||||
bindOption = ubo.getBindSelectOption(
|
||||
FamilyDmsFileViewEntity.DB_FAMILY_NAME,
|
||||
"当前群组",
|
||||
@@ -900,7 +869,6 @@ const initBindOption = async (familyName: string) => {
|
||||
|
||||
setBindOptionValue(FamilyDmsFileViewEntity.DB_FILE_PATH, "", "", [""], false);
|
||||
currFilePath.value = "";
|
||||
console.log(currFilePath.value);
|
||||
};
|
||||
|
||||
result.value.Page = pagingParams.value.page ?? 1;
|
||||
@@ -925,8 +893,8 @@ const findBySearchCriteria = async (c: DmsFileSearchCriteria) => {
|
||||
try {
|
||||
if (c.limit == 0) c.limit = pagingParams.value.pageSize;
|
||||
if (c.page == 0) c.page = pagingParams.value.page ?? 1;
|
||||
console.log("findBySearchCriteria" + currFilePath.value);
|
||||
currentFilter.value = c.Filter;
|
||||
loading.value = true;
|
||||
let data = await dmsFileService.FindFamilyBySearchCriteria(c);
|
||||
|
||||
isSearched.value = true;
|
||||
@@ -955,8 +923,10 @@ const findBySearchCriteria = async (c: DmsFileSearchCriteria) => {
|
||||
sound.value?.stop();
|
||||
}
|
||||
} catch (error) {
|
||||
|
||||
}
|
||||
finally {
|
||||
loading.value = false;
|
||||
console.log(error);
|
||||
}
|
||||
};
|
||||
|
||||
@@ -974,15 +944,28 @@ const onReSearch = async () => {
|
||||
};
|
||||
|
||||
const onReload = async () => {
|
||||
let cfp: string = currFilePath.value;
|
||||
await initBindOption("");
|
||||
let orgFn: string = currentFamilyName.value;
|
||||
let orgFp: string = currFilePath.value;
|
||||
|
||||
await initBindOption(currentFamilyName.value);
|
||||
currentFamilyName.value = orgFn;
|
||||
currFilePath.value = orgFp;
|
||||
|
||||
setBindOptionValue(
|
||||
FamilyDmsFileViewDisplayData.DB_FILE_PATH,
|
||||
cfp,
|
||||
FamilyDmsFileViewEntity.DB_FAMILY_NAME,
|
||||
currentFamilyName.value,
|
||||
"",
|
||||
[cfp],
|
||||
[currentFamilyName.value],
|
||||
false,
|
||||
);
|
||||
setBindOptionValue(
|
||||
FamilyDmsFileViewEntity.DB_FILE_PATH,
|
||||
currFilePath.value,
|
||||
"",
|
||||
[currFilePath.value],
|
||||
false,
|
||||
);
|
||||
|
||||
await findBySearchCriteria(unref(currentSearchCriteria));
|
||||
};
|
||||
|
||||
@@ -1099,7 +1082,7 @@ const handleSelectPublishVideo = async () => {
|
||||
};
|
||||
|
||||
const onGoTop = () => {
|
||||
rootPath.value='';
|
||||
rootPath.value = '';
|
||||
pathStack.value = [{ value: rootPath.value, displayName: "我的云盘" }];
|
||||
onSearchByFilePath(rootPath.value);
|
||||
};
|
||||
|
||||
@@ -279,7 +279,7 @@ const canView = ref<boolean>(false);
|
||||
const canAmend = ref<boolean>(false);
|
||||
const canDelete = ref<boolean>(false);
|
||||
const canCreate = ref<boolean>(false);
|
||||
const modalTitle = ref<string>("新增文件夹");
|
||||
const modalTitle = ref<string>("新建文件夹");
|
||||
const rootPath = ref<string>("");
|
||||
const imageSrc = ref<string>("");
|
||||
const route = useRoute();
|
||||
@@ -332,7 +332,7 @@ const currentSearchCriteria = ref<DmsFileSearchCriteria>(
|
||||
|
||||
const keys = ref<DmsFileUploadDeleteLogViewDisplayData[]>([]);
|
||||
const dmsFolderModal = ref<boolean>(false);
|
||||
const dmsFolderTitle = ref<string>("新增文件夹");
|
||||
const dmsFolderTitle = ref<string>("新建文件夹");
|
||||
const dmsFolderIsRename = ref<boolean>(false);
|
||||
const dmsFolderIsMove = ref<boolean>(false);
|
||||
const entity = ref<DmsFileEntity>(new DmsFileEntity());
|
||||
|
||||
@@ -514,7 +514,7 @@ const canView = ref<boolean>(false);
|
||||
const canAmend = ref<boolean>(false);
|
||||
const canDelete = ref<boolean>(false);
|
||||
const canCreate = ref<boolean>(false);
|
||||
const modalTitle = ref<string>("新增文件夹");
|
||||
const modalTitle = ref<string>("新建文件夹");
|
||||
const rootPath = ref<string>("");
|
||||
const imageSrc = ref<string>("");
|
||||
const route = useRoute();
|
||||
@@ -569,7 +569,7 @@ const currentSearchCriteria = ref<DmsFileSearchCriteria>(
|
||||
|
||||
const keys = ref<DmsFileUploadViewDisplayData[]>([]);
|
||||
const dmsFolderModal = ref<boolean>(false);
|
||||
const dmsFolderTitle = ref<string>("新增文件夹");
|
||||
const dmsFolderTitle = ref<string>("新建文件夹");
|
||||
const dmsFolderIsRename = ref<boolean>(false);
|
||||
const dmsFolderIsMove = ref<boolean>(false);
|
||||
const entity = ref<DmsFileEntity>(new DmsFileEntity());
|
||||
@@ -1127,7 +1127,7 @@ const setPicVisible = (value: boolean): void => {
|
||||
};
|
||||
|
||||
const onCreate = () => {
|
||||
dmsFolderTitle.value = "新增文件夹";
|
||||
dmsFolderTitle.value = "新建文件夹";
|
||||
dmsFolderIsRename.value = false;
|
||||
dmsFolderIsMove.value = false;
|
||||
dmsFolderModal.value = true;
|
||||
|
||||
@@ -419,7 +419,7 @@ const canView = ref<boolean>(false);
|
||||
const canAmend = ref<boolean>(false);
|
||||
const canDelete = ref<boolean>(false);
|
||||
const canCreate = ref<boolean>(false);
|
||||
const modalTitle = ref<string>("新增文件夹");
|
||||
const modalTitle = ref<string>("新建文件夹");
|
||||
const rootPath = ref<string>("");
|
||||
const imageSrc = ref<string>("");
|
||||
const route = useRoute();
|
||||
@@ -471,7 +471,7 @@ const currentSearchCriteria = ref<DmsFileSearchCriteria>(
|
||||
|
||||
const keys = ref<FamilyDmsFileViewDisplayData[]>([]);
|
||||
const dmsFolderModal = ref<boolean>(false);
|
||||
const dmsFolderTitle = ref<string>("新增文件夹");
|
||||
const dmsFolderTitle = ref<string>("新建文件夹");
|
||||
const dmsFolderIsRename = ref<boolean>(false);
|
||||
const dmsFolderIsMove = ref<boolean>(false);
|
||||
const entity = ref<DmsFileEntity>(new DmsFileEntity());
|
||||
@@ -931,7 +931,7 @@ const onCreate = () => {
|
||||
return;
|
||||
}
|
||||
|
||||
dmsFolderTitle.value = "新增文件夹";
|
||||
dmsFolderTitle.value = "新建文件夹";
|
||||
dmsFolderIsRename.value = false;
|
||||
dmsFolderIsMove.value = false;
|
||||
dmsFolderModal.value = true;
|
||||
|
||||
Reference in new issue
Block a user