sr-npm 1.7.518 → 2.0.0

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.
@@ -0,0 +1,27 @@
1
+ name: Update Sites After Release Main
2
+
3
+ on:
4
+ push:
5
+ branches:
6
+ - main
7
+ pull_request:
8
+ branches:
9
+ - main
10
+ workflow_dispatch:
11
+
12
+ permissions:
13
+ contents: write
14
+ packages: write
15
+
16
+ jobs:
17
+ update-sites:
18
+ uses: psdevteamenterprise/ci-workflows/.github/workflows/publish-and-notify.yml@main
19
+ with:
20
+ sites_to_update: "['psdevteamenterprise/tests-site', 'psdevteamenterprise/external-template', 'psdevteamenterprise/internal']"
21
+
22
+ secrets:
23
+ GH_TOKEN: ${{ secrets.GH_TOKEN }}
24
+ NPM_TOKEN: ${{ secrets.SR_NPM_PUBLISH }}
25
+ GH_APP_ID: ${{ secrets.GH_APP_ID }}
26
+ GH_APP_PRIVATE_KEY: ${{ secrets.GH_APP_PRIVATE_KEY }}
27
+ WIX_CLI_API_KEY: ${{ secrets.WIX_CLI_TOKEN }}
@@ -94,7 +94,6 @@ const COLLECTIONS_FIELDS = {
94
94
  COMPANY_ID: 'companyId',
95
95
  SMART_TOKEN: 'x-smarttoken',
96
96
  DESIRED_BRAND: 'desiredBrand',
97
- DISABLE_MULTI_BRAND: 'disableMultiBrand',
98
97
  }
99
98
 
100
99
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sr-npm",
3
- "version": "1.7.518",
3
+ "version": "2.0.0",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -3,8 +3,7 @@ const {wixData} = require('wix-data');
3
3
  const { window } = require('@wix/site-window');
4
4
  const { query,queryParams,onChange} = require("wix-location-frontend");
5
5
  const { location } = require("@wix/site-location");
6
- const { COLLECTIONS, TOKEN_NAME } = require('../backend/collectionConsts');
7
- const { getTokenFromCMS } = require('../backend/secretsData');
6
+ const { COLLECTIONS } = require('../backend/collectionConsts');
8
7
 
9
8
  const {
10
9
  debounce,
@@ -496,23 +495,13 @@ async function updateMapMarkers(_$w){
496
495
 
497
496
  }
498
497
 
499
- async function handleBrandDropdown(_$w) {
500
- const brands = await wixData.query(COLLECTIONS.BRANDS).find();
501
- let disableMultiBrand;
502
- try {
503
- disableMultiBrand = await getTokenFromCMS(TOKEN_NAME.DISABLE_MULTI_BRAND);
504
- } catch (e) {
505
- if (e.message !== "[getTokenFromCMS], No disableMultiBrand found") throw e;
506
- console.log("disableMultiBrand token wasn't found");
507
-
508
- }
509
- console.log("disableMultiBrand: ", disableMultiBrand);
510
- if (brands.items.length > 1 && disableMultiBrand !== 'true') {
498
+ async function handleBrandDropdown(_$w){
499
+ const brands=await wixData.query(COLLECTIONS.BRANDS).find();
500
+ if(brands.items.length>1){
511
501
  console.log("showing brand dropdown");
512
502
  _$w('#dropdownBrand').show();
513
503
  }
514
504
  }
515
-
516
505
  module.exports = {
517
506
  careersPageOnReady,
518
507
  };
@@ -59,6 +59,7 @@ describe('fetchPositionsFromSRAPI error handling', () => {
59
59
  });
60
60
 
61
61
 
62
+
62
63
  });
63
64
 
64
65
  describe('fetchJobDescription error handling', () => {