@zeedhi/teknisa-components-common 1.64.0 → 1.65.0

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.
@@ -25,7 +25,7 @@
25
25
  <div class='fl pad1y space-right2'>
26
26
  <span class="strong">100% </span>
27
27
  <span class="quiet">Statements</span>
28
- <span class='fraction'>1389/1389</span>
28
+ <span class='fraction'>1393/1393</span>
29
29
  </div>
30
30
 
31
31
 
@@ -46,7 +46,7 @@
46
46
  <div class='fl pad1y space-right2'>
47
47
  <span class="strong">100% </span>
48
48
  <span class="quiet">Lines</span>
49
- <span class='fraction'>1318/1318</span>
49
+ <span class='fraction'>1322/1322</span>
50
50
  </div>
51
51
 
52
52
 
@@ -324,13 +324,13 @@
324
324
  <div class="chart"><div class="cover-fill cover-full" style="width: 100%"></div><div class="cover-empty" style="width: 0%"></div></div>
325
325
  </td>
326
326
  <td data-value="100" class="pct high">100%</td>
327
- <td data-value="180" class="abs high">180/180</td>
327
+ <td data-value="184" class="abs high">184/184</td>
328
328
  <td data-value="100" class="pct high">100%</td>
329
329
  <td data-value="119" class="abs high">119/119</td>
330
330
  <td data-value="100" class="pct high">100%</td>
331
331
  <td data-value="61" class="abs high">61/61</td>
332
332
  <td data-value="100" class="pct high">100%</td>
333
- <td data-value="173" class="abs high">173/173</td>
333
+ <td data-value="177" class="abs high">177/177</td>
334
334
  </tr>
335
335
 
336
336
  <tr>
@@ -371,7 +371,7 @@
371
371
  <div class='footer quiet pad2 space-top1 center small'>
372
372
  Code coverage generated by
373
373
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
374
- at 2022-11-17T19:10:08.216Z
374
+ at 2022-11-29T16:12:22.741Z
375
375
  </div>
376
376
  <script src="prettify.js"></script>
377
377
  <script>
@@ -70,7 +70,7 @@
70
70
  <a name='L5'></a><a href='#L5'>5</a>
71
71
  <a name='L6'></a><a href='#L6'>6</a></td><td class="line-coverage quiet"><span class="cline-any cline-neutral">&nbsp;</span>
72
72
  <span class="cline-any cline-neutral">&nbsp;</span>
73
- <span class="cline-any cline-yes">28x</span>
73
+ <span class="cline-any cline-yes">29x</span>
74
74
  <span class="cline-any cline-neutral">&nbsp;</span>
75
75
  <span class="cline-any cline-yes">2x</span>
76
76
  <span class="cline-any cline-neutral">&nbsp;</span></td><td class="text"><pre class="prettyprint lang-js">import { Component } from '@zeedhi/common';
@@ -85,7 +85,7 @@ export { setClick };
85
85
  <div class='footer quiet pad2 space-top1 center small'>
86
86
  Code coverage generated by
87
87
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
88
- at 2022-11-17T19:10:08.216Z
88
+ at 2022-11-29T16:12:22.741Z
89
89
  </div>
90
90
  <script src="../../prettify.js"></script>
91
91
  <script>
@@ -151,7 +151,7 @@ export { getChild };
151
151
  <div class='footer quiet pad2 space-top1 center small'>
152
152
  Code coverage generated by
153
153
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
154
- at 2022-11-17T19:10:08.216Z
154
+ at 2022-11-29T16:12:22.741Z
155
155
  </div>
156
156
  <script src="../../prettify.js"></script>
157
157
  <script>
@@ -146,7 +146,7 @@
146
146
  <div class='footer quiet pad2 space-top1 center small'>
147
147
  Code coverage generated by
148
148
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
149
- at 2022-11-17T19:10:08.216Z
149
+ at 2022-11-29T16:12:22.741Z
150
150
  </div>
151
151
  <script src="../../prettify.js"></script>
152
152
  <script>
@@ -79,7 +79,7 @@ export * from './mock-created-helper';
79
79
  <div class='footer quiet pad2 space-top1 center small'>
80
80
  Code coverage generated by
81
81
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
82
- at 2022-11-17T19:10:08.216Z
82
+ at 2022-11-29T16:12:22.741Z
83
83
  </div>
