Bug fix in documents module when rename doc with no patient assigned

bradymiller wrote on Friday, July 26, 2013:

Hi,

Here’s a proposed bug fix:

Here is details of bug:

  1. Miscellaneous->New Documents
  2. Upload a new document
  3. After uploading it, then click on the document and then rename it and then click the submit link near the rename element
  4. Note the document now disappears (because the foreign_id in documents table gets changed from 0 to NULL).
  5. The above fix basically makes it so that all documents with a foreign_id of 0 or NULL are considered documents not yet assigned to patient(so, the doc will not disappear when you rename it).

Testing well so far.

-brady
OpenEMR

bradymiller wrote on Saturday, July 27, 2013:

hi,

Above fix testing well, so committed to both master and rel-412 branches.

-brady
OpenEMR