From 926f1df1a92e17f4ec9d8a3883314a31383af469 Mon Sep 17 00:00:00 2001 From: KMY Date: Mon, 2 Oct 2023 13:54:54 +0900 Subject: [PATCH] Fix quote --- app/services/process_references_service.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/services/process_references_service.rb b/app/services/process_references_service.rb index 83dd8a07eef785..ba9dc33285654e 100644 --- a/app/services/process_references_service.rb +++ b/app/services/process_references_service.rb @@ -128,7 +128,7 @@ def add_references statuses.each do |status| attribute_type = quote_status_ids.include?(status.id) ? 'QT' : @attributes[status.id] attribute_type = 'BT' unless quotable?(status) - quote_type = attribute_type.present? ? attribute_type.casecmp('QT').zero? : false + quote_type = attribute_type.present? ? (attribute_type.casecmp('QT').zero? || attribute_type.casecmp('RE').zero?) : false @status.quote_of_id = status.id if quote_type && (@status.quote_of_id.nil? || references.exclude?(@status.quote_of_id)) @added_objects << @status.reference_objects.new(target_status: status, attribute_type: attribute_type, quote: quote_type)