@agilemotion/oui-react-js 1.8.30 → 1.8.31
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 +111 -305
- package/dist/ViewContext.js +239 -0
- package/dist/components/Button.js +3 -2
- package/dist/components/DataGrid.css +4 -0
- package/dist/components/DataGrid.js +8 -4
- package/dist/components/DataGridFilter.js +2 -2
- package/dist/components/DataGridHeading.js +1 -1
- package/dist/components/DocumentViewer.js +22 -10
- package/dist/components/Graph.js +2 -0
- package/dist/components/HtmlPanel.js +0 -1
- package/dist/components/Icon.js +15 -0
- package/dist/components/LottieIcon.js +19 -19
- package/dist/components/SocketManager.js +3 -0
- package/dist/components/Spinner.js +56 -0
- package/dist/components/StepperTitleBar.js +11 -2
- package/dist/components/TabPage.js +1 -1
- package/dist/components/TabPanel.js +2 -1
- package/dist/components/TitleBar.js +1 -1
- package/dist/components/Toolbar.js +1 -0
- package/dist/components/WordDocumentViewer.js +27 -4
- package/dist/components/dashboard/SideMenuModuleDashboard.css +4 -0
- package/dist/components/dashboard/components/Header.js +1 -1
- package/dist/components/form/CurrencyField.js +1 -1
- package/dist/components/form/DatePicker.js +1 -1
- package/dist/components/form/FieldSet.js +1 -1
- package/dist/components/form/Form.css +8 -0
- package/dist/components/form/IconField.js +5 -3
- package/dist/components/form/LookupField.js +1 -1
- package/dist/components/form/Section.js +6 -1
- package/dist/components/form/SelectItem.js +1 -0
- package/dist/components/form/TextField.js +1 -0
- package/dist/components/form/TimePicker.js +1 -0
- package/dist/components/form/TransferList.js +6 -5
- package/dist/components/layout/Layout.js +11 -2
- package/dist/components/layout/View.css +57 -0
- package/dist/components/layout/ViewPort.js +1 -0
- package/dist/components/layout/Window.js +4 -1
- package/dist/components/layout/WindowViewPort.js +12 -3
- package/dist/components/media/TrainingRoom.js +1 -1
- package/dist/components/media/VCEventType.js +0 -3
- package/dist/event/Observable.js +11 -2
- package/dist/event/RouteActionHandler.js +50 -55
- package/dist/js/ProcurementMeetings.js +61 -0
- package/package.json +1 -1
|
@@ -37,8 +37,8 @@ class RouteActionHandler {
|
|
|
37
37
|
path = _DynamicJS.default.executeScriptObject(currentViewId + 'ViewEvaluator_' + event?.source.id, actionConfig.pathEvaluator);
|
|
38
38
|
} else {
|
|
39
39
|
path = _ApplicationManager.default.isExpression(actionConfig.path) ? _ApplicationManager.default.resolveExpressionValue(actionConfig.path, event?.data) : actionConfig.path;
|
|
40
|
-
if ('@#{history.back}' === actionConfig.path
|
|
41
|
-
let historyElement = _ApplicationManager.default.getPreviousHistoryElement();
|
|
40
|
+
if ('@#{history.back}' === actionConfig.path) {
|
|
41
|
+
let historyElement = _ApplicationManager.default.getPreviousHistoryElement(isWindow ? 'window' : 'main');
|
|
42
42
|
if (historyElement === null) {
|
|
43
43
|
console.error('Invalid path. Cannot go back in history');
|
|
44
44
|
return;
|
|
@@ -65,79 +65,74 @@ class RouteActionHandler {
|
|
|
65
65
|
parameterValues.push(param);
|
|
66
66
|
}
|
|
67
67
|
}
|
|
68
|
-
let currentGraph = _ApplicationManager.default.
|
|
68
|
+
let currentGraph = _ApplicationManager.default.getCurrentGraph(isWindow ? 'window' : 'main');
|
|
69
69
|
if ('@#{home}' === actionConfig.path) {
|
|
70
70
|
_ApplicationManager.default.navigate('/view/unload');
|
|
71
71
|
_ApplicationManager.default.navigate('/view/dashboard');
|
|
72
72
|
} else if ('@#{history.back}' === actionConfig.path && currentGraph) {
|
|
73
73
|
if (isWindow && currentGraph.config.isWindow || !isWindow && !currentGraph.config.isWindow) {
|
|
74
|
-
_ApplicationManager.default.removeLoadedGraph(
|
|
74
|
+
_ApplicationManager.default.removeLoadedGraph(isWindow && currentGraph.config.isWindow ? 'window' : 'main');
|
|
75
75
|
}
|
|
76
76
|
} else {
|
|
77
77
|
let url = location + _ApplicationManager.default.getContextRoot() + _ApplicationManager.default.getUIConfigPath() + '/view/get?version=1.0&id=' + path;
|
|
78
78
|
(0, _RestUtils.sendRequest)(url, data => {
|
|
79
79
|
if (isParent && currentGraph) {
|
|
80
80
|
if (isWindow && currentGraph.config.isWindow || !isWindow && !currentGraph.config.isWindow) {
|
|
81
|
-
_ApplicationManager.default.removeLoadedGraph(
|
|
81
|
+
_ApplicationManager.default.removeLoadedGraph(isWindow && currentGraph.config.isWindow ? 'window' : 'main');
|
|
82
82
|
}
|
|
83
83
|
}
|
|
84
84
|
if (data.type === 'view') {
|
|
85
|
-
let currentView =
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
return this.defaultModel[key];
|
|
116
|
-
},
|
|
117
|
-
loaded: () => {
|
|
118
|
-
return false;
|
|
119
|
-
}
|
|
85
|
+
let currentView = _ApplicationManager.default.getTopView(isWindow ? 'window' : 'main');
|
|
86
|
+
let view = {};
|
|
87
|
+
let defaultModel = {};
|
|
88
|
+
_Utils.default.updateModel(parameterValues, defaultModel);
|
|
89
|
+
view.config = data;
|
|
90
|
+
view.parameters = parameterValues;
|
|
91
|
+
view.parent = isParent;
|
|
92
|
+
view.graphId = actionConfig.graphId;
|
|
93
|
+
view.handle = {
|
|
94
|
+
api: {
|
|
95
|
+
get id() {
|
|
96
|
+
return data.id;
|
|
97
|
+
},
|
|
98
|
+
get model() {
|
|
99
|
+
return defaultModel;
|
|
100
|
+
},
|
|
101
|
+
getChild: id => {
|
|
102
|
+
return null;
|
|
103
|
+
},
|
|
104
|
+
updateModel: values => {
|
|
105
|
+
_Utils.default.updateModel(values, defaultModel);
|
|
106
|
+
},
|
|
107
|
+
setModelValue: (key, value) => {
|
|
108
|
+
this.defaultModel.key = value;
|
|
109
|
+
},
|
|
110
|
+
getModelValue: key => {
|
|
111
|
+
return this.defaultModel[key];
|
|
112
|
+
},
|
|
113
|
+
loaded: () => {
|
|
114
|
+
return false;
|
|
120
115
|
}
|
|
121
|
-
}
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
116
|
+
}
|
|
117
|
+
};
|
|
118
|
+
_ApplicationManager.default.addView(view, path, forward, isWindow ? 'window' : 'main');
|
|
119
|
+
// None-existing route to ensure that the current view unloads
|
|
120
|
+
if (_Utils.default.isNull(actionConfig.popUp) || actionConfig.popUp === false) {
|
|
121
|
+
// Windows do not go to the Outlet in the viewport. They get rendered into the window viewport
|
|
122
|
+
if (!isWindow) {
|
|
123
|
+
//applicationManager.navigate('/view/unload');
|
|
124
|
+
_ApplicationManager.default.navigate('/view/' + data.id);
|
|
125
|
+
} else {
|
|
126
|
+
if (isWindow) {
|
|
127
|
+
_ApplicationManager.default.openWindowView(view);
|
|
128
128
|
}
|
|
129
129
|
}
|
|
130
130
|
} else {
|
|
131
|
-
|
|
132
|
-
currentView = applicationManager.getCurrentView();
|
|
133
|
-
if (currentView) {
|
|
134
|
-
currentView.handle.api.updateModel(parameterValues);
|
|
135
|
-
let event = new Event(currentView.handle, currentView.config.id, null);
|
|
136
|
-
eventManager.fireEvent(EventType.COMPONENT_LOAD, event);
|
|
137
|
-
}*/
|
|
131
|
+
_ApplicationManager.default.openPopupView(view);
|
|
138
132
|
}
|
|
139
133
|
} else if (data.type === 'graph') {
|
|
140
|
-
|
|
134
|
+
data.isWindow = isWindow;
|
|
135
|
+
_ApplicationManager.default.loadGraph(isParent, data, parameterValues, isPopup ? 'popup' : isWindow ? 'window' : 'main');
|
|
141
136
|
}
|
|
142
137
|
}, e => {
|
|
143
138
|
console.error(e);
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = exports.ProcurementMeetings = void 0;
|
|
7
|
+
var _Media = require("./Media");
|
|
8
|
+
var _ApplicationManager = _interopRequireDefault(require("../ApplicationManager"));
|
|
9
|
+
var _VCEventType = require("../components/media/VCEventType");
|
|
10
|
+
var _SocketManager = _interopRequireDefault(require("../components/SocketManager"));
|
|
11
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
12
|
+
class ProcurementMeetings {
|
|
13
|
+
constructor(resolver) {
|
|
14
|
+
this.resolver = resolver;
|
|
15
|
+
}
|
|
16
|
+
startMeeting = meeting => {
|
|
17
|
+
let receipientIds = [];
|
|
18
|
+
for (const attendee of meeting.attendees) {
|
|
19
|
+
let username = attendee.username;
|
|
20
|
+
if (username !== _ApplicationManager.default.getUserDetails().username) {
|
|
21
|
+
receipientIds.push(username);
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
console.log("Starting meeting : ", receipientIds);
|
|
25
|
+
let eventData = {
|
|
26
|
+
systemEventType: "startMeeting",
|
|
27
|
+
recipients: receipientIds,
|
|
28
|
+
data: {
|
|
29
|
+
procurementNumber: meeting.procurementNumber
|
|
30
|
+
}
|
|
31
|
+
};
|
|
32
|
+
return _SocketManager.default.emitEvent(_VCEventType.VCEventType.SYSTEM_EVENT, eventData);
|
|
33
|
+
};
|
|
34
|
+
handleSystemEvent = (event, meeting, viewId) => {
|
|
35
|
+
console.log("PROCESSING MEETING SYSTEM EVENT : ", event);
|
|
36
|
+
let data = event.data;
|
|
37
|
+
if (event.systemEventType === 'startMeeting') {
|
|
38
|
+
if (data.procurementNumber === meeting.procurementNumber) {
|
|
39
|
+
let api = _ApplicationManager.default.resolveComponentApi(viewId);
|
|
40
|
+
api.model.started = true;
|
|
41
|
+
api = _ApplicationManager.default.resolveComponentApi("mainLayout");
|
|
42
|
+
api.refresh();
|
|
43
|
+
api = _ApplicationManager.default.resolveComponentApi("waitingLayout");
|
|
44
|
+
api.refresh();
|
|
45
|
+
|
|
46
|
+
// This event will launch the VC to launch. There is a listener in the view config that launches the view
|
|
47
|
+
_ApplicationManager.default.api.fireEvent('SERVICE_CALL_SUCCESS', {
|
|
48
|
+
source: {
|
|
49
|
+
api: {
|
|
50
|
+
id: 'procurementMeetingSession'
|
|
51
|
+
}
|
|
52
|
+
},
|
|
53
|
+
viewId: 'procurementMeetingSession'
|
|
54
|
+
});
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
};
|
|
58
|
+
}
|
|
59
|
+
exports.ProcurementMeetings = ProcurementMeetings;
|
|
60
|
+
const instance = new ProcurementMeetings();
|
|
61
|
+
var _default = exports.default = instance;
|