MCPcopy Create free account
hub / github.com/devnullvoid/pvetui / IsVMPending

Method IsVMPending

internal/ui/models/state.go:352–360  ·  view source on GitHub ↗

IsVMPending checks if a VM has a pending operation.

(vm *api.VM)

Source from the content-addressed store, hash-verified

350
351// IsVMPending checks if a VM has a pending operation.
352func (s *State) IsVMPending(vm *api.VM) (bool, string) {
353 s.pendingMutex.RLock()
354 defer s.pendingMutex.RUnlock()
355
356 key := fmt.Sprintf("%s:%d", vm.Node, vm.ID)
357 operation, exists := s.PendingVMOperations[key]
358
359 return exists, operation
360}
361
362// SetNodePending marks a node as having a pending operation.
363func (s *State) SetNodePending(node *api.Node, operation string) {

Callers 14

CanVMPerformActionsMethod · 0.95
GetVMPendingOperationMethod · 0.95
setupKeyboardHandlersMethod · 0.80
doRefreshVMDataMethod · 0.80
showMigrationDialogMethod · 0.80
NewVMConfigPageFunction · 0.80
showResizeStorageModalFunction · 0.80
createSnapshotMethod · 0.80
deleteSnapshotMethod · 0.80
rollbackSnapshotMethod · 0.80
SetVMsMethod · 0.80
createBackupMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected