address copilot comments

This commit is contained in:
Pearl Dsilva 2026-02-09 15:43:55 -05:00
parent 6ea054cb01
commit 425d8c7e70
4 changed files with 7 additions and 7 deletions

View File

@ -48,7 +48,7 @@ import java.util.function.LongFunction;
@APICommand(name = "cloneBackupOffering",
description = "Clones a backup offering from an existing offering",
responseObject = BackupOfferingResponse.class, since = "4.14.0",
responseObject = BackupOfferingResponse.class, since = "4.23.0",
authorized = {RoleType.Admin})
public class CloneBackupOfferingCmd extends BaseAsyncCmd implements DomainAndZoneIdResolver {
@ -63,7 +63,7 @@ public class CloneBackupOfferingCmd extends BaseAsyncCmd implements DomainAndZon
required = true, description = "The ID of the source backup offering to clone from")
private Long sourceOfferingId;
@Parameter(name = ApiConstants.NAME, type = BaseCmd.CommandType.STRING, required = false,
@Parameter(name = ApiConstants.NAME, type = BaseCmd.CommandType.STRING, required = true,
description = "The name of the cloned offering")
private String name;

View File

@ -955,7 +955,7 @@ public class VpcManagerImpl extends ManagerBase implements VpcManager, VpcProvis
}
normalizedDropServices.add(service.getName());
}
finalServices.removeAll(dropServices);
finalServices.removeAll(normalizedDropServices);
logger.debug("Dropped services from clone: {}", dropServices);
}

View File

@ -420,7 +420,7 @@ export default {
}
},
handleWriteCacheTypeChange (val) {
this.form.writeCacheType = val
this.form.writecachetype = val
},
isDomainAdmin () {
return ['DomainAdmin'].includes(this.$store.getters.userInfo.roletype)

View File

@ -68,7 +68,7 @@ import DetailsInput from '@/components/widgets/DetailsInput'
import store from '@/store'
export default {
name: 'CreateComputeOffering',
name: 'CloneComputeOffering',
mixins: [mixinForm],
components: {
ComputeOfferingForm,
@ -404,7 +404,7 @@ export default {
}).then(json => {
this.diskOfferings = json.listdiskofferingsresponse.diskoffering || []
if (this.selectedDiskOfferingId === '') {
this.selectedDiskOfferingId = this.diskOfferings[0].id || ''
this.selectedDiskOfferingId = this.diskOfferings?.[0]?.id || ''
}
}).finally(() => {
this.diskOfferingLoading = false
@ -636,7 +636,7 @@ export default {
}
params.sourceofferingid = this.resource.id
this.loading = true
postAPI('cloneServiceOffering', params).then(json => {
const message = this.isSystem
? `${this.$t('message.clone.service.offering')}: `