feat: 完成了 新建桶; 上传文件(基本功能)

todo: 上传 rename, 上传 public 权限选择
bug: 首次加载 conns list; 上传的时候前缀过滤失败
This commit is contained in:
zhaoyupeng
2024-10-12 17:35:59 +08:00
parent 1c818daf16
commit 777253063b
28 changed files with 791 additions and 96 deletions

View File

@@ -54,11 +54,19 @@ const useStyles = makeStyles({
export function Path() {
const styles = useStyles()
const {conn_active} = useStoreConnection()
const {bucket_active} = useStoreBucket()
const {bucket_active, bucket_get, bucket_set} = useStoreBucket()
const {prefix, files_get} = useStoreFile()
async function handleClickUp() {
const dirs = prefix.split('/').filter((item => item))
if (dirs.length > 0) {
dirs.pop()
files_get(conn_active!, bucket_active!, dirs.join("/"))
return
}
bucket_get(conn_active!, false)
bucket_set(null)
}