@@ -142,7 +142,7 @@ function refresh:StartUpdate(ctx)
142142 -- Set the filterBagID based on the current bank state and tab settings
143143 local database = addon :GetModule (' Database' )
144144 local refreshCtx = ctx :Copy ()
145-
145+
146146 -- Check if the context already has a filterBagID set (from tab switching)
147147 local existingFilter = ctx :Get (' filterBagID' )
148148 if existingFilter ~= nil then
@@ -151,18 +151,27 @@ function refresh:StartUpdate(ctx)
151151 elseif addon .atWarbank then
152152 -- If at warbank, use the current warbank tab
153153 refreshCtx :Set (' filterBagID' , addon .Bags .Bank .bankTab )
154- elseif database : GetCharacterBankTabsEnabled () then
155- -- If character bank tabs are enabled, use the current bank tab if it's a character bank tab
154+ else
155+ -- Determine what to filter based on current tab
156156 local currentTab = addon .Bags .Bank .bankTab
157- if currentTab >= Enum .BagIndex .CharacterBankTab_1 and currentTab <= Enum .BagIndex .CharacterBankTab_6 then
158- refreshCtx :Set (' filterBagID' , currentTab )
157+ local accountBankStart = addon .isRetail and Enum .BagIndex .AccountBankTab_1 or 13
158+
159+ if currentTab >= accountBankStart then
160+ -- Current tab is an account bank tab - don't filter, show all account bank items
161+ refreshCtx :Set (' filterBagID' , nil )
162+ elseif database :GetCharacterBankTabsEnabled () then
163+ -- Character bank tabs are enabled
164+ if currentTab >= Enum .BagIndex .CharacterBankTab_1 and currentTab <= Enum .BagIndex .CharacterBankTab_6 then
165+ -- Current tab is a character bank tab - filter to just this tab
166+ refreshCtx :Set (' filterBagID' , currentTab )
167+ else
168+ -- Default to first character bank tab if current tab is not a character bank tab
169+ refreshCtx :Set (' filterBagID' , Enum .BagIndex .CharacterBankTab_1 )
170+ end
159171 else
160- -- Default to first character bank tab if current tab is not a character bank tab
161- refreshCtx :Set (' filterBagID' , Enum . BagIndex . CharacterBankTab_1 )
172+ -- Character bank tabs are disabled, clear the filter for single bank tab mode
173+ refreshCtx :Set (' filterBagID' , nil )
162174 end
163- else
164- -- If character bank tabs are disabled, clear the filter for single bank tab mode
165- refreshCtx :Set (' filterBagID' , nil )
166175 end
167176
168177 items :RefreshBank (refreshCtx )
0 commit comments