Uploaded image for project: 'Liferay Apps'
  1. Liferay Apps
  2. LRA-154

Update Google Drive back end code

    XMLWordPrintable

    Details

      Description

      1. Need to be careful with throwing exceptions from the controller class. Instead of throwing exceptions, we need to handle it and put them as SessionErrors so the front end can show appropriate error messages. So, please update exception handling logic in the controller class. Rather than having just error logged, please add proper SessionError so proper error messages can be shown in the front end when the user is redirected to the target page
      2. Please update the logic in the following code. Search container will throw exception if the results is null (it doesn't happen in the current logic, but we need to be careful though). Instead of calling the service directly from UI, please have it passed from the doView method in the controller class so we can handle exception (including null check) properly and show proper error messages to the users just in case of any errors.
      view.jsp, lines from 46 to 50
      <liferay-ui:search-container-results
          total="<%=DriveLinksLocalServiceUtil.userDriveLinksCount(userId)%>"
          results="<%=DriveLinksLocalServiceUtil.userDriveLinks(userId,
      searchContainer.getStart(),searchContainer.getEnd()) %>"
      />

        Attachments

          Activity

            People

            • Assignee:
              mcalvo mcalvo
              Reporter:
              djkim Dong-Jun Kim [X] (Inactive)
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Zendesk Support