Sha256: 08786e384e322b80e7d55387185b0c3378f2d71c992c8216c45c8901db015546

Contents?: true

Size: 979 Bytes

Versions: 5

Compression:

Stored size: 979 Bytes

Contents

  var events = patient.<%= patient_api_method(criteria) %>();
  <%- if criteria.specific_occurrence -%>
  events.specific_occurrence = '<%= criteria.source_data_criteria %>'
  <%- end -%>
<%- if criteria.status -%>
  events = events.withStatuses(["<%= criteria.status %>"]<%= ", false" if criteria.hard_status %>);
<%- end -%>
<%- if criteria.negation -%>
  events = events.withNegation(<%= "getCodes(\"#{criteria.negation_code_list_id}\")" if criteria.negation_code_list_id %>);
<%- else -%>
  events = events.withoutNegation();
<%- end -%>
  var codes = <%= js_for_code_list(criteria) %>;
  var start = null;
  var end = null;
<%- if criteria.effective_time -%>
  <%- startExp = js_for_value(criteria.effective_time.low) -%>
  start = <%= startExp %><%= '.asDate()' if startExp != 'null' %>;
  <%- endExp = js_for_value(criteria.effective_time.high) -%>
  end = <%= endExp %><%= '.asDate()' if endExp != 'null' %>;
<%- end -%>
  events = events.match(codes, start, end, true);

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
hqmf2js-1.2.1 lib/generator/patient_data.js.erb
hqmf2js-1.2.0 lib/generator/patient_data.js.erb
hqmf2js-1.1.0 lib/generator/patient_data.js.erb
hqmf2js-1.0.1 lib/generator/patient_data.js.erb
hqmf2js-1.0.0 lib/generator/patient_data.js.erb