84
84
  <script src="../../prettify.js"></script>
85
85
  <script>
@@ -106,7 +106,7 @@ export { mockCreated };
106
106
  <div class='footer quiet pad2 space-top1 center small'>
107
107
  Code coverage generated by
108
108
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
109
- at 2022-11-17T19:10:08.216Z
109
+ at 2022-11-29T16:12:22.741Z
110
110
  </div>
111
111
  <script src="../../prettify.js"></script>
112
112
  <script>
@@ -692,12 +692,12 @@ FNDA:6,(anonymous_11)
692
692
  FNDA:5,(anonymous_12)
693
693
  FNDA:2,(anonymous_13)
694
694
  FNDA:1,(anonymous_14)
695
- FNDA:7,(anonymous_15)
696
- FNDA:10,(anonymous_16)
695
+ FNDA:9,(anonymous_15)
696
+ FNDA:16,(anonymous_16)
697
697
  FNDA:2,(anonymous_17)
698
- FNDA:11,(anonymous_18)
699
- FNDA:26,(anonymous_20)
700
- FNDA:25,(anonymous_21)
698
+ FNDA:13,(anonymous_18)
699
+ FNDA:32,(anonymous_20)
700
+ FNDA:33,(anonymous_21)
701
701
  FNDA:38,(anonymous_22)
702
702
  FNDA:76,(anonymous_23)
703
703
  FNDA:16,(anonymous_24)
@@ -748,24 +748,24 @@ DA:113,1
748
748
  DA:115,1
749
749
  DA:124,1
750
750
  DA:125,1
751
- DA:134,7
752
- DA:135,7
753
- DA:136,10
754
- DA:137,5
751
+ DA:134,9
752
+ DA:135,9
753
+ DA:136,16
754
+ DA:137,11
755
755
  DA:139,5
756
- DA:142,7
756
+ DA:142,9
757
757
  DA:150,2
758
758
  DA:151,2
759
- DA:159,11
760
- DA:160,11
761
- DA:161,11
762
- DA:162,11
759
+ DA:159,13
760
+ DA:160,13
761
+ DA:161,13
762
+ DA:162,13
763
763
  DA:163,2
764
764
  DA:164,1
765
765
  DA:168,1
766
- DA:173,11
767
- DA:182,26
768
- DA:185,25
766
+ DA:173,13
767
+ DA:182,32
768
+ DA:185,33
769
769
  DA:194,38
770
770
  DA:195,76
771
771
  DA:196,38
@@ -796,21 +796,21 @@ BRDA:77,9,1,6
796
796
  BRDA:88,10,0,3
797
797
  BRDA:95,11,0,1
798
798
  BRDA:111,12,0,1
799
- BRDA:136,13,0,5
799
+ BRDA:136,13,0,11
800
800
  BRDA:136,13,1,5
801
801
  BRDA:162,14,0,2
802
802
  BRDA:163,15,0,1
803
803
  BRDA:163,15,1,1
804
804
  BRDA:163,16,0,2
805
805
  BRDA:163,16,1,2
806
- BRDA:182,17,0,26
807
- BRDA:182,17,1,26
808
- BRDA:182,17,2,24
809
- BRDA:182,17,3,23
810
- BRDA:185,18,0,25
811
- BRDA:185,18,1,22
812
- BRDA:185,18,2,22
813
- BRDA:185,18,3,22
806
+ BRDA:182,17,0,32
807
+ BRDA:182,17,1,32
808
+ BRDA:182,17,2,30
809
+ BRDA:182,17,3,29
810
+ BRDA:185,18,0,33
811
+ BRDA:185,18,1,30
812
+ BRDA:185,18,2,30
813
+ BRDA:185,18,3,30
814
814
  BRDA:195,19,0,76
815
815
  BRDA:195,19,1,76
816
816
  BRDA:196,20,0,38
@@ -1170,9 +1170,9 @@ FNDA:2,(anonymous_31)
1170
1170
  FNDA:3,(anonymous_32)
1171
1171
  FNDA:106,(anonymous_33)
1172
1172
  FNDA:106,(anonymous_34)
1173
- FNDA:82,(anonymous_35)
1174
- FNDA:82,(anonymous_36)
1175
- FNDA:80,(anonymous_37)
1173
+ FNDA:83,(anonymous_35)
1174
+ FNDA:83,(anonymous_36)
1175
+ FNDA:81,(anonymous_37)
1176
1176
  FNDA:78,(anonymous_38)
