@syncfusion/ej2-querybuilder 28.1.33 → 28.1.35

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.
@@ -1943,7 +1943,7 @@ let QueryBuilder = class QueryBuilder extends Component {
1943
1943
  let element;
1944
1944
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
1945
1945
  if ((this.isNumInput && typeof args.value === 'number') || (args.type === 'input' && args.target && args.target.classList.contains('e-numerictextbox'))
1946
- && (this.selectedColumn.validation.max !== Number.MAX_VALUE || this.selectedColumn.validation.min > 0)) {
1946
+ && (this.selectedColumn.validation && (this.selectedColumn.validation.max !== Number.MAX_VALUE || this.selectedColumn.validation.min > 0))) {
1947
1947
  this.isNumInput = false;
1948
1948
  return;
1949
1949
  }
@@ -2618,6 +2618,7 @@ let QueryBuilder = class QueryBuilder extends Component {
2618
2618
  let value = '';
2619
2619
  const isNested = field.indexOf(this.separator);
2620
2620
  for (let i = 0, iLen = dataSource.length; i < iLen; i++) {
2621
+ value = '';
2621
2622
  if (isNested === 0) {
2622
2623
  value = dataSource[i][`${field}`];
2623
2624
  }
@@ -2689,8 +2690,13 @@ let QueryBuilder = class QueryBuilder extends Component {
2689
2690
  multiSelectOpen(parentId, args) {
2690
2691
  if (this.dataSource instanceof DataManager) {
2691
2692
  const element = document.getElementById(parentId);
2692
- const dropDownObj = getComponent(closest(element, '.e-rule-container').querySelector('.e-filter-input'), 'dropdownlist');
2693
- this.selectedColumn = dropDownObj.getDataByValue(dropDownObj.value);
2693
+ const dropDownObj = getComponent(closest(element, '.e-rule-container').querySelector('.e-filter-input'), this.fieldMode === 'DropdownTree' ? 'dropdowntree' : 'dropdownlist');
2694
+ if (this.fieldMode === 'DropdownTree') {
2695
+ this.selectedColumn = this.getColumn(dropDownObj.value[0]);
2696
+ }
2697
+ else {
2698
+ this.selectedColumn = dropDownObj.getDataByValue(dropDownObj.value);
2699
+ }
2694
2700
  const value = this.selectedColumn.field;
2695
2701
  let isFetched = false;
2696
2702
  if (this.dataColl[1]) {
@@ -3346,13 +3352,24 @@ let QueryBuilder = class QueryBuilder extends Component {
3346
3352
  let selectedDate;
3347
3353
  let value;
3348
3354
  let radioBtnObj;
3355
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
3356
+ let textboxValue;
3349
3357
  switch (controlName) {
3350
3358
  case 'checkbox':
3351
3359
  value = getComponent(element, controlName).value;
3352
3360
  rule.value = (value !== '') ? value : undefined;
3353
3361
  break;
3354
3362
  case 'textbox':
3355
- rule.value = getComponent(element, controlName).value;
3363
+ textboxValue = getComponent(element, controlName).value;
3364
+ if (rule.operator.indexOf('between') > -1) {
3365
+ if (typeof rule.value === 'string') {
3366
+ rule.value = [];
3367
+ }
3368
+ rule.value[i] = textboxValue;
3369
+ }
3370
+ else {
3371
+ rule.value = textboxValue;
3372
+ }
3356
3373
  break;
3357
3374
  case 'dropdownlist':
3358
3375
  rule.value = getComponent(element, controlName).value;