From 904c66c94909a1eb8760b498a1dac64f92af608b Mon Sep 17 00:00:00 2001 From: zwx1126739 Date: Wed, 16 Oct 2024 16:30:35 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=A4=87=E5=BF=98=E5=BD=95js?= =?UTF-8?q?crash?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: zwx1126739 --- common/utils/src/main/ets/default/baseUtil/FolderUtil.ets | 6 +++--- features/src/main/ets/components/CusDialogComp.ets | 8 ++++---- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/common/utils/src/main/ets/default/baseUtil/FolderUtil.ets b/common/utils/src/main/ets/default/baseUtil/FolderUtil.ets index 966f414..22b8596 100644 --- a/common/utils/src/main/ets/default/baseUtil/FolderUtil.ets +++ b/common/utils/src/main/ets/default/baseUtil/FolderUtil.ets @@ -121,10 +121,10 @@ export class FolderUtil { } if (folderData!.uuid === undefined || folderData!.uuid === null) { LogUtil.info(TAG, "isFolderMoveIn folderData uuid undefined") - folderData.uuid = 'sys_def_unClassified_uuid'; + folderData!.uuid = 'sys_def_unClassified_uuid'; } - LogUtil.info(TAG, "isFolderMoveIn folderDataUuid " + folderData.uuid) - return (folderData.uuid == SysDefFolderUuid.UnClassified || folderData.folder_type == FolderType.CusDef) + LogUtil.info(TAG, "isFolderMoveIn folderDataUuid " + folderData!.uuid); + return (folderData!.uuid == SysDefFolderUuid.UnClassified || folderData!.folder_type == FolderType.CusDef); } /** diff --git a/features/src/main/ets/components/CusDialogComp.ets b/features/src/main/ets/components/CusDialogComp.ets index 2d8372c..0fc5e37 100644 --- a/features/src/main/ets/components/CusDialogComp.ets +++ b/features/src/main/ets/components/CusDialogComp.ets @@ -280,18 +280,18 @@ struct NoteDataMoveItemComp { build() { Flex({ alignItems: ItemAlign.Center, wrap: FlexWrap.NoWrap }) { Flex({ alignItems: ItemAlign.Center, wrap: FlexWrap.NoWrap }) { - Image(FolderUtil.getFolderIcon(this.folderItem.uuid)) + Image(FolderUtil.getFolderIcon(this.folderItem!.uuid)) .objectFit(ImageFit.Fill) .width(24) .height(24) .flexShrink(0) - .fillColor(FolderUtil.getFolderIconColor(this.AllFolderArray, this.folderItem.uuid, false)) + .fillColor(FolderUtil.getFolderIconColor(this.AllFolderArray, this.folderItem!.uuid, false)) } .width(24) Column() { Flex({ alignItems: ItemAlign.Center, wrap: FlexWrap.NoWrap, justifyContent: FlexAlign.SpaceBetween }) { - Text(FolderUtil.getFolderText(this.folderItem)) + Text(FolderUtil.getFolderText(this.folderItem!)) .fontSize(16) .textAlign(TextAlign.Center) .maxLines(1) @@ -299,7 +299,7 @@ struct NoteDataMoveItemComp { .flexShrink(1) .fontWeight(FontWeight.Medium) Image((FolderUtil.getCommonFolder(this.AllFolderArray, this.CheckedNoteArray) == null - || FolderUtil.getCommonFolder(this.AllFolderArray, this.CheckedNoteArray) != this.folderItem) ? $r("app.media.foldMove_unselect") : $r("app.media.foldMove_select")) + || FolderUtil.getCommonFolder(this.AllFolderArray, this.CheckedNoteArray) != this.folderItem!) ? $r("app.media.foldMove_unselect") : $r("app.media.foldMove_select")) .objectFit(ImageFit.Fill) .width(24) .height(24) -- Gitee