top of page

Forum Posts

crgroberts1
Apr 20, 2023
In Velo Pro Discussion
Hello All, Please help I just can't see where I am going wrong? I have collected data in a dataset called 'ratings'. In Ratings I have 4 fields - Rating Number, Organisation, Title, Module. I am looking to calculate an aggregate of the ratings on a dynamic organisation or dynamic Module item page that calculates just the ratings filtered by Organisation Name and Module Text and the have the values connected to two inputs - a number and a Progress Bar. (i.e. Showing the 'Access' (Title) with rating '1' (rating)for 'Royal Life Saving'(OrganisationName) in 'Supervision Planning'(Module Text) and 'Supervisor' with rating 5 for Royal Life Saving in Supervision Planning. Here is my code on a Dynamic Organisation item page: import wixData from 'wix-data'; const filter = wixData.filter().contains("dynamicDataset", "title"); const filter = wixData.filter().contains("moduleDataset", "title"); $w.onReady(() => { Sum_amount(); }); let having = wixData.filter().contains("moduleDataset", "title") export function Sum_amount() { wixData.aggregate("Ratings") .filter(filter) .group("moduleText") .having(having) .sum("rating", "sumrating") .run() .then((results) => { $w('#input2').value = results.items[0].sumrating; //display total in input field at bottom of table $w('#progressBar3').value = results.items[0].sumrating; //display total in input field at bottom of table }); } @Yisrael (Wix) ?
Filtering an Aggregate calculation by two datasets content media
0
0
13
crgroberts1
Oct 27, 2020
In Coding with Velo
I am looking to display a repeater (grid) of all plans within my Pricing Plans, however I only want to show the items in which the member has purchased. Each repeater item needs to link to a seperate member page (not dynamic) that is linked to the Pricing Plans permission. (i know how to do this part) I have looked at the Event Handler for Paid Plans but I cant get it to work and connect to the page This screen shot from the Dashboard is similiar to the outpu of what I am trying to achieve. A list (or grid) of Purchase Plan and a button to go to the relevant page. Just change 'Apps' tp 'Plan'
How to Show a repeater container based on logged in users purchased plans content media
0
0
14

crgroberts1

More actions
bottom of page