Skip to content
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

Vue.js 3 - AjaxStore - Filter Not working #8788

Closed
guilherme-pinto-reeeliance opened this issue Mar 11, 2024 · 7 comments
Closed

Vue.js 3 - AjaxStore - Filter Not working #8788

guilherme-pinto-reeeliance opened this issue Mar 11, 2024 · 7 comments
Assignees
Labels
high-priority Urgent to have fixed resolved Fixed but not yet released (available in the nightly builds)
Milestone

Comments

@guilherme-pinto-reeeliance
Copy link

When using AjaxStore Grid with Vue.js 3 + Nuxtjs 3 Bryntum grid

"@bryntum/grid": "^5.6.8",
"@bryntum/grid-vue-3": "^5.6.8",

The server its responding normally with the filter working but the bryntum its havings this errors

We are having this problem when the user hits one character

Screenshot 2024-03-11 at 20 53 25

TypeError: Cannot read properties of undefined (reading 'dataset')
at Proxy.processCellContent (http://localhost:3000/_nuxt/node_modules/@bryntum/grid-vue-3/src/WrapperHelperVue3.js?v=a0350e9d:52:38)
at Proxy.renderCell (http://localhost:3000/_nuxt/node_modules/@bryntum/grid/grid.module.js?v=a0350e9d:94800:60)
at Proxy.render (http://localhost:3000/_nuxt/node_modules/@bryntum/grid/grid.module.js?v=a0350e9d:94655:17)
at Proxy.renderFromRow (http://localhost:3000/_nuxt/node_modules/@bryntum/grid/grid.module.js?v=a0350e9d:95802:11)
at Proxy.refresh (http://localhost:3000/_nuxt/node_modules/@bryntum/grid/grid.module.js?v=a0350e9d:95867:8)
at Proxy.refreshRows (http://localhost:3000/_nuxt/node_modules/@bryntum/grid/grid.module.js?v=a0350e9d:103605:18)
at Proxy.resumeRefresh (http://localhost:3000/_nuxt/node_modules/@bryntum/grid/grid.module.js?v=a0350e9d:103697:14)
at Proxy.internalOnStoreEndApplyChangeset (http://localhost:3000/_nuxt/node_modules/@bryntum/grid/grid.module.js?v=a0350e9d:102960:10)
at Proxy.trigger (http://localhost:3000/_nuxt/node_modules/@bryntum/grid/grid.module.js?v=a0350e9d:5064:34)
at Proxy.syncDataset (http://localhost:3000/_nuxt/node_modules/@bryntum/grid/grid.module.js?v=a0350e9d:28184:8)

And when the user hits a second character this error

Screenshot 2024-03-11 at 20 53 07
TypeError: 'get' on proxy: property 'parser' is a read-only and non-configurable data property on the proxy target but the proxy did not return its actual value (expected '#' but got '#')
at Proxy.parse (http://localhost:3000/_nuxt/node_modules/@bryntum/grid/grid.module.js?v=a0350e9d:20878:41)
at Proxy.changeValue (http://localhost:3000/_nuxt/node_modules/@bryntum/grid/grid.module.js?v=a0350e9d:66566:58)
at Proxy.set (http://localhost:3000/_nuxt/node_modules/@bryntum/grid/grid.module.js?v=a0350e9d:1628:44)
at Reflect.set ()
at MutableReactiveHandler.set (http://localhost:3000/_nuxt/node_modules/.cache/vite/client/deps/chunk-DSIC5XJC.js?v=a0350e9d:1517:32)
at Proxy.updateColumnFilterFields (http://localhost:3000/_nuxt/node_modules/@bryntum/grid/grid.module.js?v=a0350e9d:83763:25)
at Proxy.onStoreFilter (http://localhost:3000/_nuxt/node_modules/@bryntum/grid/grid.module.js?v=a0350e9d:83877:12)
at Proxy.trigger (http://localhost:3000/_nuxt/node_modules/@bryntum/grid/grid.module.js?v=a0350e9d:5064:34)
at Proxy.triggerFilterEvent (http://localhost:3000/_nuxt/node_modules/@bryntum/grid/grid.module.js?v=a0350e9d:24876:12)
at Proxy.afterPerformFilter (http://localhost:3000/_nuxt/node_modules/@bryntum/grid/grid.module.js?v=a0350e9d:24871:14)

After this the bryntum stop working

After Hours and Hours of debug i think i found the source of this problem
This on the performFilter method where did you guys have a promise internalLoad

const result = await me.internalLoad({}, "", (event)=>{
                me.data = event.data;
                event = silent ? null : {
                    action: "filter",
                    filters,
                    oldCount,
                    records: me.storage.values
                };
                me.afterPerformFilter(event);
                me.trigger("refresh", event);
            }

on my tests the start of all errors its this part.

@matsbryntse matsbryntse added the high-priority Urgent to have fixed label Apr 4, 2024
@ghulamghousdev ghulamghousdev self-assigned this Apr 4, 2024
@jsakalos
Copy link

jsakalos commented Apr 4, 2024

@guilherme-pinto-reeeliance, would you please post a showcase we can run and debug or the exact steps to reproduce the problem with one of our demos?

@guilherme-pinto-reeeliance
Copy link
Author

@ghulamghousdev
Copy link
Member

Hi @guilherme-pinto-reeeliance,

Thanks for sharing it. We have a high prio ticket here #8846. I was working on it. I have fixed the issue already, will try to push to get it merge tomorrow. You can track this issue there.

@jsakalos
Copy link

jsakalos commented Apr 4, 2024

Explanation: vue: true must be used with an appropriate renderer and it should not do anything by itself. The problem was that setting this flag but not providing the renderer caused the crash. The fix makes the code impervious to that combination. We expect it will be released in 5.6.9 or latest 5.6.10. Until then just remove the vue flag.

@guilherme-pinto-reeeliance
Copy link
Author

@ghulamghousdev
Copy link
Member

@guilherme-pinto-reeeliance the test case provided by you does not include any renderer. And I have tried it in our online example with a vue renderer and issue was resolved.

@SergeyMaltsev SergeyMaltsev added the resolved Fixed but not yet released (available in the nightly builds) label Apr 5, 2024
@SergeyMaltsev SergeyMaltsev added this to the 5.6.9 milestone Apr 5, 2024
@SergeyMaltsev
Copy link
Contributor

Closed as duplicate for resolved issue
#8846

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
high-priority Urgent to have fixed resolved Fixed but not yet released (available in the nightly builds)
Projects
None yet
Development

No branches or pull requests

5 participants