ASSIGNDEFAULTDASHBOARD not assigning dash

Austin Hart shared this problem 5 years ago
Resolved

Hi, Im having trouble assigning default dashes with the web service API. My call looks like this


<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:web="http://webservices.web.mi.hof.com/">

<soapenv:Header />

<soapenv:Body>

<web:remoteAdministrationCall>

<arg0>

<loginId>admin@yellowfin.com.au</loginId>

<password>test</password>

<orgId>1</orgId>

<function>ASSIGNDEFAULTDASHBOARD</function>

<group>

<groupName>Administrators</groupName>

<groupId>11950</groupId>

</group>

<contentResources>

<resourceId>72070</resourceId>

</contentResources>

</arg0>

</web:remoteAdministrationCall>

</soapenv:Body>

</soapenv:Envelope>


And this is the response


<?xml version="1.0"?>

<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">

<S:Body>

<ns2:remoteAdministrationCallResponse xmlns:ns2="http://webservices.web.mi.hof.com/">

<return>

<errorCode>0</errorCode>

<messages>Successfully Authenticated User: admin@yellowfin.com.au</messages>

<messages>Web Service Request Complete</messages>

<sessionId>e05a97500388e76cf769c908ac9bd0b2</sessionId>

<statusCode>SUCCESS</statusCode>

</return>

</ns2:remoteAdministrationCallResponse>

</S:Body>

</S:Envelope>


the response indicates that everything is working, however the default dashes assigned indicate otherwise.

/9ca4f754cac8115ad1ccbbbbdb8ce3c6

Is there anything evident that I am missing here.


P.S the group Id was retrieved with <function>GETGROUP</function>


<group>

<groupName>Administrators</groupName>

</group>


and the resourceId was retrieved with GETIDFORUUID so I am fairly confident the ids are correct

Replies (8)

photo
1

Hi Austin,

Thanks for reaching out. I don't think the issue is your web service setup, or rather I wouldn't start there. This likely has to do with the dashboard assignment workflow. To confirm this, if you try to add a default dashboard to one of your groups now from the UI instead, does it work? I'm going to guess the result will be the same.

The reason for this is that assigning dashboards can only happen in two circumstances: the users will have to have not logged in before. If they've already logged in, then whatever dashboards were present at that time are the dashboards they'll have assigned; or, the second way you can assign dashboards after user creation would be to have each user remove all their currently assigned dashboards, so that they have no dashboards and essentially start from scratch in assigning dashboards. From this point if you run the ASSIGNDEFAULTDASHBOARD web service, which ever dashboard's you choose to add should then show up for the specified users.

Please let me know how goes and if you have any other questions.

Regards,

Mike

photo
1

Hi Mike, thats good information to know. However I think youre jumping ahead a step. In my case I have not even got to the point of testing default dashboards available to users. When in the UI I can manually add default dashboards successfully.

/20220c317055f99776df52e2785e592b

However, when I add dashboards via the call in the original post, the "Assigned:" section remains blank.

I expect that I should be able to see dashboards assigned with ASSIGNDEFAULTDASHBOARD, yes?

photo
1

Hi Austin,

I did indeed jump the gun here. The code you've supplied is indeed incorrect. I've provided an attachment containing what should be a working example. However, it turns out this is not working anyways!

As such, I've gone ahead and logged a defect for this, but I'm afraid the UI option will be the only workaround at this time.

Any potential updates regarding this will be posted here.

Regards,

Mike

photo
1

Ok. Whats the timeline on something like this? Will there be a hotfix for our current version? Will this be updated in the next release?

photo
1

Hi Austin,

Support can't provide any kind of ETA or be able to indicate what build it will be in until the dev team investigates and provides feedback on their findings, but I'll keep you updated as soon as updates come along.

Regards,

Mike

photo
1

Hello,

I have taken over support of the pipeline that consumes this webservice on our side. Ultimately I came full circle on this issue after a fair bit of troubleshooting. Is there any update here?Also, it appears exceptions are not thrown and the service says it is successful when it is not. I think it would be better if there was a global exception handler of some sort that makes it clear when a web service call fails. The silent failure with success message is what really makes this difficult to triage.

Please provide the latest updates on this issue, and whether or not future builds have corrected it.

Thanks,

Travis

photo
1

Hi Travis,

Thanks for reaching out. I agree that the error logging should be more robust, that would certainly help us as well. I should note though that if you want more behind-the-scenes details such as, for example, what SQL queries are being run, you can enable DEBUG logging. You can read how to do that here.

That said, there's no updates on this task as of yet, but I've gone ahead and requested one. I'll keep you posted.

Regards,

Mike

photo
photo
1

Hi Austin/Travis,

It turns out this works, the Wiki was just missing info. The corresponding Wiki entry has been updated, which you can reference here.

To specifically point out the changes though, the following was added under 'ASSIGNDEFAULTDASHBOARD':

  • added a new row to the ContentResource Element table called ResourceType
  • in the SOAP request code example, added the line <ResourceType>GROUP</ResourceType>
  • under 'Step-by-step instructions', in the code example for 'Use the ContentResources object to specify a dashboard', added 'dashboardContentResource.setResourceType("GROUP");'
  • also added 'dashboardContentResource.setResourceType("GROUP");' to the complete code example
  • added the missing %> to the end of the complete code example

Please follow the updated instructions and confirm whether this is now working for you.

Thanks,

Mike

photo
1

Hi Austin,

I just wanted to check in and see if you've had the chance to test this with new parameters added in yet.

Regards,

Mike

photo
1

Hi Austin,

I'm going to go ahead and mark this one as Resolved since I haven't heard back from you, and believe the remaining provided details will get this resolved for you, but if you have further questions or concerns on this, if you respond, it will re-open the case and put it back in my queue and I'll be happy to help.

Regards,

Mike

photo
1

Hi Mike,

I apologize for not responding. Austin is no longer with our organization and I didn't stay on top of this piece. I can say that we got this working however there is one slight issue with the documentation on the Wiki:

https://wiki.yellowfinbi.com/pages/viewpage.action?pageId=20709809

This was added to the <contentResources> section:

<ResourceType>GROUP</ResourceType>
However, the R should be lower case:

<resourceType>GROUP</resourceType>
Once we did that, everything is working as expected.

Thank you so much for the help!

photo
1

Hi Ryan,

Thanks for letting us know! I've reached out to the appropriate party to change this.

Considering this is now resolved I'll go ahead and close this case out, but please don't hesitate to reach out with any other questions or concerns.

Regards,

Mike

Leave a Comment
 
Attach a file