style: 系统快照恢复样式调整 (#3845)

pull/3856/head
ssongliu 10 months ago committed by GitHub
parent fb06e29aa3
commit ece2cb433d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -330,7 +330,7 @@ var UpdateCronjobSpec = &gormigrate.Migration{
Source: snap.From, Source: snap.From,
BackupType: snap.From, BackupType: snap.From,
BaseModel: model.BaseModel{ BaseModel: model.BaseModel{
CreatedAt: job.CreatedAt, CreatedAt: record.CreatedAt,
}, },
} }
_ = tx.Create(&item).Error _ = tx.Create(&item).Error
@ -348,7 +348,7 @@ var UpdateCronjobSpec = &gormigrate.Migration{
Source: mapAccount[uint(job.TargetDirID)].Type, Source: mapAccount[uint(job.TargetDirID)].Type,
BackupType: mapAccount[uint(job.TargetDirID)].Type, BackupType: mapAccount[uint(job.TargetDirID)].Type,
BaseModel: model.BaseModel{ BaseModel: model.BaseModel{
CreatedAt: job.CreatedAt, CreatedAt: record.CreatedAt,
}, },
} }
_ = tx.Create(&item).Error _ = tx.Create(&item).Error
@ -364,7 +364,7 @@ var UpdateCronjobSpec = &gormigrate.Migration{
FileName: path.Base(record.File), FileName: path.Base(record.File),
BackupType: mapAccount[uint(job.TargetDirID)].Type, BackupType: mapAccount[uint(job.TargetDirID)].Type,
BaseModel: model.BaseModel{ BaseModel: model.BaseModel{
CreatedAt: job.CreatedAt, CreatedAt: record.CreatedAt,
}, },
} }
if record.FromLocal { if record.FromLocal {

@ -48,13 +48,6 @@
<el-tag type="info" v-if="snapInfo.recoverStatus === 'Waiting'"> <el-tag type="info" v-if="snapInfo.recoverStatus === 'Waiting'">
{{ $t('commons.table.statusWaiting') }} {{ $t('commons.table.statusWaiting') }}
</el-tag> </el-tag>
<!-- <el-button
style="margin-left: 15px"
@click="recoverSnapshot(true)"
:disabled="snapInfo.recoverStatus !== 'Success'"
>
{{ $t('setting.recover') }}
</el-button> -->
</el-form-item> </el-form-item>
<el-form-item <el-form-item
:label="$t('setting.lastRecoverAt')" :label="$t('setting.lastRecoverAt')"
@ -77,6 +70,7 @@
</div> </div>
</el-card> </el-card>
<div v-if="snapInfo.recoverStatus === 'Failed'">
<span class="card-title">{{ $t('setting.rollback') }}</span> <span class="card-title">{{ $t('setting.rollback') }}</span>
<el-divider class="divider" /> <el-divider class="divider" />
<div v-if="!snapInfo.rollbackStatus && !snapInfo.lastRollbackedAt"> <div v-if="!snapInfo.rollbackStatus && !snapInfo.lastRollbackedAt">
@ -139,6 +133,7 @@
</el-form-item> </el-form-item>
</div> </div>
</div> </div>
</div>
</el-col> </el-col>
</el-row> </el-row>
</el-form> </el-form>

Loading…
Cancel
Save