fix: 修改计划任务下载判断 (#2284)

This commit is contained in:
ssongliu 2023-09-14 10:54:17 +08:00 committed by GitHub
parent 279f8f0e6c
commit 5c0fb405d0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View file

@ -148,7 +148,7 @@ func RemoveRepeatElement(a interface{}) (ret []interface{}) {
func LoadSizeUnit(value float64) string {
if value > 1073741824 {
return fmt.Sprintf("%.2fM", value/1073741824)
return fmt.Sprintf("%.2fG", value/1073741824)
}
if value > 1048576 {
return fmt.Sprintf("%.2fM", value/1048576)

View file

@ -599,7 +599,7 @@ const onDownload = async (record: any, backupID: number) => {
type = i18n.global.t('website.website');
break;
}
if (currentRecord.value.file.indexOf(',') !== 0) {
if (currentRecord.value.file.indexOf(',') !== -1) {
MsgInfo(i18n.global.t('cronjob.allOptionHelper', [type]));
return;
}