mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2025-03-09 15:40:18 +00:00
Added meshcore string translations.
This commit is contained in:
parent
01dbc70098
commit
5fa5cf5cb5
8 changed files with 470 additions and 386 deletions
|
@ -3243,7 +3243,7 @@ function processConsoleCommand(cmd, args, rights, sessionid) {
|
|||
var response = null;
|
||||
switch (cmd) {
|
||||
case 'help': { // Displays available commands
|
||||
var fin = '', f = '', availcommands = 'agentupdate,errorlog,msh,timerinfo,coreinfo,coredump,service,fdsnapshot,fdcount,startupoptions,alert,agentsize,versions,help,info,osinfo,args,print,type,dbkeys,dbget,dbset,dbcompact,eval,parseuri,httpget,wslist,plugin,wsconnect,wssend,wsclose,notify,ls,ps,kill,netinfo,location,power,wakeonlan,setdebug,smbios,rawsmbios,toast,lock,users,openurl,getscript,getclip,setclip,log,av,cpuinfo,sysinfo,apf,scanwifi,wallpaper,agentmsg,task';
|
||||
var fin = '', f = '', availcommands = 'translations,agentupdate,errorlog,msh,timerinfo,coreinfo,coredump,service,fdsnapshot,fdcount,startupoptions,alert,agentsize,versions,help,info,osinfo,args,print,type,dbkeys,dbget,dbset,dbcompact,eval,parseuri,httpget,wslist,plugin,wsconnect,wssend,wsclose,notify,ls,ps,kill,netinfo,location,power,wakeonlan,setdebug,smbios,rawsmbios,toast,lock,users,openurl,getscript,getclip,setclip,log,av,cpuinfo,sysinfo,apf,scanwifi,wallpaper,agentmsg,task';
|
||||
if (require('os').dns != null) { availcommands += ',dnsinfo'; }
|
||||
try { require('linux-dhcp'); availcommands += ',dhcp'; } catch (e) { }
|
||||
if (process.platform == 'win32') { availcommands += ',cs,safemode,wpfhwacceleration,uac'; }
|
||||
|
@ -3261,6 +3261,10 @@ function processConsoleCommand(cmd, args, rights, sessionid) {
|
|||
response = "Available commands: \r\n" + fin + ".";
|
||||
break;
|
||||
}
|
||||
case 'translations': {
|
||||
response = JSON.stringify(coretranslations);
|
||||
break;
|
||||
}
|
||||
case 'dhcp': // This command is only supported on Linux, this is because Linux does not give us the DNS suffix for each network adapter independently so we have to ask the DHCP server.
|
||||
{
|
||||
try { require('linux-dhcp'); } catch (e) { response = 'Unknown command "dhcp", type "help" for list of avaialble commands.'; break; }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue