From 90c4c3826d021197b9bf5a30319d80997aaa936f Mon Sep 17 00:00:00 2001 From: cxt <853663049@qq.com> Date: Wed, 26 Feb 2020 12:44:33 +0800 Subject: [PATCH] =?UTF-8?q?=E6=99=BA=E8=83=BD=E7=BB=84=E5=8D=B7=E5=BA=94?= =?UTF-8?q?=E6=8E=92=E9=99=A4=E6=9C=AA=E5=8F=91=E5=B8=83=E7=9A=84=E7=BC=96?= =?UTF-8?q?=E7=A8=8B=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/queries/optional_item_query.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/queries/optional_item_query.rb b/app/queries/optional_item_query.rb index a12b62b93..a5f7dea78 100644 --- a/app/queries/optional_item_query.rb +++ b/app/queries/optional_item_query.rb @@ -19,7 +19,8 @@ class OptionalItemQuery < ApplicationQuery end if hacks.present? - items = ItemBank.where(container_id: hacks.where(status: 1).pluck(:id), container_type: "Hack").or(ItemBank.where(id: items.pluck(:id))) + items = ItemBank.where(container_id: hacks.where(status: 1).pluck(:id), container_type: "Hack") + .or(ItemBank.where(id: items.pluck(:id)).where("item_type != '6'")) end public = source.present? ? source.to_i : 1