SysSingleton GetSystemUrl
No edit summary
(Automatically adding template at the end of the page.)
 
(8 intermediate revisions by 4 users not shown)
Line 1: Line 1:
By adding this method to your SysSingleton and marking it with Eco.ExternalLateBound=anyvalue you can get access to the running turnkey system's url address:
Adding this method to your SysSingleton and marking it with Eco.ExternalLateBound=anyvalue can give you access to the running Turnkey system's URL address:
  SysSingleton.GetSystemUrl():string
  SysSingleton.GetSystemUrl():string
[[File:2018-08-06 21h32 08.png|none|thumb|1000x1000px|x]]
[[File:2018-08-06 21h32 08.png|none|thumb|1000x1000px|x]]
Making the method "IsQuery" makes it available in ocl (not only action language) - and you can write things like this:
Making the method "IsQuery" makes it available in OCL (not only action language) - and you can write things like this:
  SysSingleton.oclSingleton.GetSystemUrl()+ '/SiteAssets/ProjectReportTemplate.odt'
  SysSingleton.oclSingleton.GetSystemUrl()+ '/SiteAssets/ProjectReportTemplate.odt'
...this will fully qualify the address to a report template found in SiteAssets.
...this will fully qualify the address to a report template found in SiteAssets.


Or maybe you need an QRImage with a fully qualified url back to your system:
Or maybe you need a QRImage with a fully qualified URL back to your system:
  ZXing.QRImage(300,300,SysSingleton.oclSingleton.GetSystemUrl()+
  ZXing.QRImage(300,300,SysSingleton.oclSingleton.GetSystemUrl()+
       '/Turnkey/AngularApp#/ToolInfo/'+self.Guid.asstring)
       '/Turnkey/AngularApp#/ToolInfo/'+self.Guid.asstring)


Please note that this is the URL of the TurnKeyserver. Thus is an action originating from TurnKey needed to set the URL, this action may be if needed to persist for server-side jobs or SysAsync tickets running on MDrivenServer.
Please note that this is the URL of the TurnKeyserver. Thus, an action originating from TurnKey needs to set the URL. This action may be necessary to persist the address for server-side jobs or SysAsync tickets running on MDrivenServer.
 
Note that this function (and all ExternalLateBound ) are only available at the TunrkeyLevel - not the MDrivenServer level.
 
''Maybe you searched for GetServerUrl - but the name is GetSystemUrl (Leave this for better indexing).''
 
==== Additional methods ExternalLateBound method on SysSingelton ====
Additional methods ExternalLateBound method on SysSingelton as SHA512ComputeHash, SHA256ComputeHash and BitConverterToString are found here: [[SHA512ComputeHash, SHA256ComputeHash and BitConverterToString]]
[[Category:MDriven Turnkey]]
[[Category:MDriven Server]]
{{Edited|July|12|2024}}

Latest revision as of 15:47, 10 February 2024

Adding this method to your SysSingleton and marking it with Eco.ExternalLateBound=anyvalue can give you access to the running Turnkey system's URL address:

SysSingleton.GetSystemUrl():string
x

Making the method "IsQuery" makes it available in OCL (not only action language) - and you can write things like this:

SysSingleton.oclSingleton.GetSystemUrl()+ '/SiteAssets/ProjectReportTemplate.odt'

...this will fully qualify the address to a report template found in SiteAssets.

Or maybe you need a QRImage with a fully qualified URL back to your system:

ZXing.QRImage(300,300,SysSingleton.oclSingleton.GetSystemUrl()+
     '/Turnkey/AngularApp#/ToolInfo/'+self.Guid.asstring)

Please note that this is the URL of the TurnKeyserver. Thus, an action originating from TurnKey needs to set the URL. This action may be necessary to persist the address for server-side jobs or SysAsync tickets running on MDrivenServer.

Note that this function (and all ExternalLateBound ) are only available at the TunrkeyLevel - not the MDrivenServer level.

Maybe you searched for GetServerUrl - but the name is GetSystemUrl (Leave this for better indexing).

Additional methods ExternalLateBound method on SysSingelton

Additional methods ExternalLateBound method on SysSingelton as SHA512ComputeHash, SHA256ComputeHash and BitConverterToString are found here: SHA512ComputeHash, SHA256ComputeHash and BitConverterToString

This page was edited 89 days ago on 02/10/2024. What links here