fix(filters): use correct filter string instead of object
This commit is contained in:
parent
9814ff9667
commit
ccd79a7089
|
|
@ -64,7 +64,10 @@ watch(
|
|||
},
|
||||
)
|
||||
|
||||
function escapeHtml(unsafe: string): string {
|
||||
function escapeHtml(unsafe: string|null|undefined): string {
|
||||
if (!unsafe) {
|
||||
return ''
|
||||
}
|
||||
return unsafe
|
||||
.replace(/&/g, '&')
|
||||
.replace(/</g, '<')
|
||||
|
|
@ -73,7 +76,10 @@ function escapeHtml(unsafe: string): string {
|
|||
.replace(/'/g, ''')
|
||||
}
|
||||
|
||||
function unEscapeHtml(unsafe: string): string {
|
||||
function unEscapeHtml(unsafe: string|null|undefined): string {
|
||||
if (!unsafe) {
|
||||
return ''
|
||||
}
|
||||
return unsafe
|
||||
.replace(/&/g, '&')
|
||||
.replace(/</g, '<')
|
||||
|
|
|
|||
|
|
@ -77,10 +77,10 @@ function save() {
|
|||
|
||||
emit('update:modelValue', {
|
||||
...view.value,
|
||||
filter: transformFilterForApi(view.value?.filter || ''),
|
||||
filter: transformFilterForApi(view.value?.filter?.filter || ''),
|
||||
bucketConfiguration: view.value?.bucketConfiguration.map(bc => ({
|
||||
title: bc.title,
|
||||
filter: transformFilterForApi(bc.filter || ''),
|
||||
filter: transformFilterForApi(bc.filter?.filter || ''),
|
||||
})),
|
||||
})
|
||||
}
|
||||
|
|
@ -233,7 +233,7 @@ function handleBubbleSave() {
|
|||
</div>
|
||||
|
||||
<FilterInput
|
||||
v-model="view.bucketConfiguration[index].filter"
|
||||
v-model="view.bucketConfiguration[index].filter.filter"
|
||||
:project-id="view.projectId"
|
||||
:input-label="$t('project.views.filter')"
|
||||
class="mb-2"
|
||||
|
|
|
|||
Loading…
Reference in New Issue