set default priority level to Low

This commit is contained in:
Asier Isayas
2023-10-19 13:45:47 -04:00
parent 6493c985b4
commit eacbeae417
7 changed files with 23 additions and 42 deletions

View File

@@ -1,3 +1,4 @@
import { PriorityLevel } from "@azure/cosmos";
import * as Constants from "../Common/Constants";
import { LocalStorageUtility, StorageKey } from "./StorageUtility";
@@ -6,7 +7,7 @@ export const createDefaultSettings = () => {
LocalStorageUtility.setEntryNumber(StorageKey.CustomItemPerPage, Constants.Queries.itemsPerPage);
LocalStorageUtility.setEntryString(StorageKey.IsCrossPartitionQueryEnabled, "true");
LocalStorageUtility.setEntryNumber(StorageKey.MaxDegreeOfParellism, Constants.Queries.DefaultMaxDegreeOfParallelism);
LocalStorageUtility.setEntryString(StorageKey.PriorityLevel, Constants.PriorityLevel.Default);
LocalStorageUtility.setEntryString(StorageKey.PriorityLevel, PriorityLevel.Low);
};
export const hasSettingsDefined = (): boolean => {
@@ -19,6 +20,6 @@ export const hasSettingsDefined = (): boolean => {
export const ensurePriorityLevel = () => {
if (!LocalStorageUtility.hasItem(StorageKey.PriorityLevel)) {
LocalStorageUtility.setEntryString(StorageKey.PriorityLevel, Constants.PriorityLevel.Default);
LocalStorageUtility.setEntryString(StorageKey.PriorityLevel, PriorityLevel.Low);
}
};