mirror of
https://github.com/ONLYOFFICE/document-server-integration.git
synced 2026-02-10 18:05:10 +08:00
Merge remote-tracking branch 'remotes/origin/develop' into feature/on-request-reference-source
# Conflicts: # CHANGELOG.md
This commit is contained in:
@ -155,22 +155,24 @@ public class FileModel {
|
||||
public void changeType(final String modeParam, final String typeParam, final User user, final String fileName) {
|
||||
// check if the file with such an extension can be edited
|
||||
String fileExt = FileUtility.getFileExtension(document.getTitle());
|
||||
Boolean canFill = DocumentManager.getFillExts().contains(fileExt);
|
||||
Boolean canEdit = DocumentManager.getEditedExts().contains(fileExt);
|
||||
|
||||
if (modeParam != null) {
|
||||
mode = modeParam;
|
||||
} else {
|
||||
mode = canFill ? "fillForms" : "edit";
|
||||
mode = "edit";
|
||||
}
|
||||
if (typeParam != null) {
|
||||
type = typeParam;
|
||||
}
|
||||
|
||||
// check if the Submit form button is displayed or not
|
||||
editorConfig.getCustomization().setSubmitForm(user.getId().equals("uid-1"));
|
||||
if (!mode.equals("view")) {
|
||||
editorConfig.getCustomization().setSubmitForm(user.getId().equals("uid-1"));
|
||||
}
|
||||
|
||||
if ((!canEdit && mode.equals("edit") || mode.equals("fillForms")) && canFill) {
|
||||
if ((!canEdit && mode.equals("edit") || mode.equals("fillForms"))
|
||||
&& DocumentManager.getFillExts().contains(fileExt)) {
|
||||
canEdit = true;
|
||||
mode = "fillForms";
|
||||
}
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
version=1.10.0
|
||||
version=1.11.0
|
||||
|
||||
filesize-max=5242880
|
||||
storage-folder=app_data
|
||||
|
||||
Reference in New Issue
Block a user