XWiki Platform
  1. XWiki Platform
  2. XWIKI-10805

Expose Document.isTranslation() to the web API

    Details

    • Type: Improvement Improvement
    • Status: Closed Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 6.2-milestone-1
    • Fix Version/s: 6.2-milestone-2
    • Component/s: Old Core
    • Labels:
      None
    • Difficulty:
      Trivial
    • Documentation:
      N/A
    • Similar issues:

      Description

      From the web API it is not that easy to find out if the Document instance you are holding is the main document or a translation.

      Such situations can occur when using:

      - $doc.getTranslatedDocument()
      - $xwiki.getDeletedDocument(...).getDocument()
      - etc...
      

      The new method should look something like this:

      $doc.isTranslation()
      

        Issue Links

          Activity

          There are no comments yet on this issue.

            People

            • Assignee:
              Eduard Moraru
              Reporter:
              Eduard Moraru
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: