• If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Announcement

Collapse
No announcement yet.

URL Widget to allow system variables

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • URL Widget to allow system variables

    When you define a URL widget kindly consider supporting system defined substitution values such as:

    IBM i host name
    Valence User (could be IBM i profile or Valence profile)
    Environment Name

    There are cases where you launch a URL and it may reference:
    host name (IBM i system)
    User ID (current logged in user)
    Environment Name or ID

    eg. http://<HOST>:8014/cgidev2p/program.pgm?user=<USER>&environment=<ENV>

    It would be useful if it was possible to reference Valence system defined variables. Consider allowing the customer to set their own system values. These values should be made available as references within the URL.

    Benefit.
    Provide greater flexibility.

    Helps to eliminate hard-coded URLs or the need to create multiple URL widgets where the host name or user is referenced as an argument.

    Provides improved environment management. Define URL once to cover multiple environments..

  • #2
    Hi Jim -

    We will put this on our to-do list for the URL Widget in NAB. We already allow for this with the "Launch App/URL" behavior in case that provides you any help now.

    Here is a link to those docs: https://valence6.helpdocsonline.com/nab-launch-app

    An app variable is already created for the current user (nabUser) which can be used as part of your URL. You can create your own custom app variables (environment, hostName, etc...) and then set those values via "SetAppVar" in a startup application.

    Comment


    • #3
      Sean,

      Ideally it would be best if Valence made available system variables eliminating the need for developers to prepare same.

      A System variable such as hostName (SQL current server) would benefit the Developer community or better still, the ability to set a system variable based on the result of an SQL statement (eg select current server from sysibm/sysdummy1). This would be a powerful and flexible method of setting values without coding.

      Can you share a link to view a documented list of current Valence System variables.

      Thanks

      Comment


      • #4
        Hi Jim -

        Our todo list does contain the ability to map a Valence setting to an SQL statement....likely in the form of vvIn_setting('SOME_SETTING_VALUE').

        The full list of settings are currently listed in file VVSETTINGS.

        Comment

        Working...
        X