@magic-xpa/engine 4.1200.0-dev4120.162 → 4.1200.0-dev4120.164

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.
@@ -315,6 +315,7 @@ class ConstInterface {
315
315
  static MG_ATTR_HANDLER_ONFORM = "HandlerOnForm";
316
316
  static MG_ATTR_DROP_USERFORMATS = "dropuserformats";
317
317
  static MG_ATTR_CONTROL_NAME = "ControlName";
318
+ static MG_ATTR_SEARCH_STR = "searchStr";
318
319
  static MG_TAG_HIDDEN_CONTOLS = "HiddenControls";
319
320
  static MG_ATTR_ISNS = "Isns";
320
321
  static MG_ATTR_SPECIAL_CANCEL_ON_CREATE = "SpecialCancelOnCreate";
@@ -10101,6 +10102,7 @@ class RefreshEventCommand extends EventCommand {
10101
10102
  /// </summary>
10102
10103
  class FetchDataControlValuesEventCommand extends EventCommand {
10103
10104
  ControlName = null;
10105
+ FilterData = null;
10104
10106
  constructor() {
10105
10107
  super(InternalInterface.MG_ACT_FETCH_DATA_CONTROL_VALUES);
10106
10108
  }
@@ -10109,6 +10111,7 @@ class FetchDataControlValuesEventCommand extends EventCommand {
10109
10111
  helper.SerializeTaskTag(this.TaskTag);
10110
10112
  helper.SerializeMagicEvent(this.MagicEvent);
10111
10113
  helper.SerializeAttribute(ConstInterface.MG_ATTR_CONTROL_NAME, this.ControlName);
10114
+ helper.SerializeAttribute(ConstInterface.MG_ATTR_SEARCH_STR, this.FilterData);
10112
10115
  return helper.GetString();
10113
10116
  }
10114
10117
  getCommandInfo() {
@@ -10557,6 +10560,7 @@ class SelectProgramCommand extends ExecOperCommand {
10557
10560
  /// </summary>
10558
10561
  class ControlItemsRefreshCommand extends DataviewCommand {
10559
10562
  Control = null;
10563
+ FilterData = null;
10560
10564
  constructor() {
10561
10565
  super();
10562
10566
  }
@@ -10627,11 +10631,12 @@ class CommandFactory {
10627
10631
  /// <param name="taskId"></param>
10628
10632
  /// <param name="control"></param>
10629
10633
  /// <returns></returns>
10630
- static CreateControlItemsRefreshCommand(taskId, control) {
10634
+ static CreateControlItemsRefreshCommand(taskId, control, filterData) {
10631
10635
  let command = new ControlItemsRefreshCommand();
10632
10636
  command.CommandType = DataViewCommandType.ControlItemsRefresh;
10633
10637
  command.TaskTag = taskId;
10634
10638
  command.Control = control;
10639
+ command.FilterData = filterData;
10635
10640
  return command;
10636
10641
  }
10637
10642
  /// <summary>
@@ -10736,10 +10741,11 @@ class CommandFactory {
10736
10741
  /// <param name="controlName"></param>
10737
10742
  /// <param name="generationParam"></param>
10738
10743
  /// <returns></returns>
10739
- static CreatecFetchDataControlValuesCommand(taskTag, controlName) {
10744
+ static CreatecFetchDataControlValuesCommand(taskTag, controlName, filterData) {
10740
10745
  let fetchDataControlValuesEventCommand = new FetchDataControlValuesEventCommand();
10741
10746
  fetchDataControlValuesEventCommand.TaskTag = taskTag;
10742
10747
  fetchDataControlValuesEventCommand.ControlName = controlName;
10748
+ fetchDataControlValuesEventCommand.FilterData = filterData;
10743
10749
  return fetchDataControlValuesEventCommand;
10744
10750
  }
10745
10751
  static CreateSubformRefreshCommand(taskTag, subformTaskTag, explicitSubformRefresh) {
@@ -16871,7 +16877,7 @@ class ExpressionEvaluator extends GuiExpressionEvaluator {
16871
16877
  let control = tsk.getForm().GetCtrl(val1.StrVal);
16872
16878
  //This function is applicable only for Combo box, List box etc. i.e. for choice controls. Also it will refresh items only if Source table is attached to the data control.
16873
16879
  if (control != null && control.isChoiceControl() && control.isDataCtrl()) {
16874
- let command = CommandFactory.CreateControlItemsRefreshCommand(tsk.getTaskTag(), control);
16880
+ let command = CommandFactory.CreateControlItemsRefreshCommand(tsk.getTaskTag(), control, "");
16875
16881
  await tsk.DataviewManager.CurrentDataviewManager.Execute(command);
16876
16882
  success = true;
16877
16883
  }
@@ -18386,7 +18392,7 @@ class ExpressionEvaluator extends GuiExpressionEvaluator {
18386
18392
  if (!isNullOrUndefined(args)) {
18387
18393
  // TODO: This is a patch fix put for MXPA-30360. Problem is that the lazy loading components are not loaded in an async way.
18388
18394
  // Hence for the first record cycle the CallJS operation was not working. So, async loading of lazy loaded comps should be
18389
- // handled.
18395
+ // handled.
18390
18396
  resVal.StrVal = Commands.addCallJS(form, form.UniqueName, methodName, args);
18391
18397
  resVal.Attr = StorageAttribute.ALPHA;
18392
18398
  }
@@ -25169,13 +25175,15 @@ class ResultValue {
25169
25175
 
25170
25176
  class RemoteControlItemsRefreshCommand extends RemoteDataViewCommandBase {
25171
25177
  control = null;
25178
+ filterData = null;
25172
25179
  constructor(command) {
25173
25180
  super(command);
25174
25181
  this.control = command.Control;
25182
+ this.filterData = command.FilterData;
25175
25183
  }
25176
25184
  async Execute() {
25177
25185
  let res = new ResultValue();
25178
- let cmd = CommandFactory.CreatecFetchDataControlValuesCommand(this.Task.getTaskTag(), this.control.getName());
25186
+ let cmd = CommandFactory.CreatecFetchDataControlValuesCommand(this.Task.getTaskTag(), this.control.getName(), this.filterData);
25179
25187
  this.Task.getMGData().CmdsToServer.Add(cmd);
25180
25188
  // Fetch data control values from server.
25181
25189
  await RemoteCommandsProcessor.GetInstance().Execute_1(CommandsProcessorBase_SendingInstruction.TASKS_AND_COMMANDS, CommandsProcessorBase_SessionStage.NORMAL, res);
@@ -37370,6 +37378,13 @@ class EventsManager {
37370
37378
  case InternalInterface.MG_ACT_SET_EXTERNAL_VALUE:
37371
37379
  let refreshDisplay = await evt.getArgList().getArgValue(1, StorageAttribute.BOOLEAN, 0) === '1' ? true : false;
37372
37380
  await ctrl.validateAndSetValueIfAllowed(evt.getValue(), refreshDisplay);
37381
+ //We will be here if we type in character(s)
37382
+ //And if the control has Autocomplete Mode and On Demand property set to true, we need to display the autocomplete list
37383
+ //based on whatever value user has typed. So, excute ControlItemsRefresh command to fetch the data control's values.
37384
+ if (ctrl.isOnDemandSelectionList()) {
37385
+ let command = CommandFactory.CreateControlItemsRefreshCommand(task.getTaskTag(), ctrl, evt.getValue());
37386
+ await task.DataviewManager.CurrentDataviewManager.Execute(command);
37387
+ }
37373
37388
  break;
37374
37389
  }
37375
37390
  }
@@ -39544,7 +39559,7 @@ class CommandsTable {
39544
39559
  }
39545
39560
  }
39546
39561
 
39547
- let CurrentClientVersion = '4.1200.0-dev4120.162';
39562
+ let CurrentClientVersion = '4.1200.0-dev4120.164';
39548
39563
 
39549
39564
  // @dynamic
39550
39565
  class ClientManager {