修复文件管理字节转换的问题

This commit is contained in:
fangxiang 2022-12-02 18:01:20 +08:00
parent e9de33ef21
commit f133eae00e
1 changed files with 1 additions and 1 deletions

View File

@ -578,7 +578,7 @@ export default defineComponent({
align: "center", align: "center",
label: $t.t("file size"), label: $t.t("file size"),
field: (val: FileEntity) => field: (val: FileEntity) =>
val.is_directory ? null : Math.ceil((val ? val.file_size : 0) / 1000), val.is_directory ? null : Math.ceil((val ? val.file_size : 0) / 1024),
format: (val: any) => (val != null ? `${val} KB` : ""), format: (val: any) => (val != null ? `${val} KB` : ""),
sortable: true, sortable: true,
}, },