sr-npm 1.7.578 → 1.7.580

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sr-npm",
3
- "version": "1.7.578",
3
+ "version": "1.7.580",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -229,6 +229,7 @@ async function refreshFacetCounts(_$w) {
229
229
  const counts = new Map(); // valueId -> count
230
230
  for (const job of jobs) {
231
231
  const referencedfield= await wixData.queryReferenced(COLLECTIONS.JOBS, job, JOBS_COLLECTION_FIELDS.MULTI_REF_JOBS_CUSTOM_VALUES)
232
+ console.log("referencedfield: ",referencedfield)
232
233
  const vals = referencedfield._items
233
234
  //const vals = job[JOB_VALUES_FIELD] || [];
234
235
  for (const val of vals) {
@@ -284,6 +285,17 @@ async function refreshFacetCounts(_$w) {
284
285
  _$w(CAREERS_MULTI_BOXES_PAGE_CONSTS.SELECTED_VALUES_REPEATER).data = selectedItems;
285
286
  }
286
287
 
288
+ async function findAll(q) {
289
+ const out = [];
290
+ let res = await q.limit(1000).find();
291
+ out.push(...res.items);
292
+ while (res.hasNext()) {
293
+ res = await res.next();
294
+ out.push(...res.items);
295
+ }
296
+ return out;
297
+ }
298
+
287
299
 
288
300
  module.exports = {
289
301
  careersMultiBoxesPageOnReady