Announcement

Collapse
No announcement yet.

Mirth filter by date

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Mirth filter by date

    hello mirth
    I am novice in Mirth 3.5.
    I create a channel that reads a database (openmrs) and translates it to HL7 in a file.
    in the filter -destination part I write this javascript code, to receive only new patients (by date)
    Code:
    var dd = DateUtil.getCurrentDate("MMddyyyyHHmmss");
    var  A02 = $(‘date_created’);
    var  A011 = $(‘date_changed’)
    if A02 = dd || A011 = DD
    {
    return true;
    }
    else
    {
    return false;
    }
    Thanks for your help

  • #2
    What do you wish to know?

    Comment


    • #3
      Hello,

      try to change this line:

      if A02 = dd || A011 = DD

      for this

      if (A02 == dd || A011 == DD)

      Hope this helps,

      RB

      Comment

      Working...
      X