Wappler Version : 6.0.3
Operating System : Windows 10
Server Model: Node
Database Type: MariaDB
Hosting Type: Docker
Expected behavior
What do you think should happen?
When using Dynamic variables in a Data View, before 6.0.3 with a project files update options such as Sort On and Direction should work.
Actual behavior
What actually happens?
If using either of those options, have not tested others, the data view will not display anything. Removing the dynamic attributes shows the data. This worked just fine in 6.0.2.
How to reproduce
Detail a step by step guide to reproduce the issue
A screenshot or short video indicating the problem
A copy of your code would help. Include: JS, HTML.
Test your steps on a clean page to see if you still have an issue
Add a data view to a server connect, set a dynamic attribute such as Sort On and link it to an field to sort by. The data will be blank.
OR
Add a data view to a server connect, set a dynamic attribute such as Sort On and Direction for use on a table to sort the columns via Query Manager. Again the data will be blank.
Did not seem to have an issue or notice the expression builder but the data on the page is empty for me. I just reverted back to 6.0.2 and updated the project files, republished and am working again on all my issues so far. As I have other employees using this site, I needed a quick fix so the revert to the previous version was it for me.
Was also having an odd navigation issue where clicking on a navigation button would not navigate but trying another button then trying it again it would navigate. Reverted also fixed that too. Node platform, internal navigation. The URL does change when clicking but the page does not change and still shows where they were at.
Tested this issue on the latest release 6.1.0 and it is still a problem so I will have to stay on 6.0.2 for now still. After updating I am prompted to update the project assets as expected. After updating the assets is when it breaks. I tested updating to 6.1.0 but not updating assets and it still works. If that helps narrow it down I took a screenshot of what is updated. This does happen in multiple projects, not just a single one. Different backend databases. Both Node
I just now created a test page. I have a simple server connect for a database query, nothing special there. It is just showing all data on a table. Then I have a Data View and a Query manager. On the Data View I have in the dynamic attributes a Query manager Sort and Dir setup. Finally using the bootstrap table generator to display the Data View with the Query Manager setup for sorting and sort direction. When on 6.0.2 you can see the data displayed and sorting on all columns works. On any newer version the data is not displayed. If I remove the Dynamic Attributes under the Data View the data is again displayed.
After some further testing in making these screenshots. I discovered only the first column will be sortable and if you try to sort any other column it will not work, then if you try and refresh the page while sorting the other column it will then be blank.
While I am doing the testing on this page, there is no security restrict setup on the query.
Good call, was on beta went ahead and reinstalled 6.1.0 so we can test more and swapped to stable. Updated project assets to stable channel after a restart of Wappler. No error and sorting works, data is displayed in all instances. I tested in another site with a lot more queries and tables in it where I was also having the same issue. Updated the assets to stable and the data views appear to be working. Unfortunately having a lot of other issues now so I will need to work through that before publishing that site.
So appears to be an issue in the Beta channel then for this issue.
I believe I was on Beta channel for CouchDB/PouchDB setup but looks like its on stable now as well since I see it in the list while in stable.
One of the changes I am noticing between the Stable and Beta on the Data View:
In Beta, I can have multiple filters. In Stable, I can have one filter but if I use the same expression the data view snaps back to page one. Example below of what I mean by snapping.
(some actual field/dropdown names changed) Copying and pasting out of the Data Bindings - Code tab for the Filter under the Data View.
Filter that works on Stable:
Field1Name==select_location.value
Filter that does not work on Stable, but works on Beta:
Just following up on this. I will still have to stay on 6.0.2. Tested on 6.1.1 last week and issue was still there. I have too many filters applied on data views using the expression builder so will need to stay on Beta channel since it behaves in a worse fashion on Stable channel from my last post.