1177
1177
  FNDA:120,(anonymous_40)
1178
1178
  FNDA:18,(anonymous_41)
@@ -1349,9 +1349,9 @@ DA:390,106
1349
1349
  DA:391,106
1350
1350
  DA:392,106
1351
1351
  DA:396,106
1352
- DA:397,80
1352
+ DA:397,81
1353
1353
  DA:398,16
1354
- DA:401,80
1354
+ DA:401,81
1355
1355
  DA:405,106
1356
1356
  DA:406,78
1357
1357
  DA:410,78
@@ -1546,9 +1546,9 @@ BRDA:324,15,0,1
1546
1546
  BRDA:337,16,0,1
1547
1547
  BRDA:363,17,0,1
1548
1548
  BRDA:397,18,0,16
1549
- BRDA:397,19,0,80
1550
- BRDA:397,19,1,65
1551
- BRDA:397,19,2,64
1549
+ BRDA:397,19,0,81
1550
+ BRDA:397,19,1,66
1551
+ BRDA:397,19,2,65
1552
1552
  BRDA:414,20,0,17
1553
1553
  BRDA:414,20,1,61
1554
1554
  BRDA:414,21,0,78
@@ -2421,23 +2421,23 @@ FN:492,(anonymous_28)
2421
2421
  FN:505,(anonymous_29)
2422
2422
  FN:522,(anonymous_30)
2423
2423
  FN:530,(anonymous_31)
2424
- FN:536,(anonymous_32)
2425
- FN:558,(anonymous_33)
2426
- FN:582,(anonymous_34)
2427
- FN:584,(anonymous_35)
2428
- FN:589,(anonymous_36)
2429
- FN:597,(anonymous_37)
2430
- FN:605,(anonymous_38)
2431
- FN:614,(anonymous_39)
2432
- FN:623,(anonymous_40)
2433
- FN:626,(anonymous_42)
2434
- FN:630,(anonymous_43)
2435
- FN:630,(anonymous_44)
2436
- FN:634,(anonymous_45)
2437
- FN:668,(anonymous_46)
2438
- FN:672,(anonymous_47)
2439
- FN:673,(anonymous_48)
2440
- FN:681,(anonymous_49)
2424
+ FN:539,(anonymous_32)
2425
+ FN:567,(anonymous_33)
2426
+ FN:588,(anonymous_34)
2427
+ FN:590,(anonymous_35)
2428
+ FN:595,(anonymous_36)
2429
+ FN:603,(anonymous_37)
2430
+ FN:611,(anonymous_38)
2431
+ FN:620,(anonymous_39)
2432
+ FN:629,(anonymous_40)
2433
+ FN:632,(anonymous_42)
2434
+ FN:636,(anonymous_43)
2435
+ FN:636,(anonymous_44)
2436
+ FN:640,(anonymous_45)
2437
+ FN:674,(anonymous_46)
2438
+ FN:678,(anonymous_47)
2439
+ FN:679,(anonymous_48)
2440
+ FN:687,(anonymous_49)
2441
2441
  FNF:42
2442
2442
  FNH:42
2443
2443
  FNDA:121,(anonymous_7)
@@ -2464,9 +2464,9 @@ FNDA:4,(anonymous_27)
2464
2464
  FNDA:3,(anonymous_28)
2465
2465
  FNDA:1,(anonymous_29)
2466
2466
  FNDA:3,(anonymous_30)
2467
- FNDA:6,(anonymous_31)
2467
+ FNDA:7,(anonymous_31)
2468
2468
  FNDA:10,(anonymous_32)
2469
- FNDA:6,(anonymous_33)
2469
+ FNDA:10,(anonymous_33)
2470
2470
  FNDA:1,(anonymous_34)
2471
2471
  FNDA:5,(anonymous_35)
2472
2472
  FNDA:121,(anonymous_36)
@@ -2574,69 +2574,73 @@ DA:520,1
2574
2574
  DA:522,1
2575
2575
  DA:523,3
2576
2576
  DA:524,2
