Skip to content
Snippets Groups Projects
Unverified Commit 723cbcf9 authored by Sean Tsai's avatar Sean Tsai Committed by GitHub
Browse files

Fix a bug in confirm category delete (#1351)

parent c2ebfc72
No related branches found
No related tags found
No related merge requests found
...@@ -69,7 +69,20 @@ export default function ConfirmCategoryDelete({ ...@@ -69,7 +69,20 @@ export default function ConfirmCategoryDelete({
<View style={{ flex: 1, marginLeft: 10, marginRight: 30 }}> <View style={{ flex: 1, marginLeft: 10, marginRight: 30 }}>
<CategoryAutocomplete <CategoryAutocomplete
categoryGroups={categoryGroups} categoryGroups={
group
? categoryGroups.filter(
g => g.id !== group.id && !!g.is_income === isIncome,
)
: categoryGroups
.filter(g => !!g.is_income === isIncome)
.map(g => ({
...g,
categories: g.categories.filter(
c => c.id !== category.id,
),
}))
}
value={transferCategory} value={transferCategory}
inputProps={{ inputProps={{
placeholder: 'Select category...', placeholder: 'Select category...',
......
---
category: Bugfix
authors: [aleetsaiya]
---
Fix a bug that user can transfer budget to the category (or group) which user want to delete
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment