Uploaded image for project: 'Sakai'
  1. Sakai
  2. SAK-18124

new web service - getPagesAndToolsForSite

    Details

    • Type: Task
    • Status: CLOSED
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.7.0, 2.8.0
    • Component/s: Web Services
    • Labels:
      None
    • Test Plan:
      Hide

      1. As a maintainer (user1), create a Sakai site, add some tools, use the Page order tool to hide some of those tools. Also add some tools that an access use would not have any access to (eg SiteStats).
      2. Add a user to that site with the access role (user2). Login with user2 and verify you cannot see the tools that you shouldn't be able to see.
      3. Using a web service client or manually, make a call to http://yourserver/sakai-axis/SakaiLogin.jws?wsdl and call the 'login' method with the username and password of either the admin user, or the site maintain user (user1).
      4. Note the sessionid you get back. Now make a call to http://yourserver/sakai-axis/SakaiScript.jws?wsdl and call the 'getPagesAndToolsForSite' method with that session id and the id of the site.
      5. Verify the returned XML document has all pages and tools for the site, including the hidden ones.
      6. Repeat step 3, this time with the username and password of the access user (user2) and use that sessionid for the web service call in step 4.
      7. Verify the returned XML document contains only the pages and tools that you can see in the portal view.

      Show
      1. As a maintainer (user1), create a Sakai site, add some tools, use the Page order tool to hide some of those tools. Also add some tools that an access use would not have any access to (eg SiteStats). 2. Add a user to that site with the access role (user2). Login with user2 and verify you cannot see the tools that you shouldn't be able to see. 3. Using a web service client or manually, make a call to http://yourserver/sakai-axis/SakaiLogin.jws?wsdl and call the 'login' method with the username and password of either the admin user, or the site maintain user (user1). 4. Note the sessionid you get back. Now make a call to http://yourserver/sakai-axis/SakaiScript.jws?wsdl and call the 'getPagesAndToolsForSite' method with that session id and the id of the site. 5. Verify the returned XML document has all pages and tools for the site, including the hidden ones. 6. Repeat step 3, this time with the username and password of the access user (user2) and use that sessionid for the web service call in step 4. 7. Verify the returned XML document contains only the pages and tools that you can see in the portal view.

      Description

      getPagesAndToolsForSite will retrieve an XML document of all pages on a site, as well as all tools on each page.

      All users will be able to request this information for sites they are members of.
      Super users will be able to request this info for any site.

      The pages listed will (ideally) be permission checked so that if a page is hidden to certain roles, user's in those roles don't get that information in the returned document. Since the check is on the page, the list of tools in that page will be skipped.

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  steve.swinsburg Steve Swinsburg
                  Reporter:
                  steve.swinsburg Steve Swinsburg
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  1 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:

                    Git Source Code