2577
- DA:531,6
2578
- DA:532,6
2579
- DA:533,4
2580
- DA:534,4
2581
- DA:535,2
2582
- DA:536,2
2583
- DA:537,10
2584
- DA:538,8
2585
- DA:539,8
2586
- DA:540,8
2577
+ DA:531,7
2578
+ DA:532,7
2579
+ DA:533,5
2580
+ DA:535,5
2581
+ DA:537,5
2582
+ DA:538,2
2583
+ DA:539,2
2584
+ DA:540,10
2587
2585
  DA:541,8
2586
+ DA:542,8
2588
2587
  DA:543,8
2589
- DA:544,6
2590
- DA:547,8
2591
- DA:548,8
2592
- DA:556,2
2593
- DA:558,2
2594
- DA:559,6
2595
- DA:560,6
2596
- DA:562,6
2597
- DA:563,5
2598
- DA:565,1
2599
- DA:570,4
2600
- DA:572,4
2601
- DA:573,2
2602
- DA:575,2
2603
- DA:578,4
2604
- DA:583,1
2605
- DA:584,1
2606
- DA:585,5
2607
- DA:590,121
2608
- DA:598,121
2609
- DA:606,242
2610
- DA:607,242
2611
- DA:609,38
2612
- DA:610,19
2613
- DA:612,19
2614
- DA:614,247
2615
- DA:620,204
2616
- DA:624,6
2617
- DA:625,6
2618
- DA:626,9
2619
- DA:627,4
2620
- DA:629,4
2621
- DA:630,3
2622
- DA:631,3
2623
- DA:633,3
2624
- DA:634,6
2588
+ DA:544,8
2589
+ DA:546,8
2590
+ DA:547,6
2591
+ DA:550,8
2592
+ DA:551,8
2593
+ DA:559,2
2594
+ DA:560,2
2595
+ DA:561,2
2596
+ DA:563,2
2597
+ DA:566,3
2598
+ DA:567,3
2599
+ DA:568,10
2600
+ DA:569,10
2601
+ DA:571,10
2602
+ DA:572,8
2603
+ DA:576,3
2604
+ DA:577,3
2605
+ DA:578,1
2606
+ DA:580,1
2607
+ DA:584,5
2608
+ DA:589,1
2609
+ DA:590,1
2610
+ DA:591,5
2611
+ DA:596,121
2612
+ DA:604,121
2613
+ DA:612,242
2614
+ DA:613,242
2615
+ DA:615,38
2616
+ DA:616,19
2617
+ DA:618,19
2618
+ DA:620,247
2619
+ DA:626,204
2620
+ DA:630,6
2621
+ DA:631,6
2622
+ DA:632,9
2623
+ DA:633,4
2624
+ DA:635,4
2625
+ DA:636,3
2625
2626
  DA:637,3
2626
- DA:640,4
2627
- DA:643,6
2628
- DA:644,6
2629
- DA:647,121
2630
- DA:649,121
2631
- DA:669,2
2632
- DA:673,10
2633
- DA:675,4
2634
- DA:676,2
2635
- DA:679,2
2627
+ DA:639,3
2628
+ DA:640,6
2629
+ DA:643,3
2630
+ DA:646,4
2631
+ DA:649,6
2632
+ DA:650,6
2633
+ DA:653,121
2634
+ DA:655,121
2635
+ DA:675,2
2636
+ DA:679,10
2636
2637
  DA:681,4
2637
- DA:685,26
2638
- LF:153
2639
- LH:153
2638
+ DA:682,2
2639
+ DA:685,2
2640
+ DA:687,4
2641
+ DA:691,26
2642
+ LF:157
2643
+ LH:157
2640
2644
  BRDA:50,0,0,570
2641
2645
  BRDA:52,1,0,570
2642
2646
  BRDA:52,1,1,1
@@ -2706,30 +2710,30 @@ BRDA:512,39,0,3
2706
2710
  BRDA:512,39,1,1
2707
2711
  BRDA:512,39,2,1
2708
2712
  BRDA:523,40,0,2
