mirror of
https://git.proxmox.com/git/pve-manager
synced 2025-08-05 09:07:19 +00:00
use correct vmid for id when in vm replication panel
values.guest is only available when the field 'guest' is not a displayfield (e.g. when in vm replication panel), so we have to use the given vmid first and only when this is not available, fall back to the value of the field Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
This commit is contained in:
parent
701acf208a
commit
de2022b85c
@ -67,12 +67,13 @@ Ext.define('PVE.window.ReplicaEdit', {
|
||||
|
||||
if (me.isCreate) {
|
||||
values.type = 'local';
|
||||
var vm = vmid || values.guest;
|
||||
var id = -1;
|
||||
if (me.highestids[values.guest] !== undefined) {
|
||||
id = me.highestids[values.guest];
|
||||
if (me.highestids[vm] !== undefined) {
|
||||
id = me.highestids[vm];
|
||||
}
|
||||
id++;
|
||||
values.id = values.guest + '-' + id.toString();
|
||||
values.id = vm + '-' + id.toString();
|
||||
delete values.guest;
|
||||
}
|
||||
return values;
|
||||
|
Loading…
Reference in New Issue
Block a user