Merge branch 'develop' into refactoring/global-colors
This commit is contained in:
commit
9a61761906
1
.github/workflows/trigger-action.yml
vendored
1
.github/workflows/trigger-action.yml
vendored
@ -6,6 +6,7 @@ on:
|
||||
branches:
|
||||
- 'hotfix/v*'
|
||||
- 'release/v*'
|
||||
- 'develop'
|
||||
|
||||
jobs:
|
||||
dispatch:
|
||||
|
@ -1,5 +1,5 @@
|
||||
{
|
||||
"DeleteOwnerRestrictionText": "Als {{productName}}-Besitzer müssen Sie den Besitz an einen anderen Benutzer übertragen, bevor Sie Ihr Konto löschen können. Bitte wählen Sie einen neuen Besitzer aus, um fortzufahren.",
|
||||
"DeleteProfileInfo": "Hinweise zum Löschen des Profils per E-Mail verschicken",
|
||||
"DeleteProfileTitle": "Dialogfeld für Löschen eines Profils"
|
||||
"DeleteProfileTitle": "Konto deaktivieren"
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
"AccountLoginType": "Typ der Kontoanmeldung",
|
||||
"AddMembers": "Mitglieder hinzufügen",
|
||||
"CreateGroup": "Gruppe erstellen",
|
||||
"DeleteSelfProfile": "Profil löschen",
|
||||
"DeleteSelfProfile": "Konto deaktivieren",
|
||||
"DisabledEmployeeStatus": "Deaktiviert",
|
||||
"DisableUserButton": "Deaktivieren",
|
||||
"EditGroup": "Gruppe bearbeiten",
|
||||
|
@ -4,11 +4,11 @@
|
||||
"ConfirmOwnerPortalSuccessMessage": "{{productName}} owner has been successfully changed. You will be redirected in 10 seconds.",
|
||||
"ConfirmOwnerPortalTitle": "Please confirm you want to change the {{productName}} owner to {{newOwner}}.",
|
||||
"CurrentNumber": "Your current mobile phone number",
|
||||
"DeleteProfileBtn": "Delete my account",
|
||||
"DeleteProfileConfirmation": "Attention! You are about to delete your account.",
|
||||
"DeleteProfileConfirmationInfo": "By clicking \"Delete my account\" you agree with our <1>Privacy policy.</1>",
|
||||
"DeleteProfileSuccessMessage": "Your account has been successfully deleted.",
|
||||
"DeleteProfileSuccessMessageInfo": "See our <1>Privacy policy</1> to learn more about deleting your account and the data associated with it.",
|
||||
"DeleteProfileBtn": "Disable my account",
|
||||
"DeleteProfileConfirmation": "Attention! You are about to disable your account.",
|
||||
"DeleteProfileConfirmationInfo": "By clicking \"Disable my account\" you agree with our <1>Privacy policy.</1>",
|
||||
"DeleteProfileSuccessMessage": "Your account is disabled",
|
||||
"DeleteProfileSuccessMessageInfo": "Your DocSpace account is successfully disabled. The DocSpace owner or admin can permanently delete your disabled account. \n\nPlease check our <1>Privacy policy</1> to learn more about deleting your account and associated data.",
|
||||
"EmailAndPasswordCopiedToClipboard": "Email and password copied to clipboard",
|
||||
"EnterAppCodeDescription": "Enter 6-digit generated code from your app. If you don't have access to your phone, use the backup codes.",
|
||||
"EnterAppCodeTitle": "Enter code from authentication app",
|
||||
|
@ -2,7 +2,9 @@
|
||||
"ActionCannotBeUndone": "The selected disabled users will be removed from {{productName}}. This action cannot be undone.",
|
||||
"CannotReassignFiles": "If you delete multiple users at once, you cannot reassign their files to other users.",
|
||||
"DeleteGroupUsersSuccessMessage": "Users have been successfully deleted.",
|
||||
"DeleteMyDocumentsUser": "All personal files and folders in Documents section of this user will be permanently deleted.",
|
||||
"DeleteMyDocumentsUser": "Personal data, all files and folders in the Documents and Trash sections of this user will be permanently deleted.",
|
||||
"DeletePersonalData": "Personal data, all personal files and folders in the Documents and Trash sections* of the selected users will be permanently deleted. Files and folders of the selected users kept in common sections* such as rooms will remain in DocSpace.",
|
||||
"DeletePersonalDataApplicable": "*Applicable for the selected users who have such files and folders.",
|
||||
"DeleteReassignDescriptionUser": "{{warningMessageMyDocuments}} Rooms created by this user and documents stored in these rooms will be reassigned automatically to an admin performing the deletion: <strong>{{userPerformedDeletion}} ({{userYou}})</strong>. Reassign data manually to choose another destination user for reassignment.",
|
||||
"DeleteUser": "Delete user",
|
||||
"DeleteUserMessage": "{{userCaption}} <strong>{{user}}</strong> will be deleted. This action cannot be undone.",
|
||||
|
@ -1,5 +1,5 @@
|
||||
{
|
||||
"DeleteOwnerRestrictionText": "Being an owner of this {{productName}}, you must transfer the ownership to another user before you can delete your account. Please choose a new owner to proceed.",
|
||||
"DeleteProfileInfo": "Send the profile deletion instructions to the email address",
|
||||
"DeleteProfileTitle": "Delete profile"
|
||||
"DeleteOwnerRestrictionText": "Being an owner of this {{productName}}, you must transfer the ownership to another user before you can disable your account. Please choose a new owner to proceed.",
|
||||
"DeleteProfileInfo": "Send the instructions for account disabling to the email address",
|
||||
"DeleteProfileTitle": "Disable account"
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
"AccountLoginType": "Account login type",
|
||||
"AddMembers": "Add members",
|
||||
"CreateGroup": "Create group",
|
||||
"DeleteSelfProfile": "Delete profile",
|
||||
"DeleteSelfProfile": "Disable account",
|
||||
"DisabledEmployeeStatus": "Disabled",
|
||||
"DisableUserButton": "Disable",
|
||||
"EditGroup": "Edit group",
|
||||
|
@ -1,5 +1,5 @@
|
||||
{
|
||||
"DeleteOwnerRestrictionText": "Como propietario de este {{productName}}, debe transferir su propiedad a otro usuario antes de poder eliminar su cuenta. Por favor, elija un nuevo propietario para proceder.",
|
||||
"DeleteProfileInfo": "Enviar las instrucciones para eliminar el perfil a la dirección de email",
|
||||
"DeleteProfileTitle": "Diálogo de eliminación de perfil"
|
||||
"DeleteProfileTitle": "Desactivar cuenta"
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
"AccountLoginType": "Tipo de inicio de sesión de la cuenta",
|
||||
"AddMembers": "Añadir miembros",
|
||||
"CreateGroup": "Crear grupo",
|
||||
"DeleteSelfProfile": "Borrar perfil",
|
||||
"DeleteSelfProfile": "Eliminar mi cuenta",
|
||||
"DisabledEmployeeStatus": "Deshabilitar",
|
||||
"DisableUserButton": "Deshabilitar",
|
||||
"EditGroup": "Editar grupo",
|
||||
|
@ -4,7 +4,7 @@
|
||||
"ConfirmOwnerPortalSuccessMessage": "Le propriétaire de {{productName}} a été changé avec succès. Dans 10 secondes, vous serez redirigé.",
|
||||
"ConfirmOwnerPortalTitle": "Veuillez confirmer le changement de propriétaire de {{productName}}. Nouveau propriétaire : {{newOwner}}.",
|
||||
"CurrentNumber": "Votre numéro de téléphone mobile actuel",
|
||||
"DeleteProfileBtn": "Supprimer mon compte",
|
||||
"DeleteProfileBtn": "Désactiver mon compte",
|
||||
"DeleteProfileConfirmation": "Attention ! Vous êtes sur le point de supprimer ce compte.",
|
||||
"DeleteProfileConfirmationInfo": "En cliquant sur \"Supprimer mon compte\", vous acceptez notre <1>politique de confidentialité.</1>",
|
||||
"DeleteProfileSuccessMessage": "Votre compte a été supprimé avec succès.",
|
||||
|
@ -1,5 +1,5 @@
|
||||
{
|
||||
"DeleteOwnerRestrictionText": "En tant que propriétaire de ce {{productName}}, vous devez transférer la propriété à un autre utilisateur avant de pouvoir supprimer votre compte. Veuillez choisir un nouveau propriétaire pour continuer.",
|
||||
"DeleteProfileInfo": "Envoyer les instructions de suppression du profil à l'adresse email",
|
||||
"DeleteProfileTitle": "Boîte de dialogue Supprimer le profil"
|
||||
"DeleteProfileTitle": "Désactiver le compte"
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
"AccountLoginType": "Type de connexion au compte",
|
||||
"AddMembers": "Ajouter des membres",
|
||||
"CreateGroup": "Créer un groupe",
|
||||
"DeleteSelfProfile": "Supprimer le profil",
|
||||
"DeleteSelfProfile": "Désactiver le compte",
|
||||
"DisabledEmployeeStatus": "Désactivé",
|
||||
"DisableUserButton": "Désactiver",
|
||||
"EditGroup": "Modifier le groupe",
|
||||
|
@ -1,5 +1,5 @@
|
||||
{
|
||||
"DeleteOwnerRestrictionText": "Essendo un proprietario di questo {{productName}}, devi trasferire la proprietà a un altro utente prima di poter eliminare il tuo account. Scegli un nuovo proprietario per procedere.",
|
||||
"DeleteProfileInfo": "Invia le istruzioni per l'eliminazione del profilo all'indirizzo email",
|
||||
"DeleteProfileTitle": "Finestra di dialogo per l'eliminazione del profilo"
|
||||
"DeleteProfileTitle": "Disattiva account"
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
"AccountLoginType": "Tipo di accesso all'account",
|
||||
"AddMembers": "Aggiungi membri",
|
||||
"CreateGroup": "Crea un gruppo",
|
||||
"DeleteSelfProfile": "Eliminare il profilo",
|
||||
"DeleteSelfProfile": "Disattiva account",
|
||||
"DisabledEmployeeStatus": "Disabilitato",
|
||||
"DisableUserButton": "Disattivare",
|
||||
"EditGroup": "Modifica il gruppo",
|
||||
|
@ -1,5 +1,5 @@
|
||||
{
|
||||
"DeleteOwnerRestrictionText": "現在、この{{productName}}の所有者になっているので、自分のアカウントを削除する前に、他のユーザーに所有権を譲渡する必要があります。新しい所有者を選択してください。",
|
||||
"DeleteProfileInfo": "プロファイル削除の手順をメールアドレスに送信します。",
|
||||
"DeleteProfileTitle": "プロファイル削除ダイアログ"
|
||||
"DeleteProfileTitle": "アカウントを無効にする"
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
"AccountLoginType": "アカウントログインの種類",
|
||||
"AddMembers": "メンバーの追加",
|
||||
"CreateGroup": "グループの作成",
|
||||
"DeleteSelfProfile": "プロファイルの削除",
|
||||
"DeleteSelfProfile": "アカウントを無効にする",
|
||||
"DisabledEmployeeStatus": "無効化",
|
||||
"DisableUserButton": "無効にする",
|
||||
"EditGroup": "グループの編集",
|
||||
|
@ -1,5 +1,5 @@
|
||||
{
|
||||
"DeleteOwnerRestrictionText": "Sendo proprietário deste {{productName}}, você deve transferir a propriedade para outro usuário antes de excluir sua conta. Escolha um novo proprietário para continuar.",
|
||||
"DeleteProfileInfo": "Enviar as instruções de exclusão de perfil para o endereço de e-mail",
|
||||
"DeleteProfileTitle": "Excluir diálogo do perfil"
|
||||
"DeleteProfileTitle": "Desativar conta"
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
"AccountLoginType": "Tipo de login da conta",
|
||||
"AddMembers": "Adicionar membros",
|
||||
"CreateGroup": "Criar grupo",
|
||||
"DeleteSelfProfile": "Excluir perfil",
|
||||
"DeleteSelfProfile": "Desativar conta",
|
||||
"DisabledEmployeeStatus": "Desabilitado",
|
||||
"DisableUserButton": "Desabilitar",
|
||||
"EditGroup": "Editar grupo",
|
||||
|
@ -1,5 +1,5 @@
|
||||
{
|
||||
"DeleteOwnerRestrictionText": "În calitate de proprietar al spațiului {{productName}} înainte de a putea șterge contul dvs, trebuie să transferați dreptul de proprietate altui utilizator. Alegeți un nou proprietar pentru a continua.",
|
||||
"DeleteProfileInfo": "Trimiteți instrucțiunile pentru ștergerea profilului la adresa e-mail",
|
||||
"DeleteProfileTitle": "Casetă de dialog Ștergere profil"
|
||||
"DeleteProfileTitle": "Dezactivare cont"
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
"AccountLoginType": "Tip de conectare la cont",
|
||||
"AddMembers": "Adăugare membru",
|
||||
"CreateGroup": "Creare grup",
|
||||
"DeleteSelfProfile": "Ștergere profil",
|
||||
"DeleteSelfProfile": "Dezactivare cont",
|
||||
"DisabledEmployeeStatus": "Dezactivat",
|
||||
"DisableUserButton": "Dezactivează",
|
||||
"EditGroup": "Modificare grup",
|
||||
|
@ -4,11 +4,11 @@
|
||||
"ConfirmOwnerPortalSuccessMessage": "Владелец {{productName}} успешно изменен. Через 10 секунд Вы будете перенаправлены.",
|
||||
"ConfirmOwnerPortalTitle": "Пожалуйста, подтвердите, что Вы хотите изменить владельца {{productName}} на {{newOwner}}.",
|
||||
"CurrentNumber": "Ваш текущий номер мобильного телефона",
|
||||
"DeleteProfileBtn": "Удалить мой аккаунт",
|
||||
"DeleteProfileConfirmation": "Внимание! Вы собираетесь удалить свою учетную запись.",
|
||||
"DeleteProfileConfirmationInfo": "Нажимая \"Удалить мою учетную запись\", вы соглашаетесь с нашей <1>Политикой конфиденциальности.</1>",
|
||||
"DeleteProfileSuccessMessage": "Ваша учетная запись была успешно удалена.",
|
||||
"DeleteProfileSuccessMessageInfo": "Ознакомьтесь с нашей <1>Политикой конфиденциальности</1>, чтобы узнать больше об удалении вашей учетной записи и связанных с ней данных.",
|
||||
"DeleteProfileBtn": "Отключить мою учетную запись",
|
||||
"DeleteProfileConfirmation": "Внимание! Вы собираетесь отключить свою учетную запись.",
|
||||
"DeleteProfileConfirmationInfo": "Нажимая \"Отключить мою учетную запись\", вы соглашаетесь с нашей <1>Политикой конфиденциальности.</1>",
|
||||
"DeleteProfileSuccessMessage": "Ваша учетная запись была успешно отключена.",
|
||||
"DeleteProfileSuccessMessageInfo": " Ваша учетная запись DocSpace успешно отключена. Владелец или администратор DocSpace могут окончательно удалить вашу отключенную учетную запись. \n\nОзнакомьтесь с нашей <1>Политикой конфиденциальности</1>, чтобы узнать больше об удалении вашей учетной записи и связанных с ней данных.",
|
||||
"EmailAndPasswordCopiedToClipboard": "Email и пароль скопированы",
|
||||
"EnterAppCodeDescription": "Введите 6-значный код, сгенерированный приложением. Если у вас нет доступа к телефону, используйте резервные коды.",
|
||||
"EnterAppCodeTitle": "Введите код из приложения для аутентификации",
|
||||
|
@ -2,7 +2,9 @@
|
||||
"ActionCannotBeUndone": "Выбранные отключенные пользователи будут удалены из {{productName}}. Это действие необратимо.",
|
||||
"CannotReassignFiles": "Если вы удалите нескольких пользователей одновременно, вы не сможете переназначить их файлы другим пользователям.",
|
||||
"DeleteGroupUsersSuccessMessage": "Пользователи были успешно удалены.",
|
||||
"DeleteMyDocumentsUser": "Все личные файлы и папки этого пользователя в разделе Документы будут окончательно удалены.",
|
||||
"DeleteMyDocumentsUser": "Все личные файлы и папки этого пользователя в разделах Документы и Корзина будут окончательно удалены.",
|
||||
"DeletePersonalData": "Личные данные, все личные файлы и папки выбранных пользователей в разделах* Документы и Корзина будут окончательно удалены. Файлы и папки выбранных пользователей, хранящиеся в общих разделах*, например, в комнатах, останутся в DocSpace.",
|
||||
"DeletePersonalDataApplicable": "*Применимо для выбранных пользователей, у которых есть такие файлы и папки.",
|
||||
"DeleteReassignDescriptionUser": "{{warningMessageMyDocuments}} Комнаты, созданные этим пользователем, и документы, хранящиеся в этих комнатах, будут автоматически переназначены администратору, выполняющему удаление: <strong>{{userPerformedDeletion}} ({{userYou}})</strong>. Переназначьте данные вручную, чтобы выбрать другого пользователя для переназначения.",
|
||||
"DeleteUser": "Удалить пользователя",
|
||||
"DeleteUserMessage": "{{userCaption}} <strong>{{user}}</strong> будет удален. Это действие не может быть отменено.",
|
||||
|
@ -1,5 +1,5 @@
|
||||
{
|
||||
"DeleteOwnerRestrictionText": "Поскольку вы являетесь владельцем данного {{productName}}, вы должны передать права владельца другому пользователю, прежде чем сможете удалить свой аккаунт. Чтобы продолжить, выберите нового владельца.",
|
||||
"DeleteProfileInfo": "Отправить инструкции по удалению профиля на адрес электронной почты",
|
||||
"DeleteProfileTitle": "Диалог удаления профиля"
|
||||
"DeleteOwnerRestrictionText": "Поскольку вы являетесь владельцем данного {{productName}}, вы должны передать права владельца другому пользователю, прежде чем сможете отключить свою учетную запись. Чтобы продолжить, выберите нового владельца.",
|
||||
"DeleteProfileInfo": "Отправить инструкции по отключению учетной записи на адрес электронной почты",
|
||||
"DeleteProfileTitle": "Отключениие учетной записи"
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
"AccountLoginType": "Тип входа в аккаунт",
|
||||
"AddMembers": "Добавить участников",
|
||||
"CreateGroup": "Создать группу",
|
||||
"DeleteSelfProfile": "Удалить профиль",
|
||||
"DeleteSelfProfile": "Отключить учетную запись",
|
||||
"DisabledEmployeeStatus": "Заблокирован",
|
||||
"DisableUserButton": "Заблокировать",
|
||||
"EditGroup": "Изменить группу",
|
||||
|
@ -1,4 +1,4 @@
|
||||
{
|
||||
"DeleteProfileInfo": "将档案删除指示发送至邮件地址",
|
||||
"DeleteProfileTitle": "删除档案对话框"
|
||||
"DeleteProfileTitle": "禁用帐户"
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
"AccountLoginType": "账户登录方式",
|
||||
"AddMembers": "添加成员",
|
||||
"CreateGroup": "创建群组",
|
||||
"DeleteSelfProfile": "删除档案",
|
||||
"DeleteSelfProfile": "禁用帐户",
|
||||
"DisabledEmployeeStatus": "已禁用",
|
||||
"DisableUserButton": "禁用",
|
||||
"EditGroup": "编辑群组",
|
||||
|
@ -101,7 +101,7 @@ const Panels = (props) => {
|
||||
selectFileFormRoomDialogVisible,
|
||||
selectFileFormRoomFilterParam,
|
||||
setSelectFileFormRoomDialogVisible,
|
||||
createFromTemplateForm,
|
||||
copyFromTemplateForm,
|
||||
hotkeyPanelVisible,
|
||||
invitePanelVisible,
|
||||
convertPasswordDialogVisible,
|
||||
@ -301,7 +301,7 @@ const Panels = (props) => {
|
||||
key="select-file-form-room-dialog"
|
||||
onClose={onCloseFileFormRoomDialog}
|
||||
openRoot={selectFileFormRoomOpenRoot}
|
||||
onSelectFile={createFromTemplateForm}
|
||||
onSelectFile={(file) => copyFromTemplateForm(file, t)}
|
||||
filterParam={selectFileFormRoomFilterParam}
|
||||
descriptionText={descriptionTextFileFormRoomDialog}
|
||||
/>
|
||||
@ -367,6 +367,7 @@ export default inject(
|
||||
createEditRoomStore,
|
||||
pluginStore,
|
||||
filesStore,
|
||||
filesActionsStore,
|
||||
}) => {
|
||||
const {
|
||||
ownerPanelVisible,
|
||||
@ -397,7 +398,6 @@ export default inject(
|
||||
selectFileFormRoomDialogVisible,
|
||||
selectFileFormRoomFilterParam,
|
||||
setSelectFileFormRoomDialogVisible,
|
||||
createFromTemplateForm,
|
||||
invitePanelOptions,
|
||||
inviteUsersWarningDialogVisible,
|
||||
changeUserTypeDialogVisible,
|
||||
@ -417,6 +417,7 @@ export default inject(
|
||||
} = dialogsStore;
|
||||
|
||||
const { preparationPortalDialogVisible } = backup;
|
||||
const { copyFromTemplateForm } = filesActionsStore;
|
||||
|
||||
const { uploadPanelVisible } = uploadDataStore;
|
||||
const { isVisible: versionHistoryPanelVisible } = versionHistoryStore;
|
||||
@ -455,7 +456,7 @@ export default inject(
|
||||
selectFileFormRoomDialogVisible,
|
||||
selectFileFormRoomFilterParam,
|
||||
setSelectFileFormRoomDialogVisible,
|
||||
createFromTemplateForm,
|
||||
copyFromTemplateForm,
|
||||
hotkeyPanelVisible,
|
||||
restoreAllPanelVisible,
|
||||
invitePanelVisible: invitePanelOptions.visible,
|
||||
|
@ -71,6 +71,8 @@ const CreateEvent = ({
|
||||
publicRoomKey,
|
||||
actionEdit,
|
||||
openOnNewPage,
|
||||
openEditor,
|
||||
createFile,
|
||||
}) => {
|
||||
const [headerTitle, setHeaderTitle] = React.useState(null);
|
||||
const [startValue, setStartValue] = React.useState("");
|
||||
@ -112,7 +114,7 @@ const CreateEvent = ({
|
||||
};
|
||||
}, [extension, title, fromTemplate, withoutDialog]);
|
||||
|
||||
const onSave = (e, value, open = true) => {
|
||||
const onSave = async (e, value, open = true) => {
|
||||
let item;
|
||||
let createdFolderId;
|
||||
|
||||
@ -157,46 +159,63 @@ const CreateEvent = ({
|
||||
return setIsLoading(false);
|
||||
});
|
||||
} else {
|
||||
const searchParams = new URLSearchParams();
|
||||
try {
|
||||
if (openEditor) {
|
||||
const searchParams = new URLSearchParams();
|
||||
|
||||
searchParams.append("parentId", parentId);
|
||||
searchParams.append("fileTitle", `${newValue}.${extension}`);
|
||||
searchParams.append("open", open);
|
||||
searchParams.append("id", id);
|
||||
searchParams.append("parentId", parentId);
|
||||
searchParams.append("fileTitle", `${newValue}.${extension}`);
|
||||
searchParams.append("open", open);
|
||||
searchParams.append("id", id);
|
||||
|
||||
if (preview) {
|
||||
searchParams.append("action", "view");
|
||||
if (preview) {
|
||||
searchParams.append("action", "view");
|
||||
}
|
||||
|
||||
if (actionEdit) {
|
||||
searchParams.append("action", "edit");
|
||||
}
|
||||
|
||||
if (publicRoomKey) {
|
||||
searchParams.append("share", publicRoomKey);
|
||||
}
|
||||
|
||||
if (isMakeFormFromFile) {
|
||||
searchParams.append("fromFile", isMakeFormFromFile);
|
||||
searchParams.append("templateId", templateId);
|
||||
} else if (fromTemplate) {
|
||||
searchParams.append("fromTemplate", fromTemplate);
|
||||
searchParams.append("formId", gallerySelected.id);
|
||||
}
|
||||
|
||||
searchParams.append("hash", new Date().getTime());
|
||||
|
||||
const url = combineUrl(
|
||||
window.location.origin,
|
||||
window.ClientConfig?.proxy?.url,
|
||||
config.homepage,
|
||||
`/doceditor/create?${searchParams.toString()}`,
|
||||
);
|
||||
|
||||
window.open(url, openOnNewPage ? "_blank" : "_self");
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
return await createFile(
|
||||
+parentId,
|
||||
`${newValue}.${extension}`,
|
||||
templateId,
|
||||
gallerySelected?.id,
|
||||
).catch((error) => {
|
||||
toastr.error(error);
|
||||
});
|
||||
} catch (error) {
|
||||
toastr.error(error);
|
||||
} finally {
|
||||
setIsLoading(false);
|
||||
onCloseAction();
|
||||
}
|
||||
|
||||
if (actionEdit) {
|
||||
searchParams.append("action", "edit");
|
||||
}
|
||||
|
||||
if (publicRoomKey) {
|
||||
searchParams.append("share", publicRoomKey);
|
||||
}
|
||||
|
||||
if (isMakeFormFromFile) {
|
||||
searchParams.append("fromFile", isMakeFormFromFile);
|
||||
searchParams.append("templateId", templateId);
|
||||
} else if (fromTemplate) {
|
||||
searchParams.append("fromTemplate", fromTemplate);
|
||||
searchParams.append("formId", gallerySelected.id);
|
||||
}
|
||||
|
||||
searchParams.append("hash", new Date().getTime());
|
||||
|
||||
const url = combineUrl(
|
||||
window.location.origin,
|
||||
window.ClientConfig?.proxy?.url,
|
||||
config.homepage,
|
||||
`/doceditor/create?${searchParams.toString()}`,
|
||||
);
|
||||
|
||||
window.open(url, openOnNewPage ? "_blank" : "_self");
|
||||
|
||||
setIsLoading(false);
|
||||
onCloseAction();
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -115,6 +115,7 @@ const GlobalEvents = ({ enablePlugins, eventListenerItemsList }) => {
|
||||
withoutDialog: payload.withoutDialog ?? false,
|
||||
preview: payload.preview ?? false,
|
||||
actionEdit: payload.edit ?? false,
|
||||
openEditor: payload.openEditor ?? true,
|
||||
onClose: () => {
|
||||
setCreateDialogProps({
|
||||
visible: false,
|
||||
@ -128,6 +129,7 @@ const GlobalEvents = ({ enablePlugins, eventListenerItemsList }) => {
|
||||
withoutDialog: false,
|
||||
preview: false,
|
||||
actionEdit: false,
|
||||
openEditor: true,
|
||||
});
|
||||
},
|
||||
});
|
||||
|
@ -63,7 +63,7 @@ const ConflictResolveDialog = (props: ConflictResolveDialogProps) => {
|
||||
handleFilesUpload,
|
||||
} = props;
|
||||
|
||||
const { t, ready } = useTranslation(["ConflictResolveDialog", "Common"]);
|
||||
const { t, ready } = useTranslation(["Common"]);
|
||||
|
||||
const {
|
||||
destFolderId,
|
||||
@ -198,7 +198,7 @@ const ConflictResolveDialog = (props: ConflictResolveDialogProps) => {
|
||||
items.length === 1 ? (
|
||||
<Trans
|
||||
t={t}
|
||||
ns="ConflictResolveDialog"
|
||||
ns="Common"
|
||||
i18nKey="ConflictResolveDescription"
|
||||
values={{ file: items[0].title, folder: folderTitle }}
|
||||
components={{ 1: <span className="bold" /> }}
|
||||
@ -206,7 +206,7 @@ const ConflictResolveDialog = (props: ConflictResolveDialogProps) => {
|
||||
) : (
|
||||
<Trans
|
||||
t={t}
|
||||
ns="ConflictResolveDialog"
|
||||
ns="Common"
|
||||
i18nKey="ConflictResolveDescriptionFiles"
|
||||
values={{ filesCount: items.length, folder: folderTitle }}
|
||||
components={{ 1: <span className="bold" /> }}
|
||||
@ -216,20 +216,20 @@ const ConflictResolveDialog = (props: ConflictResolveDialogProps) => {
|
||||
return (
|
||||
<ConflictResolve
|
||||
visible={visible}
|
||||
headerLabel={t("ConflictResolveTitle")}
|
||||
headerLabel={t("Common:ConflictResolveTitle")}
|
||||
isLoading={!ready}
|
||||
onSubmit={isUploadConflict ? onAcceptUploadType : onAcceptType}
|
||||
onClose={onCloseDialog}
|
||||
cancelButtonLabel={t("Common:CancelButton")}
|
||||
submitButtonLabel={t("Common:OKButton")}
|
||||
messageText={messageText}
|
||||
selectActionText={t("ConflictResolveSelectAction")}
|
||||
overwriteTitle={t("OverwriteTitle")}
|
||||
overwriteDescription={t("OverwriteDescription")}
|
||||
selectActionText={t("Common:ConflictResolveSelectAction")}
|
||||
overwriteTitle={t("Common:OverwriteTitle")}
|
||||
overwriteDescription={t("Common:OverwriteDescription")}
|
||||
duplicateTitle={t("Common:CreateFileCopy")}
|
||||
duplicateDescription={t("CreateDescription")}
|
||||
skipTitle={t("SkipTitle")}
|
||||
skipDescription={t("SkipDescription")}
|
||||
duplicateDescription={t("Common:CreateDescription")}
|
||||
skipTitle={t("Common:SkipTitle")}
|
||||
skipDescription={t("Common:SkipDescription")}
|
||||
/>
|
||||
);
|
||||
};
|
||||
|
@ -77,12 +77,18 @@ const BodyComponent = (props) => {
|
||||
{t("ActionCannotBeUndone", { productName: PRODUCT_NAME })}
|
||||
</Text>
|
||||
<Text className="text-warning">{t("PleaseNote")}</Text>
|
||||
<Text className="text-delete-description">
|
||||
{t("DeletePersonalData")}
|
||||
</Text>
|
||||
<Text className="text-delete-description">
|
||||
{t("CannotReassignFiles")}
|
||||
</Text>
|
||||
<Text className="text-delete-description">
|
||||
{t("ToBeAbleToReassignData")}
|
||||
</Text>
|
||||
<Text className="text-delete-description">
|
||||
{t("DeletePersonalDataApplicable")}
|
||||
</Text>
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
@ -63,7 +63,7 @@ const ProfileRemoveForm = (props) => {
|
||||
return (
|
||||
<StyledPage>
|
||||
<StyledContent>
|
||||
<StyledBody>
|
||||
<StyledBody style={{ whiteSpace: "pre-wrap" }}>
|
||||
<PortalLogo className="portal-logo" />
|
||||
<Text fontSize="23px" fontWeight="700" className="title">
|
||||
{t("DeleteProfileSuccessMessage")}
|
||||
@ -74,7 +74,9 @@ const ProfileRemoveForm = (props) => {
|
||||
ns="Confirm"
|
||||
t={t}
|
||||
>
|
||||
See our
|
||||
Your DocSpace account is successfully disabled. The DocSpace
|
||||
owner or admin can permanently delete your disabled account.
|
||||
\n\nPlease check our
|
||||
<Link
|
||||
fontSize="16px"
|
||||
fontWeight="600"
|
||||
@ -85,8 +87,7 @@ const ProfileRemoveForm = (props) => {
|
||||
>
|
||||
Privacy policy
|
||||
</Link>
|
||||
to learn more about deleting your account and the data
|
||||
associated with it.
|
||||
to learn more about deleting your account and associated data.
|
||||
</Trans>
|
||||
</Text>
|
||||
</StyledBody>
|
||||
@ -119,7 +120,7 @@ const ProfileRemoveForm = (props) => {
|
||||
ns="Confirm"
|
||||
t={t}
|
||||
>
|
||||
By clicking \"Delete my account\" you agree with our Privacy
|
||||
By clicking \"Disable my account\" you agree with our Privacy
|
||||
policy
|
||||
<Link
|
||||
type="page"
|
||||
|
@ -34,7 +34,12 @@ import { getGroup } from "@docspace/shared/api/groups";
|
||||
import { getUserById } from "@docspace/shared/api/people";
|
||||
import { MEDIA_VIEW_URL } from "@docspace/shared/constants";
|
||||
|
||||
import { Events, RoomSearchArea } from "@docspace/shared/enums";
|
||||
import {
|
||||
Events,
|
||||
FolderType,
|
||||
RoomSearchArea,
|
||||
RoomsType,
|
||||
} from "@docspace/shared/enums";
|
||||
import { getObjectByLocation } from "@docspace/shared/utils/common";
|
||||
import { useParams } from "react-router-dom";
|
||||
|
||||
@ -72,6 +77,7 @@ const useFiles = ({
|
||||
userId,
|
||||
|
||||
scrollToTop,
|
||||
selectedFolderStore,
|
||||
}) => {
|
||||
const navigate = useNavigate();
|
||||
const { id } = useParams();
|
||||
@ -298,11 +304,16 @@ const useFiles = ({
|
||||
|
||||
const event = new Event(Events.CREATE);
|
||||
|
||||
const isFormRoom =
|
||||
selectedFolderStore.roomType === RoomsType.FormRoom ||
|
||||
selectedFolderStore.type === FolderType.FormRoom;
|
||||
|
||||
const payload = {
|
||||
extension: "pdf",
|
||||
id: -1,
|
||||
fromTemplate: true,
|
||||
title: gallerySelected.attributes.name_form,
|
||||
openEditor: !isFormRoom,
|
||||
};
|
||||
|
||||
event.payload = payload;
|
||||
|
@ -278,12 +278,16 @@ class DetailsHelper {
|
||||
getAuthorDecoration = (byField = "createdBy") => {
|
||||
const onClick = () => this.openUser(this.item[byField], this.navigate);
|
||||
|
||||
const isAnonim = this.item[byField]?.isAnonim;
|
||||
const displayName = this.item[byField]?.displayName;
|
||||
const name = displayName ? decode(displayName) : "";
|
||||
|
||||
let name = displayName ? decode(displayName) : "";
|
||||
|
||||
if (isAnonim) name = this.t("Common:Anonymous");
|
||||
|
||||
//console.log("getAuthorDecoration", { name, displayName });
|
||||
|
||||
return this.isVisitor || this.isCollaborator
|
||||
return this.isVisitor || this.isCollaborator || isAnonim
|
||||
? text(name)
|
||||
: link(name, onClick);
|
||||
};
|
||||
|
@ -83,7 +83,11 @@ const HistoryBlock = ({
|
||||
/>
|
||||
<div className="info">
|
||||
<div className="title">
|
||||
<Text className="name">{decode(initiator.displayName)}</Text>
|
||||
<Text className="name">
|
||||
{initiator?.isAnonim
|
||||
? t("Common:Anonymous")
|
||||
: decode(initiator.displayName)}
|
||||
</Text>
|
||||
{initiator.isOwner && (
|
||||
<Text className="secondary-info">
|
||||
{t("Common:Owner").toLowerCase()}
|
||||
|
@ -1225,14 +1225,15 @@ export default inject(
|
||||
|
||||
const sharedItem = navigationPath.find((r) => r.shared);
|
||||
|
||||
const showNavigationButton = isLoading
|
||||
? false
|
||||
: (!isPublicRoom &&
|
||||
!isArchive &&
|
||||
canCopyPublicLink &&
|
||||
(isPublicRoomType || isCustomRoomType || isFormRoomType) &&
|
||||
shared) ||
|
||||
(sharedItem && sharedItem.canCopyPublicLink);
|
||||
const showNavigationButton =
|
||||
isLoading || !security?.CopyLink
|
||||
? false
|
||||
: (!isPublicRoom &&
|
||||
!isArchive &&
|
||||
canCopyPublicLink &&
|
||||
(isPublicRoomType || isCustomRoomType || isFormRoomType) &&
|
||||
shared) ||
|
||||
(sharedItem && sharedItem.canCopyPublicLink);
|
||||
|
||||
return {
|
||||
isGracePeriod,
|
||||
|
@ -201,6 +201,7 @@ const PureHome = (props) => {
|
||||
userId,
|
||||
|
||||
scrollToTop,
|
||||
selectedFolderStore,
|
||||
});
|
||||
|
||||
const { showUploadPanel } = useOperations({
|
||||
|
@ -1400,7 +1400,8 @@ class ContextOptionsStore {
|
||||
onClick: () => this.onCopyLink(item, t),
|
||||
disabled:
|
||||
(isPublicRoomType && item.canCopyPublicLink && !isArchive) ||
|
||||
this.publicRoomStore.isPublicRoom,
|
||||
this.publicRoomStore.isPublicRoom ||
|
||||
!item.security.CopyLink,
|
||||
},
|
||||
{
|
||||
id: "option_copy-external-link",
|
||||
|
@ -380,13 +380,6 @@ class DialogsStore {
|
||||
this.selectFileFormRoomOpenRoot = openRoot;
|
||||
};
|
||||
|
||||
createFromTemplateForm = (fileInfo) => {
|
||||
this.createMasterForm(fileInfo, {
|
||||
extension: "pdf",
|
||||
withoutDialog: true,
|
||||
});
|
||||
};
|
||||
|
||||
createMasterForm = async (fileInfo, options) => {
|
||||
const { extension = "pdf", withoutDialog, preview } = options;
|
||||
|
||||
|
@ -2714,6 +2714,37 @@ class FilesActionStore {
|
||||
await deleteFilesFromRecent(fileIds);
|
||||
await refreshFiles();
|
||||
};
|
||||
|
||||
copyFromTemplateForm = async (fileInfo, t) => {
|
||||
const selectedItemId = this.selectedFolderStore.id;
|
||||
const fileIds = [fileInfo.id];
|
||||
|
||||
const operationData = {
|
||||
destFolderId: selectedItemId,
|
||||
folderIds: [],
|
||||
fileIds,
|
||||
deleteAfter: false,
|
||||
isCopy: true,
|
||||
folderTitle: this.selectedFolderStore.title,
|
||||
translations: {
|
||||
copy: t("Common:CopyOperation"),
|
||||
},
|
||||
};
|
||||
|
||||
this.uploadDataStore.secondaryProgressDataStore.setItemsSelectionTitle(
|
||||
fileInfo.title,
|
||||
);
|
||||
|
||||
const conflicts = await checkFileConflicts(selectedItemId, [], fileIds);
|
||||
|
||||
if (conflicts.length) {
|
||||
return this.setConflictDialogData(conflicts, operationData);
|
||||
}
|
||||
|
||||
this.uploadDataStore
|
||||
.itemOperationToFolder(operationData)
|
||||
.catch((error) => toastr.error(error));
|
||||
};
|
||||
}
|
||||
|
||||
export default FilesActionStore;
|
||||
|
@ -2600,12 +2600,13 @@ class FilesStore {
|
||||
}
|
||||
};
|
||||
|
||||
createFile = (folderId, title, templateId, formId) => {
|
||||
createFile = async (folderId, title, templateId, formId) => {
|
||||
return api.files
|
||||
.createFile(folderId, title, templateId, formId)
|
||||
.then((file) => {
|
||||
return Promise.resolve(file);
|
||||
});
|
||||
})
|
||||
.then(() => this.fetchFiles(folderId, this.filter, true, true, false));
|
||||
};
|
||||
|
||||
createFolder(parentFolderId, title) {
|
||||
|
@ -296,7 +296,8 @@ const Editor = ({
|
||||
}
|
||||
|
||||
if (config?.startFilling) {
|
||||
newConfig.events.onRequestStartFilling = onSDKRequestStartFilling;
|
||||
newConfig.events.onRequestStartFilling = () =>
|
||||
onSDKRequestStartFilling?.(t("Common:StartFilling"));
|
||||
}
|
||||
|
||||
newConfig.events.onSubmit = () => {
|
||||
|
@ -125,12 +125,6 @@ const Root = ({
|
||||
selectFileDialogFileTypeDetection,
|
||||
selectFileDialogVisible,
|
||||
} = useSelectFileDialog({ instanceId: instanceId ?? "" });
|
||||
const {
|
||||
isSharingDialogVisible,
|
||||
|
||||
onCloseSharingDialog,
|
||||
onSDKRequestSharingSettings,
|
||||
} = useShareDialog();
|
||||
|
||||
const {
|
||||
getIsDisabledStartFillingSelectDialog,
|
||||
@ -139,8 +133,16 @@ const Root = ({
|
||||
onSubmitStartFillingSelectDialog,
|
||||
onSDKRequestStartFilling,
|
||||
conflictDataDialog,
|
||||
headerLabelSFSDialog,
|
||||
} = useStartFillingSelectDialog(fileInfo);
|
||||
|
||||
const {
|
||||
isSharingDialogVisible,
|
||||
|
||||
onCloseSharingDialog,
|
||||
onSDKRequestSharingSettings,
|
||||
} = useShareDialog(config, onSDKRequestStartFilling);
|
||||
|
||||
useUpdateSearchParamId(fileId, hash);
|
||||
|
||||
React.useEffect(() => {
|
||||
@ -254,11 +256,12 @@ const Root = ({
|
||||
<StartFillingSelectorDialog
|
||||
fileInfo={fileInfo}
|
||||
socketHelper={socketHelper}
|
||||
filesSettings={filesSettings}
|
||||
headerLabel={headerLabelSFSDialog}
|
||||
isVisible={isVisibleStartFillingSelectDialog}
|
||||
onClose={onCloseStartFillingSelectDialog}
|
||||
onSubmit={onSubmitStartFillingSelectDialog}
|
||||
getIsDisabled={getIsDisabledStartFillingSelectDialog}
|
||||
filesSettings={filesSettings}
|
||||
/>
|
||||
)}
|
||||
{conflictDataDialog.visible && (
|
||||
|
@ -40,6 +40,7 @@ function StartFillingSelectorDialog({
|
||||
onClose,
|
||||
onSubmit,
|
||||
filesSettings,
|
||||
headerLabel,
|
||||
}: StartFillingSelectorDialogPprops) {
|
||||
const { t } = useTranslation(["Common", "Editor"]);
|
||||
|
||||
@ -67,7 +68,7 @@ function StartFillingSelectorDialog({
|
||||
filesSettings={filesSettings}
|
||||
currentDeviceType={DeviceType.desktop}
|
||||
socketSubscribers={socketHelper.socketSubscribers}
|
||||
headerLabel={t("Common:StartFilling")}
|
||||
headerLabel={headerLabel}
|
||||
submitButtonLabel={t("Common:CopyHere")}
|
||||
onSubmit={onSubmit}
|
||||
getIsDisabled={getIsDisabled}
|
||||
|
@ -25,13 +25,23 @@
|
||||
// International. See the License terms at http://creativecommons.org/licenses/by-sa/4.0/legalcode
|
||||
|
||||
import React from "react";
|
||||
import { useTranslation } from "react-i18next";
|
||||
|
||||
const useShareDialog = () => {
|
||||
import type { IInitialConfig } from "@/types";
|
||||
|
||||
const useShareDialog = (
|
||||
config: IInitialConfig | undefined,
|
||||
onSDKRequestStartFilling: (headerLabel: string) => void,
|
||||
) => {
|
||||
const { t } = useTranslation(["Common"]);
|
||||
const [isVisible, setIsVisible] = React.useState(false);
|
||||
|
||||
const onSDKRequestSharingSettings = React.useCallback(() => {
|
||||
if (config?.startFilling)
|
||||
return onSDKRequestStartFilling(t("Common:ShareToFillOut"));
|
||||
|
||||
setIsVisible(true);
|
||||
}, []);
|
||||
}, [config?.startFilling, onSDKRequestStartFilling, t]);
|
||||
|
||||
const onClose = React.useCallback(() => {
|
||||
setIsVisible(false);
|
||||
@ -45,4 +55,3 @@ const useShareDialog = () => {
|
||||
};
|
||||
|
||||
export default useShareDialog;
|
||||
|
||||
|
@ -41,7 +41,7 @@ import type { TRoomSecurity } from "@docspace/shared/api/rooms/types";
|
||||
import type { TBreadCrumb } from "@docspace/shared/components/selector/Selector.types";
|
||||
import type { TSelectedFileInfo } from "@docspace/shared/selectors/Files/FilesSelector.types";
|
||||
import type { ConflictStateType } from "@/types";
|
||||
import { useTranslation } from "react-i18next";
|
||||
// import { useTranslation } from "react-i18next";
|
||||
|
||||
const DefaultConflictDataDialogState: ConflictStateType = {
|
||||
visible: false,
|
||||
@ -52,7 +52,8 @@ const DefaultConflictDataDialogState: ConflictStateType = {
|
||||
};
|
||||
|
||||
const useStartFillingSelectDialog = (fileInfo: TFile | undefined) => {
|
||||
const { t } = useTranslation(["Common"]);
|
||||
// const { t } = useTranslation(["Common"]);
|
||||
const [headerLabelSFSDialog, setHeaderLabelSFSDialog] = useState("");
|
||||
|
||||
const [isVisible, setIsVisible] = useState(false);
|
||||
const [conflictDataDialog, setConflictDataDialog] = useState(
|
||||
@ -61,7 +62,8 @@ const useStartFillingSelectDialog = (fileInfo: TFile | undefined) => {
|
||||
|
||||
const requestRunning = useRef(false);
|
||||
|
||||
const onSDKRequestStartFilling = useCallback((_: object) => {
|
||||
const onSDKRequestStartFilling = useCallback((headerLabel: string) => {
|
||||
setHeaderLabelSFSDialog(headerLabel);
|
||||
setIsVisible(true);
|
||||
}, []);
|
||||
|
||||
@ -180,6 +182,7 @@ const useStartFillingSelectDialog = (fileInfo: TFile | undefined) => {
|
||||
getIsDisabledStartFillingSelectDialog: getIsDisabled,
|
||||
isVisibleStartFillingSelectDialog: isVisible,
|
||||
conflictDataDialog,
|
||||
headerLabelSFSDialog,
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -233,7 +233,7 @@ export type EditorProps = {
|
||||
onSDKRequestSelectSpreadsheet?: (event: object) => void;
|
||||
onSDKRequestSelectDocument?: (event: object) => void;
|
||||
onSDKRequestReferenceSource?: (event: object) => void;
|
||||
onSDKRequestStartFilling?: (event: object) => void;
|
||||
onSDKRequestStartFilling?: (haederLabel: string) => void;
|
||||
};
|
||||
|
||||
export type TEventData = {
|
||||
@ -405,6 +405,7 @@ export type StartFillingSelectorDialogPprops = {
|
||||
fileInfo: TFile;
|
||||
isVisible: boolean;
|
||||
onClose: VoidFunction;
|
||||
headerLabel: string;
|
||||
|
||||
getIsDisabled: (
|
||||
isFirstLoad: boolean,
|
||||
|
@ -77,7 +77,6 @@ export async function fileCopyAs(
|
||||
enableExternalExt,
|
||||
password,
|
||||
}),
|
||||
false,
|
||||
);
|
||||
|
||||
const file = await (await fetch(createFile)).json();
|
||||
@ -139,7 +138,6 @@ export async function createFile(
|
||||
[["Content-Type", "application/json;charset=utf-8"]],
|
||||
"POST",
|
||||
JSON.stringify({ title, templateId, formId }),
|
||||
false,
|
||||
);
|
||||
|
||||
const file = await (await fetch(createFile)).json();
|
||||
@ -311,7 +309,6 @@ export async function getUser(share?: string) {
|
||||
[share ? ["Request-Token", share] : ["", ""]],
|
||||
"GET",
|
||||
undefined,
|
||||
false,
|
||||
);
|
||||
|
||||
if (!cookie?.includes("asc_auth_key")) return undefined;
|
||||
@ -337,7 +334,6 @@ export async function getSettings(share?: string) {
|
||||
[share ? ["Request-Token", share] : ["", ""]],
|
||||
"GET",
|
||||
undefined,
|
||||
false,
|
||||
);
|
||||
|
||||
const settingsRes = await fetch(getSettings);
|
||||
@ -363,7 +359,6 @@ export async function checkFillFromDraft(
|
||||
],
|
||||
"POST",
|
||||
JSON.stringify({ fileId: templateFileId }),
|
||||
false,
|
||||
);
|
||||
|
||||
const response = await fetch(checkFillFormDraft);
|
||||
@ -389,7 +384,6 @@ export async function openEdit(
|
||||
[share ? ["Request-Token", share] : ["", ""]],
|
||||
"GET",
|
||||
undefined,
|
||||
false,
|
||||
);
|
||||
|
||||
const res = await fetch(getConfig);
|
||||
@ -452,7 +446,6 @@ export async function getEditorUrl(
|
||||
[share ? ["Request-Token", share] : ["", ""]],
|
||||
"GET",
|
||||
undefined,
|
||||
false,
|
||||
);
|
||||
|
||||
const res = await fetch(request);
|
||||
|
@ -474,12 +474,12 @@ export const enum ErrorKeys {
|
||||
}
|
||||
|
||||
export enum RoomsType {
|
||||
PublicRoom = 6,
|
||||
FormRoom = 1,
|
||||
// FillingFormsRoom= 1, //TODO: Restore when certs will be done
|
||||
EditingRoom = 2,
|
||||
// ReviewRoom: 3, //TODO: Restore when certs will be done
|
||||
// ReadOnlyRoom: 4, //TODO: Restore when certs will be done
|
||||
PublicRoom = 6,
|
||||
CustomRoom = 5,
|
||||
}
|
||||
|
||||
|
@ -24,7 +24,7 @@
|
||||
// content are licensed under the terms of the Creative Commons Attribution-ShareAlike 4.0
|
||||
// International. See the License terms at http://creativecommons.org/licenses/by-sa/4.0/legalcode
|
||||
|
||||
import { headers } from "next/headers";
|
||||
import { headers, cookies } from "next/headers";
|
||||
|
||||
const API_PREFIX = "api/2.0";
|
||||
|
||||
@ -39,12 +39,8 @@ export const getBaseUrl = () => {
|
||||
return baseURL;
|
||||
};
|
||||
|
||||
export const getAPIUrl = (internalRequest: boolean) => {
|
||||
const baseUrl = internalRequest
|
||||
? process.env.API_HOST?.trim() ?? getBaseUrl()
|
||||
: getBaseUrl();
|
||||
|
||||
// const baseUrl = getBaseUrl();
|
||||
export const getAPIUrl = () => {
|
||||
const baseUrl = process.env.API_HOST?.trim() ?? getBaseUrl();
|
||||
|
||||
const baseAPIUrl = `${baseUrl}/${API_PREFIX}`;
|
||||
|
||||
@ -56,11 +52,11 @@ export const createRequest = (
|
||||
newHeaders: [string, string][],
|
||||
method: string,
|
||||
body?: string,
|
||||
internalRequest: boolean = true,
|
||||
) => {
|
||||
const hdrs = new Headers(headers());
|
||||
const cookieStore = cookies();
|
||||
|
||||
const apiURL = getAPIUrl(internalRequest);
|
||||
const apiURL = getAPIUrl();
|
||||
|
||||
newHeaders.forEach((hdr) => {
|
||||
if (hdr[0]) hdrs.set(hdr[0], hdr[1]);
|
||||
@ -70,6 +66,10 @@ export const createRequest = (
|
||||
|
||||
if (baseURL && process.env.API_HOST?.trim()) hdrs.set("origin", baseURL);
|
||||
|
||||
const authToken = cookieStore.get("asc_auth_key")?.value;
|
||||
|
||||
if (authToken) hdrs.set("Authorization", authToken);
|
||||
|
||||
const urls = paths.map((path) => `${apiURL}${path}`);
|
||||
|
||||
const requests = urls.map(
|
||||
|
@ -14,6 +14,7 @@
|
||||
"AddUsers": "Add users",
|
||||
"AdvancedFilter": "Search options",
|
||||
"Alert": "Alert",
|
||||
"Anonymous": "Anonymous",
|
||||
"AnyoneWithLink": "Anyone with the link",
|
||||
"ApplyButton": "Apply",
|
||||
"Archive": "Archive",
|
||||
@ -52,6 +53,10 @@
|
||||
"CommonFiles": "Common files",
|
||||
"CompanyName": "Company name",
|
||||
"Confirmation": "Confirmation",
|
||||
"ConflictResolveDescription": "The file with the name <1>{{file}}</1> already exists in the folder <1>{{folder}}</1>.",
|
||||
"ConflictResolveDescriptionFiles": "{{filesCount}} documents with the same name already exist in the folder <1>{{folder}}</1>.",
|
||||
"ConflictResolveSelectAction": "Please select the action:",
|
||||
"ConflictResolveTitle": "Overwrite confirmation",
|
||||
"Connect": "Connect",
|
||||
"Content": "Content",
|
||||
"Context": "Context",
|
||||
@ -65,6 +70,7 @@
|
||||
"Create": "Create",
|
||||
"CreateAndCopy": "Create and copy",
|
||||
"CreateCopy": "Create copy",
|
||||
"CreateDescription": "There will be two different files in the folder.",
|
||||
"CreateFileCopy": "Create file copy",
|
||||
"CreateMasterFormFromFile": "Create Form Template from file",
|
||||
"CreatePDFForm": "Create PDF Form",
|
||||
@ -176,13 +182,13 @@
|
||||
"ExpiredLink": "Expired link",
|
||||
"FeedbackAndSupport": "Feedback & Support",
|
||||
"Fill": "Fill out",
|
||||
"FillFormButton": "Fill in the form",
|
||||
"FillFormButton": "Fill",
|
||||
"FillingFormRooms": "Filling form",
|
||||
"FillingFormsRoomDescription": "Build, share and fill document templates or work with the ready presets to quickly create documents of any type.",
|
||||
"FillingFormsRoomTitle": "Filling forms room",
|
||||
"Finish": "Finish",
|
||||
"FirstName": "First name",
|
||||
"FormFilingRoomDescription": "Invite users to fill out a ready PDF form. Check the complete forms and analyze data automatically collected in a spreadsheet.",
|
||||
"FormFilingRoomDescription": "Upload PDF forms into the room. Invite users to fill out a PDF form. Review completed forms and analyze data automatically collected in a spreadsheet.",
|
||||
"FormFilingRoomTitle": "Form Filling Room",
|
||||
"FormRoom": "Form room",
|
||||
"Free": "Free",
|
||||
@ -270,8 +276,8 @@
|
||||
"Name": "Name",
|
||||
"NeedPassword": "You need a password to access the room",
|
||||
"NewDocument": "New document",
|
||||
"NewFolder": "New folder",
|
||||
"NewFillingFormRoom": "New Filling form room",
|
||||
"NewFolder": "New folder",
|
||||
"NewMasterForm": "New form template",
|
||||
"NewPresentation": "New presentation",
|
||||
"NewRoom": "New room",
|
||||
@ -293,6 +299,8 @@
|
||||
"orContinueWith": "or continue with",
|
||||
"OtherLabel": "Other",
|
||||
"OtherOperations": "Other operations",
|
||||
"OverwriteDescription": "The new file will replace the existing one as a new version.",
|
||||
"OverwriteTitle": "Overwrite with version update",
|
||||
"Owner": "Owner",
|
||||
"PageOfTotalPage": "{{page}} of {{totalPage}}",
|
||||
"Pages": "Pages",
|
||||
@ -328,8 +336,6 @@
|
||||
"ProviderSsoSetting": "Single sign-on",
|
||||
"ProviderTwitter": "Twitter",
|
||||
"ProviderZoom": "Zoom",
|
||||
"PublicRoom": "Public room",
|
||||
"PublicRoomDescription": "Invite users via external links to view documents without registration. You can also embed this room into any web interface.",
|
||||
"PublicLink": "Public link",
|
||||
"PublicRoom": "Public room",
|
||||
"PublicRoomDescription": "Invite users via external links to view documents without registration. You can also embed this room into any web interface.",
|
||||
@ -399,6 +405,7 @@
|
||||
"ShareDocument": "Share this document",
|
||||
"ShareDocumentDescription": "Provide access to the document and set the permission levels.",
|
||||
"SharedWithMe": "Shared with me",
|
||||
"ShareToFillOut": "Share to fill out",
|
||||
"ShareVia": "Share via",
|
||||
"ShowMore": "Show more",
|
||||
"SignInWithApple": "Sign in with Apple",
|
||||
@ -419,6 +426,8 @@
|
||||
"SignUpWithZoom": "Sign up with Zoom",
|
||||
"Size": "Size",
|
||||
"SizeImageLarge": "The image size is too large, please select another image.",
|
||||
"SkipDescription": "No file will be copied. The original file will be retained in the destination folder.",
|
||||
"SkipTitle": "Skip",
|
||||
"SomethingWentWrong": "Something went wrong.",
|
||||
"SortBy": "Sort by",
|
||||
"SpaceManagement": "Space Management",
|
||||
@ -477,14 +486,5 @@
|
||||
"Website": "Website",
|
||||
"Yes": "Yes",
|
||||
"Yesterday": "Yesterday",
|
||||
"You": "You",
|
||||
"ConflictResolveDescription": "The file with the name <1>{{file}}</1> already exists in the folder <1>{{folder}}</1>.",
|
||||
"ConflictResolveDescriptionFiles": "{{filesCount}} documents with the same name already exist in the folder <1>{{folder}}</1>.",
|
||||
"ConflictResolveSelectAction": "Please select the action:",
|
||||
"ConflictResolveTitle": "Overwrite confirmation",
|
||||
"CreateDescription": "There will be two different files in the folder.",
|
||||
"OverwriteDescription": "The new file will replace the existing one as a new version.",
|
||||
"OverwriteTitle": "Overwrite with version update",
|
||||
"SkipDescription": "No file will be copied. The original file will be retained in the destination folder.",
|
||||
"SkipTitle": "Skip"
|
||||
"You": "You"
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user