2709
- BRDA:532,41,0,4
2710
- BRDA:534,42,0,2
2711
- BRDA:534,42,1,2
2712
- BRDA:534,43,0,4
2713
- BRDA:534,43,1,2
2714
- BRDA:537,44,0,8
2715
- BRDA:537,45,0,10
2716
- BRDA:537,45,1,8
2717
- BRDA:537,46,0,8
2718
- BRDA:537,46,1,2
2719
- BRDA:543,47,0,6
2720
- BRDA:562,48,0,5
2721
- BRDA:562,48,1,1
2722
- BRDA:572,49,0,2
2723
- BRDA:607,50,0,38
2724
- BRDA:607,51,0,242
2725
- BRDA:607,51,1,204
2726
- BRDA:609,52,0,19
2727
- BRDA:609,52,1,19
2728
- BRDA:625,53,0,4
2729
- BRDA:625,54,0,6
2730
- BRDA:625,54,1,2
2731
- BRDA:629,55,0,3
2732
- BRDA:675,56,0,2
2713
+ BRDA:532,41,0,5
2714
+ BRDA:537,42,0,2
2715
+ BRDA:537,42,1,3
2716
+ BRDA:537,43,0,5
2717
+ BRDA:537,43,1,3
2718
+ BRDA:540,44,0,8
2719
+ BRDA:540,45,0,10
2720
+ BRDA:540,45,1,8
2721
+ BRDA:540,46,0,8
2722
+ BRDA:540,46,1,2
2723
+ BRDA:546,47,0,6
2724
+ BRDA:560,48,0,2
2725
+ BRDA:571,49,0,8
2726
+ BRDA:577,50,0,1
2727
+ BRDA:613,51,0,38
2728
+ BRDA:613,52,0,242
2729
+ BRDA:613,52,1,204
2730
+ BRDA:615,53,0,19
2731
+ BRDA:615,53,1,19
2732
+ BRDA:631,54,0,4
2733
+ BRDA:631,55,0,6
2734
+ BRDA:631,55,1,2
2735
+ BRDA:635,56,0,3
2736
+ BRDA:681,57,0,2
2733
2737
  BRF:93
2734
2738
  BRH:93
2735
2739
  end_of_record
@@ -2868,12 +2872,12 @@ SF:tests/__helpers__/component-event-helper.ts
2868
2872
  FN:3,(anonymous_0)
2869
2873
  FNF:1
2870
2874
  FNH:1
2871
- FNDA:28,(anonymous_0)
2872
- DA:3,28
2875
+ FNDA:29,(anonymous_0)
2876
+ DA:3,29
2873
2877
  DA:5,2
2874
2878
  LF:2
2875
2879
  LH:2
2876
- BRDA:3,0,0,25
2880
+ BRDA:3,0,0,26
2877
2881
  BRF:1
2878
2882
  BRH:1
2879
2883
  end_of_record
