Web:Client: fix copy link room into room
This commit is contained in:
parent
c868251a53
commit
8747d65400
@ -230,7 +230,17 @@ class ContextOptionsStore {
|
||||
|
||||
onCopyLinkRoom = (item, t) => {
|
||||
const { folderUrl } = item;
|
||||
const url = combineUrl(window.location.origin, config.homepage, folderUrl);
|
||||
const { getFolderUrl } = this.filesStore;
|
||||
|
||||
const newFolderUrl = folderUrl
|
||||
? folderUrl
|
||||
: getFolderUrl(item.id, item.isRoom || item.isFolder);
|
||||
|
||||
const url = combineUrl(
|
||||
window.location.origin,
|
||||
config.homepage,
|
||||
newFolderUrl
|
||||
);
|
||||
copy(url);
|
||||
|
||||
toastr.success(t("Translations:LinkCopySuccess"));
|
||||
@ -657,6 +667,8 @@ class ContextOptionsStore {
|
||||
]
|
||||
: [];
|
||||
|
||||
console.log(item);
|
||||
|
||||
const optionsModel = [
|
||||
{
|
||||
id: "option_select",
|
||||
|
@ -1916,6 +1916,24 @@ class FilesStore {
|
||||
return this.filter.search;
|
||||
}
|
||||
|
||||
getFolderUrl = (id, isFolder) => {
|
||||
const url = getCategoryUrl(this.categoryType, id);
|
||||
|
||||
const folderUrl = isFolder
|
||||
? combineUrl(
|
||||
AppServerConfig.proxyURL,
|
||||
config.homepage,
|
||||
`${url}?folder=${id}`
|
||||
)
|
||||
: null;
|
||||
|
||||
console.log(isFolder);
|
||||
|
||||
console.log(folderUrl);
|
||||
|
||||
return folderUrl;
|
||||
};
|
||||
|
||||
get filesList() {
|
||||
const { getIcon } = this.filesSettingsStore;
|
||||
//return [...this.folders, ...this.files];
|
||||
@ -2011,15 +2029,7 @@ class FilesStore {
|
||||
|
||||
const { isRecycleBinFolder } = this.treeFoldersStore;
|
||||
|
||||
const url = getCategoryUrl(this.categoryType, id);
|
||||
|
||||
const folderUrl = isFolder
|
||||
? combineUrl(
|
||||
AppServerConfig.proxyURL,
|
||||
config.homepage,
|
||||
`${url}?folder=${id}`
|
||||
)
|
||||
: null;
|
||||
const folderUrl = this.getFolderUrl(id, isFolder);
|
||||
|
||||
const needConvert = canConvert(fileExst);
|
||||
const isEditing =
|
||||
|
Loading…
Reference in New Issue
Block a user