top of page

Forum Posts

info
Jul 13, 2020
In Coding with Velo
If I have a dataset that is public, but is only connected and loaded on a page that is password protected, is that secure? Is it safe to assume that only people with the password will be able to access the dataset?
0
2
35
info
Jul 13, 2020
In Coding with Velo
I'm filtering search results based on title and description fields in the database. The filter updates from an input field. The problem is that when a user types cmd+backspace and clears the input, it doesn't update the search term. Whatever the results of the last search term stay on the page. For example, if I enter an invalid search term, like "acbrgr", nothing is returned. If I cmd+backspace, still no results appear. If I backspace one character at a time to clear the field, then it restores the original data normally. If I enter a search term that is valid and displays a subset of results, cmd+backspace still shows that subset. I'd expect it to properly display all data. import wixData from 'wix-data'; $w.onReady(function () { $w('#input15').onInput((event) => { $w('#dataset1') .setFilter( wixData.filter().contains('title', event.target.value) .or(wixData.filter().contains('description', event.target.value)) ) }) }); Is this a bug with filtering? I've console logged the event.target.value on cmd+backspace, and it is ''. Same value when backspacing one character a time.
0
1
29
info
Apr 11, 2020
In Coding with Velo
I have the below router that queries a data collection. It works, unless I add one additional import, in which case it returns a 500 timeout error. import { ok, notFound } from "wix-router"; import wixData from 'wix-data'; // If I remove the below import, the page loads. With it, I get a 500 timeout error. import wixUsers from "wix-users"; export async function myRouter_Router(request, response) { return await wixData.query("myCollection") .eq("_id", request.path[0]) .find() .then((queryResult) => { if (queryResult.length > 0) { return ok("myRouter-page", queryResult.items[0]); } return notFound(); }) } The difference is literally just this line: import wixUsers from "wix-users"; Without it, the page loads. With it, I get the 500 error. I'm stumped. Any help would be appreciated. Thanks.
0
4
201

info

More actions
bottom of page