mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2025-11-07 04:42:54 -05:00
Implement ?gotodevicername url option (#7131)
* update default.handlebars to implement gotodevicername Adding a new gotodevicername url option to reach the device page * update default3.handlebars to implement gotodevicername Adding a new gotodevicername url option to reach the device page * update mobile.handlebars to implement gotodevicername Adding a new gotodevicername url option to reach the device page --------- Co-authored-by: rida.abou <rida.abouechcharaf@pytech.it>
This commit is contained in:
@@ -2072,6 +2072,7 @@
|
||||
delete urlargs.viewmode;
|
||||
delete urlargs.gotonode;
|
||||
delete urlargs.gotodevicename;
|
||||
delete urlargs.gotodevicername;
|
||||
delete urlargs.gotodeviceip;
|
||||
delete urlargs.gotomesh;
|
||||
delete urlargs.gotouser;
|
||||
@@ -4528,7 +4529,11 @@
|
||||
var foundNode = null;
|
||||
if (nodes != null) { for (var i in nodes) { if (nodes[i].name == args.gotodevicename) { foundNode = nodes[i]._id; } } }
|
||||
if (foundNode) { gotoDevice(foundNode, xviewmode); goBackStack.push(1); }
|
||||
} else if (args.gotodeviceip != null) {
|
||||
} else if (args.gotodevicername != null) {
|
||||
var foundNode = null;
|
||||
if (nodes != null) { for (var i in nodes) { if (nodes[i].rname == args.gotodevicername) { foundNode = nodes[i]._id; } } }
|
||||
if (foundNode) { gotoDevice(foundNode, xviewmode); goBackStack.push(1); }
|
||||
else if (args.gotodeviceip != null) {
|
||||
var foundNode = null;
|
||||
if (nodes != null) { for (var i in nodes) { if (nodes[i].ip == args.gotodeviceip) { foundNode = nodes[i]._id; } } }
|
||||
if (foundNode) { gotoDevice(foundNode, xviewmode); goBackStack.push(1); }
|
||||
|
||||
Reference in New Issue
Block a user