@@ -1114,6 +1114,7 @@ class GridBase {
1114
1114
  const filterForm = Metadata.getInstance(`${this.grid.name}-filter-form`);
1115
1115
  if (filterForm.validate()) {
1116
1116
  const { datasource } = this.grid;
1117
+ this.grid.callEvent('beforeApplyFilter', { component: this.grid, event });
1117
1118
  if (datasource instanceof TekRestDatasource || datasource instanceof TekMemoryDatasource) {
1118
1119
  const dynamicFilter = {};
1119
1120
  Object.keys(filterForm.value).forEach((item) => {
@@ -1134,23 +1135,25 @@ class GridBase {
1134
1135
  }
1135
1136
  });
1136
1137
  datasource.dynamicFilter = dynamicFilter;
1138
+ if (!event.defaultPrevented) {
1139
+ datasource.setDynamicFilter(dynamicFilter);
1140
+ this.filterModal.hide();
1141
+ }
1137
1142
  }
1138
1143
  else {
1144
+ const filter = {};
1139
1145
  Object.keys(filterForm.value).forEach((item) => {
1140
1146
  let columnName = item.split(`${this.grid.name}-filter-AND-CONTAINS-`)[1];
1141
1147
  columnName = columnName.split('-').slice(0, -1).join('-'); // remove index
1142
1148
  if (filterForm.value[item]) {
1143
- datasource.filter[columnName] = filterForm.value[item];
1144
- }
1145
- else {
1146
- delete datasource.filter[columnName];
1149
+ filter[columnName] = filterForm.value[item];
1147
1150
  }
1148
1151
  });
1149
- }
1150
- this.grid.callEvent('beforeApplyFilter', { component: this.grid, event });
1151
- if (!event.defaultPrevented) {
1152
- datasource.get();
1153
- this.filterModal.hide();
1152
+ datasource.filter = filter;
1153
+ if (!event.defaultPrevented) {
1154
+ datasource.setFilter(filter);
1155
+ this.filterModal.hide();
1156
+ }
1154
1157
  }
1155
1158
  this.grid.changeLayout(event);
1156
1159
  }
@@ -1119,6 +1119,7 @@
1119
1119
  const filterForm = core.Metadata.getInstance(`${this.grid.name}-filter-form`);
1120
1120
  if (filterForm.validate()) {
1121
1121
  const { datasource } = this.grid;
1122
+ this.grid.callEvent('beforeApplyFilter', { component: this.grid, event });
1122
1123
  if (datasource instanceof TekRestDatasource || datasource instanceof TekMemoryDatasource) {
1123
1124
  const dynamicFilter = {};
1124
1125
  Object.keys(filterForm.value).forEach((item) => {
@@ -1139,23 +1140,25 @@
1139
1140
  }
1140
1141
  });
1141
1142
  datasource.dynamicFilter = dynamicFilter;
1143
+ if (!event.defaultPrevented) {
1144
+ datasource.setDynamicFilter(dynamicFilter);
1145
+ this.filterModal.hide();
1146
+ }
1142
1147
  }
1143
1148
  else {
1149
+ const filter = {};
1144
1150
  Object.keys(filterForm.value).forEach((item) => {
1145
1151
  let columnName = item.split(`${this.grid.name}-filter-AND-CONTAINS-`)[1];
1146
1152
  columnName = columnName.split('-').slice(0, -1).join('-'); // remove index
1147
1153
  if (filterForm.value[item]) {
1148
- datasource.filter[columnName] = filterForm.value[item];
1149
- }
1150
- else {
1151
- delete datasource.filter[columnName];
1154
+ filter[columnName] = filterForm.value[item];
1152
1155
  }
1153
1156
  });
1154
- }
1155
- this.grid.callEvent('beforeApplyFilter', { component: this.grid, event });
1156
- if (!event.defaultPrevented) {
1157
- datasource.get();
1158
- this.filterModal.hide();
1157
+ datasource.filter = filter;
1158
+ if (!event.defaultPrevented) {
1159
+ datasource.setFilter(filter);
1160
+ this.filterModal.hide();
1161
+ }
1159
1162
  }
1160
1163
  this.grid.changeLayout(event);
1161
1164
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zeedhi/teknisa-components-common",
3
- "version": "1.64.0",
3
+ "version": "1.65.0",
4
4
  "description": "Teknisa Components Common",
5
5
  "author": "Zeedhi <zeedhi@teknisa.com>",
6
6
  "license": "ISC",
@@ -31,5 +31,5 @@
31
31
  "peerDependencies": {
32
32
  "@zeedhi/core": "*"
33
33
  },
34
- "gitHead": "5594f5e85645cbc422c9e175b980624f08c447c2"
34
+ "gitHead": "83d40038a8a18ce4f1a59b888aa42b97d6f70cc6"
35
35
  }
@@ -2334,8 +2334,8 @@ describe('TekGrid', () => {
2334
2334
  'grid_filterClick13-filter-AND-CONTAINS-salary-0': '1000',
2335
2335
  };
2336
2336
  const applyButtonObject = new Button(applyButton);
2337
- setClick(applyButtonObject, { defaultPrevented: true });
2338
- expect((instance.datasource as TekRestDatasource).filter).toEqual({
2337
+ setClick(applyButtonObject);
2338
+ expect(instance.datasource.filter).toEqual({
2339
2339
  id: '1;2;3',
2340
2340
  name: 'teste',
2341
2341
  salary: '1000',
@@ -2343,7 +2343,9 @@ describe('TekGrid', () => {
2343
2343
  expect(beforeApplyFilterCalled).toBeTruthy();
2344
2344
  expect(changeLayoutCalled).toBeTruthy();
2345
2345
  expect(instance.columnHasFilterData({ name: 'name' } as TekGridColumn)).toBeTruthy();
2346
- expect(spyDatasourceGet).not.toBeCalled();
2346
+
2347
+ setClick(applyButtonObject, { defaultPrevented: true });
2348
+ expect(spyDatasourceGet).toBeCalledTimes(1);
2347
2349
  spyMetadata.mockReset();
2348
2350
  spyDatasourceGet.mockReset();
2349
2351
  spyModalService.mockReset();