@magic-xpa/engine 4.1000.0-dev4100.109 → 4.1000.0-dev4100.113

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.
Files changed (45) hide show
  1. package/esm2020/src/ClientManager.mjs +11 -11
  2. package/esm2020/src/ConstInterface.mjs +3 -1
  3. package/esm2020/src/CurrentClientVersion.mjs +2 -2
  4. package/esm2020/src/commands/ClientToServer/DataviewCommand.mjs +6 -6
  5. package/esm2020/src/commands/ClientToServer/EvaluateCommand.mjs +4 -4
  6. package/esm2020/src/commands/ClientToServer/EventCommand.mjs +8 -8
  7. package/esm2020/src/commands/ClientToServer/ExecOperCommand.mjs +4 -4
  8. package/esm2020/src/commands/ClientToServer/IniputForceWriteCommand.mjs +5 -5
  9. package/esm2020/src/commands/ClientToServer/RecomputeCommand.mjs +7 -7
  10. package/esm2020/src/commands/ClientToServer/TransactionCommand.mjs +6 -6
  11. package/esm2020/src/commands/ServerToClient/EnhancedVerifyCommand.mjs +8 -8
  12. package/esm2020/src/commands/ServerToClient/ResultCommand.mjs +7 -7
  13. package/esm2020/src/data/DataView.mjs +34 -34
  14. package/esm2020/src/data/DataviewManager.mjs +7 -7
  15. package/esm2020/src/data/Record.mjs +10 -10
  16. package/esm2020/src/data/TaskTransactionManager.mjs +4 -4
  17. package/esm2020/src/data/XMLBasedDcValuesBuilder.mjs +5 -5
  18. package/esm2020/src/env/Environment.mjs +14 -7
  19. package/esm2020/src/env/MirrorString.mjs +2 -3
  20. package/esm2020/src/event/EventHandler.mjs +6 -3
  21. package/esm2020/src/event/EventHandlerPosition.mjs +5 -1
  22. package/esm2020/src/event/RunTimeEvent.mjs +16 -16
  23. package/esm2020/src/gui/FormsTable.mjs +8 -8
  24. package/esm2020/src/gui/MgControl.mjs +10 -10
  25. package/esm2020/src/gui/MgForm.mjs +3 -6
  26. package/esm2020/src/http/HttpManager.mjs +8 -8
  27. package/esm2020/src/remote/RemoteCommandsProcessor.mjs +35 -26
  28. package/esm2020/src/rt/DataviewHeaderBase.mjs +16 -16
  29. package/esm2020/src/security/UserDetails.mjs +12 -12
  30. package/esm2020/src/tasks/MGData.mjs +4 -4
  31. package/esm2020/src/tasks/RCTimer.mjs +10 -10
  32. package/esm2020/src/tasks/Task.mjs +42 -42
  33. package/esm2020/src/util/FlowMonitorQueue.mjs +107 -2
  34. package/esm2020/src/util/PrmMap.mjs +6 -6
  35. package/esm2020/src/util/ReturnResult.mjs +7 -7
  36. package/fesm2015/magic-xpa-engine.mjs +404 -281
  37. package/fesm2015/magic-xpa-engine.mjs.map +1 -1
  38. package/fesm2020/magic-xpa-engine.mjs +404 -281
  39. package/fesm2020/magic-xpa-engine.mjs.map +1 -1
  40. package/package.json +6 -6
  41. package/src/ConstInterface.d.ts +2 -0
  42. package/src/env/Environment.d.ts +2 -0
  43. package/src/util/FlowMonitorQueue.d.ts +8 -0
  44. package/src/util/PrmMap.d.ts +1 -1
  45. package/magic-xpa-engine.d.ts +0 -2
@@ -1,6 +1,6 @@
1
1
  import { StringBuilder, Int32, NString, ApplicationException, NNumber, List, Debug, Char, RefParam, NumberStyles, HashUtils, DateTime, Dictionary, Stack, NChar, isNullOrUndefined, WebException, Thread, Encoding, Exception, isUndefined, Hashtable, NotImplementedException, Array_Enumerator, ISO_8859_1_Encoding, Int64 } from '@magic-xpa/mscorelib';
2
2
  import { XMLConstants, StorageAttribute, ViewRefreshMode, InternalInterface, Logger, StorageAttributeCheck, StrUtil, SubformType, TableBehaviour, MgControlType, ScrollBarThumbType, ForceExit, XmlParser, Misc, Base64, Priority, SyncExecutionHelper, Queue, Constants, DateTimeUtils, Logger_LogLevels, Logger_MessageDirection, MsgInterface, RequestInfo, OSEnvironment, JSON_Utils, UtilDateJpn, UtilStrByteMode, PICInterface, WindowType, BrkScope, RaiseAt, CtrlButtonTypeGui } from '@magic-xpa/utils';
3
- import { RecordUtils, GuiFieldBase, ExpVal, BlobType, FieldDef, GuiTaskBase, MgControlBase, PropInterface, GuiDataCollection, CommandType, Commands, HtmlProperties, ControlTable, Modifiers, KeyboardItem, TaskDefinitionIdTableSaxHandler, DisplayConvertor, MgTimer, GuiConstants, RuntimeContextBase, UsernamePasswordCredentials, Styles, Manager, NUM_TYPE, VectorType, GuiExpressionEvaluator, ExpressionInterface, PIC, DataModificationTypes, GuiDataViewBase, ObjectReferencesCollection, EMPTY_DCREF, ObjectReferenceBase, PropTable, FieldsTable as FieldsTable$1, DcValuesBuilderBase, MgFormBase, GuiEnvironment, TaskDefinitionId, Events, Helps, FocusManager, EventsProcessor, UIBridge } from '@magic-xpa/gui';
3
+ import { RecordUtils, GuiFieldBase, ExpVal, BlobType, FieldDef, GuiTaskBase, MgControlBase, PropInterface, GuiDataCollection, CommandType, Commands, HtmlProperties, ControlTable, Modifiers, KeyboardItem, TaskDefinitionIdTableSaxHandler, DisplayConvertor, VectorType, PIC, MgTimer, GuiConstants, RuntimeContextBase, UsernamePasswordCredentials, Styles, Manager, NUM_TYPE, GuiExpressionEvaluator, ExpressionInterface, DataModificationTypes, GuiDataViewBase, ObjectReferencesCollection, EMPTY_DCREF, ObjectReferenceBase, PropTable, FieldsTable as FieldsTable$1, DcValuesBuilderBase, MgFormBase, GuiEnvironment, TaskDefinitionId, Events, Helps, FocusManager, EventsProcessor, UIBridge } from '@magic-xpa/gui';
4
4
  import { HttpHeaders, HttpErrorResponse } from '@angular/common/http';
5
5
  import { timer, Subject } from 'rxjs';
6
6
 
@@ -271,6 +271,7 @@ ConstInterface.MG_ATTR_LOCAL_AS400SET = "local_as400set";
271
271
  ConstInterface.MG_ATTR_LOCAL_EXTRA_GENGO = "local_extraGengo";
272
272
  ConstInterface.MG_ATTR_LOCAL_FLAGS = "local_flags";
273
273
  ConstInterface.MG_ATTR_SPEACIAL_ANSI_EXP = "SpecialAnsiExpression";
274
+ ConstInterface.MG_ATTR_SPECIAL_IMMEDIATE_HANDLER_END = "SpecialImmediateHandlerEnd";
274
275
  ConstInterface.MG_ATTR_SPECIAL_SHOW_STATUSBAR_PANES = "SpecialShowStatusBarPanes";
275
276
  ConstInterface.MG_ATTR_SPECIAL_ROUTE_TO_ROOT_PROG_ON_CONTEXT_RECREATION = "SpecialRouteToRootProgramOnContextRecreation";
276
277
  ConstInterface.MG_ATTR_SPECIAL_SPECIAL_EDIT_LEFT_ALIGN = "SpecialEditLeftAlign";
@@ -475,6 +476,7 @@ ConstInterface.RC_TOKEN_DATA = "DATA=";
475
476
  ConstInterface.WEBCLIENT_REINITIALIZE_REQUEST = "WCREINITIALIZEREQUEST=Y";
476
477
  ConstInterface.MAIN_PROG_VIEW = "MainProgramsDataView";
477
478
  ConstInterface.GLOBAL_PARAM_LIST = "GlobalParamList";
479
+ ConstInterface.ENV_VAR_LIST = "EnvVarList";
478
480
  ConstInterface.LAST_EXCEPTION = "LastException";
479
481
  ConstInterface.CTX_REMOVED_FROM_SRVR = "CtxRemovedFromSrvr";
480
482
  ConstInterface.LAST_ROUTE_EVENT = "LastRouteEvent";
@@ -640,13 +642,6 @@ class CommandSerializationHelper {
640
642
  }
641
643
 
