IBM Worklight - How to set default values for the

2019-09-02 12:54发布

I have deployed IBM Worklight Application Center on WebSphere Liberty profile. I have then also installed the client app in my mobile device. However, the first time I open the client it asks for server login details, such as: username, password, server address, port, context, etc.

I would like to know if it is possible to fill the server and port fields with default values.

1条回答
男人必须洒脱
2楼-- · 2019-09-02 13:06

Yes, it is possible. You have several ways to handle what you're asking for.

  1. Since you also have the project source code, you can customize it. That is, alter the HTML so that the text fields will contain default values.

  2. It is also possible to customize these values using a config.json file in the App Center's Worklight project:

    url
    The hardcoded address of the Application Center server. If this property is set, the address fields of the Login view are not displayed.

    defaultPort
    If the url property is null, this property prefills the port field of the Login view on a phone. This is a default value; the field can be edited by the user.

    defaultContext
    If the url property is null, this property prefills the context field of the Login view on a phone. This is a default value; the field can be edited by the user.

You can read more here:

查看更多
登录 后发表回答