cancel
Showing results for 
Search instead for 
Did you mean: 

SUp 2.1 HWC - Custom.js - read user credentials

Aksel
Participant
0 Kudos

Hi folks,

a small question, maybe there is also such a small answer available...

I wondering how to get the SUPUsername written to a key?

I was trying something like this in Custom.js, method customAfterWorkflowLoad()

(uname is the key/field to show)


var user = document.getElementById("uname");
var supUserName = getURLParam("supusername");
        if(supUserName){
            user.value = supUserName;
        } 

getURLParam("supusername") does not work...

Any Idea?

Regards,

Aksel

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi,

I had tried to to read supUserName in the method customAfterShowScreen, and it is working fine.

Can you try to read that in this method?

Regards,

Edison

former_member186566
Active Participant
0 Kudos

Hi

Any one found answer for the above query? Pls share if you have any.

In 2.2 there is a library file hwc-api.js which helps to get and process the whole connection settings through workflow packages like username, password, port etc.

http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc01853.0220/doc/html/vhu13...

So, I hope there should be some way to get the HWC user details from SUP2.1.3. I have checked api.js and utils.js which only specifies "supusername" and this also for credential based workflow app.

If any one solved this, pls share with us.

Regards

Yokesvaran.k

Dan_vL
Product and Topic Expert
Product and Topic Expert
0 Kudos

The following sample may be helpful.

Credentials in a Mobile Workflow  https://cw.sdn.sap.com/cw/docs/DOC-149768

Former Member
0 Kudos

Did you get any solution for this?

Regards,

Pavan

former_member186566
Active Participant
0 Kudos

Hi Pavan,

I found solution for this post.

We had situation to pass username, Application name, Device name and its type etc to an operation. Do the below steps to pass these parameters.

  1. Open the Workflow form editior.
  2. Select the screen in which you want to pass parameters in Flow Design.
  3. Open as Screen Design
  4. Select the required operation in Menu box.
  5. Goto the property screen -> Parameter mappings
  6. Select a parameter name->edit
  7. By default "Mapping type" will be "Key" mode, You can also select other mapping type like Username. Please refer the screen shot attached

Not only username, you can also select BackendUsername, BackendPassword, DeviceId, Devicetype, MessageId, ModuleName, ModuleVersion, QueueId etc.

I hope this will help you. All the best.

Regards

Yokesvaran Kumarasamy

Former Member
0 Kudos

Thanks a lot Yokesvaran. This helped .

Regards,

Pavan

former_member186566
Active Participant
0 Kudos

Hi Pavan,

Good to hear that.

Regards

Yokesvaran Kumarasamy

Ian_Thain
Developer Advocate
Developer Advocate
0 Kudos

Can you try "supuser" ?

Ian