2 Replies Latest reply: Jun 11, 2013 5:19 AM by Micael Leal RSS

    PHP/SOAP QMSAPI:Document Administrator



      I've been looking up the QMSAPIDocumentation.chm to find the appropriate method which allows me to modify the document administrator for a particular, but I don't seem to find the needed class or method nor the property. I'm trying to access it with PHP, SOAP.


      I found out how to change the document access but not the folder path access. Here: http://community.qlik.com/message/104179#104179


      The reason why I'd like to do it, is that I have some domain users which can read multiple QVW files if they got the rights, but I'd like also to create project domain admins, which actually have access on different folder path and are allowed to be admin of one group of domain users.


      So far the starting point seems to be DocumentFolder.DocumentFolderAdministrator.Usernames.


      But I don't find an example in that API how to adress the username or to set it or eventually retrieve all current usernames.


      Funny thing, they wrote UserNames as property, but it doesn't exist in the Webservice .... when I do a var_dump ...


      So far, what I could find was to access on different properties.


      With :




      I can retrieve the same information like in the QMS API Document when you search DocumentFolder all members









      Now, when I try to do


                      $qlikviewUserDocumentFoldersTmp = $this->client->GetUserDocumentFolders(array('qvsID' => $this->qlikviewServerInfo->ServiceInfo->ID, 'scope' => 'General'))->GetUserDocumentFoldersResult->DocumentFolder;


                      foreach($qlikviewUserDocumentFoldersTmp as $folder)


                                        $myDocFolder = $this->client->GetDocumentFolder(array('id' => $folder->ID, 'scope' => 'General'));



                                        //$this->client->GetUserDocumentFolders(array('qvsID' => $this->qlikviewServerInfo->ServiceInfo->ID, 'scope' => 'General'))->GetUserDocumentFoldersResult->DocumentFolder[$tmp]->Administrators=array('vh610','ah631');





      Where $tmp is being increased in a loop.


      And now I execute again:




      In fact, I can see the 2 administrators as output, but they aren't saved in




      System->Setup->Management Service->Distribution Services->General->Document Administrators but it doesn't add it there




      System->Setup->Management Service->QlikView Servers->Folder Access->Supervisors or Document Administrators


      Please, someone could help me out? I'm trying to find a solution for 2 weeks


      Hope someone could help me out.



        • Re: PHP/SOAP QMSAPI:Document Administrator

          I actually can now access its properties, but still cannot save it.





          It prints me with




          All exisiting administrators for one mounted folder, but if I try to modify it, the QMS doesn't takes it into account.


          If in the QMC I try to add a new admin for a document, I've to press "Apply", is there a similar functionality for the QMS API?

            • Re: PHP/SOAP QMSAPI:Document Administrator

              Finally found the solution.... It adds 1 folder administrator at the moment, looking forward how to add multiple user administrators.


                              $myqlikviewQVSSettings = new stdClass();

                              $myqlikviewQVSSettings = $this->client->GetQVSSettings(array('qvsID' => $this->qlikviewServerInfo->ServiceInfo->ID, 'scope' => 'Logging'))->GetQVSSettingsResult;

                              $myqlikviewQVSSettings->Cluster = $this->getQVSSettings()->Cluster;

                              $myqlikviewQVSSettings->Distribution =$this->getQVSSettings()->Distribution;

                              $myqlikviewQVSSettings->Documents = $this->getQVSSettings()->Documents;

                              $myqlikviewQVSSettings->Folders = $this->getQVSSettings()->Folders;

                               // Here you should select which folder you want to change!


                              $myqlikviewQVSSettings->General = $this->getQVSSettings()->General;

                              $myqlikviewQVSSettings->Logging = $this->getQVSSettings()->Logging;


                              $myqlikviewQVSSettings->QVSID = $this->getQVSSettings()->QVSID;



                              //var_dump($this->getQVSSettings()); //prints all properties

                              //Save the QVSSettings

                              $this->client->SaveQVSSettings(array('qvsSettings' => $myqlikviewQVSSettings));


              Hope this might help one day, someone who'll be using SOAP wtih PHP instead of C#.