Skip to content
This repository was archived by the owner on Mar 18, 2024. It is now read-only.

Commit

Permalink
Merge branch 'main' into issue1417
Browse files Browse the repository at this point in the history
  • Loading branch information
azlam-abdulsalam authored Nov 8, 2023
2 parents 6228916 + 2f07ff4 commit 75e2424
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion packages/core/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@dxatscale/sfpowerscripts.core",
"version": "36.2.0",
"version": "36.3.0",
"description": "Core Module used by sfpowerscripts",
"main": "lib/index",
"types": "lib/index",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import SFPLogger, { LoggerLevel } from '@dxatscale/sfp-logger';
import { Org } from '@salesforce/core';
import ScratchOrg from '../../../ScratchOrg';
const retry = require('async-retry');
const ORDER_BY_FILTER = ' ORDER BY CreatedDate ASC';
const ORDER_BY_FILTER = ' ORDER BY CreatedDate DESC';

export default class ScratchOrgInfoFetcher {
constructor(private hubOrg: Org) {}
Expand Down Expand Up @@ -47,9 +47,9 @@ export default class ScratchOrgInfoFetcher {
let query;

if (tag)
query = `SELECT Pooltag__c, Id, CreatedDate, ScratchOrg, ExpirationDate, SignupUsername, SignupEmail, Password__c, Allocation_status__c,LoginUrl,SfdxAuthUrl__c FROM ScratchOrgInfo WHERE Pooltag__c = '${tag}' AND Status = 'Active' `;
query = `SELECT Pooltag__c, Id, CreatedDate, ScratchOrg, ExpirationDate, SignupUsername, SignupEmail, Password__c, Allocation_status__c, LoginUrl, SfdxAuthUrl__c FROM ScratchOrgInfo WHERE Pooltag__c = '${tag}' AND Status = 'Active' `;
else
query = `SELECT Pooltag__c, Id, CreatedDate, ScratchOrg, ExpirationDate, SignupUsername, SignupEmail, Password__c, Allocation_status__c,LoginUrl,SfdxAuthUrl__c FROM ScratchOrgInfo WHERE Pooltag__c != null AND Status = 'Active' `;
query = `SELECT Pooltag__c, Id, CreatedDate, ScratchOrg, ExpirationDate, SignupUsername, SignupEmail, Password__c, Allocation_status__c, LoginUrl, SfdxAuthUrl__c FROM ScratchOrgInfo WHERE Pooltag__c != null AND Status = 'Active' `;

if (isMyPool) {
query = query + ` AND createdby.username = '${this.hubOrg.getUsername()}' `;
Expand All @@ -74,7 +74,7 @@ export default class ScratchOrgInfoFetcher {
return retry(
async (bail) => {
let query;
query = `SELECT Id, Pooltag__c,SignupUsername,Description,ScratchOrg FROM ScratchOrgInfo WHERE Pooltag__c = null AND Status = 'Active'`;
query = `SELECT Id, Pooltag__c, SignupUsername, Description, ScratchOrg FROM ScratchOrgInfo WHERE Pooltag__c = null AND Status = 'Active'`;
query = query + ORDER_BY_FILTER;
SFPLogger.log('QUERY:' + query, LoggerLevel.TRACE);
const results = (await hubConn.query(query)) as any;
Expand Down Expand Up @@ -104,7 +104,7 @@ export default class ScratchOrgInfoFetcher {

return retry(
async (bail) => {
let query = `SELECT Id, CreatedDate, ScratchOrg, ExpirationDate, SignupUsername, SignupEmail, Password__c, Allocation_status__c,LoginUrl FROM ScratchOrgInfo WHERE Pooltag__c = '${tag}' AND Status = 'Active' `;
let query = `SELECT Id, CreatedDate, ScratchOrg, ExpirationDate, SignupUsername, SignupEmail, Password__c, Allocation_status__c, LoginUrl FROM ScratchOrgInfo WHERE Pooltag__c = '${tag}' AND Status = 'Active' `;
SFPLogger.log('QUERY:' + query, LoggerLevel.TRACE);
const results = (await hubConn.query(query)) as any;
SFPLogger.log('RESULT:' + JSON.stringify(results), LoggerLevel.TRACE);
Expand All @@ -119,7 +119,7 @@ export default class ScratchOrgInfoFetcher {

return retry(
async (bail) => {
let query = `SELECT Id, CreatedDate, ScratchOrg, ExpirationDate, SignupUsername, SignupEmail, Password__c, Allocation_status__c,LoginUrl FROM ScratchOrgInfo WHERE Pooltag__c = '${tag}' AND Status = 'Active' `;
let query = `SELECT Id, CreatedDate, ScratchOrg, ExpirationDate, SignupUsername, SignupEmail, Password__c, Allocation_status__c, LoginUrl FROM ScratchOrgInfo WHERE Pooltag__c = '${tag}' AND Status = 'Active' `;
SFPLogger.log('QUERY:' + query, LoggerLevel.TRACE);
const results = (await hubConn.query(query)) as any;
return results.totalSize;
Expand Down
4 changes: 2 additions & 2 deletions packages/sfpowerscripts-cli/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@dxatscale/sfpowerscripts",
"description": "DX@Scale Toolkit",
"version": "25.2.0",
"version": "25.3.0",
"license": "MIT",
"author": "dxatscale",
"release": "December 23",
Expand All @@ -13,7 +13,7 @@
"dependencies": {
"@dxatscale/sfdx-process-wrapper": "^1.0.2",
"@dxatscale/sfp-logger": "^2.1.2",
"@dxatscale/sfpowerscripts.core": "^36.2.0",
"@dxatscale/sfpowerscripts.core": "^36.3.0",
"@dxatscale/sfprofiles": "^2.0.8",
"@oclif/core": "2.11.8",
"@oclif/plugin-commands": "^3.0.3",
Expand Down
2 changes: 1 addition & 1 deletion pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 75e2424

Please sign in to comment.