@syncfusion/ej2-querybuilder
Advanced tools
Comparing version 24.2.9 to 25.1.35
@@ -7,2 +7,11 @@ # Changelog | ||
#### New Features | ||
- Provided the support to get / set the Mongo Query from query builder. | ||
- Provided the support to get / set the Parameter SQL and Named Parameter SQL from query builder. | ||
- Provided the Clone support to query builder rules/ groups. | ||
- Provided the Lock support to query builder rules/ groups. | ||
### QueryBuilder | ||
#### Bug Fixes | ||
@@ -9,0 +18,0 @@ |
/*! | ||
* filename: index.d.ts | ||
* version : 24.2.9 | ||
* version : 25.1.35 | ||
* Copyright Syncfusion Inc. 2001 - 2023. All rights reserved. | ||
@@ -5,0 +5,0 @@ * Use of this code is subject to the terms of our license. |
{ | ||
"_from": "@syncfusion/ej2-querybuilder@*", | ||
"_id": "@syncfusion/ej2-querybuilder@24.2.8", | ||
"_id": "@syncfusion/ej2-querybuilder@18.24.1", | ||
"_inBundle": false, | ||
"_integrity": "sha512-xNwR6dONcXxRCvZ32B9fD6m39auYyQnxbNRF5oPM2sKt5ado9TyQvIc5/9xxiZrDQ+FAlC/qDTsb88Q3ao4f1g==", | ||
"_integrity": "sha512-ujZuYcmKu3KsFyS06QnLCHFo2iAoP/xGSfn5H5+Bz72cs7gO8fkLxDHEGZ/FAq5d3H5knyxsbczY4M/T4d/A0g==", | ||
"_location": "/@syncfusion/ej2-querybuilder", | ||
@@ -26,6 +26,6 @@ "_phantomChildren": {}, | ||
], | ||
"_resolved": "https://nexus.syncfusioninternal.com/repository/ej2-hotfix-new/@syncfusion/ej2-querybuilder/-/ej2-querybuilder-24.2.8.tgz", | ||
"_shasum": "63932c8d748d6ddf307fa4a1cbed272d9bf9b6bc", | ||
"_resolved": "https://nexus.syncfusioninternal.com/repository/ej2-release/@syncfusion/ej2-querybuilder/-/ej2-querybuilder-18.24.1.tgz", | ||
"_shasum": "9c720eb30d9ffdbd3b0fdff5462862a88930b6ed", | ||
"_spec": "@syncfusion/ej2-querybuilder@*", | ||
"_where": "/jenkins/workspace/elease-automation_release_24.1.1/packages/included", | ||
"_where": "/jenkins/workspace/elease-automation_release_25.1.1/packages/included", | ||
"author": { | ||
@@ -36,8 +36,8 @@ "name": "Syncfusion Inc." | ||
"dependencies": { | ||
"@syncfusion/ej2-base": "~24.2.7", | ||
"@syncfusion/ej2-buttons": "~24.2.7", | ||
"@syncfusion/ej2-calendars": "~24.2.9", | ||
"@syncfusion/ej2-dropdowns": "~24.2.9", | ||
"@syncfusion/ej2-inputs": "~24.2.9", | ||
"@syncfusion/ej2-splitbuttons": "~24.2.7" | ||
"@syncfusion/ej2-base": "~25.1.35", | ||
"@syncfusion/ej2-buttons": "~25.1.35", | ||
"@syncfusion/ej2-calendars": "~25.1.35", | ||
"@syncfusion/ej2-dropdowns": "~25.1.35", | ||
"@syncfusion/ej2-inputs": "~25.1.35", | ||
"@syncfusion/ej2-splitbuttons": "~25.1.35" | ||
}, | ||
@@ -71,5 +71,5 @@ "deprecated": false, | ||
"typings": "index.d.ts", | ||
"version": "24.2.9", | ||
"version": "25.1.35", | ||
"sideEffects": false, | ||
"homepage": "https://www.syncfusion.com/javascript-ui-controls" | ||
} |
@@ -0,1 +1,3 @@ | ||
import * as index from './index'; | ||
index.QueryBuilder.Inject(index.QueryLibrary); | ||
export * from './index'; |
@@ -6,1 +6,2 @@ /** | ||
export * from './query-builder-model'; | ||
export * from './query-library'; |
@@ -5,1 +5,2 @@ /** | ||
export * from './query-builder'; | ||
export * from './query-library'; |
@@ -1,2 +0,2 @@ | ||
import { Component, INotifyPropertyChanged, NotifyPropertyChanges, getComponent, MouseEventArgs, Browser, compile, append } from '@syncfusion/ej2-base';import { Property, ChildProperty, Complex, L10n, closest, extend, isNullOrUndefined, Collection, cldrData } from '@syncfusion/ej2-base';import { getInstance, addClass, removeClass, rippleEffect, detach, classList } from '@syncfusion/ej2-base';import { Internationalization, DateFormatOptions, KeyboardEventArgs, getUniqueID, select } from '@syncfusion/ej2-base';import { Button, CheckBox, RadioButton, ChangeEventArgs as ButtonChangeEventArgs, RadioButtonModel } from '@syncfusion/ej2-buttons';import { DropDownList, ChangeEventArgs as DropDownChangeEventArgs, FieldSettingsModel, CheckBoxSelection, DropDownTreeModel, DropDownTree } from '@syncfusion/ej2-dropdowns';import { MultiSelect, MultiSelectChangeEventArgs, PopupEventArgs, MultiSelectModel, DropDownListModel } from '@syncfusion/ej2-dropdowns';import { EmitType, Event, EventHandler, getValue, Animation, BaseEventArgs } from '@syncfusion/ej2-base';import { Query, Predicate, DataManager, Deferred } from '@syncfusion/ej2-data';import { TextBox, NumericTextBox, InputEventArgs, ChangeEventArgs as InputChangeEventArgs } from '@syncfusion/ej2-inputs';import { TextBoxModel, NumericTextBoxModel } from '@syncfusion/ej2-inputs';import { DatePicker, ChangeEventArgs as CalendarChangeEventArgs, DatePickerModel } from '@syncfusion/ej2-calendars';import { DropDownButton, ItemModel, MenuEventArgs } from '@syncfusion/ej2-splitbuttons';import { Tooltip, createSpinner, showSpinner, hideSpinner, TooltipEventArgs } from '@syncfusion/ej2-popups';import { compile as templateCompiler } from '@syncfusion/ej2-base'; | ||
import { Component, INotifyPropertyChanged, NotifyPropertyChanges, getComponent, MouseEventArgs, Browser, compile, append, ModuleDeclaration, getDefaultDateObject } from '@syncfusion/ej2-base';import { Property, ChildProperty, Complex, L10n, closest, extend, isNullOrUndefined, Collection, cldrData } from '@syncfusion/ej2-base';import { getInstance, addClass, removeClass, rippleEffect, detach, classList } from '@syncfusion/ej2-base';import { Internationalization, DateFormatOptions, KeyboardEventArgs, getUniqueID, select } from '@syncfusion/ej2-base';import { Button, CheckBox, RadioButton, ChangeEventArgs as ButtonChangeEventArgs, RadioButtonModel } from '@syncfusion/ej2-buttons';import { DropDownList, ChangeEventArgs as DropDownChangeEventArgs, FieldSettingsModel, CheckBoxSelection, DropDownTreeModel, DropDownTree } from '@syncfusion/ej2-dropdowns';import { MultiSelect, MultiSelectChangeEventArgs, PopupEventArgs, MultiSelectModel, DropDownListModel } from '@syncfusion/ej2-dropdowns';import { EmitType, Event, EventHandler, getValue, Animation, BaseEventArgs } from '@syncfusion/ej2-base';import { Query, Predicate, DataManager, Deferred } from '@syncfusion/ej2-data';import { TextBox, NumericTextBox, InputEventArgs, ChangeEventArgs as InputChangeEventArgs } from '@syncfusion/ej2-inputs';import { TextBoxModel, NumericTextBoxModel } from '@syncfusion/ej2-inputs';import { DatePicker, ChangeEventArgs as CalendarChangeEventArgs, DatePickerModel } from '@syncfusion/ej2-calendars';import { DropDownButton, ItemModel, MenuEventArgs } from '@syncfusion/ej2-splitbuttons';import { Tooltip, createSpinner, showSpinner, hideSpinner, TooltipEventArgs } from '@syncfusion/ej2-popups';import { compile as templateCompiler } from '@syncfusion/ej2-base'; | ||
import {TemplateColumn,Validation,FormatObject,ActionEventArgs,ChangeEventArgs,RuleChangeEventArgs,FieldMode,DisplayMode,SortDirection} from "./query-builder"; | ||
@@ -168,2 +168,9 @@ import {ComponentModel} from '@syncfusion/ej2-base'; | ||
/** | ||
* Specifies whether rule is locked or not. | ||
* | ||
* @default false | ||
*/ | ||
isLocked?: boolean; | ||
} | ||
@@ -221,2 +228,30 @@ | ||
* | ||
* @default false | ||
*/ | ||
cloneRule?: boolean; | ||
/** | ||
* Specifies the boolean value in ruleDelete that the enable/disable the buttons in rule. | ||
* | ||
* @default false | ||
*/ | ||
cloneGroup?: boolean; | ||
/** | ||
* Specifies the boolean value in ruleDelete that the enable/disable the buttons in rule. | ||
* | ||
* @default false | ||
*/ | ||
lockRule?: boolean; | ||
/** | ||
* Specifies the boolean value in ruleDelete that the enable/disable the buttons in rule. | ||
* | ||
* @default false | ||
*/ | ||
lockGroup?: boolean; | ||
/** | ||
* Specifies the boolean value in ruleDelete that the enable/disable the buttons in rule. | ||
* | ||
* @default true | ||
@@ -449,2 +484,35 @@ */ | ||
/** | ||
* Specifies a boolean value whether enable / disable the new rule adding while adding new groups. | ||
* | ||
* @remarks | ||
* If this property is true, the empty rule is inserted while inserting new group. | ||
* If set to false, the group is inserted without any rule. | ||
* | ||
* @default true | ||
*/ | ||
addRuleToNewGroups?: boolean; | ||
/** | ||
* Specifies a boolean value whether enable / disable the auto selection with the first value for the field. | ||
* | ||
* @remarks | ||
* If this property is true, the field dropdown list will render with the first value of the dropdown list. | ||
* If set to false, the dropdown list render with placeholder. | ||
* | ||
* @default false | ||
*/ | ||
autoSelectField?: boolean; | ||
/** | ||
* Specifies a boolean value whether enable / disable the auto selection with the first value for the operator. | ||
* | ||
* @remarks | ||
* If this property is true, the operator dropdown list will render with the first value of the dropdown list. | ||
* If set to false, the dropdown list render with placeholder. | ||
* | ||
* @default true | ||
*/ | ||
autoSelectOperator?: boolean; | ||
/** | ||
* Specifies the separator string for column. | ||
@@ -451,0 +519,0 @@ * |
/** | ||
* Query Builder Source | ||
*/ | ||
import { Component, INotifyPropertyChanged } from '@syncfusion/ej2-base'; | ||
import { Component, INotifyPropertyChanged, ModuleDeclaration } from '@syncfusion/ej2-base'; | ||
import { ChildProperty } from '@syncfusion/ej2-base'; | ||
@@ -155,2 +155,8 @@ import { QueryBuilderModel, ShowButtonsModel, ColumnsModel, RuleModel, ValueModel } from './query-builder-model'; | ||
not: boolean; | ||
/** | ||
* Specifies whether rule is locked or not. | ||
* | ||
* @default false | ||
*/ | ||
isLocked: boolean; | ||
} | ||
@@ -199,2 +205,26 @@ /** | ||
* | ||
* @default false | ||
*/ | ||
cloneRule: boolean; | ||
/** | ||
* Specifies the boolean value in ruleDelete that the enable/disable the buttons in rule. | ||
* | ||
* @default false | ||
*/ | ||
cloneGroup: boolean; | ||
/** | ||
* Specifies the boolean value in ruleDelete that the enable/disable the buttons in rule. | ||
* | ||
* @default false | ||
*/ | ||
lockRule: boolean; | ||
/** | ||
* Specifies the boolean value in ruleDelete that the enable/disable the buttons in rule. | ||
* | ||
* @default false | ||
*/ | ||
lockGroup: boolean; | ||
/** | ||
* Specifies the boolean value in ruleDelete that the enable/disable the buttons in rule. | ||
* | ||
* @default true | ||
@@ -308,2 +338,10 @@ */ | ||
private dummyDropdownTreeDs; | ||
private groupCounter; | ||
private lockItems; | ||
private groupIndex; | ||
private ruleIndex; | ||
private isLastGroup; | ||
private cloneGrpBtnClick; | ||
private isMiddleGroup; | ||
private cloneRuleBtnClick; | ||
/** | ||
@@ -484,2 +522,32 @@ * Triggers when the component is created. | ||
/** | ||
* Specifies a boolean value whether enable / disable the new rule adding while adding new groups. | ||
* | ||
* @remarks | ||
* If this property is true, the empty rule is inserted while inserting new group. | ||
* If set to false, the group is inserted without any rule. | ||
* | ||
* @default true | ||
*/ | ||
addRuleToNewGroups: boolean; | ||
/** | ||
* Specifies a boolean value whether enable / disable the auto selection with the first value for the field. | ||
* | ||
* @remarks | ||
* If this property is true, the field dropdown list will render with the first value of the dropdown list. | ||
* If set to false, the dropdown list render with placeholder. | ||
* | ||
* @default false | ||
*/ | ||
autoSelectField: boolean; | ||
/** | ||
* Specifies a boolean value whether enable / disable the auto selection with the first value for the operator. | ||
* | ||
* @remarks | ||
* If this property is true, the operator dropdown list will render with the first value of the dropdown list. | ||
* If set to false, the dropdown list render with placeholder. | ||
* | ||
* @default true | ||
*/ | ||
autoSelectOperator: boolean; | ||
/** | ||
* Specifies the separator string for column. | ||
@@ -507,2 +575,3 @@ * | ||
protected getModuleName(): string; | ||
requiredModules(): ModuleDeclaration[]; | ||
private GetRootColumnName; | ||
@@ -750,3 +819,3 @@ private initialize; | ||
* @param {string} sqlString - 'sql String' to be passed to set the rule. | ||
* @param {boolean} sqlLocale - Set `true` if Localization for Sql query. | ||
* @param {boolean} sqlLocale - Optional. Set `true` if Localization for Sql query. | ||
* @returns {void} | ||
@@ -768,6 +837,81 @@ */ | ||
* @param {boolean} allowEscape - Set `true` if it exclude the escape character. | ||
* @param {boolean} sqlLocale - Set `true` if Localization for Sql query. | ||
* @param {boolean} sqlLocale - Set `true` if Localization for Sql query. | ||
* @returns {string} - Sql query from rules. | ||
*/ | ||
getSqlFromRules(rule?: RuleModel, allowEscape?: boolean, sqlLocale?: boolean): string; | ||
/** | ||
* Gets the parameter SQL query from rules. | ||
* | ||
* @param {RuleModel} rule – Specify the rule to be passed to get the parameter sql string. | ||
* @returns {ParameterizedSql} – Parameterized SQL query from rules. | ||
*/ | ||
getParameterizedSql(rule?: RuleModel): ParameterizedSql; | ||
/** | ||
* Sets the rules from the parameter sql query. | ||
* | ||
* @param { ParameterizedSql} sqlQuery – Specifies the parameter SQL to be passed to set the rule and load it to the query builder. | ||
* @returns {void} | ||
*/ | ||
setParameterizedSql(sqlQuery: ParameterizedSql): void; | ||
/** | ||
* Gets the named parameter SQL query from rules. | ||
* | ||
* @param {RuleModel} rule – Specify the rule to be passed to get the named parameter SQL string. | ||
* @returns {ParameterizedNamedSql} – Parameterized Named SQL query from rules. | ||
*/ | ||
getParameterizedNamedSql(rule?: RuleModel): ParameterizedNamedSql; | ||
/** | ||
* Sets the rules from the named parameter SQL query. | ||
* | ||
* @param { ParameterizedNamedSql } sqlQuery – Specifies the named parameter SQL to be passed to set the rule and load it to the query builder. | ||
* @returns {void} | ||
*/ | ||
setParameterizedNamedSql(sqlQuery: ParameterizedNamedSql): void; | ||
/** | ||
* Set the rules from Mongo query. | ||
* | ||
* @param {string} mongoQuery - 'sql String' to be passed to get the rule. | ||
* @param {boolean} mongoLocale - Set `true` if Localization for Mongo query. | ||
* @returns {void} | ||
*/ | ||
setMongoQuery(mongoQuery: string, mongoLocale?: boolean): void; | ||
/** | ||
* Gets the Mongo query from rules. | ||
* | ||
* @param {RuleModel} rule - 'rule' to be passed to get the sql. | ||
* @returns {object} - Sql query from rules. | ||
*/ | ||
getSqlFromRules(rule?: RuleModel, allowEscape?: boolean, sqlLocale?: boolean): string; | ||
getMongoQuery(rule?: RuleModel): string; | ||
/** | ||
* Clones the rule based on the rule ID to the specific group. | ||
* | ||
* @param {string} ruleID - Specifies the ruleID that needs to be cloned. | ||
* @param {string} groupID - Specifies the groupID in which the rule to be cloned. | ||
* @param {number} index - Specifies the index to insert the cloned rule inside the group. | ||
* @returns {void} | ||
*/ | ||
cloneRule(ruleID: string, groupID: string, index: number): void; | ||
/** | ||
* Clones the group based on the group ID to the specific group. | ||
* | ||
* @param {string} groupID - Specifies the groupID that needs to be cloned. | ||
* @param {string} parentGroupID - Specifies the parentGroupID in which the group to be cloned. | ||
* @param {number} index - Specifies the index to insert the cloned group inside the parent group. | ||
* @returns {void} | ||
*/ | ||
cloneGroup(groupID: string, parentGroupID: string, index: number): void; | ||
/** | ||
* Locks the rule based on the rule ID. | ||
* | ||
* @param {string} ruleID - Specifies the ruleID that needs to be locked. | ||
* @returns {void} | ||
*/ | ||
lockRule(ruleID: string): void; | ||
/** | ||
* Locks the group based on the group ID | ||
* | ||
* @param {string} groupID - Specifies the groupID that needs to be locked. | ||
* @returns {void} | ||
*/ | ||
lockGroup(groupID: string): void; | ||
private sqlParser; | ||
@@ -782,2 +926,15 @@ private parseSqlStrings; | ||
private processParser; | ||
/** | ||
* Clone the Group | ||
* | ||
* @param {Element | string} target - 'target' to be passed to clone the group. | ||
* @returns {void} | ||
*/ | ||
private groupClone; | ||
private ruleClone; | ||
private ruleLock; | ||
private groupLock; | ||
private updateLockItems; | ||
private disableHeaderControls; | ||
private disableRuleControls; | ||
} | ||
@@ -876,1 +1033,29 @@ export interface Level { | ||
} | ||
/** | ||
* Interface to define the parameter SQL query. | ||
* | ||
*/ | ||
export interface ParameterizedSql { | ||
/** | ||
* Specifies the SQL `WHERE` clause with `?` placeholders for each value. | ||
*/ | ||
sql: string; | ||
/** | ||
* Specifies the parameter values in the same order their respective placeholders appear in the `sql` string. | ||
*/ | ||
params: object[]; | ||
} | ||
/** | ||
* Interface to define the parameterized named SQL query. | ||
* | ||
*/ | ||
export interface ParameterizedNamedSql { | ||
/** | ||
* Specifies the SQL `WHERE` clause with bind variable placeholders for each value. | ||
*/ | ||
sql: string; | ||
/** | ||
* Specifies the bind variable names from the `sql` string to the associated values. | ||
*/ | ||
params: Record<string, object>; | ||
} |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
4686099
143
49492
+ Added@syncfusion/ej2-base@25.1.35(transitive)
+ Added@syncfusion/ej2-buttons@25.1.39(transitive)
+ Added@syncfusion/ej2-calendars@25.1.42(transitive)
+ Added@syncfusion/ej2-data@25.1.35(transitive)
+ Added@syncfusion/ej2-dropdowns@25.1.41(transitive)
+ Added@syncfusion/ej2-icons@25.1.35(transitive)
+ Added@syncfusion/ej2-inputs@25.1.42(transitive)
+ Added@syncfusion/ej2-lists@25.1.41(transitive)
+ Added@syncfusion/ej2-navigations@25.1.42(transitive)
+ Added@syncfusion/ej2-notifications@25.1.35(transitive)
+ Added@syncfusion/ej2-popups@25.1.42(transitive)
+ Added@syncfusion/ej2-splitbuttons@25.1.38(transitive)
- Removed@syncfusion/ej2-base@24.2.8(transitive)
- Removed@syncfusion/ej2-buttons@24.2.7(transitive)
- Removed@syncfusion/ej2-calendars@24.2.9(transitive)
- Removed@syncfusion/ej2-data@24.2.3(transitive)
- Removed@syncfusion/ej2-dropdowns@24.2.9(transitive)
- Removed@syncfusion/ej2-icons@24.2.3(transitive)
- Removed@syncfusion/ej2-inputs@24.2.9(transitive)
- Removed@syncfusion/ej2-lists@24.2.8(transitive)
- Removed@syncfusion/ej2-navigations@24.2.8(transitive)
- Removed@syncfusion/ej2-notifications@24.2.4(transitive)
- Removed@syncfusion/ej2-popups@24.2.10(transitive)
- Removed@syncfusion/ej2-splitbuttons@24.2.7(transitive)