642
644
  class EventCommand extends ClientOriginatedCommandTaskTag {
643
- constructor(magicEvent) {
644
- super();
645
- this.TaskTag = null;
646
- this.MagicEvent = 0;
647
- this.ClientRecId = 0;
648
- this.MagicEvent = magicEvent;
649
- }
650
645
  get CommandTypeAttribute() {
651
646
  return ConstInterface.MG_ATTR_VAL_EVENT;
652
647
  }
@@ -662,6 +657,13 @@ class EventCommand extends ClientOriginatedCommandTaskTag {
662
657
  return false;
663
658
  return true;
664
659
  }
660
+ constructor(magicEvent) {
661
+ super();
662
+ this.TaskTag = null;
663
+ this.MagicEvent = 0;
664
+ this.ClientRecId = 0;
665
+ this.MagicEvent = magicEvent;
666
+ }
665
667
  SerializeCommandData() {
666
668
  let helper = new CommandSerializationHelper();
667
669
  helper.SerializeTaskTag(this.TaskTag);
@@ -1171,15 +1173,6 @@ class OpeningTaskDetails {
1171
1173
  }
1172
1174
 
1173
1175
  class MgControl extends MgControlBase {
1174
- constructor(type, taskOrParentMgForm, parentControlOrParentControlIdx) {
1175
- if (arguments.length === 0)
1176
- super();
1177
- else if (arguments.length === 3 && (type === null || type.constructor === Number) && (taskOrParentMgForm === null || taskOrParentMgForm instanceof TaskBase) && (parentControlOrParentControlIdx === null || parentControlOrParentControlIdx.constructor === Number))
1178
- super(type, taskOrParentMgForm.getForm(), parentControlOrParentControlIdx);
1179
- else
1180
- super(type, taskOrParentMgForm, parentControlOrParentControlIdx);
1181
- this.initialize();
1182
- }
1183
1176
  initialize() {
1184
1177
  this._focusedStopExecution = false;
1185
1178
  this._inControlSuffix = false;
@@ -1192,6 +1185,15 @@ class MgControl extends MgControlBase {
1192
1185
  this.HasZoomHandler = false;
1193
1186
  this.ArgList = null;
1194
1187
  }
1188
+ constructor(type, taskOrParentMgForm, parentControlOrParentControlIdx) {
1189
+ if (arguments.length === 0)
1190
+ super();
1191
+ else if (arguments.length === 3 && (type === null || type.constructor === Number) && (taskOrParentMgForm === null || taskOrParentMgForm instanceof TaskBase) && (parentControlOrParentControlIdx === null || parentControlOrParentControlIdx.constructor === Number))
1192
+ super(type, taskOrParentMgForm.getForm(), parentControlOrParentControlIdx);
1193
+ else
1194
+ super(type, taskOrParentMgForm, parentControlOrParentControlIdx);
1195
+ this.initialize();
1196
+ }
1195
1197
  GetVarIndex() {
1196
1198
  return super.getForm().getTask().DataView.Dvcount + this.veeIndx;
1197
1199
  }
@@ -3124,6 +3126,21 @@ class MgPriorityBlockingQueue {
3124
3126
  }
3125
3127
 
3126
3128
  class RunTimeEvent extends RunTimeEventBase {
3129
+ set Control(value) {
3130
+ this._ctrl = value;
3131
+ }
3132
+ set DisplayLine(value) {
3133
+ this._displayLine = value;
3134
+ }
3135
+ get Control() {
3136
+ return this._ctrl;
3137
+ }
3138
+ get ControlsList() {
3139
+ return this._controlsList;
3140
+ }
3141
+ get Direction() {
3142
+ return this._direction;
3143
+ }
3127
3144
  constructor(taskRefOrCtrlRefOrTaskrefOrFldRefOrEvt, ctrlRefOrGuiTriggeredEventOrLineOrControlsListOrDirectionOrColumnHeaderOrRtEvtOrCurrentTask, ignoreSpecifiedControlOrGuiTriggeredEventOrLineOrXOrControlOrActivatedFromMDIFrame, yOrCtlIdx, width, height) {
3128
3145
  super();
3129
3146
  this._controlsList = null;
@@ -3185,21 +3202,6 @@ class RunTimeEvent extends RunTimeEventBase {
3185
3202
  else if (arguments.length === 1 && taskRefOrCtrlRefOrTaskrefOrFldRefOrEvt instanceof RunTimeEvent)
3186
3203
  Object.assign(this, taskRefOrCtrlRefOrTaskrefOrFldRefOrEvt);
3187
3204
  }
3188
- set Control(value) {
3189
- this._ctrl = value;
3190
- }
3191
- set DisplayLine(value) {
3192
- this._displayLine = value;
3193
- }
3194
- get Control() {
3195
- return this._ctrl;
3196
- }
3197
- get ControlsList() {
3198
- return this._controlsList;
3199
- }
3200
- get Direction() {
3201
- return this._direction;
3202
- }
3203
3205
  constructor_5(taskRef) {
3204
3206
  this.init(taskRef);
3205
3207
  }
@@ -3529,7 +3531,17 @@ class FlowMonitorQueue {
3529
3531
  this._isRecompute = false;
3530
3532
  this._isTask = false;
3531
3533
  this._isTaskFlow = false;
3534
+ this._isDataView = false;
3532
3535
  this.ShouldSerialize = false;
3536
+ this.padRight = (string, length, character = ' ') => {
3537
+ let result = "";
3538
+ let totalLength = length - string.length;
3539
+ for (let i = 0; i < totalLength; i++) {
3540
+ result = character + result;
3541
+ }
3542
+ result = result + string;
3543
+ return result;
3544
+ };
3533
3545
  }
3534
3546
  static get Instance() {
3535
3547
  if (FlowMonitorQueue._instance === null)
@@ -3587,6 +3599,9 @@ class FlowMonitorQueue {
3587
3599
  case ConstInterface.MG_ATTR_TASKFLW:
3588
3600
  this._isTaskFlow = XmlParser.getBoolean(valueStr);
3589
3601
  break;
3602
+ case ConstInterface.MG_TAG_DATAVIEW:
3603
+ this._isDataView = XmlParser.getBoolean(valueStr);
3604
+ break;
3590
3605
  case ConstInterface.MG_ATTR_RECOMP:
3591
3606
  this._isRecompute = XmlParser.getBoolean(valueStr);
3592
3607
  break;
@@ -3644,6 +3659,96 @@ class FlowMonitorQueue {
3644
3659
  Logger.Instance.WriteSupportToLog(taskInfo + ": " + info, true);
3645
3660
  }
3646
3661
  }
3662
+ appendVirtualsAndParameters(currentValues) {
3663
+ let act = new ActivityItem(this, FlowMonitorQueue.ACT_TASK_FLW, InternalInterface.MG_ACT_REC_PREFIX);
3664
+ act.setInfo(currentValues);
3665
+ this._queue.put(act);
3666
+ }
3667
+ addDataViewFlow(task) {
3668
+ if (this._isDataView) {
3669
+ let fldTab = task.DataView.GetFieldsTab();
3670
+ let preparedDisplayString = "";
3671
+ let finaldisplayData = "\n";
3672
+ let fldValue;
3673
+ let data = "";
3674
+ for (let i = 0; i < fldTab.getSize(); i++) {
3675
+ let fldDef = fldTab.getField(i);
3676
+ if (!fldDef.IsEventHandlerField && (fldDef.IsVirtual && !fldDef.VirAsReal) || fldDef.isParam()) {
3677
+ fldValue = fldDef.isNull() ? fldDef.getNullValue() : fldDef.getValue(true);
3678
+ data = this.getFieldData(fldDef.getType(), fldValue, fldDef.getPicture(), fldDef.getCellsType(), task);
3679
+ preparedDisplayString = this.PrepareDisplayString(fldDef.isParam(), fldDef.getVarName(), data, true);
3680
+ finaldisplayData = finaldisplayData + preparedDisplayString + "\n";
3681
+ }
3682
+ }
3683
+ this.appendVirtualsAndParameters(finaldisplayData);
3684
+ }
3685
+ }
3686
+ getFieldData(Storagetype, data, picture, vecCellType, task) {
3687
+ switch (Storagetype) {
3688
+ case StorageAttribute.DOTNET:
3689
+ data = FlowMonitorQueue.UNPRINTABLE_STR_LOG;
3690
+ break;
3691
+ case StorageAttribute.BLOB:
3692
+ {
3693
+ if (BlobType.isValidBlob(data)) {
3694
+ let contentType = BlobType.getContentType(data);
3695
+ if (contentType == BlobType.CONTENT_TYPE_ANSI || contentType == BlobType.CONTENT_TYPE_UNICODE)
3696
+ data = data != null ? BlobType.getString(data) : "";
3697
+ else
3698
+ data = FlowMonitorQueue.UNPRINTABLE_STR_LOG;
3699
+ }
3700
+ else
3701
+ data = "";
3702
+ }
3703
+ break;
3704
+ case StorageAttribute.NUMERIC:
3705
+ case StorageAttribute.DATE:
3706
+ case StorageAttribute.TIME:
3707
+ let conv = DisplayConvertor.Instance;
3708
+ data = conv.mg2disp(data, " ", new PIC(picture, Storagetype, task.getCompIdx()), false, task.getCompIdx(), false);
3709
+ break;
3710
+ case StorageAttribute.BLOB_VECTOR:
3711
+ let vecOutData;
3712
+ if (data == null) {
3713
+ vecOutData = "[]";
3714
+ }
3715
+ else {
3716
+ let cellAtt = vecCellType;
3717
+ let vector = new VectorType(data);
3718
+ if (cellAtt == StorageAttribute.BLOB && !VectorType.validateBlobContents(data))
3719
+ vecOutData = "[]";
3720
+ else {
3721
+ let vecSize = VectorType.getVecSize(data);
3722
+ let cellPicture = (cellAtt == StorageAttribute.NUMERIC || cellAtt == StorageAttribute.DATE || cellAtt == StorageAttribute.TIME) ? PIC.buildPicture(cellAtt, vector.getVecCell(1), task.getCompIdx(), true).getFormat() : picture;
3723
+ vecOutData = "[";
3724
+ for (let i = 0; i < vecSize; i++) {
3725
+ vecOutData += this.getFieldData(cellAtt, vector.getVecCell(i + 1), cellPicture, vecCellType, task);
3726
+ vecOutData += i < vecSize - 1 ? "," : "]";
3727
+ }
3728
+ }
3729
+ }
3730
+ data = vecOutData;
3731
+ break;
3732
+ case StorageAttribute.BOOLEAN:
3733
+ data = data == "1" ? "TRUE" : "FALSE";
3734
+ break;
3735
+ }
3736
+ return data;
3737
+ }
3738
+ PrepareDisplayString(mode, name, valueContent, addDoubleQuotes) {
3739
+ let str = "";
3740
+ let finalStringToDisplay = "";
3741
+ if (addDoubleQuotes)
3742
+ finalStringToDisplay = finalStringToDisplay + "\"";
3743
+ finalStringToDisplay = finalStringToDisplay + name;
3744
+ if (addDoubleQuotes)
3745
+ finalStringToDisplay = finalStringToDisplay + "\"";
3746
+ let paddedName = this.padRight(name, 34);
3747
+ let formatOfStringVirtual = `Virtual`;
3748
+ let formatOfStringParameter = `Parameter`;
3749
+ str = (mode ? formatOfStringParameter : formatOfStringVirtual) + " : " + `${paddedName}` + " : " + `${valueContent.trim()}`;
3750
+ return str;
3751
+ }
3647
3752
  addTaskFlowRec(id, state, taskInfo) {
3648
3753
  if (this._enabled && this._isTaskFlow) {
3649
3754
  let info;
@@ -3808,6 +3913,7 @@ class FlowMonitorQueue {
3808
3913
  }
3809
3914
  }
3810
3915
  FlowMonitorQueue._instance = null;
3916
+ FlowMonitorQueue.UNPRINTABLE_STR_LOG = "#UNPRINTABLE#";
3811
3917
  FlowMonitorQueue.S_EVENT_STR1 = ">>Starts ";
3812
3918
  FlowMonitorQueue.S_EVENT_STR2 = " Event";
3813
3919
  FlowMonitorQueue.S_EVENT_PROPAGATED = "Event was propagated";
@@ -3869,6 +3975,15 @@ class TimerObjectCollection {
3869
3975
  }
3870
3976
  TimerObjectCollection.MgDataToTimerObjList = new Dictionary();
3871
3977
  class RCTimer extends MgTimer {
3978
+ get TimerIntervalMiliSeconds() {
3979
+ return this._timerIntervalMilliSeconds;
3980
+ }
3981
+ set IsIdleTimer(value) {
3982
+ this._isIdle = value;
3983
+ }
3984
+ get IsIdleTimer() {
3985
+ return this._isIdle;
3986
+ }
3872
3987
  constructor(mgData, milliseconds, isIdle) {
3873
3988
  super(milliseconds);
3874
3989
  this._mgData = null;
@@ -3880,15 +3995,6 @@ class RCTimer extends MgTimer {
3880
3995
  TimerObjectCollection.MgDataToTimerObjList.Add(mgDataId, new List());
3881
3996
  TimerObjectCollection.MgDataToTimerObjList.get_Item(mgDataId).push(this);
3882
3997
  }
3883
- get TimerIntervalMiliSeconds() {
3884
- return this._timerIntervalMilliSeconds;
3885
- }
3886
- set IsIdleTimer(value) {
3887
- this._isIdle = value;
3888
- }
3889
- get IsIdleTimer() {
3890
- return this._isIdle;
3891
- }
3892
3998
  GetMgdata() {
3893
3999
  return this._mgData;
3894
4000
  }
@@ -4034,6 +4140,9 @@ class ExecutionStack {
4034
4140
  }
4035
4141
 
4036
4142
  class ExecOperCommand extends ClientOriginatedCommandTaskTag {
4143
+ get CommandTypeAttribute() {
4144
+ return ConstInterface.MG_ATTR_VAL_EXEC_OPER;
4145
+ }
4037
4146
  constructor() {
4038
4147
  super();
4039
4148
  this.ExecutionStack = null;
@@ -4047,9 +4156,6 @@ class ExecOperCommand extends ClientOriginatedCommandTaskTag {
4047
4156
  this.CheckOnly = false;
4048
4157
  this.DitIdx = Int32.MinValue;
4049
4158
  }
4050
- get CommandTypeAttribute() {
4051
- return ConstInterface.MG_ATTR_VAL_EXEC_OPER;
4052
- }
4053
4159
  SerializeCommandData() {
4054
4160
  let helper = new CommandSerializationHelper();
4055
4161
  let execStackExists = this.ExecutionStack !== null && !this.ExecutionStack.empty();
@@ -4504,13 +4610,6 @@ class HttpClientAsync extends HttpClientBase {
4504
4610
  }
4505
4611
 
4506
4612
  class HttpManager {
4507
- constructor() {
4508
- this._httpCommunicationTimeoutMS = HttpManager.DEFAULT_HTTP_COMMUNICATION_TIMEOUT;
4509
- this._httpClientAsync = null;
4510
- this._isAbortingMagicEngine = false;
4511
- this._httpClientAsync = new HttpClientAsync(HttpManager._nativeHttpClient);
4512
- this.RegisterBasicDelegates();
4513
- }
4514
4613
  getHttpClient() {
4515
4614
  if (this.IsAbortingMagicEngine)
4516
4615
  return new HttpClientSync();
@@ -4530,6 +4629,13 @@ class HttpManager {
4530
4629
  }
4531
4630
  get IsAbortingMagicEngine() { return this._isAbortingMagicEngine; }
4532
4631
  set IsAbortingMagicEngine(isAbortingMagicEngine) { this._isAbortingMagicEngine = isAbortingMagicEngine; }
4632
+ constructor() {
4633
+ this._httpCommunicationTimeoutMS = HttpManager.DEFAULT_HTTP_COMMUNICATION_TIMEOUT;
4634
+ this._httpClientAsync = null;
4635
+ this._isAbortingMagicEngine = false;
4636
+ this._httpClientAsync = new HttpClientAsync(HttpManager._nativeHttpClient);
4637
+ this.RegisterBasicDelegates();
4638
+ }
4533
4639
  RegisterBasicDelegates() {
4534
4640
  HttpClientEvents.GetHttpCommunicationTimeout_Event = this.GetHttpCommunicationTimeoutMS.bind(this);
4535
4641
  }
@@ -5075,6 +5181,12 @@ var RequestStatus;
5075
5181
  RequestStatus[RequestStatus["Abort"] = 2] = "Abort";
5076
5182
  })(RequestStatus || (RequestStatus = {}));
5077
5183
  class RemoteCommandsProcessor extends CommandsProcessorBase {
5184
+ static GetInstance() {
5185
+ if (RemoteCommandsProcessor._instance === null) {
5186
+ RemoteCommandsProcessor._instance = new RemoteCommandsProcessor();
5187
+ }
5188
+ return RemoteCommandsProcessor._instance;
5189
+ }
5078
5190
  constructor() {
5079
5191
  super();
5080
5192
  this._lastRequestTime = 0;
@@ -5085,12 +5197,6 @@ class RemoteCommandsProcessor extends CommandsProcessorBase {
5085
5197
  HttpManager.GetInstance();
5086
5198
  this.RegisterDelegates();
5087
5199
  }
5088
- static GetInstance() {
5089
- if (RemoteCommandsProcessor._instance === null) {
5090
- RemoteCommandsProcessor._instance = new RemoteCommandsProcessor();
5091
- }
5092
- return RemoteCommandsProcessor._instance;
5093
- }
5094
5200
  CheckAndSetSessionCounter(newSessionCounter) {
5095
5201
  if (newSessionCounter === ConstInterface.SESSION_COUNTER_CLOSE_CTX_INDICATION) {
5096
5202
  Debug.Assert(this.GetSessionCounter() === ConstInterface.SESSION_COUNTER_CLOSE_CTX_INDICATION);
@@ -5123,10 +5229,12 @@ class RemoteCommandsProcessor extends CommandsProcessorBase {
5123
5229
  async StoreSessionReInitializingDataOnLocalStorage() {
5124
5230
  let mainPrgViewStringForServer = await this.BuildXMLForMainProgramDataView();
5125
5231
  let globalParamsString = AccessHelper.globalParams.mirrorAllToXML();
5232
+ let changedEnvVarList = AccessHelper.envParamsTable.mirrorAllToXML();
5126
5233
  let dataStorage = window.localStorage;
5127
5234
  dataStorage.setItem(ConstInterface.IS_SESSION_REINITIALIZING, "true");
5128
5235
  dataStorage.setItem(ConstInterface.MAIN_PROG_VIEW, mainPrgViewStringForServer.toString());
5129
5236
  dataStorage.setItem(ConstInterface.GLOBAL_PARAM_LIST, globalParamsString);
5237
+ dataStorage.setItem(ConstInterface.ENV_VAR_LIST, changedEnvVarList);
5130
5238
  dataStorage.setItem(ConstInterface.LAST_EXCEPTION, RemoteCommandsProcessor.lastExceptionMessage);
5131
5239
  if (RuntimeContextBase.Instance.RemovedContextFromServer)
5132
5240
  dataStorage.setItem(ConstInterface.CTX_REMOVED_FROM_SRVR, "1");
@@ -5353,6 +5461,7 @@ class RemoteCommandsProcessor extends CommandsProcessorBase {
5353
5461
  let reqBuf;
5354
5462
  let isInitialCall = sessionStage === CommandsProcessorBase_SessionStage.INITIAL;
5355
5463
  let globalParamsString = null;
5464
+ let envVarsString = null;
5356
5465
  if (this.DelayCommandExecution)
5357
5466
  return;
5358
5467
  if (Logger.Instance.LogLevel == Logger_LogLevels.RequestInfo && !isInitialCall)
@@ -5378,12 +5487,16 @@ class RemoteCommandsProcessor extends CommandsProcessorBase {
5378
5487
  let buffer = new StringBuilder();
5379
5488
  if (!RemoteCommandsProcessor.IsSessionReInitializing)
5380
5489
  buffer.Append(reqBuf);
5381
- if (RemoteCommandsProcessor.IsSessionReInitializing)
5490
+ if (RemoteCommandsProcessor.IsSessionReInitializing) {
5382
5491
  globalParamsString = this.RestoreSessionReInitializingDataFromLocalStorage(ConstInterface.GLOBAL_PARAM_LIST);
5383
- else
5492
+ envVarsString = this.RestoreSessionReInitializingDataFromLocalStorage(ConstInterface.ENV_VAR_LIST);
5493
+ }
5494
+ else {
5384
5495
  globalParamsString = AccessHelper.globalParams.mirrorToXML();
5496
+ envVarsString = AccessHelper.envParamsTable.mirrorToXML();
5497
+ }
5385
5498
  changes.Append(globalParamsString);
5386
- changes.Append(AccessHelper.envParamsTable.mirrorToXML());
5499
+ changes.Append(envVarsString);
5387
5500
  if (changes.Length > 0) {
5388
5501
  changes.Insert(0, "<" + ConstInterface.MG_TAG_ENV_CHANGES + ">");
5389
5502
  changes.Append("</" + ConstInterface.MG_TAG_ENV_CHANGES + ">");
@@ -5422,13 +5535,15 @@ class RemoteCommandsProcessor extends CommandsProcessorBase {
5422
5535
  dataStorage.removeItem(ConstInterface.IS_SESSION_REINITIALIZING);
5423
5536
  dataStorage.removeItem(ConstInterface.MAIN_PROG_VIEW);
5424
5537
  dataStorage.removeItem(ConstInterface.GLOBAL_PARAM_LIST);
5538
+ dataStorage.removeItem(ConstInterface.ENV_VAR_LIST);
5425
5539
  dataStorage.removeItem(ConstInterface.LAST_EXCEPTION);
5426
5540
  }
5427
5541
  }
5428
5542
  FlowMonitorQueue.Instance.enable(false);
5429
5543
  await this.ProcessResponse(respBuf, AccessHelper.mgDataTable.currMgdID, null, res);
5430
5544
  if (RemoteCommandsProcessor.IsSessionReInitializing) {
5431
- AccessHelper.globalParams.RestoreGlobalParams(globalParamsString);
5545
+ AccessHelper.globalParams.RestoreParams(globalParamsString);
5546
+ AccessHelper.envParamsTable.RestoreParams(envVarsString);
5432
5547
  let dataStorage = window.localStorage;
5433
5548
  let ctxRemoved = dataStorage.getItem(ConstInterface.CTX_REMOVED_FROM_SRVR);
5434
5549
  if (ctxRemoved === "1") {
@@ -5730,21 +5845,6 @@ RemoteCommandsProcessor.InitialUrl = null;
5730
5845
  RemoteCommandsProcessor.WEB_COMMUNICATION_PROTOCOL_VERSION = "14002";
5731
5846
  RemoteCommandsProcessor._shouldScrambleAndUnscrambleMessages = false;
5732
5847
  class HandshakeResponse {
5733
- constructor(responseXML) {
5734
- this._scrambleMessages = true;
5735
- this._contextId = null;
5736
- this._privateSessionId = null;
5737
- this._inputPassword = false;
5738
- this._httpTimeout = 0;
5739
- this._systemLogin = null;
5740
- this._maxInternalLogLevel = null;
5741
- try {
5742
- JSON_Utils.JSONFromXML(responseXML, this.FillFromJSON.bind(this));
5743
- }
5744
- catch (ex) {
5745
- Logger.Instance.WriteExceptionToLog(ex, responseXML);
5746
- }
5747
- }
5748
5848
  get ScrambleMessages() {
5749
5849
  return this._scrambleMessages;
5750
5850
  }
@@ -5766,6 +5866,21 @@ class HandshakeResponse {
5766
5866
  get MaxInternalLogLevel() {
5767
5867
  return this._maxInternalLogLevel;
5768
5868
  }
5869
+ constructor(responseXML) {
5870
+ this._scrambleMessages = true;
5871
+ this._contextId = null;
5872
+ this._privateSessionId = null;
5873
+ this._inputPassword = false;
5874
+ this._httpTimeout = 0;
5875
+ this._systemLogin = null;
5876
+ this._maxInternalLogLevel = null;
5877
+ try {
5878
+ JSON_Utils.JSONFromXML(responseXML, this.FillFromJSON.bind(this));
5879
+ }
5880
+ catch (ex) {
5881
+ Logger.Instance.WriteExceptionToLog(ex, responseXML);
5882
+ }
5883
+ }
5769
5884
  FillFromJSON(error, result) {
5770
5885
  if (error != null) {
5771
5886
  throw error;
@@ -7319,6 +7434,9 @@ class EventHandlerPosition {
7319
7434
  case InternalInterface.MG_ACT_REC_SUFFIX:
7320
7435
  case InternalInterface.MG_ACT_CTRL_PREFIX:
7321
7436
  case InternalInterface.MG_ACT_CTRL_SUFFIX: {
7437
+ if (this._rtEvt.getInternalCode() == InternalInterface.MG_ACT_REC_PREFIX) {
7438
+ FlowMonitorQueue.Instance.addDataViewFlow(this._task);
7439
+ }
7322
7440
  if (this._handlerIdx === -1) {
7323
7441
  for (this._handlerIdx = this._handlersTab.getSize() - 1; this._handlerIdx >= 0; this._handlerIdx--) {
7324
7442
  let handler = this._handlersTab.getHandler(this._handlerIdx);
@@ -7484,11 +7602,6 @@ var DataViewCommandType;
7484
7602
  DataViewCommandType[DataViewCommandType["SQLExecute"] = 20] = "SQLExecute";
7485
7603
  })(DataViewCommandType || (DataViewCommandType = {}));
7486
7604
  class DataviewCommand extends ClientOriginatedCommandTaskTag {
7487
- constructor() {
7488
- super();
7489
- this.CommandType = 0;
7490
- this.TaskTag = null;
7491
- }
7492
7605
  get CommandTypeAttribute() {
7493
7606
  throw new NotImplementedException();
7494
7607
  }
@@ -7499,6 +7612,11 @@ class DataviewCommand extends ClientOriginatedCommandTaskTag {
7499
7612
  get ShouldSerialize() {
7500
7613
  return false;
7501
7614
  }
7615
+ constructor() {
7616
+ super();
7617
+ this.CommandType = 0;
7618
+ this.TaskTag = null;
7619
+ }
7502
7620
  }
7503
7621
 
7504
7622
  class AddUserRangeDataviewCommand extends DataviewCommand {
@@ -7720,12 +7838,6 @@ class NonReversibleExitEventCommand extends EventCommand {
7720
7838
  }
7721
7839
 
7722
7840
  class RecomputeCommand extends ClientOriginatedCommandTaskTag {
7723
- constructor() {
7724
- super();
7725
- this.TaskTag = null;
7726
- this.FldId = 0;
7727
- this.IgnoreSubformRecompute = false;
7728
- }
7729
7841
  get CommandTypeAttribute() {
7730
7842
  return ConstInterface.MG_ATTR_VAL_RECOMP;
7731
7843
  }
@@ -7737,17 +7849,18 @@ class RecomputeCommand extends ClientOriginatedCommandTaskTag {
7737
7849
  helper.SerializeAttribute(ConstInterface.MG_ATTR_IGNORE_SUBFORM_RECOMPUTE, '1');
7738
7850
  return helper.GetString();
7739
7851
  }
7852
+ constructor() {
7853
+ super();
7854
+ this.TaskTag = null;
7855
+ this.FldId = 0;
7856
+ this.IgnoreSubformRecompute = false;
7857
+ }
7740
7858
  getCommandInfo() {
7741
7859
  return NString.Format('[{0} in {1} for Field {2}]', this.CommandTypeAttribute.charAt(0).toUpperCase() + this.CommandTypeAttribute.substr(1, this.CommandTypeAttribute.length), this.Task.getTaskInfo(), this.Task.getFieldDef(this.FldId).getName());
7742
7860
  }
7743
7861
  }
7744
7862
 
7745
7863
  class TransactionCommand extends ClientOriginatedCommandTaskTag {
7746
- constructor() {
7747
- super();
7748
- this.TaskTag = null;
7749
- this.ReversibleExit = false;
7750
- }
7751
7864
  get CommandTypeAttribute() {
7752
7865
  return ConstInterface.MG_ATTR_VAL_TRANS;
7753
7866
  }
@@ -7761,6 +7874,11 @@ class TransactionCommand extends ClientOriginatedCommandTaskTag {
7761
7874
  helper.SerializeAttribute(ConstInterface.MG_ATTR_TRANS_LEVEL, this.Level);
7762
7875
  return helper.GetString();
7763
7876
  }
7877
+ constructor() {
7878
+ super();
7879
+ this.TaskTag = null;
7880
+ this.ReversibleExit = false;
7881
+ }
7764
7882
  getCommandInfo() {
7765
7883
  return NString.Format('[{0} in {1}]', this.Oper === 'C' ? 'Commit Transaction' : 'Abort Transaction', this.Task.getTaskInfo());
7766
7884
  }
@@ -7779,6 +7897,9 @@ class UnloadCommand extends ClientOriginatedCommand {
7779
7897
  }
7780
7898
 
7781
7899
  class EvaluateCommand extends ClientOriginatedCommandTaskTag {
7900
+ get CommandTypeAttribute() {
7901
+ return ConstInterface.MG_ATTR_VAL_EVAL;
7902
+ }
7782
7903
  constructor() {
7783
7904
  super();
7784
7905
  this.TaskTag = null;
@@ -7787,9 +7908,6 @@ class EvaluateCommand extends ClientOriginatedCommandTaskTag {
7787
7908
  this.MprgCreator = null;
7788
7909
  this.LengthExpVal = Int32.MinValue;
7789
7910
  }
7790
- get CommandTypeAttribute() {
7791
- return ConstInterface.MG_ATTR_VAL_EVAL;
7792
- }
7793
7911
  SerializeCommandData() {
7794
7912
  let helper = new CommandSerializationHelper();
7795
7913
  helper.SerializeTaskTag(this.TaskTag);
@@ -7837,10 +7955,6 @@ class GlobalParamsQueryCommand extends QueryCommand {
7837
7955
  }
7838
7956
 
7839
7957
  class IniputForceWriteCommand extends ClientOriginatedCommand {
7840
- constructor() {
7841
- super();
7842
- this.Text = null;
7843
- }
7844
7958
  get CommandTypeAttribute() {
7845
7959
  return ConstInterface.MG_ATTR_VAL_INIPUT_FORCE_WRITE;
7846
7960
  }
@@ -7850,6 +7964,10 @@ class IniputForceWriteCommand extends ClientOriginatedCommand {
7850
7964
  SerializeCommandData() {
7851
7965
  return " " + ConstInterface.MG_ATTR_VAL_INIPUT_PARAM + "=\"" + XmlParser.escape(this.Text) + "\"";
7852
7966
  }
7967
+ constructor() {
7968
+ super();
7969
+ this.Text = null;
7970
+ }
7853
7971
  getCommandInfo() {
7854
7972
  return NString.Format('[{0} with {1}] ', this.CommandTypeAttribute, this.Text);
7855
7973
  }
@@ -8145,10 +8263,6 @@ var ParamParseResult;
8145
8263
  })(ParamParseResult || (ParamParseResult = {}));
8146
8264
 
8147
8265
  class PrmMap {
8148
- constructor() {
8149
- this.values = null;
8150
- this.values = new Dictionary();
8151
- }
8152
8266
  getvalue(s) {
8153
8267
  if (this.values.ContainsKey(s))
8154
8268
  return this.values.get_Item(s);
@@ -8161,6 +8275,10 @@ class PrmMap {
8161
8275
  remove(s) {
8162
8276
  this.values.Remove(s);
8163
8277
  }
8278
+ constructor() {
8279
+ this.values = null;
8280
+ this.values = new Dictionary();
8281
+ }
8164
8282
  }
8165
8283
  class MirrorPrmMap extends PrmMap {
8166
8284
  constructor(type) {
@@ -8241,7 +8359,7 @@ class MirrorPrmMap extends PrmMap {
8241
8359
  while (this.mirrorFromXML(parser.getNextTag(), parser)) {
8242
8360
  }
8243
8361
  }
8244
- RestoreGlobalParams(xml) {
8362
+ RestoreParams(xml) {
8245
8363
  let parser = new XmlParser(xml);
8246
8364
  while (this.mirrorFromXML(parser.getNextTag(), parser)) {
8247
8365
  }
@@ -8316,6 +8434,7 @@ class Environment {
8316
8434
  this._debugMode = 0;
8317
8435
  this._significantNumSize = 0;
8318
8436
  this._specialAnsiExpression = false;
8437
+ this._specialImmediatehandlerEnd = false;
8319
8438
  this._specialShowStatusBarPanes = false;
8320
8439
  this._specialRouteToRootProgOnContextRecreation = false;
8321
8440
  this._specialCancelOnCreate = false;
@@ -8469,6 +8588,9 @@ class Environment {
8469
8588
  case ConstInterface.MG_ATTR_LOCAL_FLAGS:
8470
8589
  this._localFlags = valueStr;
8471
8590
  break;
8591
+ case ConstInterface.MG_ATTR_SPECIAL_IMMEDIATE_HANDLER_END:
8592
+ this._specialImmediatehandlerEnd = XmlParser.getBoolean(valueStr);
8593
+ break;
8472
8594
  case ConstInterface.MG_ATTR_SPEACIAL_ANSI_EXP:
8473
8595
  this._specialAnsiExpression = XmlParser.getBoolean(valueStr);
8474
8596
  break;
@@ -8673,6 +8795,9 @@ class Environment {
8673
8795
  GetLocalFlag(f) {
8674
8796
  return this._localFlags !== null && this._localFlags.indexOf(f) >= 0;
8675
8797
  }
8798
+ getSpecialImmediateHandlerEnd() {
8799
+ return this._specialImmediatehandlerEnd;
8800
+ }
8676
8801
  getSpecialAnsiExpression() {
8677
8802
  return this._specialAnsiExpression;
8678
8803
  }
@@ -8742,6 +8867,12 @@ class Environment {
8742
8867
  }
8743
8868
  Environment.Instance = new Environment();
8744
8869
  class EnvironmentDetails {
8870
+ set UpdateInQueryMode(value) {
8871
+ this._updateInQueryMode = value;
8872
+ }
8873
+ set CreateInModifyMode(value) {
8874
+ this._createInModifyMode = value;
8875
+ }
8745
8876
  constructor() {
8746
8877
  this._createInModifyMode = false;
8747
8878
  this._updateInQueryMode = false;
@@ -8752,12 +8883,6 @@ class EnvironmentDetails {
8752
8883
  this.ProjDir = null;
8753
8884
  this.CompIdx = 0;
8754
8885
  }
8755
- set UpdateInQueryMode(value) {
8756
- this._updateInQueryMode = value;
8757
- }
8758
- set CreateInModifyMode(value) {
8759
- this._createInModifyMode = value;
8760
- }
8761
8886
  allowUpdateInQueryMode() {
8762
8887
  return this._updateInQueryMode;
8763
8888
  }
@@ -8845,17 +8970,6 @@ class GlobalParams extends MirrorPrmMap {
8845
8970
  GlobalParams.Instance = new GlobalParams();
8846
8971
 
8847
8972
  class UserDetails {
8848
- constructor() {
8849
- this.UserName = null;
8850
- this.UserID = null;
8851
- this.UserInfo = null;
8852
- this.Password = null;
8853
- this.IsLoggedIn = false;
8854
- this.UserName = NString.Empty;
8855
- this.UserInfo = NString.Empty;
8856
- this.IsLoggedIn = false;
8857
- this.setUserID(NString.Empty);
8858
- }
8859
8973
  setIsLoggedIn(value) {
8860
8974
  this.IsLoggedIn = value;
8861
8975
  }
@@ -8875,6 +8989,17 @@ class UserDetails {
8875
8989
  UserDetails._instance = new UserDetails();
8876
8990
  return UserDetails._instance;
8877
8991
  }
8992
+ constructor() {
8993
+ this.UserName = null;
8994
+ this.UserID = null;
8995
+ this.UserInfo = null;
8996
+ this.Password = null;
8997
+ this.IsLoggedIn = false;
8998
+ this.UserName = NString.Empty;
8999
+ this.UserInfo = NString.Empty;
9000
+ this.IsLoggedIn = false;
9001
+ this.setUserID(NString.Empty);
9002
+ }
8878
9003
  fillData(parser) {
8879
9004
  let tokensVector;
8880
9005
  let endContext = parser.getXMLdata().indexOf(XMLConstants.TAG_TERM, parser.getCurrIndex());
@@ -9683,8 +9808,7 @@ class MirrorString {
9683
9808
  this._reserved = false;
9684
9809
  }
9685
9810
  mirrorToXML() {
9686
- return ConstInterface.MG_ATTR_ENV_VALUE + "=\"" + XmlParser.escape(this._value) + "\" " +
9687
- ConstInterface.MG_ATTR_ENV_WRITEINI + "=F";
9811
+ return ConstInterface.MG_ATTR_ENV_VALUE + "=\"" + XmlParser.escape(this._value) + "\"";
9688
9812
  }
9689
9813
  init(name, xmlParser) {
9690
9814
  let valueStart, valueEnd, reserveStart, paramEnd;
@@ -14338,6 +14462,12 @@ class DataViewBase extends GuiDataViewBase {
14338
14462
  }
14339
14463
 
14340
14464
  class Record {
14465
+ get InCompute() {
14466
+ return this._inCompute;
14467
+ }
14468
+ get InRecompute() {
14469
+ return this._inRecompute;
14470
+ }
14341
14471
  constructor(dvOrTableCacheOrCIdOrRecord, dataview) {
14342
14472
  this._id = Int32.MinValue;
14343
14473
  this.dbViewRowIdx = 0;
@@ -14355,12 +14485,6 @@ class Record {
14355
14485
  else
14356
14486
  this.constructor_1(dvOrTableCacheOrCIdOrRecord, dataview);
14357
14487
  }
14358
- get InCompute() {
14359
- return this._inCompute;
14360
- }
14361
- get InRecompute() {
14362
- return this._inRecompute;
14363
- }
14364
14488
  constructor_0(dvOrTableCache) {
14365
14489
  if (dvOrTableCache instanceof DataViewBase)
14366
14490
  this._dataview = dvOrTableCache;
@@ -15156,14 +15280,14 @@ Record.FLAG_MODIFIED_ATLEAST_ONCE = (0x40);
15156
15280
  Record.INCREASE = true;
15157
15281
  Record.DECREASE = false;
15158
15282
  class DcValuesReference extends ObjectReferenceBase {
15283
+ get DcValues() {
15284
+ return this.Referent;
15285
+ }
15159
15286
  constructor(controlId, referencedDcValues) {
15160
15287
  super(referencedDcValues);
15161
15288
  this.ditIdx = 0;
15162
15289
  this.ditIdx = controlId;
15163
15290
  }
15164
- get DcValues() {
15165
- return this.Referent;
15166
- }
15167
15291
  Clone() {
15168
15292
  return new DcValuesReference(this.ditIdx, this.Referent);
15169
15293
  }
@@ -15439,21 +15563,6 @@ class RecordsTable {
15439
15563
  RecordsTable.REC_NOT_FOUND = -1;
15440
15564
 
15441
15565
  class DataviewHeaderBase {
15442
- constructor(task) {
15443
- this._cond = null;
15444
- this._task = null;
15445
- this.Loc = null;
15446
- this._dir = '\0';
15447
- this._id = 0;
15448
- this._keyIdx = 0;
15449
- this._retVal = null;
15450
- this.returnfield = null;
15451
- this.LinkStartAfterField = 0;
15452
- this.KeyExpression = 0;
15453
- this._task = task;
15454
- this._keyIdx = -1;
15455
- this._cond = new YesNoExp(true);
15456
- }
15457
15566
  get ReturnField() {
15458
15567
  if (this.returnfield === null && this._retVal !== null)
15459
15568
  this.returnfield = this.Task.getFieldByValueStr(this._retVal);
@@ -15474,6 +15583,21 @@ class DataviewHeaderBase {
15474
15583
  get LinkEvaluateCondition() {
15475
15584
  return this._linkEvalCondition;
15476
15585
  }
15586
+ constructor(task) {
15587
+ this._cond = null;
15588
+ this._task = null;
15589
+ this.Loc = null;
15590
+ this._dir = '\0';
15591
+ this._id = 0;
15592
+ this._keyIdx = 0;
15593
+ this._retVal = null;
15594
+ this.returnfield = null;
15595
+ this.LinkStartAfterField = 0;
15596
+ this.KeyExpression = 0;
15597
+ this._task = task;
15598
+ this._keyIdx = -1;
15599
+ this._cond = new YesNoExp(true);
15600
+ }
15477
15601
  SetAttributes(attributes) {
15478
15602
  let keys = attributes.Keys;
15479
15603
  keys.forEach((text) => {
@@ -16764,16 +16888,16 @@ class RecordOutOfDataViewException extends ApplicationException {
16764
16888
  }
16765
16889
 
16766
16890
  class XMLBasedDcValuesBuilder extends DcValuesBuilderBase {
16891
+ set SerializedDCVals(value) {
16892
+ this.parser.setXMLdata(value);
16893
+ this.parser.setCurrIndex(0);
16894
+ }
16767
16895
  constructor() {
16768
16896
  super();
16769
16897
  this.dcv = null;
16770
16898
  this.parser = null;
16771
16899
  this.parser = new XmlParser();
16772
16900
  }
16773
- set SerializedDCVals(value) {
16774
- this.parser.setXMLdata(value);
16775
- this.parser.setCurrIndex(0);
16776
- }
16777
16901
  Build() {
16778
16902
  this.dcv = null;
16779
16903
  let endContext = this.parser.getXMLdata().indexOf(XMLConstants.TAG_TERM, this.parser.getCurrIndex());
@@ -16853,6 +16977,39 @@ const RECOVERY_ACT_NONE = 'N';
16853
16977
  const TRANS_STAT_CLOSED = 'C';
16854
16978
  const TRANS_STAT_OPENED = 'O';
16855
16979
  class DataView extends DataViewBase {
16980
+ set InsertAt(value) {
16981
+ this._insertAt = value;
16982
+ }
16983
+ get InsertAt() {
16984
+ return this._insertAt;
16985
+ }
16986
+ get CurrRec() {
16987
+ return this._currRec_DO_NOT_USE_DIRECTLY_USE_SETTER_GETTER;
16988
+ }
16989
+ set CurrRec(value) {
16990
+ if (this._currRec_DO_NOT_USE_DIRECTLY_USE_SETTER_GETTER !== null && value === null) {
16991
+ this._currRec_DO_NOT_USE_DIRECTLY_USE_SETTER_GETTER.resetDcValueId();
16992
+ }
16993
+ this._currRec_DO_NOT_USE_DIRECTLY_USE_SETTER_GETTER = value;
16994
+ if (this._currRec_DO_NOT_USE_DIRECTLY_USE_SETTER_GETTER !== null) {
16995
+ this._currRec_DO_NOT_USE_DIRECTLY_USE_SETTER_GETTER.SetDcValueId();
16996
+ }
16997
+ }
16998
+ get FlushUpdates() {
16999
+ return this._flushUpdates;
17000
+ }
17001
+ get HasMainTable() {
17002
+ return this._hasMainTable;
17003
+ }
17004
+ get CurrentRecId() {
17005
+ return this._currRecId;
17006
+ }
17007
+ get FirstRecord() {
17008
+ return this._recordsTab.getRecByIdx(0);
17009
+ }
17010
+ get LastRecord() {
17011
+ return this._recordsTab.getRecByIdx(this._recordsTab.getSize() - 1);
17012
+ }
16856
17013
  constructor(taskOrDataView) {
16857
17014
  super();
16858
17015
  this._cacheLruTimeStamp = 0;
@@ -16904,39 +17061,6 @@ class DataView extends DataViewBase {
16904
17061
  Object.assign(this, taskOrDataView);
16905
17062
  }
16906
17063
  }
16907
- set InsertAt(value) {
16908
- this._insertAt = value;
16909
- }
16910
- get InsertAt() {
16911
- return this._insertAt;
16912
- }
16913
- get CurrRec() {
16914
- return this._currRec_DO_NOT_USE_DIRECTLY_USE_SETTER_GETTER;
16915
- }
16916
- set CurrRec(value) {
16917
- if (this._currRec_DO_NOT_USE_DIRECTLY_USE_SETTER_GETTER !== null && value === null) {
16918
- this._currRec_DO_NOT_USE_DIRECTLY_USE_SETTER_GETTER.resetDcValueId();
16919
- }
16920
- this._currRec_DO_NOT_USE_DIRECTLY_USE_SETTER_GETTER = value;
16921
- if (this._currRec_DO_NOT_USE_DIRECTLY_USE_SETTER_GETTER !== null) {
16922
- this._currRec_DO_NOT_USE_DIRECTLY_USE_SETTER_GETTER.SetDcValueId();
16923
- }
16924
- }
16925
- get FlushUpdates() {
16926
- return this._flushUpdates;
16927
- }
16928
- get HasMainTable() {
16929
- return this._hasMainTable;
16930
- }
16931
- get CurrentRecId() {
16932
- return this._currRecId;
16933
- }
16934
- get FirstRecord() {
16935
- return this._recordsTab.getRecByIdx(0);
16936
- }
16937
- get LastRecord() {
16938
- return this._recordsTab.getRecByIdx(this._recordsTab.getSize() - 1);
16939
- }
16940
17064
  Init() {
16941
17065
  this.init();
16942
17066
  }
@@ -18509,6 +18633,12 @@ class ReturnResultBase {
18509
18633
  }
18510
18634
 
18511
18635
  class ReturnResult extends ReturnResultBase {
18636
+ get Success() {
18637
+ return this.success;
18638
+ }
18639
+ get ErrorDescription() {
18640
+ return this.errorDescription;
18641
+ }
18512
18642
  constructor(errorDescriptionCodeOrErrorDescriptionOrInnerResult, innerResult) {
18513
18643
  super();
18514
18644
  this.errorDescription = null;
@@ -18523,12 +18653,6 @@ class ReturnResult extends ReturnResultBase {
18523
18653
  else
18524
18654
  this.constructor_03(errorDescriptionCodeOrErrorDescriptionOrInnerResult);
18525
18655
  }
18526
- get Success() {
18527
- return this.success;
18528
- }
18529
- get ErrorDescription() {
18530
- return this.errorDescription;
18531
- }
18532
18656
  constructor_00(errorDescriptionCode) {
18533
18657
  this.success = false;
18534
18658
  this.ErrorId = errorDescriptionCode;
@@ -18628,13 +18752,13 @@ class Transaction {
18628
18752
  }
18629
18753
 
18630
18754
  class TaskTransactionManager {
18755
+ get isClosingTopmostTask() {
18756
+ return MGDataCollection.Instance.StartupMgData.getFirstTask().InEndTask;
18757
+ }
18631
18758
  constructor(task) {
18632
18759
  this.task = null;
18633
18760
  this.task = task;
18634
18761
  }
18635
- get isClosingTopmostTask() {
18636
- return MGDataCollection.Instance.StartupMgData.getFirstTask().InEndTask;
18637
- }
18638
18762
  AllowTransaction(transBegin, forLocal) {
18639
18763
  let result;
18640
18764
  if (forLocal)
@@ -18978,12 +19102,6 @@ class RemoteDataviewManager extends DataviewManagerBase {
18978
19102
  }
18979
19103
 
18980
19104
  class DataviewManager extends DataviewManagerBase {
18981
- constructor(task) {
18982
- super(task);
18983
- this.RemoteDataviewManager = null;
18984
- this.HasRemoteData = true;
18985
- this.RemoteDataviewManager = new RemoteDataviewManager(task);
18986
- }
18987
19105
  get TaskService() {
18988
19106
  return this.Task.TaskService;
18989
19107
  }
@@ -18998,6 +19116,12 @@ class DataviewManager extends DataviewManagerBase {
18998
19116
  get VirtualDataviewManager() {
18999
19117
  return this.TaskService.GetDataviewManagerForVirtuals(this.Task);
19000
19118
  }
19119
+ constructor(task) {
19120
+ super(task);
19121
+ this.RemoteDataviewManager = null;
19122
+ this.HasRemoteData = true;
19123
+ this.RemoteDataviewManager = new RemoteDataviewManager(task);
19124
+ }
19001
19125
  async Execute(command) {
19002
19126
  return await this.CurrentDataviewManager.Execute(command);
19003
19127
  }
@@ -19238,11 +19362,7 @@ class MgForm extends MgFormBase {
19238
19362
  this.GetDataview().setTopRecIdxModified(true);
19239
19363
  try {
19240
19364
  this._suffixDone = false;
19241
- let newDisplayLine = this.GetDataview().getCurrRecIdx() + size;
19242
- if (unit === Constants.MOVE_UNIT_PAGE && this.isLineMode())
19243
- if (newDisplayLine > this.GetDataview().getSize() - 1)
19244
- visibleLine -= newDisplayLine - (this.GetDataview().getSize() - 1);
19245
- await this.setCurrRowByDisplayLine(newDisplayLine, true, false);
19365
+ await this.setCurrRowByDisplayLine(this.GetDataview().getCurrRecIdx() + size, true, false);
19246
19366
  this.GetDataview().setTopRecIdxModified(false);
19247
19367
  await this.RefreshDisplay(Constants.TASK_REFRESH_FORM);
19248
19368
  }
@@ -19282,6 +19402,7 @@ class MgForm extends MgFormBase {
19282
19402
  try {
19283
19403
  await this.RefreshDisplay(Constants.TASK_REFRESH_FORM);
19284
19404
  await this.setCurrRowByDisplayLine(this.GetDataview().getTopRecIdx() + this.getLastValidRow(), false, true);
19405
+ visibleLine = this.getLastValidRow();
19285
19406
  }
19286
19407
  catch (Exception) {
19287
19408
  }
@@ -21354,8 +21475,10 @@ class EventHandler {
21354
21475
  continue;
21355
21476
  else if (this._operationTab.getOperation(oper.getBlockEnd()).getServerId() < nextOperIdx)
21356
21477
  continue;
21357
- if (!taskEnd)
21358
- await this._task.evalEndCond(ConstInterface.END_COND_EVAL_IMMIDIATE);
21478
+ if (!taskEnd) {
21479
+ if (await this._task.evalEndCond(ConstInterface.END_COND_EVAL_IMMIDIATE) && Environment.Instance.getSpecialImmediateHandlerEnd())
21480
+ break;
21481
+ }
21359
21482
  if (this._taskMgdID !== mgdID)
21360
21483
  isChangedCurrWndRef.value = true;
21361
21484
  if (!this._task.isMainProg() && this._task.isOpenWin())
@@ -22149,13 +22272,6 @@ class UserEventsTable {
22149
22272
  }
22150
22273
 
22151
22274
  class FormsTable {
22152
- constructor(task, parentForm) {
22153
- this._task = null;
22154
- this._parentForm = null;
22155
- this._formsStringXml = null;
22156
- this._task = task;
22157
- this._parentForm = parentForm;
22158
- }
22159
22275
  get Count() {
22160
22276
  return this._formsStringXml.length;
22161
22277
  }
@@ -22164,6 +22280,13 @@ class FormsTable {
22164
22280
  return this._formsStringXml.get_Item(formDisplayIndex - 1);
22165
22281
  return null;
22166
22282
  }
22283
+ constructor(task, parentForm) {
22284
+ this._task = null;
22285
+ this._parentForm = null;
22286
+ this._formsStringXml = null;
22287
+ this._task = task;
22288
+ this._parentForm = parentForm;
22289
+ }
22167
22290
  async fillData() {
22168
22291
  this._formsStringXml = new List();
22169
22292
  let parser = Manager.GetCurrentRuntimeContext().Parser;
@@ -22353,6 +22476,47 @@ var Task_Direction;
22353
22476
  Task_Direction[Task_Direction["FORE"] = 1] = "FORE";
22354
22477
  })(Task_Direction || (Task_Direction = {}));
22355
22478
  class Task extends TaskBase {
22479
+ get ParentTask() {
22480
+ return this._parentTask;
22481
+ }
22482
+ set TryingToCommit(value) {
22483
+ this._tryingToCommit = value;
22484
+ }
22485
+ get TryingToCommit() {
22486
+ return this._tryingToCommit;
22487
+ }
22488
+ get TaskService() {
22489
+ if (this._taskService == null)
22490
+ this._taskService = new RemoteTaskService();
22491
+ return this._taskService;
22492
+ }
22493
+ static get CommandsProcessor() {
22494
+ return CommandsProcessorManager.GetCommandsProcessor();
22495
+ }
22496
+ get LogicalStudioParentTask() {
22497
+ if (this.StudioParentTask === null && !super.isMainProg()) {
22498
+ return GuiDataCollection.MGDataTable.GetMainProgByCtlIdx(this.ContextID, this._ctlIdx);
22499
+ }
22500
+ return this.StudioParentTask;
22501
+ }
22502
+ get KnownToServer() {
22503
+ return this._knownToServer;
22504
+ }
22505
+ set Transaction(value) {
22506
+ this.DataviewManager.CurrentDataviewManager.Transaction = value;
22507
+ }
22508
+ get Transaction() {
22509
+ return this.DataviewManager.CurrentDataviewManager.Transaction;
22510
+ }
22511
+ get TaskDefinitionId() {
22512
+ if (this.taskDefinitionId === null) {
22513
+ this.taskDefinitionId = new TaskDefinitionId(this._ctlIdx, this.ProgramIsn, this.TaskIsn, this._isPrg);
22514
+ }
22515
+ return this.taskDefinitionId;
22516
+ }
22517
+ static get IsBlockingBatch() {
22518
+ return false;
22519
+ }
22356
22520
  constructor(parent) {
22357
22521
  super();
22358
22522
  this._dvCache = null;
@@ -22421,47 +22585,6 @@ class Task extends TaskBase {
22421
22585
  }
22422
22586
  this.constructor_1(parent);
22423
22587
  }
22424
- get ParentTask() {
22425
- return this._parentTask;
22426
- }
22427
- set TryingToCommit(value) {
22428
- this._tryingToCommit = value;
22429
- }
22430
- get TryingToCommit() {
22431
- return this._tryingToCommit;
22432
- }
22433
- get TaskService() {
22434
- if (this._taskService == null)
22435
- this._taskService = new RemoteTaskService();
22436
- return this._taskService;
22437
- }
22438
- static get CommandsProcessor() {
22439
- return CommandsProcessorManager.GetCommandsProcessor();
22440
- }
22441
- get LogicalStudioParentTask() {
22442
- if (this.StudioParentTask === null && !super.isMainProg()) {
22443
- return GuiDataCollection.MGDataTable.GetMainProgByCtlIdx(this.ContextID, this._ctlIdx);
22444
- }
22445
- return this.StudioParentTask;
22446
- }
22447
- get KnownToServer() {
22448
- return this._knownToServer;
22449
- }
22450
- set Transaction(value) {
22451
- this.DataviewManager.CurrentDataviewManager.Transaction = value;
22452
- }
22453
- get Transaction() {
22454
- return this.DataviewManager.CurrentDataviewManager.Transaction;
22455
- }
22456
- get TaskDefinitionId() {
22457
- if (this.taskDefinitionId === null) {
22458
- this.taskDefinitionId = new TaskDefinitionId(this._ctlIdx, this.ProgramIsn, this.TaskIsn, this._isPrg);
22459
- }
22460
- return this.taskDefinitionId;
22461
- }
22462
- static get IsBlockingBatch() {
22463
- return false;
22464
- }
22465
22588
  constructor_0() {
22466
22589
  this.ActionManager = new ActionManager();
22467
22590
  this.DataView = new DataView(this);
@@ -24858,6 +24981,9 @@ class CompMainPrgTable {
24858
24981
  }
24859
24982
 
24860
24983
  class MGData {
24984
+ get ForceModal() {
24985
+ return this.forceModal;
24986
+ }
24861
24987
  constructor(toClient, toServer, id, parent, isModal, forceModal) {
24862
24988
  this._expHandlers = null;
24863
24989
  this._id = 0;
@@ -24878,9 +25004,6 @@ class MGData {
24878
25004
  else
24879
25005
  this.constructor_1(id, parent, isModal, forceModal);
24880
25006
  }
24881
- get ForceModal() {
24882
- return this.forceModal;
24883
- }
24884
25007
  constructor_0(id, parent, isModal) {
24885
25008
  this._timerHandlers = new HandlersTable();
24886
25009
  this._expHandlers = new HandlersTable();
@@ -28882,13 +29005,6 @@ class VerifyCommand extends ClientTargetedCommandBase {
28882
29005
  }
28883
29006
 
28884
29007
  class EnhancedVerifyCommand extends VerifyCommand {
28885
- constructor() {
28886
- super();
28887
- this._buttonsID = '\0';
28888
- this._image = '\0';
28889
- this._returnValStr = null;
28890
- this._returnVal = null;
28891
- }
28892
29008
  async ProcessMessageBoxResponse(task, returnValue) {
28893
29009
  if (task !== null)
28894
29010
  await Operation.setoperVerifyReturnValue(returnValue, this._returnVal);
@@ -28919,6 +29035,13 @@ class EnhancedVerifyCommand extends VerifyCommand {
28919
29035
  break;
28920
29036
  }
28921
29037
  }
29038
+ constructor() {
29039
+ super();
29040
+ this._buttonsID = '\0';
29041
+ this._image = '\0';
29042
+ this._returnValStr = null;
29043
+ this._returnVal = null;
29044
+ }
28922
29045
  }
28923
29046
 
28924
29047
  class ResetRangeCommand extends ClientTargetedCommandBase {
@@ -29015,12 +29138,6 @@ class ResetLocateCommand extends ClientTargetedCommandBase {
29015
29138
  }
29016
29139
 
29017
29140
  class ResultCommand extends ClientTargetedCommandBase {
29018
- constructor() {
29019
- super();
29020
- this._isNull = false;
29021
- this._attr = StorageAttribute.NONE;
29022
- this._val = null;
29023
- }
29024
29141
  async Execute(res) {
29025
29142
  if (this._isNull)
29026
29143
  res.SetResultValue(null, StorageAttribute.NONE);
@@ -29046,6 +29163,12 @@ class ResultCommand extends ClientTargetedCommandBase {
29046
29163
  break;
29047
29164
  }
29048
29165
  }
29166
+ constructor() {
29167
+ super();
29168
+ this._isNull = false;
29169
+ this._attr = StorageAttribute.NONE;
29170
+ this._val = null;
29171
+ }
29049
29172
  }
29050
29173
 
29051
29174
  class AddSortCommand extends ClientTargetedCommandBase {
@@ -29410,19 +29533,9 @@ class CommandsTable {
29410
29533
  }
29411
29534
  }
29412
29535
 
29413
- let CurrentClientVersion = '4.1000.0-dev4100.109';
29536
+ let CurrentClientVersion = '4.1000.0-dev4100.113';
29414
29537
 
29415
29538
  class ClientManager {
29416
- constructor() {
29417
- this._globalUniqueSessionId = null;
29418
- this._buttonIsClicked = false;
29419
- RuntimeContextBase.Instance.Init(RemoteCommandsProcessor.RC_NO_CONTEXT_ID);
29420
- LastFocusedManager.Instance.Init(MGDataCollection.Instance);
29421
- LastFocusedManager.Instance.LastActionTime = Misc.getSystemMilliseconds();
29422
- RemoteCommandsProcessor.ShouldScrambleAndUnscrambleMessages = true;
29423
- this._globalUniqueSessionId = UniqueIDUtils.GetUniqueMachineID() + "_";
29424
- this.RegisterDelegates();
29425
- }
29426
29539
  static get Instance() {
29427
29540
  if (ClientManager._instance === null)
29428
29541
  ClientManager._instance = new ClientManager();
@@ -29622,6 +29735,16 @@ class ClientManager {
29622
29735
  Logger.Instance.WriteToLog("-----------------------------------------------------------------------------", true);
29623
29736
  }
29624
29737
  }
29738
+ constructor() {
29739
+ this._globalUniqueSessionId = null;
29740
+ this._buttonIsClicked = false;
29741
+ RuntimeContextBase.Instance.Init(RemoteCommandsProcessor.RC_NO_CONTEXT_ID);
29742
+ LastFocusedManager.Instance.Init(MGDataCollection.Instance);
29743
+ LastFocusedManager.Instance.LastActionTime = Misc.getSystemMilliseconds();
29744
+ RemoteCommandsProcessor.ShouldScrambleAndUnscrambleMessages = true;
29745
+ this._globalUniqueSessionId = UniqueIDUtils.GetUniqueMachineID() + "_";
29746
+ this.RegisterDelegates();
29747
+ }
29625
29748
  InitGuiManager() {
29626
29749
  Manager.EventsManager = EventsManager.Instance;
29627
29750
  Manager.DefaultServerName = ServerConfig.Instance.getServer();