mirror of
https://gitee.com/openharmony/applications_dlp_manager
synced 2024-11-27 03:50:45 +00:00
!260 [缺陷]文件名解密错误
Merge pull request !260 from 王力量/day0828_fileName_weekly
This commit is contained in:
commit
b186810544
@ -215,7 +215,7 @@ struct changeEncryption {
|
|||||||
let srcFileUri: string = GlobalContext.load('uri');
|
let srcFileUri: string = GlobalContext.load('uri');
|
||||||
let srcFileMsg: FileMsg = FileUtils.getAllSuffixByUri(srcFileUri);
|
let srcFileMsg: FileMsg = FileUtils.getAllSuffixByUri(srcFileUri);
|
||||||
let documentSaveOptions = new picker.DocumentSaveOptions();
|
let documentSaveOptions = new picker.DocumentSaveOptions();
|
||||||
documentSaveOptions.newFileNames = [plaintextFile];
|
documentSaveOptions.newFileNames = [decodeURIComponent(plaintextFile)];
|
||||||
documentSaveOptions.fileSuffixChoices = [`.${srcFileMsg.fileType}`];
|
documentSaveOptions.fileSuffixChoices = [`.${srcFileMsg.fileType}`];
|
||||||
documentSaveOptions.defaultFilePathUri = srcFileUri.substring(0,
|
documentSaveOptions.defaultFilePathUri = srcFileUri.substring(0,
|
||||||
srcFileUri.length - srcFileMsg.fileType.length - srcFileMsg.fileName.length - 5);
|
srcFileUri.length - srcFileMsg.fileType.length - srcFileMsg.fileName.length - 5);
|
||||||
|
@ -363,7 +363,7 @@ struct DlpDialog {
|
|||||||
AppStorage.setOrCreate('hiFileType', srcFileMsg.fileType);
|
AppStorage.setOrCreate('hiFileType', srcFileMsg.fileType);
|
||||||
let documentSaveOptions = new picker.DocumentSaveOptions();
|
let documentSaveOptions = new picker.DocumentSaveOptions();
|
||||||
displayName = displayName + '.dlp';
|
displayName = displayName + '.dlp';
|
||||||
documentSaveOptions.newFileNames = [decodeURI(srcFileMsg.fileName)];
|
documentSaveOptions.newFileNames = [decodeURIComponent(srcFileMsg.fileName)];
|
||||||
documentSaveOptions.fileSuffixChoices = [srcFileMsg.fileType + '.dlp'];
|
documentSaveOptions.fileSuffixChoices = [srcFileMsg.fileType + '.dlp'];
|
||||||
documentSaveOptions.defaultFilePathUri = srcFileUri.substring(0,
|
documentSaveOptions.defaultFilePathUri = srcFileUri.substring(0,
|
||||||
srcFileUri.length - srcFileMsg.fileType.length - srcFileMsg.fileName.length);
|
srcFileUri.length - srcFileMsg.fileType.length - srcFileMsg.fileName.length);
|
||||||
|
Loading…
Reference in New Issue
Block a user