Uploaded image for project: 'PhenoTips'
  1. PT-1304

When a patient is created through velocity unknown component adds a meaningless doc version

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Medium
    • Resolution: Cannot Reproduce
    • Affects versions: None
    • Fix versions: None
    • Components: None
    • Labels:
      None
    • Sprint:
    • External issue ID:
      1304

      Description

      Not sure if velocity is required, but this does not happen when a new patient is added through UI:

      The velocity code is:

      #set ($p = $services.patients.createNewPatient())
      #set ($d = $xwiki.getDocument($p.document))
      #set ($o = $d.getObject('PhenoTips.PatientClass'))
      #set ($discard = $o.set('external_id', ...))
      ...
      $d.save("modification X")

      Running the code creates a patient, and patient's history has 3 versions:

      1.1 is blank,
      1.2 has all the changes the script is supposed to do and the comment is as expected ("modification X")
      1.3 is identical to 1.2 and has no comments

        Attachments

          Issue links

            Activity

              People

              • Assignee:
                sdumitriu Sergiu Dumitriu
                Reporter:
                asm Andrew Misyura
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: