mirror of
https://github.com/kuaifan/dootask.git
synced 2025-12-11 18:42:54 +00:00
perf: 压缩下载改名打包下载
This commit is contained in:
parent
6ffb458ffc
commit
4205b68b8c
@ -1014,7 +1014,7 @@ class FileController extends AbstractController
|
||||
}
|
||||
|
||||
/**
|
||||
* @api {get} api/file/download/zip 20. 压缩下载
|
||||
* @api {get} api/file/download/zip 20. 打包下载
|
||||
*
|
||||
* @apiDescription 需要token身份
|
||||
* @apiVersion 1.0.0
|
||||
|
||||
@ -74,6 +74,7 @@ class SystemController extends AbstractController
|
||||
'image_compress',
|
||||
'image_save_local',
|
||||
'start_home',
|
||||
'file_upload_limit',
|
||||
])) {
|
||||
unset($all[$key]);
|
||||
}
|
||||
@ -114,6 +115,7 @@ class SystemController extends AbstractController
|
||||
$setting['image_compress'] = $setting['image_compress'] ?: 'open';
|
||||
$setting['image_save_local'] = $setting['image_save_local'] ?: 'open';
|
||||
$setting['start_home'] = $setting['start_home'] ?: 'close';
|
||||
$setting['file_upload_limit'] = $setting['file_upload_limit'] ?: '';
|
||||
//
|
||||
return Base::retSuccess('success', $setting ?: json_decode('{}'));
|
||||
}
|
||||
|
||||
@ -244,9 +244,10 @@ class File extends AbstractModel
|
||||
"type" => 'more',
|
||||
"autoThumb" => false,
|
||||
"path" => $path,
|
||||
"size" => 100 * 1024
|
||||
]);
|
||||
if (Base::isError($data)) {
|
||||
return $data;
|
||||
throw new ApiException($data['msg']);
|
||||
}
|
||||
$data = $data['data'];
|
||||
//
|
||||
|
||||
@ -616,6 +616,7 @@ class WebSocketDialog extends AbstractModel
|
||||
"type" => 'more',
|
||||
"path" => $path,
|
||||
"fileName" => $fileName,
|
||||
"size" => 100 * 1024
|
||||
]);
|
||||
}
|
||||
//
|
||||
|
||||
@ -1382,7 +1382,8 @@ APP推送
|
||||
|
||||
未设置时间
|
||||
检测到所属的任务列表已被删除,该操作将会还原任务列表,你确定要还原归档吗?
|
||||
压缩下载
|
||||
你确定要下载【(*)】文件吗?
|
||||
你确定要下载(*)等(*)个文件吗?
|
||||
打包下载
|
||||
你确定要打包下载【(*)】文件吗?
|
||||
你确定要打包下载(*)等(*)个文件吗?
|
||||
此文件夹内已有共享文件夹,子文件的共享状态将被取消,是否继续?
|
||||
文件上传限制
|
||||
@ -50,8 +50,8 @@
|
||||
{{$L('剪切')}}
|
||||
</Button>
|
||||
<Button :disabled="compressedSownloadDisabled" size="small" type="info" @click="downloadZipFile(selectIds)">
|
||||
<Icon type="ios-download-outline" />
|
||||
{{$L('压缩下载')}}
|
||||
<Icon type="ios-download" />
|
||||
{{$L('打包下载')}}
|
||||
</Button>
|
||||
<Button size="small" type="error" @click="deleteFile(selectIds)">
|
||||
<Icon type="ios-trash" />
|
||||
@ -199,7 +199,7 @@
|
||||
<DropdownItem name="send" :disabled="contextMenuItem.type == 'folder'">{{$L('发送')}}</DropdownItem>
|
||||
<DropdownItem name="link" :divided="contextMenuItem.userid != userId && !contextMenuItem.share" :disabled="contextMenuItem.type == 'folder'">{{$L('链接')}}</DropdownItem>
|
||||
<DropdownItem name="download" :disabled="contextMenuItem.ext == '' || (contextMenuItem.userid != userId && contextMenuItem.permission == 0)">{{$L('下载')}}</DropdownItem>
|
||||
<DropdownItem name="downloadzip" :disabled="contextMenuItem.userid != userId && contextMenuItem.permission == 0">{{$L('压缩下载')}}</DropdownItem>
|
||||
<DropdownItem name="downloadzip" :disabled="contextMenuItem.userid != userId && contextMenuItem.permission == 0">{{$L('打包下载')}}</DropdownItem>
|
||||
|
||||
<DropdownItem name="delete" divided style="color:red">{{$L('删除')}}</DropdownItem>
|
||||
</template>
|
||||
@ -1419,9 +1419,9 @@ export default {
|
||||
const fileName = ids.length === 1 ? `【${firstFile.name}】${typeName}` : `【${firstFile.name}】等${ids.length}个${typeName}`;
|
||||
|
||||
$A.modalConfirm({
|
||||
title: '下载文件',
|
||||
content: `你确定要下载${fileName}吗?`,
|
||||
okText: '立即下载',
|
||||
title: '打包下载',
|
||||
content: `你确定要打包下载${fileName}吗?`,
|
||||
okText: '确定',
|
||||
onOk: () => {
|
||||
return new Promise((resolve, reject) => {
|
||||
this.$store.dispatch("call", {
|
||||
|
||||
@ -165,6 +165,16 @@
|
||||
</RadioGroup>
|
||||
<div class="form-tip">{{$L('仅支持网页版。')}}</div>
|
||||
</FormItem>
|
||||
<FormItem v-if="$A.isDooServer()" :label="$L('文件上传限制')" prop="fileUploadLimit">
|
||||
<div style="width: 192px;">
|
||||
<Input type="number" number v-model="formDatum.file_upload_limit" :placeholder="$L('默认不限制')">
|
||||
<template #append>
|
||||
<span>MB</span>
|
||||
</template>
|
||||
</Input>
|
||||
</div>
|
||||
<div class="form-tip">{{$L('包含消息发送文件')}}</div>
|
||||
</FormItem>
|
||||
</div>
|
||||
</div>
|
||||
</Form>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user