Possible bug? Disappearing background on repeater with query

When I load a repeater and run a query such as : $w(“#dataset1”).setFilter(wixData.filter().eq(“state”, statevalue).eq(“county”,currentvalue));

the repeater loads with complete data and then filters itself but in doing so the background of the repeater disappears. I don’t know if this is a bug or I am doing something wrong.

Hey Mustafa,

I tried this myself and I see what you mean. Maybe it’s a “feature” and not a bug. :wink:

I’m working on this and will get back to you when I understand what’s going on. I’ll get back to you when I’m smarter.

Yisrael

Hey Mustafa,

Me again. OK - that was quick. Now I understand what’s happening… I think.

First of all, I must admit that I’m not sure what you’re referring to as the “repeater background”. But I’ll try to outline what’s going on…

  • Click here to see what a page is: Page

  • A page has a Page design which provides a background color or design to the center (or content part) of the page.

  • The part of the web page outside of the center (content) part of the page can be assigned a Page background .
    Assign a Page design to your page. What happens? The page design should appear the same no matter what’s going on in the repeater.

Assign a Page background to your page. What happens? The page background should appear the same no matter what’s going on in the repeater.

Get back to me if you see some other behavior. You can include screens shots (even partial) illustrating whatever it is you feel is incorrect.

Yisrael

Hi Yisrael,

Thankyou so much for your prompt response. I understand what you are trying to say but my query was a little different. So here goes:

I use a “repeating layout” with a solid background behind each container (yellow) here:


A filter query is run on the page to filter the results based on the users county coming in as a locally stored variable from the previous page.

When the result sorts (immediately after the database loads) The results displayed (container items) lose their background.


The code from my page is here:

import {local} from ‘wix-storage’;
import wixData from ‘wix-data’;

$w.onReady(function () {

});

export function dataset1_ready() {
let currentvalue = local.getItem(“countyvar”);
let statevalue = local.getItem(“statevar”);
$w(“#dataset1”).setFilter(wixData.filter().eq(“state”, statevalue).eq(“county”,currentvalue));
$w(“#text38”).text = currentvalue;
console.info(currentvalue);
console.info(statevalue);

$w(“#repeater1”).expand();
local.clear();

}

Aha. Didn’t notice that. I’ll play around and try to reproduce the problem.

Hey mustafa,

I was able to reproduce the problem. I tried using a dataset and also by directly doing a query on the database collection. Both ways caused the repeater background to disappear.

I’m trying to find out what the story is. We’ll get back to you when we’ve checked this out.

Thanks for your patience.

Yisrael

Thankyou Yisrael! I have worked out a temporary workaround by substituting a shape and making the opacity of the repeater background to 0, but the real solution will be the best :slight_smile:

Hey Mustafa - you’re a smart guy.

Can you post the URL of your site. I’m having some other smart guys look at this problem as well.

Thanks,

Yisrael

Thankyou Yisrael :slight_smile: The site is for a client who is a little touchy about privacy prior to launch, would you mind if I PM or email you?

We don’t support PM right now, and it obviously isn’t a good idea for me to post my email address here. Let me see if I can find a workaround to this problem.

Thanks again!

NP. Meanwhile, I just explained to the smart guys I mentioned before how to reproduce the problem. Hopefully they can work it out.

Hey Mustafa!

Good news. It’s a bug. And a ticket has been opened.

Thank you for pointing this out. Take a cigar out of petty cash.

Best regards,

Yisrael