1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-06 01:12:03 +00:00

Merge branch '7.1' into master

This commit is contained in:
lian
2020-11-25 15:05:57 +08:00
32 changed files with 340 additions and 83 deletions

View File

@@ -25,7 +25,7 @@ const { repoID, repoName, filePath, fileName, mode, draftID, isDraft, hasDraft,
const { siteRoot, serviceUrl, seafileCollabServer } = window.app.config;
const userInfo = window.app.userInfo;
const userName = userInfo.username;
let dirPath = '/';
let dirPath = Utils.getDirName(filePath);
function getImageFileNameWithTimestamp() {
var d = Date.now();
@@ -143,7 +143,8 @@ class EditorApi {
}
getFiles() {
return seafileAPI.listDir(repoID, dirPath, { recursive: true} ).then((response) => {
const rootPath = '/';
return seafileAPI.listDir(repoID, rootPath, { recursive: true} ).then((response) => {
var files = response.data.dirent_list.map((item) => {
return {
name: item.name,