diff --git a/README.md b/README.md index a26961636..927778f99 100644 --- a/README.md +++ b/README.md @@ -5,13 +5,13 @@ The most robust logger for Salesforce. Works with Apex, Lightning Components, Flow, Process Builder & Integrations. Designed for Salesforce admins, developers & architects. -## Unlocked Package - v4.10.2 +## Unlocked Package - v4.10.3 -[![Install Unlocked Package in a Sandbox](./images/btn-install-unlocked-package-sandbox.png)](https://test.salesforce.com/packaging/installPackage.apexp?p0=04t5Y0000023SAGQA2) -[![Install Unlocked Package in Production](./images/btn-install-unlocked-package-production.png)](https://login.salesforce.com/packaging/installPackage.apexp?p0=04t5Y0000023SAGQA2) +[![Install Unlocked Package in a Sandbox](./images/btn-install-unlocked-package-sandbox.png)](https://test.salesforce.com/packaging/installPackage.apexp?p0=04t5Y0000023SAfQAM) +[![Install Unlocked Package in Production](./images/btn-install-unlocked-package-production.png)](https://login.salesforce.com/packaging/installPackage.apexp?p0=04t5Y0000023SAfQAM) [![View Documentation](./images/btn-view-documentation.png)](https://jongpie.github.io/NebulaLogger/) -`sfdx package install --wait 20 --security-type AdminsOnly --package 04t5Y0000023S8jQAE` +`sfdx package install --wait 20 --security-type AdminsOnly --package 04t5Y0000023SAfQAM` ## Managed Package - v4.10.0 @@ -19,7 +19,7 @@ The most robust logger for Salesforce. Works with Apex, Lightning Components, Fl [![Install Managed Package in Production](./images/btn-install-managed-package-production.png)](https://login.salesforce.com/packaging/installPackage.apexp?mgd=true&p0=04t5Y0000015nWeQAI) [![View Milestone](./images/btn-view-managed-package-milestone.png)](https://github.com/jongpie/NebulaLogger/milestone/10?closed=1) -`sfdx package install --wait 20 --security-type AdminsOnly --package 04t5Y0000015nWeQAI` +`sfdx package install --wait 30 --security-type AdminsOnly --package 04t5Y0000015nWeQAI` --- diff --git a/nebula-logger/core/main/configuration/objects/LoggerSettings__c/fields/EndTime__c.field-meta.xml b/nebula-logger/core/main/configuration/objects/LoggerSettings__c/fields/EndTime__c.field-meta.xml new file mode 100644 index 000000000..6a06c6073 --- /dev/null +++ b/nebula-logger/core/main/configuration/objects/LoggerSettings__c/fields/EndTime__c.field-meta.xml @@ -0,0 +1,9 @@ + + + EndTime__c + false + Optional - when set, the LoggerSettings__c record is only used when EndTime__c >= System.now() + + false + DateTime + diff --git a/nebula-logger/core/main/configuration/objects/LoggerSettings__c/fields/StartTime__c.field-meta.xml b/nebula-logger/core/main/configuration/objects/LoggerSettings__c/fields/StartTime__c.field-meta.xml new file mode 100644 index 000000000..438b9a574 --- /dev/null +++ b/nebula-logger/core/main/configuration/objects/LoggerSettings__c/fields/StartTime__c.field-meta.xml @@ -0,0 +1,10 @@ + + + StartTime__c + false + Optional - when set, the LoggerSettings__c record is only used when StartTime__c <= System.now() + + false + false + DateTime + diff --git a/nebula-logger/core/main/log-management/lwc/loggerSettings/__tests__/data/createRecord.json b/nebula-logger/core/main/log-management/lwc/loggerSettings/__tests__/data/createRecord.json index 94d8bfbed..563cb2981 100644 --- a/nebula-logger/core/main/log-management/lwc/loggerSettings/__tests__/data/createRecord.json +++ b/nebula-logger/core/main/log-management/lwc/loggerSettings/__tests__/data/createRecord.json @@ -4,12 +4,13 @@ }, "DefaultLogOwner__c": null, "DefaultLogPurgeAction__c": "Delete", - "DefaultPlatformEventStorageLocation__c": "CUSTOM_OBJECTS", - "DefaultPlatformEventStorageLoggingLevel__c": null, - "DefaultScenario__c": null, "DefaultLogShareAccessLevel__c": "Read", "DefaultNumberOfDaysToRetainLogs__c": 14, + "DefaultPlatformEventStorageLocation__c": "CUSTOM_OBJECTS", + "DefaultPlatformEventStorageLoggingLevel__c": null, "DefaultSaveMethod__c": "EVENT_BUS", + "DefaultScenario__c": null, + "EndTime__c": null, "IsAnonymousModeEnabled__c": false, "IsApexSystemDebugLoggingEnabled__c": true, "IsDataMaskingEnabled__c": true, @@ -17,5 +18,6 @@ "IsJavaScriptConsoleLoggingEnabled__c": true, "IsRecordFieldStrippingEnabled__c": false, "IsSavingEnabled__c": true, - "LoggingLevel__c": "DEBUG" + "LoggingLevel__c": "DEBUG", + "StartTime__c": null } diff --git a/nebula-logger/core/main/log-management/lwc/loggerSettings/__tests__/data/getRecords.json b/nebula-logger/core/main/log-management/lwc/loggerSettings/__tests__/data/getRecords.json index c352c261f..c99fa28d7 100644 --- a/nebula-logger/core/main/log-management/lwc/loggerSettings/__tests__/data/getRecords.json +++ b/nebula-logger/core/main/log-management/lwc/loggerSettings/__tests__/data/getRecords.json @@ -17,6 +17,7 @@ "DefaultPlatformEventStorageLoggingLevel__c": null, "DefaultSaveMethod__c": "EVENT_BUS", "DefaultScenario__c": null, + "EndTime__c": null, "Id": "a031g000003WHwzAAG", "IsAnonymousModeEnabled__c": false, "IsApexSystemDebugLoggingEnabled__c": true, @@ -28,6 +29,7 @@ "LastModifiedDate": "2021-12-02T05:35:37.000+0000", "LoggingLevel__c": "INFO", "SetupOwnerId": "00D1g000000HgecEAC", + "StartTime__c": null, "CreatedBy": { "attributes": { "type": "User", @@ -75,6 +77,7 @@ "DefaultPlatformEventStorageLoggingLevel__c": null, "DefaultSaveMethod__c": "EVENT_BUS", "DefaultScenario__c": null, + "EndTime__c": null, "Id": "a031g000003WFMiAAO", "IsAnonymousModeEnabled__c": false, "IsApexSystemDebugLoggingEnabled__c": true, @@ -86,6 +89,7 @@ "LastModifiedDate": "2021-12-02T05:00:18.000+0000", "LoggingLevel__c": "DEBUG", "SetupOwnerId": "00e1g000000ySdaAAE", + "StartTime__c": null, "CreatedBy": { "attributes": { "type": "User", @@ -133,6 +137,7 @@ "DefaultPlatformEventStorageLoggingLevel__c": null, "DefaultSaveMethod__c": "EVENT_BUS", "DefaultScenario__c": null, + "EndTime__c": null, "Id": "a031g000003WHvQAAW", "IsAnonymousModeEnabled__c": false, "IsApexSystemDebugLoggingEnabled__c": true, @@ -144,6 +149,7 @@ "LastModifiedDate": "2021-12-02T05:35:02.000+0000", "LoggingLevel__c": "INFO", "SetupOwnerId": "00e1g000000ySdXAAU", + "StartTime__c": null, "CreatedBy": { "attributes": { "type": "User", @@ -191,6 +197,7 @@ "DefaultPlatformEventStorageLoggingLevel__c": null, "DefaultSaveMethod__c": "EVENT_BUS", "DefaultScenario__c": null, + "EndTime__c": null, "Id": "a031g000003WFMOAA4", "IsAnonymousModeEnabled__c": false, "IsApexSystemDebugLoggingEnabled__c": true, @@ -202,6 +209,7 @@ "LastModifiedDate": "2021-11-30T05:22:42.000+0000", "LoggingLevel__c": "FINER", "SetupOwnerId": "0051g000007o2bTAAQ", + "StartTime__c": null, "CreatedBy": { "attributes": { "type": "User", @@ -249,6 +257,7 @@ "DefaultPlatformEventStorageLoggingLevel__c": null, "DefaultSaveMethod__c": "EVENT_BUS", "DefaultScenario__c": null, + "EndTime__c": null, "Id": "a031g000003WFMYAA4", "IsAnonymousModeEnabled__c": false, "IsApexSystemDebugLoggingEnabled__c": true, @@ -260,6 +269,7 @@ "LastModifiedDate": "2021-11-30T04:59:57.000+0000", "LoggingLevel__c": "DEBUG", "SetupOwnerId": "0051g000007o2baAAA", + "StartTime__c": null, "CreatedBy": { "attributes": { "type": "User", @@ -307,6 +317,7 @@ "DefaultPlatformEventStorageLoggingLevel__c": null, "DefaultSaveMethod__c": "EVENT_BUS", "DefaultScenario__c": null, + "EndTime__c": null, "Id": "a031g000003WHvVAAW", "IsAnonymousModeEnabled__c": false, "IsApexSystemDebugLoggingEnabled__c": true, @@ -318,6 +329,7 @@ "LastModifiedDate": "2021-11-30T22:36:40.000+0000", "LoggingLevel__c": "DEBUG", "SetupOwnerId": "0051g000007o2bcAAA", + "StartTime__c": null, "CreatedBy": { "attributes": { "type": "User", @@ -365,6 +377,7 @@ "DefaultPlatformEventStorageLoggingLevel__c": null, "DefaultSaveMethod__c": "EVENT_BUS", "DefaultScenario__c": null, + "EndTime__c": null, "Id": "a031g000003WFORAA4", "IsAnonymousModeEnabled__c": false, "IsApexSystemDebugLoggingEnabled__c": true, @@ -376,6 +389,7 @@ "LastModifiedDate": "2021-11-30T06:16:01.000+0000", "LoggingLevel__c": "DEBUG", "SetupOwnerId": "0051g000007o2bZAAQ", + "StartTime__c": null, "CreatedBy": { "attributes": { "type": "User", @@ -423,6 +437,7 @@ "DefaultPlatformEventStorageLoggingLevel__c": null, "DefaultSaveMethod__c": "EVENT_BUS", "DefaultScenario__c": null, + "EndTime__c": null, "Id": "a031g000003WFMJAA4", "IsAnonymousModeEnabled__c": false, "IsApexSystemDebugLoggingEnabled__c": true, @@ -434,6 +449,7 @@ "LastModifiedDate": "2021-12-02T05:09:48.000+0000", "LoggingLevel__c": "DEBUG", "SetupOwnerId": "0051g000007oJ8cAAE", + "StartTime__c": null, "CreatedBy": { "attributes": { "type": "User", @@ -481,6 +497,7 @@ "DefaultPlatformEventStorageLoggingLevel__c": null, "DefaultSaveMethod__c": "EVENT_BUS", "DefaultScenario__c": null, + "EndTime__c": null, "Id": "a031g000003WFMnAAO", "IsAnonymousModeEnabled__c": false, "IsApexSystemDebugLoggingEnabled__c": true, @@ -492,6 +509,7 @@ "LastModifiedDate": "2021-11-30T05:22:31.000+0000", "LoggingLevel__c": "WARN", "SetupOwnerId": "0051g000007o2bNAAQ", + "StartTime__c": null, "CreatedBy": { "attributes": { "type": "User", diff --git a/nebula-logger/core/main/log-management/lwc/loggerSettings/__tests__/data/getSchemaForName.json b/nebula-logger/core/main/log-management/lwc/loggerSettings/__tests__/data/getSchemaForName.json index 38c21e03b..cb33840a6 100644 --- a/nebula-logger/core/main/log-management/lwc/loggerSettings/__tests__/data/getSchemaForName.json +++ b/nebula-logger/core/main/log-management/lwc/loggerSettings/__tests__/data/getSchemaForName.json @@ -90,6 +90,20 @@ "localApiName": "DefaultSaveMethod__c", "type": "String" }, + "DefaultScenario__c": { + "apiName": "DefaultScenario__c", + "inlineHelpText": "Sets a default scenario for the transaction", + "label": "Log Scenario", + "localApiName": "DefaultScenario__c", + "type": "String" + }, + "EndTime__c": { + "apiName": "EndTime__c", + "inlineHelpText": "TODO", + "label": "End Time", + "localApiName": "EndTime__c", + "type": "Datetime" + }, "IsAnonymousModeEnabled__c": { "apiName": "IsAnonymousModeEnabled__c", "inlineHelpText": "When enabled, any logs generated will not have any user-specific details set - any fields related to the User, Profile, etc. will be null. Note: this feature only works properly when using the save method EVENT_BUS.", @@ -145,12 +159,12 @@ "localApiName": "LoggingLevel__c", "type": "String" }, - "DefaultScenario__c": { - "apiName": "DefaultScenario__c", - "inlineHelpText": "Sets a default scenario for the transaction", - "label": "Log Scenario", - "localApiName": "DefaultScenario__c", - "type": "String" + "StartTime__c": { + "apiName": "StartTime__c", + "inlineHelpText": "TODO", + "label": "Start Time", + "localApiName": "StartTime__c", + "type": "Datetime" } }, "label": "Logger Settings", diff --git a/nebula-logger/core/main/log-management/lwc/loggerSettings/loggerSettings.html b/nebula-logger/core/main/log-management/lwc/loggerSettings/loggerSettings.html index 863dadbed..657613df9 100644 --- a/nebula-logger/core/main/log-management/lwc/loggerSettings/loggerSettings.html +++ b/nebula-logger/core/main/log-management/lwc/loggerSettings/loggerSettings.html @@ -39,7 +39,7 @@ -