@agilemotion/oui-react-js 1.6.0 → 1.6.2
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.
- package/dist/ApplicationManager.js +698 -421
- package/dist/BasicApp.js +5 -5
- package/dist/BasicAppHome.js +55 -26
- package/dist/DynamicJS.js +147 -65
- package/dist/InteractionPortalApp.css +1 -1
- package/dist/InteractionPortalApp.js +5 -5
- package/dist/InteractionPortalAppHome.js +65 -18
- package/dist/InteractionPortalApp_old.js +107 -61
- package/dist/RestUtils.js +339 -287
- package/dist/TypedValue.js +18 -15
- package/dist/Utils.js +375 -276
- package/dist/WithRouter.js +6 -6
- package/dist/assets/jss/components/authNavbarStyle.js +166 -164
- package/dist/assets/jss/components/buttonStyle.js +1 -1
- package/dist/assets/jss/components/cardAvatarStyle.js +1 -1
- package/dist/assets/jss/components/cardBodyStyle.js +1 -1
- package/dist/assets/jss/components/cardFooterStyle.js +1 -1
- package/dist/assets/jss/components/cardHeaderStyle.js +13 -13
- package/dist/assets/jss/components/cardIconStyle.js +1 -1
- package/dist/assets/jss/components/cardStyle.js +1 -1
- package/dist/assets/jss/components/cardTextStyle.js +1 -1
- package/dist/assets/jss/components/customDropdownStyle.js +168 -169
- package/dist/assets/jss/components/customInputStyle.js +9 -3
- package/dist/assets/jss/components/dropdownStyle.js +69 -69
- package/dist/assets/jss/components/footerStyle.js +19 -13
- package/dist/assets/jss/components/headerLinksStyle.js +45 -48
- package/dist/assets/jss/components/headerStyle.js +68 -65
- package/dist/assets/jss/components/navbarLinksStyle.js +66 -77
- package/dist/assets/jss/components/navbarStyle.js +79 -76
- package/dist/assets/jss/components/sidebarStyle.js +436 -436
- package/dist/assets/jss/components/typographyStyle.js +9 -3
- package/dist/assets/jss/rootStyle.js +96 -81
- package/dist/assets/jss/views/layoutStyle.js +44 -41
- package/dist/assets/jss/views/loginBasicStyle.js +1 -1
- package/dist/assets/jss/views/loginBusinessPortalStyle.js +1 -1
- package/dist/assets/jss/views/loginStyle.js +82 -77
- package/dist/components/AlertBar.js +50 -17
- package/dist/components/AlertItem.js +35 -12
- package/dist/components/AlertTemplate.js +30 -29
- package/dist/components/Button.js +62 -34
- package/dist/components/Calendar.js +140 -91
- package/dist/components/ConfirmationDialog.js +36 -11
- package/dist/components/DataGrid.js +512 -270
- package/dist/components/DataGridColumn.js +47 -22
- package/dist/components/DataGridFilter.js +186 -105
- package/dist/components/DataGridHeading.js +50 -32
- package/dist/components/Dialog.js +90 -35
- package/dist/components/DocumentTemplateDesigner.js +34 -16
- package/dist/components/DocumentTemplateDesignerComponent.css +0 -157
- package/dist/components/DocumentTemplateDesignerComponent.js +118 -62
- package/dist/components/DocumentTemplatePlaceholderDialog.js +52 -30
- package/dist/components/DocumentViewer.js +34 -18
- package/dist/components/DocumentViewerComponent.js +26 -9
- package/dist/components/ElementResizeHandler.js +229 -207
- package/dist/components/FileThumb.js +32 -10
- package/dist/components/Graph.js +153 -85
- package/dist/components/GraphNode.js +58 -38
- package/dist/components/HtmlPanel.js +67 -39
- package/dist/components/Icon.js +206 -166
- package/dist/components/LoadingIndicator.js +3 -3
- package/dist/components/LottieIcon.js +1 -1
- package/dist/components/PopupView.js +39 -19
- package/dist/components/Portlet.js +35 -19
- package/dist/components/RegularButton.js +28 -32
- package/dist/components/SignaturePanel.js +37 -17
- package/dist/components/SocketManager.js +178 -119
- package/dist/components/StepperTitleBar.js +62 -42
- package/dist/components/TabPage.js +30 -25
- package/dist/components/TabPanel.js +86 -33
- package/dist/components/TableCellContent.js +51 -32
- package/dist/components/TemplateDesigner.js +173 -121
- package/dist/components/TemplateItemEventHandler.js +335 -221
- package/dist/components/TemplateTable.js +183 -118
- package/dist/components/TitleBar.js +26 -11
- package/dist/components/Toolbar.js +67 -38
- package/dist/components/Tooltip.js +43 -35
- package/dist/components/Tree.js +85 -44
- package/dist/components/UseIsVisible.js +25 -4
- package/dist/components/card/Card.js +27 -33
- package/dist/components/card/CardAvatar.js +20 -19
- package/dist/components/card/CardBody.js +24 -27
- package/dist/components/card/CardFooter.js +23 -24
- package/dist/components/card/CardHeader.js +24 -27
- package/dist/components/card/CardIcon.js +17 -13
- package/dist/components/card/CardText.js +17 -13
- package/dist/components/customInput/CustomInput.js +22 -36
- package/dist/components/dashboard/{BasicBusinessAppDashboard.js → FoldingSideTabDashboard.js} +111 -63
- package/dist/components/dashboard/SideMenuModuleDashboard.css +60 -0
- package/dist/components/dashboard/SideMenuModuleDashboard.js +423 -0
- package/dist/components/dashboard/TopMenuModuleDashboard.js +138 -0
- package/dist/components/dashboard/components/Header.js +29 -12
- package/dist/components/dashboard/components/LeftDrawer.js +3 -5
- package/dist/components/dashboard/components/UserIdentity.js +2 -2
- package/dist/components/dashboard/components/blackDashboard/fixedPlugin/FixedPlugin.js +131 -87
- package/dist/components/dashboard/components/blackDashboard/sidebar/FoldingTabSidebar.js +488 -0
- package/dist/components/dashboard/components/blackDashboard/sidebar/ModuleMenu.js +64 -0
- package/dist/components/dashboard/components/blackDashboard/sidebar/ModuleMenuSidebar.css +65 -0
- package/dist/components/dashboard/components/blackDashboard/sidebar/ModuleMenuSidebar.js +556 -0
- package/dist/components/dashboard/components/portal/Timeline.js +1 -1
- package/dist/components/dashboard/components/portal/Workspace.js +5 -11
- package/dist/components/footer/Footer.js +31 -24
- package/dist/components/footer/HomeFooter.js +68 -34
- package/dist/components/form/AddressSearch.js +78 -42
- package/dist/components/form/AutoComplete.js +136 -55
- package/dist/components/form/BaseField.js +108 -56
- package/dist/components/form/Checkbox.js +10 -8
- package/dist/components/form/DatePicker.js +47 -25
- package/dist/components/form/FieldSet.js +217 -84
- package/dist/components/form/Form.js +334 -200
- package/dist/components/form/GridField.js +185 -82
- package/dist/components/form/IconField.js +9 -7
- package/dist/components/form/ImageEditor.js +141 -92
- package/dist/components/form/LabelField.js +12 -10
- package/dist/components/form/LookupField.js +54 -32
- package/dist/components/form/MultiFileUploadField.js +101 -67
- package/dist/components/form/RadioGroup.js +33 -16
- package/dist/components/form/Section.js +84 -34
- package/dist/components/form/SelectItem.js +55 -33
- package/dist/components/form/SignatureTemplateDesignerField.js +11 -9
- package/dist/components/form/Switch.js +10 -8
- package/dist/components/form/TextField.js +34 -16
- package/dist/components/form/TimePicker.js +19 -15
- package/dist/components/form/TransferList.js +153 -75
- package/dist/components/form/UploadField.js +183 -128
- package/dist/components/grid/GridContainer.js +12 -8
- package/dist/components/grid/GridItem.js +12 -8
- package/dist/components/layout/CollapsiblePanel.js +44 -18
- package/dist/components/layout/Layout.js +81 -40
- package/dist/components/layout/VC.css +1 -1
- package/dist/components/layout/View.js +136 -62
- package/dist/components/layout/ViewContainer.js +13 -11
- package/dist/components/layout/ViewPort.js +25 -10
- package/dist/components/layout/Window.js +87 -53
- package/dist/components/layout/WindowViewPort.js +38 -16
- package/dist/components/media/ClosablePanel.js +7 -7
- package/dist/components/media/LobbyWaitingList.js +7 -9
- package/dist/components/media/MediaSoupHelper.js +379 -187
- package/dist/components/media/SideBarContent.js +22 -14
- package/dist/components/media/SocketRequest.js +5 -1
- package/dist/components/media/SocketResponse.js +5 -1
- package/dist/components/media/Timer.js +35 -15
- package/dist/components/media/Toolbar.css +5 -0
- package/dist/components/media/Toolbar.js +220 -102
- package/dist/components/media/ToolbarButton.js +82 -33
- package/dist/components/media/Toolbar_bck.js +142 -70
- package/dist/components/media/Tracks.js +31 -28
- package/dist/components/media/TrainingRoom.js +284 -121
- package/dist/components/media/Transports.js +27 -24
- package/dist/components/media/VCEventManager.js +95 -31
- package/dist/components/media/VCEventType.js +5 -1
- package/dist/components/media/VCParticipantList.js +40 -14
- package/dist/components/media/VCParticipantListItem.js +92 -41
- package/dist/components/media/VCRoom.js +29 -11
- package/dist/components/media/VCRoomParticipant.js +488 -242
- package/dist/components/media/VCRoomRecorder.js +236 -175
- package/dist/components/media/VCRoomWorkspace.js +505 -245
- package/dist/components/media/Video.js +89 -25
- package/dist/components/media/VideoPlayer.js +56 -22
- package/dist/components/media/chat/ChatRoom.js +255 -132
- package/dist/components/media/chat/ChatRoomItem.js +35 -14
- package/dist/components/media/chat/ChatRoomList.js +43 -13
- package/dist/components/menu/CollapsibleMenu.js +39 -20
- package/dist/components/menu/MenuBars.js +81 -48
- package/dist/components/menu/MenuButton.js +95 -60
- package/dist/components/menu/MenuItem.js +28 -9
- package/dist/components/menu/MenuLink.js +12 -10
- package/dist/components/menu/PopupMenu.js +16 -12
- package/dist/components/navbars/AuthNavbar.js +27 -18
- package/dist/components/navbars/HomeNavbar.js +243 -194
- package/dist/components/navbars/PortalNavbar.js +50 -26
- package/dist/components/signatures/AgilitySignaturePanel.js +96 -39
- package/dist/components/signatures/AlertItem.js +36 -13
- package/dist/components/signatures/Card.js +4 -4
- package/dist/components/signatures/DocumentContainer.js +141 -57
- package/dist/components/signatures/ImageSignatureInput.js +90 -59
- package/dist/components/signatures/MenuButton.js +53 -33
- package/dist/components/signatures/Prompt.js +26 -5
- package/dist/components/signatures/ResponsiveTable.js +302 -197
- package/dist/components/signatures/SearchView.js +77 -36
- package/dist/components/signatures/SignatorySearch.js +30 -10
- package/dist/components/signatures/SignatorySearchForm.js +35 -18
- package/dist/components/signatures/SignatureInput.js +56 -26
- package/dist/components/signatures/SignatureInputProps.js +107 -55
- package/dist/components/signatures/SignatureTemplateDesigner.js +340 -235
- package/dist/components/signatures/Toolbar.js +135 -94
- package/dist/components/signatures/ViewUtils.js +273 -224
- package/dist/components/typography/Danger.js +3 -5
- package/dist/components/typography/Info.js +3 -5
- package/dist/components/typography/Link.js +3 -5
- package/dist/event/ActionHandlers.js +57 -43
- package/dist/event/Event.js +16 -13
- package/dist/event/EventListener.js +39 -36
- package/dist/event/EventType.js +5 -1
- package/dist/event/LoadDataActionHandler.js +20 -8
- package/dist/event/Observable.js +323 -142
- package/dist/event/RouteActionHandler.js +139 -125
- package/dist/event/ScriptActionHandler.js +20 -8
- package/dist/event/ServiceCallActionHandler.js +51 -39
- package/dist/event/SignalGraphActionHandler.js +19 -7
- package/dist/js/Addresses.js +38 -24
- package/dist/js/Calendar.js +168 -161
- package/dist/js/DynamicLib.js +14 -11
- package/dist/js/Media.js +213 -120
- package/dist/js/Validators.js +6 -5
- package/dist/js/Windows.js +48 -47
- package/dist/redux/store/ConfigureStore.js +17 -9
- package/dist/redux/store/DashboardStore.js +110 -43
- package/dist/redux/store/History.js +1 -1
- package/dist/redux/store/SecurityStore.js +59 -20
- package/dist/security/TokenManager.js +44 -30
- package/dist/theme-default.js +1 -1
- package/dist/view/Dashboard.js +230 -137
- package/dist/view/PortalDashboard.js +5 -5
- package/dist/view/Settings.js +4 -2
- package/dist/view/Views.js +27 -14
- package/dist/view/security/ChangePasswordBasic.js +97 -40
- package/dist/view/security/ForgotPassword.js +59 -22
- package/dist/view/security/ForgotPasswordBasic.js +62 -21
- package/dist/view/security/Login.js +64 -24
- package/dist/view/security/LoginBasic.js +65 -26
- package/dist/view/security/LoginInteractionPortal.js +62 -25
- package/dist/view/security/ResetPassword.js +65 -23
- package/dist/view/security/ResetPasswordBasic.js +91 -37
- package/dist/view/security/Security.js +12 -12
- package/package.json +1 -2
- package/dist/components/dashboard/BusinessPortalAppDashboard.js +0 -154
- package/dist/components/dashboard/components/blackDashboard/sidebar/Sidebar.js +0 -447
- /package/dist/components/dashboard/{BusinessPortalAppDashboard.css → TopMenuModuleDashboard.css} +0 -0
- /package/dist/components/dashboard/components/blackDashboard/sidebar/{Sidebar.css → FoldingTabSidebar.css} +0 -0
package/dist/RestUtils.js
CHANGED
|
@@ -19,10 +19,24 @@ var _EventType = _interopRequireDefault(require("./event/EventType"));
|
|
|
19
19
|
|
|
20
20
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
21
21
|
|
|
22
|
-
|
|
22
|
+
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
|
|
23
|
+
|
|
24
|
+
function _createForOfIteratorHelper(o, allowArrayLike) { var it; if (typeof Symbol === "undefined" || o[Symbol.iterator] == null) { if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = o[Symbol.iterator](); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it.return != null) it.return(); } finally { if (didErr) throw err; } } }; }
|
|
25
|
+
|
|
26
|
+
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
27
|
+
|
|
28
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
|
29
|
+
|
|
30
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
31
|
+
|
|
32
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
33
|
+
|
|
34
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
35
|
+
|
|
36
|
+
var location = window.location.protocol + '//' + window.location.hostname;
|
|
23
37
|
exports.location = location;
|
|
24
38
|
|
|
25
|
-
|
|
39
|
+
var status = function status(response) {
|
|
26
40
|
if (response.ok) {
|
|
27
41
|
return Promise.resolve(response);
|
|
28
42
|
} else {
|
|
@@ -30,397 +44,435 @@ const status = response => {
|
|
|
30
44
|
}
|
|
31
45
|
};
|
|
32
46
|
|
|
33
|
-
|
|
47
|
+
var json = function json(response) {
|
|
34
48
|
return response.text();
|
|
35
49
|
};
|
|
36
50
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
return true;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
return paramValue.hasOwnProperty('value') ? _Utils.default.isNull(paramValue.value) : false;
|
|
51
|
+
var RestUtils = /*#__PURE__*/function () {
|
|
52
|
+
function RestUtils() {
|
|
53
|
+
_classCallCheck(this, RestUtils);
|
|
44
54
|
}
|
|
45
55
|
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
56
|
+
_createClass(RestUtils, [{
|
|
57
|
+
key: "isParamValueNull",
|
|
58
|
+
value: function isParamValueNull(paramValue) {
|
|
59
|
+
if (_Utils.default.isNull(paramValue)) {
|
|
60
|
+
return true;
|
|
61
|
+
}
|
|
49
62
|
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
63
|
+
return paramValue.hasOwnProperty('value') ? _Utils.default.isNull(paramValue.value) : false;
|
|
64
|
+
}
|
|
65
|
+
}, {
|
|
66
|
+
key: "invokeRest",
|
|
67
|
+
value: function invokeRest(service, component, viewId, successCallback, errorCallback, invalidParamCallback, returnValueBinding, successMessage) {
|
|
68
|
+
var _this = this;
|
|
54
69
|
|
|
55
|
-
|
|
56
|
-
|
|
70
|
+
var event = arguments.length > 8 && arguments[8] !== undefined ? arguments[8] : null;
|
|
71
|
+
var url = service.url.startsWith('http://') || service.url.startsWith('https://') ? service.url : location + "".concat(_ApplicationManager.default.getContextRoot() + service.url);
|
|
72
|
+
var requestBody = null;
|
|
57
73
|
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
}
|
|
74
|
+
if (!_Utils.default.isNull(service.parameters)) {
|
|
75
|
+
var queryString = '';
|
|
76
|
+
var pathParameters = '';
|
|
77
|
+
var requestBodyParamFound = false;
|
|
63
78
|
|
|
64
|
-
|
|
65
|
-
|
|
79
|
+
var _iterator = _createForOfIteratorHelper(service.parameters),
|
|
80
|
+
_step;
|
|
66
81
|
|
|
67
|
-
|
|
82
|
+
try {
|
|
83
|
+
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
|
84
|
+
var parameter = _step.value;
|
|
68
85
|
|
|
69
|
-
|
|
70
|
-
httpParameterType = 'QUERY_PARAMETER';
|
|
71
|
-
}
|
|
86
|
+
var parameterValue = _ApplicationManager.default.resolveParameterValue(parameter, event ? event.data : null);
|
|
72
87
|
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
88
|
+
if (!_Utils.default.isNull(parameter.validator) && !_Utils.default.evaluateBooleanExpression(parameter.validator.nullable, parameter.name) && this.isParamValueNull(parameterValue)) {
|
|
89
|
+
if (!_Utils.default.isNull(invalidParamCallback)) {
|
|
90
|
+
console.error('INVALID PARAMETER : ', parameter);
|
|
91
|
+
invalidParamCallback(parameter);
|
|
92
|
+
}
|
|
78
93
|
|
|
79
|
-
|
|
80
|
-
queryString += parameterValue.type + ':';
|
|
94
|
+
return;
|
|
81
95
|
}
|
|
82
96
|
|
|
83
|
-
|
|
84
|
-
|
|
97
|
+
var httpParameterType = parameter.httpParameterType;
|
|
98
|
+
|
|
99
|
+
if (_Utils.default.isNull(httpParameterType)) {
|
|
100
|
+
httpParameterType = 'QUERY_PARAMETER';
|
|
85
101
|
}
|
|
86
102
|
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
103
|
+
if (httpParameterType === 'QUERY_PARAMETER') {
|
|
104
|
+
if (!_Utils.default.isNull(parameterValue)) {
|
|
105
|
+
if (queryString.length > 0) {
|
|
106
|
+
queryString += '&';
|
|
107
|
+
}
|
|
91
108
|
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
}
|
|
96
|
-
}
|
|
109
|
+
if (!_Utils.default.isNull(service.includeParameterTypes) && service.includeParameterTypes === true) {
|
|
110
|
+
queryString += parameterValue.type + ':';
|
|
111
|
+
}
|
|
97
112
|
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
113
|
+
if (parameterValue.type === 'MapObject') {
|
|
114
|
+
parameterValue.value.type = 'MapEntityDto';
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
queryString += parameter.name + '=';
|
|
118
|
+
queryString += typeof parameterValue.value === 'string' || typeof parameterValue.value === 'number' ? parameterValue.value : JSON.stringify(parameterValue.value);
|
|
119
|
+
}
|
|
120
|
+
}
|
|
105
121
|
|
|
106
|
-
|
|
107
|
-
|
|
122
|
+
if (httpParameterType === 'PATH_VARIABLE') {
|
|
123
|
+
if (!_Utils.default.isNull(parameterValue)) {
|
|
124
|
+
pathParameters += '/' + (_typeof(parameterValue.value) === 'object' ? JSON.stringify(parameterValue.value) : parameterValue.instanceType === 'TypedValue' ? parameterValue.value : parameterValue);
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
if (httpParameterType === 'REQUEST_BODY') {
|
|
129
|
+
if (requestBodyParamFound) {
|
|
130
|
+
console.error('Only one request body is permitted');
|
|
131
|
+
return;
|
|
108
132
|
} else {
|
|
109
|
-
if (
|
|
110
|
-
requestBody
|
|
133
|
+
if (!this.isParamValueNull(parameterValue)) {
|
|
134
|
+
requestBody = parameterValue.instanceType === 'TypedValue' ? parameterValue.value : parameterValue;
|
|
135
|
+
|
|
136
|
+
if (parameterValue.type === 'MapObject') {
|
|
137
|
+
requestBody.type = 'MapEntityDto';
|
|
138
|
+
} else {
|
|
139
|
+
if (_typeof(requestBody) === 'object') {
|
|
140
|
+
requestBody.type = parameterValue.type;
|
|
141
|
+
}
|
|
142
|
+
}
|
|
111
143
|
}
|
|
112
144
|
}
|
|
113
145
|
}
|
|
114
146
|
}
|
|
147
|
+
} catch (err) {
|
|
148
|
+
_iterator.e(err);
|
|
149
|
+
} finally {
|
|
150
|
+
_iterator.f();
|
|
115
151
|
}
|
|
116
|
-
}
|
|
117
152
|
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
153
|
+
if (pathParameters.length > 0) {
|
|
154
|
+
url += pathParameters;
|
|
155
|
+
}
|
|
121
156
|
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
157
|
+
if (queryString.length > 0) {
|
|
158
|
+
url += '?';
|
|
159
|
+
url += queryString;
|
|
160
|
+
}
|
|
125
161
|
}
|
|
126
|
-
}
|
|
127
162
|
|
|
128
|
-
|
|
129
|
-
|
|
163
|
+
var headers = service.headers;
|
|
164
|
+
var contentType = null;
|
|
130
165
|
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
166
|
+
if (!_Utils.default.isNull(headers)) {
|
|
167
|
+
contentType = headers['Content-Type'];
|
|
168
|
+
}
|
|
134
169
|
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
170
|
+
if (requestBody !== null && service.method === 'GET') {
|
|
171
|
+
throw new Error('A request body parameter cannot be specified for a GET request');
|
|
172
|
+
}
|
|
138
173
|
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
174
|
+
if (requestBody !== null || service.method === 'POST') {
|
|
175
|
+
console.log("POSTING REST REQUEST BODY : ", requestBody);
|
|
176
|
+
postData(url, function (response) {
|
|
177
|
+
if (!_Utils.default.isNull(successCallback)) {
|
|
178
|
+
_this.processSuccessfulResponseData(component, response, successCallback, viewId, successMessage);
|
|
179
|
+
}
|
|
145
180
|
|
|
146
|
-
|
|
181
|
+
var path = _Utils.default.getPropertyChainPath(returnValueBinding);
|
|
147
182
|
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
183
|
+
if (!_Utils.default.isNull(path.valueObject) && !_Utils.default.isNull(path.property)) {
|
|
184
|
+
path.valueObject[path.property] = response;
|
|
185
|
+
}
|
|
151
186
|
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
187
|
+
_this.fireEvent(viewId, component, _EventType.default.SERVICE_CALL_SUCCESS, response);
|
|
188
|
+
}, function (e) {
|
|
189
|
+
if (!_Utils.default.isNull(errorCallback)) {
|
|
190
|
+
errorCallback(e);
|
|
191
|
+
}
|
|
157
192
|
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
193
|
+
_this.fireEvent(viewId, component, _EventType.default.SERVICE_CALL_FAILURE);
|
|
194
|
+
}, !service.url.startsWith('http://'), requestBody);
|
|
195
|
+
} else if (contentType === 'application/pdf' || contentType === 'application/vnd.ms-excel') {
|
|
196
|
+
download(url, function (data) {}, function (e) {
|
|
197
|
+
if (!_Utils.default.isNull(errorCallback)) {
|
|
198
|
+
errorCallback(e);
|
|
199
|
+
}
|
|
200
|
+
});
|
|
201
|
+
} else {
|
|
202
|
+
sendRequest(url, function (data) {
|
|
203
|
+
var path = _Utils.default.getPropertyChainPath(returnValueBinding);
|
|
169
204
|
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
205
|
+
if (!_Utils.default.isNull(path.valueObject) && !_Utils.default.isNull(path.property)) {
|
|
206
|
+
path.valueObject[path.property] = data;
|
|
207
|
+
}
|
|
173
208
|
|
|
174
|
-
|
|
209
|
+
_this.fireEvent(viewId, component, _EventType.default.SERVICE_CALL_SUCCESS, data);
|
|
175
210
|
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
211
|
+
if (!_Utils.default.isNull(successCallback)) {
|
|
212
|
+
successCallback(data);
|
|
213
|
+
}
|
|
214
|
+
}, function (e) {
|
|
215
|
+
_this.fireEvent(viewId, component, _EventType.default.SERVICE_CALL_FAILURE);
|
|
181
216
|
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
217
|
+
if (!_Utils.default.isNull(errorCallback)) {
|
|
218
|
+
errorCallback(e);
|
|
219
|
+
}
|
|
220
|
+
}, !service.url.startsWith('http://'));
|
|
221
|
+
}
|
|
186
222
|
}
|
|
187
|
-
}
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
223
|
+
}, {
|
|
224
|
+
key: "invokeRpc",
|
|
225
|
+
value: function invokeRpc(rpcDetails, component, viewId, successCallback, errorCallback, invalidParamCallback, returnValueBinding, successMessage) {
|
|
226
|
+
var _this2 = this;
|
|
227
|
+
|
|
228
|
+
var event = arguments.length > 8 && arguments[8] !== undefined ? arguments[8] : null;
|
|
229
|
+
var request = {};
|
|
230
|
+
request.id = viewId;
|
|
231
|
+
var split = rpcDetails.serviceId.split('.');
|
|
232
|
+
request.service = split[1];
|
|
233
|
+
request.method = rpcDetails.procedureName;
|
|
234
|
+
var module = split[0].toLowerCase();
|
|
235
|
+
|
|
236
|
+
if (!_Utils.default.isNull(rpcDetails.parameters) && rpcDetails.parameters.length > 0) {
|
|
237
|
+
request.parameters = [];
|
|
238
|
+
|
|
239
|
+
for (var i = 0; i < rpcDetails.parameters.length; i++) {
|
|
240
|
+
var parameterConfig = rpcDetails.parameters[i];
|
|
241
|
+
var parameter = {};
|
|
242
|
+
parameter.name = parameterConfig.name;
|
|
243
|
+
parameter.index = parameterConfig.index;
|
|
244
|
+
|
|
245
|
+
var val = _ApplicationManager.default.resolveParameterValue(parameterConfig, event ? event.data : null);
|
|
246
|
+
|
|
247
|
+
if (!_Utils.default.isNull(val)) {
|
|
248
|
+
parameter.value = val.value;
|
|
249
|
+
parameter.type = val.type;
|
|
250
|
+
}
|
|
196
251
|
|
|
197
|
-
|
|
198
|
-
|
|
252
|
+
if (typeof parameter.value === 'undefined') {
|
|
253
|
+
parameter.value = null;
|
|
254
|
+
}
|
|
199
255
|
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
parameter.name = parameterConfig.name;
|
|
204
|
-
parameter.index = parameterConfig.index;
|
|
256
|
+
if (_Utils.default.isNull(parameter.type)) {
|
|
257
|
+
parameter.type = 'String';
|
|
258
|
+
}
|
|
205
259
|
|
|
206
|
-
|
|
260
|
+
if (!_Utils.default.isNull(parameterConfig.validator) && _Utils.default.evaluateBooleanExpression(parameterConfig.validator.nullable, parameterConfig.name) === false && this.isParamValueNull(parameter)) {
|
|
261
|
+
if (!_Utils.default.isNull(invalidParamCallback)) {
|
|
262
|
+
console.error('INVALID PARAMETER : ', parameter);
|
|
263
|
+
invalidParamCallback(parameter);
|
|
264
|
+
}
|
|
207
265
|
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
parameter.type = val.type;
|
|
211
|
-
}
|
|
266
|
+
return;
|
|
267
|
+
}
|
|
212
268
|
|
|
213
|
-
|
|
214
|
-
parameter.value = null;
|
|
269
|
+
request.parameters.push(parameter);
|
|
215
270
|
}
|
|
271
|
+
}
|
|
216
272
|
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
273
|
+
this.doFetch(location + _ApplicationManager.default.getContextRoot() + '/' + module + '/api/v1/rpc/invoke', function (response) {
|
|
274
|
+
if (!_Utils.default.isNull(viewId) && !_Utils.default.isNull(component)) {
|
|
275
|
+
var path = _Utils.default.getPropertyChainPath(returnValueBinding);
|
|
220
276
|
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
console.error('INVALID PARAMETER : ', parameter);
|
|
224
|
-
invalidParamCallback(parameter);
|
|
277
|
+
if (!_Utils.default.isNull(path.valueObject) && !_Utils.default.isNull(path.property)) {
|
|
278
|
+
path.valueObject[path.property] = response;
|
|
225
279
|
}
|
|
226
280
|
|
|
227
|
-
|
|
281
|
+
_this2.fireEvent(viewId, component, _EventType.default.SERVICE_CALL_SUCCESS, response.data);
|
|
282
|
+
|
|
283
|
+
if (successCallback !== null) {
|
|
284
|
+
successCallback(response);
|
|
285
|
+
}
|
|
286
|
+
}
|
|
287
|
+
}, function (e) {
|
|
288
|
+
if (errorCallback !== null) {
|
|
289
|
+
errorCallback(e);
|
|
228
290
|
}
|
|
229
291
|
|
|
230
|
-
|
|
231
|
-
|
|
292
|
+
if (!_Utils.default.isNull(viewId) && !_Utils.default.isNull(component)) {
|
|
293
|
+
_this2.fireEvent(viewId, component, _EventType.default.SERVICE_CALL_FAILURE);
|
|
294
|
+
}
|
|
295
|
+
}, true, 'POST', false, request, viewId, successMessage, true);
|
|
232
296
|
}
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
297
|
+
}, {
|
|
298
|
+
key: "doPostData",
|
|
299
|
+
value: function doPostData(url, successCallback, errorCallback, secure, data, viewId, successMessage) {
|
|
300
|
+
this.fetchWithCustomConfig(url, successCallback, errorCallback, secure, null, 'POST', false, data, 'rest');
|
|
301
|
+
}
|
|
302
|
+
}, {
|
|
303
|
+
key: "doFetch",
|
|
304
|
+
value: function doFetch(url, successCallback, errorCallback, secure, method, download, body, viewId, successMessage, track) {
|
|
305
|
+
this.fetchWithCustomConfig(url, successCallback, errorCallback, secure, null, method, download, body, null, viewId, successMessage, track);
|
|
306
|
+
}
|
|
307
|
+
}, {
|
|
308
|
+
key: "fetchWithCustomConfig",
|
|
309
|
+
value: function fetchWithCustomConfig(url, successCallback, errorCallback, secure, config, method, download, body, serviceType, viewId, successMessage, track) {
|
|
310
|
+
var accessToken = sessionStorage.getItem('accessToken');
|
|
311
|
+
var idToken = sessionStorage.getItem('idToken');
|
|
312
|
+
var data = body ? JSON.stringify(body) : null;
|
|
313
|
+
var fetchConfig = config;
|
|
314
|
+
|
|
315
|
+
if (_Utils.default.isNull(fetchConfig)) {
|
|
316
|
+
if (_Utils.default.isNull(secure) || secure === true) {
|
|
317
|
+
fetchConfig = {
|
|
318
|
+
method: _Utils.default.isNull(method) ? 'GET' : method,
|
|
319
|
+
headers: {
|
|
320
|
+
'Content-Type': 'application/x-www-form-urlencoded',
|
|
321
|
+
'Authorization': 'Bearer ' + accessToken,
|
|
322
|
+
'idToken': idToken
|
|
323
|
+
},
|
|
324
|
+
body: data
|
|
325
|
+
};
|
|
326
|
+
} else {
|
|
327
|
+
fetchConfig = {
|
|
328
|
+
method: _Utils.default.isNull(method) ? 'GET' : method,
|
|
329
|
+
headers: {
|
|
330
|
+
'Content-Type': 'application/json',
|
|
331
|
+
'Accept': 'application/json'
|
|
332
|
+
},
|
|
333
|
+
body: data
|
|
334
|
+
};
|
|
240
335
|
}
|
|
241
336
|
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
if (successCallback !== null) {
|
|
245
|
-
successCallback(response);
|
|
337
|
+
if ('rest' === serviceType) {
|
|
338
|
+
fetchConfig.headers['Content-Type'] = 'application/json; charset=utf-8';
|
|
246
339
|
}
|
|
247
340
|
}
|
|
248
|
-
}, e => {
|
|
249
|
-
if (errorCallback !== null) {
|
|
250
|
-
errorCallback(e);
|
|
251
|
-
}
|
|
252
|
-
|
|
253
|
-
if (!_Utils.default.isNull(viewId) && !_Utils.default.isNull(component)) {
|
|
254
|
-
this.fireEvent(viewId, component, _EventType.default.SERVICE_CALL_FAILURE);
|
|
255
|
-
}
|
|
256
|
-
}, true, 'POST', false, request, viewId, successMessage, true);
|
|
257
|
-
}
|
|
258
|
-
|
|
259
|
-
doPostData(url, successCallback, errorCallback, secure, data, viewId, successMessage) {
|
|
260
|
-
this.fetchWithCustomConfig(url, successCallback, errorCallback, secure, null, 'POST', false, data, 'rest');
|
|
261
|
-
}
|
|
262
|
-
|
|
263
|
-
doFetch(url, successCallback, errorCallback, secure, method, download, body, viewId, successMessage, track) {
|
|
264
|
-
this.fetchWithCustomConfig(url, successCallback, errorCallback, secure, null, method, download, body, null, viewId, successMessage, track);
|
|
265
|
-
}
|
|
266
|
-
|
|
267
|
-
fetchWithCustomConfig(url, successCallback, errorCallback, secure, config, method, download, body, serviceType, viewId, successMessage, track) {
|
|
268
|
-
const accessToken = sessionStorage.getItem('accessToken');
|
|
269
|
-
const idToken = sessionStorage.getItem('idToken');
|
|
270
|
-
let data = body ? JSON.stringify(body) : null;
|
|
271
|
-
let fetchConfig = config;
|
|
272
|
-
|
|
273
|
-
if (_Utils.default.isNull(fetchConfig)) {
|
|
274
|
-
if (_Utils.default.isNull(secure) || secure === true) {
|
|
275
|
-
fetchConfig = {
|
|
276
|
-
method: _Utils.default.isNull(method) ? 'GET' : method,
|
|
277
|
-
headers: {
|
|
278
|
-
'Content-Type': 'application/x-www-form-urlencoded',
|
|
279
|
-
'Authorization': 'Bearer ' + accessToken,
|
|
280
|
-
'idToken': idToken
|
|
281
|
-
},
|
|
282
|
-
body: data
|
|
283
|
-
};
|
|
284
|
-
} else {
|
|
285
|
-
fetchConfig = {
|
|
286
|
-
method: _Utils.default.isNull(method) ? 'GET' : method,
|
|
287
|
-
headers: {
|
|
288
|
-
'Content-Type': 'application/json',
|
|
289
|
-
'Accept': 'application/json'
|
|
290
|
-
},
|
|
291
|
-
body: data
|
|
292
|
-
};
|
|
293
|
-
}
|
|
294
|
-
|
|
295
|
-
if ('rest' === serviceType) {
|
|
296
|
-
fetchConfig.headers['Content-Type'] = 'application/json; charset=utf-8';
|
|
297
|
-
}
|
|
298
|
-
}
|
|
299
341
|
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
342
|
+
if (download) {
|
|
343
|
+
if (url.indexOf('?') < 0) {
|
|
344
|
+
url += '?';
|
|
345
|
+
} else {
|
|
346
|
+
url += '&';
|
|
347
|
+
}
|
|
306
348
|
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
} else {
|
|
313
|
-
if (_Utils.default.isNull(track) || track === true) {
|
|
314
|
-
(0, _reactPromiseTracker.trackPromise)(this.executeFetch(url, fetchConfig, successCallback, viewId, successMessage, errorCallback));
|
|
349
|
+
url += 'access_token=' + accessToken;
|
|
350
|
+
url += '&idToken=' + idToken;
|
|
351
|
+
url += '&themePrimaryColor=' + encodeURIComponent(_ApplicationManager.default.getApplicationPrimaryColor());
|
|
352
|
+
url += '&themeSecondaryColor=' + encodeURIComponent(_ApplicationManager.default.getApplicationSecondaryColor());
|
|
353
|
+
window.open(encodeURI(url), '_blank');
|
|
315
354
|
} else {
|
|
316
|
-
|
|
355
|
+
if (_Utils.default.isNull(track) || track === true) {
|
|
356
|
+
(0, _reactPromiseTracker.trackPromise)(this.executeFetch(url, fetchConfig, successCallback, viewId, successMessage, errorCallback));
|
|
357
|
+
} else {
|
|
358
|
+
this.executeFetch(url, fetchConfig, successCallback, viewId, successMessage, errorCallback);
|
|
359
|
+
}
|
|
317
360
|
}
|
|
318
361
|
}
|
|
319
|
-
}
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
this.processSuccessfulResponseData(null, data, successCallback, viewId, successMessage);
|
|
324
|
-
}).catch(e => {
|
|
325
|
-
console.error(e);
|
|
362
|
+
}, {
|
|
363
|
+
key: "executeFetch",
|
|
364
|
+
value: function executeFetch(url, fetchConfig, successCallback, viewId, successMessage, errorCallback) {
|
|
365
|
+
var _this3 = this;
|
|
326
366
|
|
|
327
|
-
|
|
328
|
-
|
|
367
|
+
return fetch(encodeURI(url), fetchConfig).then(status).then(json).then(function (data) {
|
|
368
|
+
_this3.processSuccessfulResponseData(null, data, successCallback, viewId, successMessage);
|
|
369
|
+
}).catch(function (e) {
|
|
370
|
+
console.error(e);
|
|
329
371
|
|
|
330
|
-
|
|
372
|
+
if (e.status === 401 && !url.endsWith('/logout')) {
|
|
373
|
+
errorCallback(e);
|
|
331
374
|
|
|
332
|
-
|
|
333
|
-
}
|
|
375
|
+
_ApplicationManager.default.clear();
|
|
334
376
|
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
}
|
|
338
|
-
});
|
|
339
|
-
}
|
|
377
|
+
_ApplicationManager.default.navigate('/login');
|
|
378
|
+
}
|
|
340
379
|
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
380
|
+
if (errorCallback !== null) {
|
|
381
|
+
errorCallback(e);
|
|
382
|
+
}
|
|
383
|
+
});
|
|
384
|
+
}
|
|
385
|
+
}, {
|
|
386
|
+
key: "processSuccessfulResponseData",
|
|
387
|
+
value: function processSuccessfulResponseData(component, data, successCallback, viewId, successMessage) {
|
|
388
|
+
var response;
|
|
389
|
+
|
|
390
|
+
if (!_Utils.default.isNull(data) && data.toString().trim().length === 0) {
|
|
391
|
+
response = null;
|
|
392
|
+
} else if (_typeof(data) === 'object' || _Utils.default.isNull(data) || data.toString().trim().length === 0) {
|
|
352
393
|
response = data;
|
|
394
|
+
} else {
|
|
395
|
+
try {
|
|
396
|
+
response = JSON.parse(data);
|
|
397
|
+
} catch (ignored) {
|
|
398
|
+
response = data;
|
|
399
|
+
}
|
|
353
400
|
}
|
|
354
|
-
}
|
|
355
401
|
|
|
356
|
-
|
|
357
|
-
|
|
402
|
+
if (successCallback !== null) {
|
|
403
|
+
var responseData = response ? response.data : null;
|
|
358
404
|
|
|
359
|
-
|
|
360
|
-
|
|
405
|
+
if (response && responseData && response.dataType === 'message') {
|
|
406
|
+
var event = new _Event.default(_ApplicationManager.default, viewId, responseData);
|
|
361
407
|
|
|
362
|
-
|
|
408
|
+
_Observable.default.fireEvent(_EventType.default.MESSAGE_ARRIVED, event);
|
|
363
409
|
|
|
364
|
-
|
|
365
|
-
|
|
410
|
+
if (component !== null) {
|
|
411
|
+
event = new _Event.default(component, viewId, responseData);
|
|
366
412
|
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
let event = new _Event.default(_ApplicationManager.default, viewId, message);
|
|
413
|
+
_Observable.default.fireEvent(_EventType.default.MESSAGE_ARRIVED, event);
|
|
414
|
+
}
|
|
415
|
+
} else if (!_Utils.default.isNull(successMessage)) {
|
|
416
|
+
var message = {
|
|
417
|
+
messageType: 'SUCCESS',
|
|
418
|
+
message: _ApplicationManager.default.populateTemplate(successMessage, response ? response.data : null)
|
|
419
|
+
};
|
|
375
420
|
|
|
376
|
-
|
|
421
|
+
var _event = new _Event.default(_ApplicationManager.default, viewId, message);
|
|
377
422
|
|
|
378
|
-
|
|
379
|
-
event = new _Event.default(component, viewId, message);
|
|
423
|
+
_Observable.default.fireEvent(_EventType.default.MESSAGE_ARRIVED, _event);
|
|
380
424
|
|
|
381
|
-
|
|
425
|
+
if (component !== null) {
|
|
426
|
+
_event = new _Event.default(component, viewId, message);
|
|
427
|
+
|
|
428
|
+
_Observable.default.fireEvent(_EventType.default.MESSAGE_ARRIVED, _event);
|
|
429
|
+
}
|
|
382
430
|
}
|
|
383
|
-
}
|
|
384
431
|
|
|
385
|
-
|
|
432
|
+
successCallback(response);
|
|
433
|
+
}
|
|
386
434
|
}
|
|
387
|
-
}
|
|
435
|
+
}, {
|
|
436
|
+
key: "fireEvent",
|
|
437
|
+
value: function fireEvent(viewId, component, eventType, response) {
|
|
438
|
+
var event = new _Event.default(component, viewId, response);
|
|
388
439
|
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
_Observable.default.fireEvent(eventType, event);
|
|
393
|
-
}
|
|
440
|
+
_Observable.default.fireEvent(eventType, event);
|
|
441
|
+
}
|
|
442
|
+
}]);
|
|
394
443
|
|
|
395
|
-
|
|
444
|
+
return RestUtils;
|
|
445
|
+
}();
|
|
396
446
|
|
|
397
|
-
|
|
447
|
+
var instance = new RestUtils();
|
|
398
448
|
|
|
399
|
-
|
|
449
|
+
var postData = function postData(url, successCallback, errorCallback, secure, data) {
|
|
400
450
|
instance.doPostData(url, successCallback, errorCallback, secure, data);
|
|
401
451
|
};
|
|
402
452
|
|
|
403
453
|
exports.postData = postData;
|
|
404
454
|
|
|
405
|
-
|
|
455
|
+
var sendRequest = function sendRequest(url, successCallback, errorCallback, secure, track) {
|
|
406
456
|
instance.doFetch(url, successCallback, errorCallback, secure, null, null, null, null, null, track);
|
|
407
457
|
};
|
|
408
458
|
|
|
409
459
|
exports.sendRequest = sendRequest;
|
|
410
460
|
|
|
411
|
-
|
|
461
|
+
var download = function download(url, successCallback, errorCallback, secure) {
|
|
412
462
|
instance.doFetch(url, successCallback, errorCallback, secure, 'GET', true);
|
|
413
463
|
};
|
|
414
464
|
|
|
415
465
|
exports.download = download;
|
|
416
466
|
|
|
417
|
-
|
|
467
|
+
var invokeRpc = function invokeRpc(rpcDetails, component, viewId, successCallback, errorCallback, invalidParamCallback, returnValueBinding, successMessage) {
|
|
468
|
+
var event = arguments.length > 8 && arguments[8] !== undefined ? arguments[8] : null;
|
|
418
469
|
instance.invokeRpc(rpcDetails, component, viewId, successCallback, errorCallback, invalidParamCallback, returnValueBinding, successMessage, event);
|
|
419
470
|
};
|
|
420
471
|
|
|
421
472
|
exports.invokeRpc = invokeRpc;
|
|
422
473
|
|
|
423
|
-
|
|
474
|
+
var invokeRest = function invokeRest(serviceConfig, component, viewId, successCallback, errorCallback, invalidParamCallback, returnValueBinding, successMessage) {
|
|
475
|
+
var event = arguments.length > 8 && arguments[8] !== undefined ? arguments[8] : null;
|
|
424
476
|
instance.invokeRest(serviceConfig, component, viewId, successCallback, errorCallback, invalidParamCallback, returnValueBinding, successMessage, event);
|
|
425
477
|
};
|
|
426
478
|
|