so i finally figured out how to sort my data sheet with a button on my site . and it works fine . unfortunately when i went to go make an adjustment to it today , the code was gone , i clicked the button and no code shows up in the “Page” i know i’m
just looking in the wrong spot or something , help XD
Hi Francisco, can you post a link to the site so we can check what happened?
Hi Francisco,
We were able to recover the last version of code that wasn’t an empty file:
import wixData from "wix-data";
export function button10_click() {
$w("#dataset1").setSort(wixData.sort().ascending('endDate'));
}
export function button11_click() {
$w("#dataset1").setSort(wixData.sort().descending('_createdDate'));
}
Code files are not saved automatically between editor sessions.
We recommend always saving the site before refreshing or closing the editor.
I wish there was just an actual ui to implement sorting . its so frustrating . and no one on fiver knows what the hell they are doing with wix code its too new XD , should start a forum thread to seek help maybe even for payment XD
Regarding sort ui, it would be great if you can submit a feature request with how you’d like it to look and behave.
I would definitely start a thread seeking help, there are coders on the forum.