New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add record filter preset saving #1227
Add record filter preset saving #1227
Conversation
client/web/compose/src/components/PageBlocks/RecordListBase.vue
Outdated
Show resolved
Hide resolved
client/web/compose/src/components/PageBlocks/RecordListBase.vue
Outdated
Show resolved
Hide resolved
client/web/compose/src/components/PageBlocks/RecordListBase.vue
Outdated
Show resolved
Hide resolved
client/web/compose/src/components/PageBlocks/RecordListBase.vue
Outdated
Show resolved
Hide resolved
client/web/compose/src/components/PageBlocks/RecordListBase.vue
Outdated
Show resolved
Hide resolved
client/web/compose/src/components/PageBlocks/RecordListBase.vue
Outdated
Show resolved
Hide resolved
client/web/compose/src/components/PageBlocks/RecordListBase.vue
Outdated
Show resolved
Hide resolved
client/web/compose/src/components/PageBlocks/RecordListBase.vue
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mistakenly selected Approve.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- If i close the save as preset naming modal I cannot save another preset
- Apply filter that you save as preset
- If I press reset, the Custom filter still stays
- This should be configurable, that means a new option in the record list configurator
customFilterPresets
, should be a checkbox in the filter preset section - Make sure the record list filter component is also configurable to be able to hide that save as preset button since its not just used in the record list. And make sure its disabled in other places record list filter is used. We only want custom presets on record list block.
} | ||
|
||
// Emit only value and not whole record with every filter | ||
this.$emit('filter', this.processFilter()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks like you can just have a onSave function with (close = true, type = 'filter').
So that code doesn't repeat
name: 'CustomFilterPreset', | ||
|
||
props: { | ||
showCustomPresetFilterModal: { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can this be called visible
, since based on where it is it is obvious it's the custom filter preset modal (component name)
default: false, | ||
}, | ||
|
||
customFilter: { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this can just be called filter
}, | ||
|
||
watch: { | ||
showCustomPresetFilterModal (val) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do the visible: { immediate: true, handler () } syntax please
}, | ||
|
||
created () { | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need for this if its empty
@@ -263,6 +263,12 @@ record: | |||
recordList: | |||
addRecord: Add | |||
cancelSelection: Cancel | |||
customFilter: Custom filter | |||
customPresetFilter: Custom preset filter |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i dont think you use this anywhere
customFilter: Custom filter | ||
customPresetFilter: Custom preset filter | ||
presetFilter: | ||
reset: Reset |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This also wont be needed since you don't need reset
@@ -263,6 +263,12 @@ record: | |||
recordList: | |||
addRecord: Add | |||
cancelSelection: Cancel | |||
customFilter: Custom filter | |||
customPresetFilter: Custom preset filter | |||
presetFilter: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
filterPresets, presetFilter means something else
class="pt-0" | ||
> | ||
<b-form-group | ||
:label="$t('recordList.presetFilter.filterName')" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
label-class primary
> | ||
<b-form-input | ||
v-model="filterName" | ||
required |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the required here doesn't have any effect, you should however prevent saving(button should be disabled) if there is no filter name. You can also indicate its required by having a * in the label
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- If i close the save as preset naming modal I cannot save another preset
- Saving as preset without applying filter doesn't apply and/or save the not applied one in the preset
- If I press reset, the Custom filter still stays
- This should be configurable, that means a new option in the record list configurator
customFilterPresets
, should be a checkbox in the filter preset section - Make sure the record list filter component is also configurable to be able to hide that save as preset button since its not just used in the record list. And make sure its disabled in other places record list filter is used. We only want custom presets on record list block.
Issues found after QC check:
|
c550f3f
to
aa28be2
Compare
The following changes are implemented
TODO: Summary
Changes in the user interface:
TODO: Add screenshots, recordings or remove this section
Checklist when submitting a final (!draft) PR