From 08e1e074f361abb9a703171b78ba272215647ce6 Mon Sep 17 00:00:00 2001 From: agravell047 Date: Thu, 25 Apr 2024 10:54:30 -0400 Subject: [PATCH] updated name logic --- .../my_health/app/helpers/my_health/prescription_helper.rb | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/modules/my_health/app/helpers/my_health/prescription_helper.rb b/modules/my_health/app/helpers/my_health/prescription_helper.rb index 2ce53492f63..a5f521cad69 100644 --- a/modules/my_health/app/helpers/my_health/prescription_helper.rb +++ b/modules/my_health/app/helpers/my_health/prescription_helper.rb @@ -67,10 +67,12 @@ def get_field_data(field, data) when /dispensed_date/ data[:sorted_dispensed_date] when 'prescription_name' - if data.disp_status != 'Active: Non-VA' || data.prescription_name + if data[:disp_status] == 'Active: Non-VA' && data[:prescription_name].nil? + data[:orderable_item] + elsif !data[:prescription_name].nil? data[:prescription_name] else - data[:orderable_item] + '~' end when 'disp_status' data[:disp_status]