Spotlight xstore widget showing the wrong number?

This topic has 19 replies, 2 voices, and was last updated 1 months ago ago by Luca Rossi

  • Avatar: Nicolo
    Nicolo
    Participant
    September 2, 2024 at 14:51

    Hi

    There seem to be an issue with the spotlight widget, showing the wrong number?

    Amount of products on sale is not 4, its only 2. Plese check the video attahched, and feel free to test for yourself:

    https://elmate.no/alle-produkter/

    I think the root cause of this is the ability to subscribe and save on tea products. (the code was added by your customization service in the child theme)

    I have added login credentials in the private area for quick troubleshooting.

    Thanks!

    Please, contact administrator
    for this information.
    Files is visible for topic creator and
    support staff only.
    18 Answers
    Avatar: Justin
    Luca Rossi
    Support staff
    September 3, 2024 at 06:00

    Hi @Nicolo,

    The sale count function is coming from the WooCommerce plugin not from our custom code: wc_get_product_ids_on_sale();

    After taking a look closer at the code, we could see that WooCommerce also count the sale of variation products:

    
    		return $wpdb->get_results(
    			"
    			SELECT posts.ID as id, posts.post_parent as parent_id
    			FROM {$wpdb->posts} AS posts
    			INNER JOIN {$wpdb->wc_product_meta_lookup} AS lookup ON posts.ID = lookup.product_id
    			$outofstock_join
    			WHERE posts.post_type IN ( 'product', 'product_variation' )
    			AND posts.post_status = 'publish'
    			AND lookup.onsale = 1
    			$outofstock_where
    			AND posts.post_parent NOT IN (
    				SELECT ID FROM <code>$wpdb->posts</code> as posts
    				WHERE posts.post_type = 'product'
    				AND posts.post_parent = 0
    				AND posts.post_status != 'publish'
    			)
    			GROUP BY posts.ID
    			"
    		);
    

    Please double check your variable products, it seems they’re on sale also.

    Best Regards,
    8Theme’s Team

    Avatar: Nicolo
    Nicolo
    Participant
    September 3, 2024 at 08:28

    Hi

    Thanks for providing me the code for further inspection.

    It makes sense that its coming from the variable products.

    Note: There is a difference between the xstore sidebar filter widget and the xstore spotlight widget.

    The sidebar is showing “2 products”
    The spotlight is showing 4 products”

    How can we make sure these are the same, and as you can see on the video we only want the parent product to be counted. (on screen you only see 2 product thumbnails after filtering down to “on sale”)

    To sum up, a total of 2 products would be corrrect for both the sidebar and the spotlight.

    How can this be fixed? Looking forward to hear from you!

    Files is visible for topic creator and
    support staff only.
    Avatar: Justin
    Luca Rossi
    Support staff
    September 3, 2024 at 09:57

    Dear Nicolo,

    We hope this message finds you well.

    We would like to inform you that we have noticed a discrepancy in the count displayed under the Product Filter widget. As of now, there is no immediate fix available for this issue.

    We have escalated this matter to our development team for further review and resolution. We will keep you updated on the progress and notify you once a solution has been implemented.

    Thank you for your understanding and patience.

    Best regards,
    The 8Theme Team

    Avatar: Nicolo
    Nicolo
    Participant
    September 3, 2024 at 11:48

    Thanks for the notice.

    Looking forward to hear from you once its fixed.

    In the meantime i have a follow up question regarding the spotlight widget:

    How do i activate the ajax feature added to the latest update?

    Feel free to read the about the uprgade here:

    https://8theme.upvoty.com/b/xstore/make-category-spotlight-ajaxrefresh-on-shop-page/

    Avatar: Justin
    Luca Rossi
    Support staff
    September 4, 2024 at 11:09

    Dear Nicolo,

    We hope this message finds you well. I am writing to inform you that the AJAX feature is currently operational exclusively within the categories section. It has not yet been implemented in the following three filters: All Products, New Arrivals, and Sale.

    For a clearer demonstration, please view our video at the following link: [https://www.awesomescreenshot.com/video/31169754?key=50c9e49c59060e9bec3b4a61ff98e21f](https://www.awesomescreenshot.com/video/31169754?key=50c9e49c59060e9bec3b4a61ff98e21f).

    Thank you for your attention to this matter.

    Best regards,
    The 8Theme Team

    Avatar: Nicolo
    Nicolo
    Participant
    September 4, 2024 at 12:51

    Aha, i see it, thanks for the video

    How can i activate this for my shop page.

    https://elmate.no/alle-produkter/

    I see that my categories are still not working as in the video you provided.

    Looking forward to hear from you.

    P.S. for futher troubleshooting you have the login credentials in the first message of this forum page.

    Avatar: Justin
    Luca Rossi
    Support staff
    September 4, 2024 at 16:20

    Hi @Nicolo,

    Can you please check again on the category images?

    It might be the cache issue.

    Best regards,
    The 8Theme Team

    Avatar: Nicolo
    Nicolo
    Participant
    September 5, 2024 at 11:52

    Hi again Luca

    Thanks for your advice.

    I cleared the cache with w3total plugin. And entered inkognito:

    The attached videos are the result of both dekstop and mobile

    Regards

    Files is visible for topic creator and
    support staff only.
    Avatar: Justin
    Luca Rossi
    Support staff
    September 6, 2024 at 10:50

    Dear Nicolo,

    We hope this message finds you well.

    We would like to inform you that the Ajax filter is currently operational exclusively on the category images, as shown here: https://prnt.sc/le1DoBifvVRn.

    To further enhance this feature, we kindly suggest that you consider submitting additional feature requests at the following link: https://8theme.upvoty.com/b/xstore/make-category-spotlight-ajaxrefresh-on-shop-page/.

    Thank you for your attention to this matter. We look forward to your valuable feedback.

    Best Regards,
    The 8Theme Team

    Avatar: Nicolo
    Nicolo
    Participant
    September 6, 2024 at 12:35

    Hi Luca

    I got that, fully understood.

    Not alle products or sale, only the categories: “sett” “te” “utstyr”

    Now lets inspect only the categories to see if they are fully working.

    Please have a close look of the video:

    Let me know if you see the errors – not filtering correctly

    At the end of the video, it all of a sudden went from ajax to refreshing?

    Looking forward to hearing from you

    Files is visible for topic creator and
    support staff only.
    Avatar: Justin
    Luca Rossi
    Support staff
    September 7, 2024 at 14:16

    Dear Nicolo,

    We hope this message finds you well. We kindly request that you review the URL stated when you clicked on each category image, as there appears to be an issue where all categories are combined when filtering the products. This functionality should mirror the product filter found on the left sidebar.

    Thank you for your attention to this matter.

    Best regards,
    The 8Theme Team

    Avatar: Nicolo
    Nicolo
    Participant
    September 7, 2024 at 18:22

    We kindly request that you review the URL stated when you clicked on each category image, as there appears to be an issue where all categories are combined when filtering the products. This functionality should mirror the product filter found on the left sidebar.
    – I agree with you 100%. And i confirm that the issue is present.

    How do we fix this issue?

    Thanks alot for your help so far

    Avatar: Justin
    Luca Rossi
    Support staff
    September 9, 2024 at 05:06

    Hi @Nicolo,

    We meant the category items will combine when you click on each category.

    This is the logic of Spotlight Categories Element is working for now.

    We don’t have any custom codes to make it work as separated yet.

    Best regards,
    The 8Theme Team

    Avatar: Nicolo
    Nicolo
    Participant
    September 9, 2024 at 12:18

    I see, will it stay like this?

    Or are you working on it to filter separated?

    And regarding the number issue, how is it going, what is the status?

    https://userimg.8theme.com/storage/2024/09/02/31531-Spotlight%20showing%20wrong%20nr%20-%20Made%20with%20Clipchamp%20(1).mp4

    Avatar: Justin
    Luca Rossi
    Support staff
    September 9, 2024 at 15:52

    Hi @Nicolo,

    I see, will it stay like this?

    Or are you working on it to filter separated?

    We suggest you to add more comments to the feature request link so Jack can take a look on this.

    And regarding the number issue, how is it going, what is the status?

    Our development team is still working on it. Stay tuned.

    Best regards,
    The 8Theme Team

    Avatar: Justin
    Luca Rossi
    Support staff
    September 10, 2024 at 10:36

    Dear @Nicolo,

    Our development team has applied the hotfix of sale count product issue on your website.

    Could you please double check again?

    Thank you!

    Avatar: Nicolo
    Nicolo
    Participant
    September 12, 2024 at 08:47

    I just checked and it works great

    We can close this thread now

    I will add the comments from our thread to Jack, thanks for the advice!

    Regards

    Avatar: Justin
    Luca Rossi
    Support staff
    September 12, 2024 at 08:55

    If you need anything else please let us know.

  • Viewing 19 results - 1 through 19 (of 19 total)

The issue related to '‘Spotlight xstore widget showing the wrong number?’' has been successfully resolved, and the topic is now closed for further responses

8theme customization service
We're using our own and third-party cookies to improve your experience and our website. Keep on browsing to accept our cookie policy.