@openui5/sap.ui.integration 1.113.0 → 1.115.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.reuse/dep5 +0 -5
- package/THIRDPARTY.txt +1 -7
- package/package.json +6 -6
- package/src/sap/ui/integration/.library +1 -1
- package/src/sap/ui/integration/ActionDefinition.js +1 -1
- package/src/sap/ui/integration/Designtime.js +1 -1
- package/src/sap/ui/integration/Extension.js +1 -1
- package/src/sap/ui/integration/Host.js +1 -1
- package/src/sap/ui/integration/cards/AdaptiveContent.js +1 -1
- package/src/sap/ui/integration/cards/AnalyticalContent.js +15 -3
- package/src/sap/ui/integration/cards/AnalyticsCloudContent.js +2 -2
- package/src/sap/ui/integration/cards/BaseContent.js +91 -29
- package/src/sap/ui/integration/cards/BaseContentRenderer.js +5 -5
- package/src/sap/ui/integration/cards/BaseListContent.js +3 -3
- package/src/sap/ui/integration/cards/CalendarContent.js +207 -8
- package/src/sap/ui/integration/cards/ComponentContent.js +3 -3
- package/src/sap/ui/integration/cards/Footer.js +4 -6
- package/src/sap/ui/integration/cards/Header.js +2 -2
- package/src/sap/ui/integration/cards/ListContent.js +24 -1
- package/src/sap/ui/integration/cards/NumericHeader.js +2 -2
- package/src/sap/ui/integration/cards/ObjectContent.js +79 -13
- package/src/sap/ui/integration/cards/TableContent.js +19 -2
- package/src/sap/ui/integration/cards/TableContentRenderer.js +2 -2
- package/src/sap/ui/integration/cards/TimelineContent.js +17 -1
- package/src/sap/ui/integration/cards/TimelineContentRenderer.js +1 -1
- package/src/sap/ui/integration/cards/WebPageContent.js +8 -6
- package/src/sap/ui/integration/cards/actions/CardActions.js +1 -1
- package/src/sap/ui/integration/cards/adaptivecards/elements/UI5InputChoiceSet.js +1 -1
- package/src/sap/ui/integration/cards/adaptivecards/elements/UI5InputDate.js +1 -1
- package/src/sap/ui/integration/cards/adaptivecards/elements/UI5InputNumber.js +1 -1
- package/src/sap/ui/integration/cards/adaptivecards/elements/UI5InputText.js +1 -1
- package/src/sap/ui/integration/cards/adaptivecards/elements/UI5InputToggle.js +1 -1
- package/src/sap/ui/integration/cards/filters/BaseFilter.js +2 -1
- package/src/sap/ui/integration/cards/filters/DateRangeFilter.js +6 -136
- package/src/sap/ui/integration/cards/filters/FilterBar.js +1 -1
- package/src/sap/ui/integration/cards/filters/FilterBarFactory.js +1 -1
- package/src/sap/ui/integration/cards/filters/SearchFilter.js +1 -1
- package/src/sap/ui/integration/cards/filters/SelectFilter.js +10 -4
- package/src/sap/ui/integration/cards/list/MicrochartsResizeHelper.js +1 -1
- package/src/sap/ui/integration/controls/ActionsStrip.js +1 -1
- package/src/sap/ui/integration/controls/ActionsToolbar.js +1 -1
- package/src/sap/ui/integration/controls/BlockingMessage.js +267 -0
- package/src/sap/ui/integration/controls/LinkWithIcon.js +1 -1
- package/src/sap/ui/integration/controls/ListContentItem.js +7 -2
- package/src/sap/ui/integration/controls/ListContentItemRenderer.js +2 -2
- package/src/sap/ui/integration/controls/Microchart.js +1 -1
- package/src/sap/ui/integration/controls/MicrochartLegend.js +1 -1
- package/src/sap/ui/integration/controls/ObjectStatus.js +1 -1
- package/src/sap/ui/integration/controls/Paginator.js +1 -1
- package/src/sap/ui/integration/controls/PaginatorRenderer.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/BaseEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/PropertyEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/PropertyEditors.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/BasePropertyEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/PropertyEditorFactory.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/arrayEditor/ArrayEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/booleanEditor/BooleanEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/codeEditor/CodeEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/dateEditor/DateEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/dateTimeEditor/DateTimeEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/enumStringEditor/EnumStringEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/groupEditor/GroupEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/iconEditor/IconEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/iconEditor/IsInIconPool.validator.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/integerEditor/IntegerEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/jsonEditor/JsonEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/listEditor/ListEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/mapEditor/MapEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/multiSelectEditor/MultiSelectEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/numberEditor/NumberEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/objectArrayEditor/ObjectArrayEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/selectEditor/SelectEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/separatorEditor/SeparatorEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/stringEditor/StringEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/propertyEditor/textAreaEditor/TextAreaEditor.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/util/binding/ObjectBinding.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/util/unset.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/IsBoolean.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/IsDate.js +7 -5
- package/src/sap/ui/integration/designtime/baseEditor/validator/IsInteger.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/IsNumber.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/IsSelectedKey.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/IsStringList.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/IsUniqueKey.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/IsUniqueList.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/IsValidBinding.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/MaxLength.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/NotABinding.js +1 -1
- package/src/sap/ui/integration/designtime/baseEditor/validator/ValidatorRegistry.js +1 -1
- package/src/sap/ui/integration/designtime/cardEditor/BASEditor.js +8 -10
- package/src/sap/ui/integration/designtime/cardEditor/CardEditor.js +0 -1
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n.properties +3 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_ar.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_bg.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_ca.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_cs.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_cy.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_da.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_de.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_el.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_en.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_en_GB.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_en_US_sappsd.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_en_US_saprigi.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_en_US_saptrc.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_es.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_es_MX.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_et.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_fi.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_fr.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_fr_CA.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_hi.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_hr.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_hu.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_id.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_it.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_iw.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_ja.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_kk.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_ko.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_lt.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_lv.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_ms.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_nl.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_no.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_pl.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_pt.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_pt_PT.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_ro.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_ru.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_sh.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_sk.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_sl.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_sv.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_th.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_tr.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_uk.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_vi.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_zh_CN.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/i18n/i18n_zh_TW.properties +2 -0
- package/src/sap/ui/integration/designtime/cardEditor/propertyEditor/complexMapEditor/ComplexMapEditor.js +1 -1
- package/src/sap/ui/integration/designtime/cardEditor/propertyEditor/destinationsEditor/DestinationsEditor.js +1 -1
- package/src/sap/ui/integration/designtime/cardEditor/propertyEditor/filtersEditor/FiltersEditor.js +4 -5
- package/src/sap/ui/integration/designtime/cardEditor/propertyEditor/iconEditor/IconEditor.js +1 -1
- package/src/sap/ui/integration/designtime/cardEditor/propertyEditor/parametersEditor/ParametersEditor.js +12 -1
- package/src/sap/ui/integration/designtime/editor/Card.js +1 -1
- package/src/sap/ui/integration/designtime/editor/CardEditor.js +2 -2
- package/src/sap/ui/integration/designtime/editor/CardPreview.js +41 -9
- package/src/sap/ui/integration/designtime/editor/css/CardPreview.css +18 -14
- package/src/sap/ui/integration/editor/Editor.js +45 -40
- package/src/sap/ui/integration/editor/EditorResourceBundles.js +1 -1
- package/src/sap/ui/integration/editor/Extension.js +1 -1
- package/src/sap/ui/integration/editor/Manifest.js +1 -1
- package/src/sap/ui/integration/editor/Settings.js +74 -63
- package/src/sap/ui/integration/editor/css/Editor.css +1 -3
- package/src/sap/ui/integration/editor/fields/BaseField.js +6 -3
- package/src/sap/ui/integration/editor/fields/BooleanField.js +1 -1
- package/src/sap/ui/integration/editor/fields/DateField.js +5 -4
- package/src/sap/ui/integration/editor/fields/DateTimeField.js +5 -4
- package/src/sap/ui/integration/editor/fields/DestinationField.js +1 -1
- package/src/sap/ui/integration/editor/fields/GroupField.js +5 -6
- package/src/sap/ui/integration/editor/fields/IntegerField.js +1 -1
- package/src/sap/ui/integration/editor/fields/NumberField.js +1 -1
- package/src/sap/ui/integration/editor/fields/ObjectField.js +60 -45
- package/src/sap/ui/integration/editor/fields/ObjectListField.js +3 -3
- package/src/sap/ui/integration/editor/fields/StringField.js +39 -14
- package/src/sap/ui/integration/editor/fields/StringListField.js +1 -1
- package/src/sap/ui/integration/editor/fields/fragment/Controller.js +1 -1
- package/src/sap/ui/integration/editor/fields/viz/ColorSelect.js +1 -1
- package/src/sap/ui/integration/editor/fields/viz/IconSelect.js +1 -1
- package/src/sap/ui/integration/editor/fields/viz/ShapeSelect.js +1 -1
- package/src/sap/ui/integration/editor/fields/viz/VizBase.js +1 -1
- package/src/sap/ui/integration/library.js +33 -4
- package/src/sap/ui/integration/messagebundle.properties +1 -1
- package/src/sap/ui/integration/messagebundle_en_US_sappsd.properties +1 -1
- package/src/sap/ui/integration/messagebundle_en_US_saprigi.properties +1 -1
- package/src/sap/ui/integration/messagebundle_en_US_saptrc.properties +1 -1
- package/src/sap/ui/integration/model/ContextModel.js +1 -1
- package/src/sap/ui/integration/model/ObservableModel.js +1 -1
- package/src/sap/ui/integration/model/PagingModelListBinding.js +1 -1
- package/src/sap/ui/integration/schemas/sap-card.json +57 -11
- package/src/sap/ui/integration/themes/base/BlockingMessage.less +11 -0
- package/src/sap/ui/integration/themes/base/Paginator.less +19 -38
- package/src/sap/ui/integration/themes/base/library.source.less +1 -0
- package/src/sap/ui/integration/util/BaseFactory.js +1 -1
- package/src/sap/ui/integration/util/BindingHelper.js +42 -13
- package/src/sap/ui/integration/util/BindingResolver.js +3 -18
- package/src/sap/ui/integration/util/CacheAndRequestDataProvider.js +4 -3
- package/src/sap/ui/integration/util/CardObserver.js +1 -1
- package/src/sap/ui/integration/util/ContentFactory.js +1 -1
- package/src/sap/ui/integration/util/CsrfTokenHandler.js +1 -1
- package/src/sap/ui/integration/util/DataProvider.js +1 -1
- package/src/sap/ui/integration/util/DataProviderFactory.js +14 -13
- package/src/sap/ui/integration/util/DateRangeHelper.js +211 -0
- package/src/sap/ui/integration/util/Destinations.js +1 -1
- package/src/sap/ui/integration/util/ErrorHandler.js +25 -175
- package/src/sap/ui/integration/util/ExtensionDataProvider.js +1 -1
- package/src/sap/ui/integration/util/Form.js +71 -21
- package/src/sap/ui/integration/util/HeaderFactory.js +1 -1
- package/src/sap/ui/integration/util/JSONBindingHelper.js +1 -1
- package/src/sap/ui/integration/util/LoadingProvider.js +3 -88
- package/src/sap/ui/integration/util/Manifest.js +1 -1
- package/src/sap/ui/integration/util/ParameterMap.js +6 -4
- package/src/sap/ui/integration/util/RequestDataProvider.js +1 -1
- package/src/sap/ui/integration/util/ServiceDataProvider.js +1 -1
- package/src/sap/ui/integration/util/ServiceManager.js +1 -1
- package/src/sap/ui/integration/util/SkeletonCard.js +1 -1
- package/src/sap/ui/integration/util/Utils.js +6 -4
- package/src/sap/ui/integration/util/Validators.js +7 -1
- package/src/sap/ui/integration/widgets/Card.js +197 -100
|
@@ -10,6 +10,7 @@ sap.ui.define([
|
|
|
10
10
|
"sap/ui/integration/cards/BaseContent",
|
|
11
11
|
"sap/ui/integration/util/BindingHelper",
|
|
12
12
|
"sap/ui/integration/util/BindingResolver",
|
|
13
|
+
"sap/f/cards/loading/CalendarPlaceholder",
|
|
13
14
|
"sap/f/CalendarAppointmentInCard",
|
|
14
15
|
"sap/f/CalendarInCard",
|
|
15
16
|
"sap/f/PlanningCalendarInCardLegend",
|
|
@@ -27,14 +28,17 @@ sap.ui.define([
|
|
|
27
28
|
"sap/ui/core/date/UniversalDate",
|
|
28
29
|
"sap/ui/unified/CalendarLegendItem",
|
|
29
30
|
"sap/ui/core/Configuration",
|
|
30
|
-
"sap/ui/core/date/UI5Date"
|
|
31
|
-
|
|
31
|
+
"sap/ui/core/date/UI5Date",
|
|
32
|
+
"sap/ui/unified/DateRange",
|
|
33
|
+
"sap/ui/core/Core"
|
|
34
|
+
],
|
|
32
35
|
function (CalendarContentRenderer,
|
|
33
36
|
ResizeHandler,
|
|
34
37
|
library,
|
|
35
38
|
BaseContent,
|
|
36
39
|
BindingHelper,
|
|
37
40
|
BindingResolver,
|
|
41
|
+
CalendarPlaceholder,
|
|
38
42
|
CalendarAppointmentInCard,
|
|
39
43
|
CalendarInCard,
|
|
40
44
|
PlanningCalendarInCardLegend,
|
|
@@ -52,7 +56,9 @@ sap.ui.define([
|
|
|
52
56
|
UniversalDate,
|
|
53
57
|
CalendarLegendItem,
|
|
54
58
|
Configuration,
|
|
55
|
-
UI5Date
|
|
59
|
+
UI5Date,
|
|
60
|
+
DateRange,
|
|
61
|
+
Core
|
|
56
62
|
) {
|
|
57
63
|
"use strict";
|
|
58
64
|
|
|
@@ -73,7 +79,7 @@ sap.ui.define([
|
|
|
73
79
|
* @extends sap.ui.integration.cards.BaseContent
|
|
74
80
|
*
|
|
75
81
|
* @author SAP SE
|
|
76
|
-
* @version 1.
|
|
82
|
+
* @version 1.115.0
|
|
77
83
|
*
|
|
78
84
|
* @constructor
|
|
79
85
|
* @private
|
|
@@ -104,6 +110,49 @@ sap.ui.define([
|
|
|
104
110
|
}
|
|
105
111
|
});
|
|
106
112
|
|
|
113
|
+
/**
|
|
114
|
+
* Changes the calendar view to the specified month.
|
|
115
|
+
*
|
|
116
|
+
* @ui5-restricted
|
|
117
|
+
* @private
|
|
118
|
+
* @param {int} iMonth The selected month, which month the calendar should display.
|
|
119
|
+
*/
|
|
120
|
+
CalendarContent.prototype.changeMonth = function (iMonth) {
|
|
121
|
+
this._oCalendar._getMonthPicker().setMonth(iMonth);
|
|
122
|
+
this._oCalendar._selectMonth();
|
|
123
|
+
this.invalidate();
|
|
124
|
+
this.getCardInstance().fireStateChanged();
|
|
125
|
+
};
|
|
126
|
+
|
|
127
|
+
/**
|
|
128
|
+
* Changes the calendar date to the passed date.
|
|
129
|
+
*
|
|
130
|
+
* @ui5-restricted
|
|
131
|
+
* @private
|
|
132
|
+
* @param {Date} oDate The selected date, the month and year of which the calendar should display.
|
|
133
|
+
*/
|
|
134
|
+
CalendarContent.prototype.changeDate = function (oDate) {
|
|
135
|
+
var oCardActions = this.getActions(),
|
|
136
|
+
oDateRange = new DateRange(),
|
|
137
|
+
oCal = this._oCalendar;
|
|
138
|
+
|
|
139
|
+
oDateRange.setStartDate(oDate);
|
|
140
|
+
oCal.destroySelectedDates();
|
|
141
|
+
oCal.addAggregation('selectedDates', oDateRange);
|
|
142
|
+
this._oFocusedDate = oCal.getSelectedDates()[0] ? oCal.getSelectedDates()[0] : null;
|
|
143
|
+
oCal.addSelectedDate(oDateRange);
|
|
144
|
+
|
|
145
|
+
oCal._getYearPicker().setYear(oDate.getFullYear());
|
|
146
|
+
oCal._getYearPicker().fireSelect();
|
|
147
|
+
oCal._selectYear();
|
|
148
|
+
|
|
149
|
+
this.changeMonth(oDate.getMonth());
|
|
150
|
+
|
|
151
|
+
oCardActions.fireAction(this, "DateChange", {
|
|
152
|
+
"selectedDate": oDate
|
|
153
|
+
});
|
|
154
|
+
};
|
|
155
|
+
|
|
107
156
|
/**
|
|
108
157
|
* Creates the internal structure of the card.
|
|
109
158
|
* @private
|
|
@@ -225,6 +274,21 @@ sap.ui.define([
|
|
|
225
274
|
oEvent.control.toggleStyleClass("sapMPCInCardTwoColumns", oEvent.target.getBoundingClientRect().width > 576);
|
|
226
275
|
};
|
|
227
276
|
|
|
277
|
+
/**
|
|
278
|
+
* @override
|
|
279
|
+
*/
|
|
280
|
+
CalendarContent.prototype.createLoadingPlaceholder = function (oConfiguration) {
|
|
281
|
+
var oCard = this.getCardInstance(),
|
|
282
|
+
iContentMinItems = oCard.getContentMinItems(oConfiguration);
|
|
283
|
+
|
|
284
|
+
return new CalendarPlaceholder({
|
|
285
|
+
minItems: iContentMinItems !== null ? iContentMinItems : 2,
|
|
286
|
+
maxLegendItems: oConfiguration.maxLegendItems ? parseInt(oConfiguration.maxLegendItems) : 2,
|
|
287
|
+
item: oConfiguration.item ? oConfiguration.item.template : {},
|
|
288
|
+
legendItem: oConfiguration.legendItem ? oConfiguration.legendItem.template : {}
|
|
289
|
+
});
|
|
290
|
+
};
|
|
291
|
+
|
|
228
292
|
/**
|
|
229
293
|
* @override
|
|
230
294
|
*/
|
|
@@ -275,6 +339,141 @@ sap.ui.define([
|
|
|
275
339
|
}
|
|
276
340
|
};
|
|
277
341
|
|
|
342
|
+
/**
|
|
343
|
+
* @override
|
|
344
|
+
*/
|
|
345
|
+
CalendarContent.prototype.getStaticConfiguration = function () {
|
|
346
|
+
var oConfiguration = this.getParsedConfiguration(),
|
|
347
|
+
aAppointments = this.getAppointments(),
|
|
348
|
+
aSpecialDates = this._oCalendar.getSpecialDates(),
|
|
349
|
+
sLegendId = this._oCalendar.getLegend(),
|
|
350
|
+
oLegend = Core.byId(sLegendId),
|
|
351
|
+
aLegendItems = oLegend.getItems(),
|
|
352
|
+
aLegendAppointmentItems = oLegend.getAppointmentItems(),
|
|
353
|
+
oFocusedDate = this._oCalendar.getSelectedDates()[0] ?
|
|
354
|
+
this._oCalendar.getSelectedDates()[0].getStartDate() :
|
|
355
|
+
null,
|
|
356
|
+
oSelectededDate = this._oCalendar.getSelectedDates()[0] ? this._oCalendar.getSelectedDates()[0] : null,
|
|
357
|
+
oSelectedDateEnd = oSelectededDate.getStartDate ? oSelectededDate.getStartDate().getTime() + 86400000 : null,
|
|
358
|
+
oSelectedJsStartDate = oSelectededDate.getStartDate(),
|
|
359
|
+
iMaxItems = oConfiguration.maxItems,
|
|
360
|
+
iMaxLegendItems = oConfiguration.maxLegendItems,
|
|
361
|
+
sNoItemsText = oConfiguration.noItemsText,
|
|
362
|
+
aResolvedItems = [],
|
|
363
|
+
aResolvedSpecialDates = [],
|
|
364
|
+
aResolvedLegendItems = [],
|
|
365
|
+
bMoreItems = false,
|
|
366
|
+
sFocusedDateISO;
|
|
367
|
+
|
|
368
|
+
sFocusedDateISO = oFocusedDate ? oFocusedDate.toISOString() : null;
|
|
369
|
+
sFocusedDateISO = sFocusedDateISO ? sFocusedDateISO : oConfiguration.date;
|
|
370
|
+
|
|
371
|
+
aAppointments.forEach(function (oItem, i) {
|
|
372
|
+
var oStartDate = oItem.getStartDate(),
|
|
373
|
+
oEndDate = oItem.getEndDate(),
|
|
374
|
+
aTemplateKeys,
|
|
375
|
+
singleAssembledItem,
|
|
376
|
+
bAppInDaY = oStartDate >= oSelectedJsStartDate && oStartDate <= oSelectedDateEnd,
|
|
377
|
+
bAppEndsInDay = oEndDate >= oSelectedJsStartDate && oEndDate <= oSelectedDateEnd,
|
|
378
|
+
bDayInApp = oStartDate <= oSelectedJsStartDate && oEndDate > oSelectedDateEnd,
|
|
379
|
+
bIncludeAppointment = bAppInDaY || bAppEndsInDay || bDayInApp;
|
|
380
|
+
|
|
381
|
+
if (bIncludeAppointment) {
|
|
382
|
+
aTemplateKeys = Object.keys(oConfiguration.item.template);
|
|
383
|
+
singleAssembledItem = {};
|
|
384
|
+
|
|
385
|
+
aTemplateKeys.forEach(function(sKey) {
|
|
386
|
+
var oBindingInfo = BindingHelper.prependRelativePaths(oConfiguration.item.template[sKey], this.getBindingPath("appointments") + "/" + i);
|
|
387
|
+
|
|
388
|
+
singleAssembledItem[sKey] = BindingResolver.resolveValue(oBindingInfo, this);
|
|
389
|
+
}.bind(this));
|
|
390
|
+
singleAssembledItem.startDate = new Date(singleAssembledItem.startDate).toISOString();
|
|
391
|
+
if (singleAssembledItem.endDate) {
|
|
392
|
+
singleAssembledItem.endDate = new Date(singleAssembledItem.endDate).toISOString();
|
|
393
|
+
}
|
|
394
|
+
aResolvedItems.push(singleAssembledItem);
|
|
395
|
+
if (aResolvedItems.length > oConfiguration.maxItems) {
|
|
396
|
+
bMoreItems = true;
|
|
397
|
+
}
|
|
398
|
+
}
|
|
399
|
+
}.bind(this));
|
|
400
|
+
|
|
401
|
+
aSpecialDates.forEach(function (oItem, i) {
|
|
402
|
+
var oCal = this._oCalendar,
|
|
403
|
+
oStartDate = oItem.getStartDate(),
|
|
404
|
+
oEndDate = oItem.getEndDate(),
|
|
405
|
+
oViewedMonth = oCal._getMonthPicker().getMonth() ?
|
|
406
|
+
oCal._getMonthPicker().getMonth() :
|
|
407
|
+
oCal._getFocusedDate().getMonth(),
|
|
408
|
+
oViewedYear = Number(oCal._getYearString()),
|
|
409
|
+
bStartsWithinMonth = oStartDate.getMonth() === oViewedMonth,
|
|
410
|
+
bEndsWithinMonth = oEndDate ? oEndDate.getMonth() === oViewedMonth : false,
|
|
411
|
+
bStartsWithinYear = oStartDate.getFullYear() === oViewedYear,
|
|
412
|
+
bEndsWithinYear = oItem.getEndDate() ?
|
|
413
|
+
oItem.getEndDate().getFullYear() === oViewedYear :
|
|
414
|
+
bStartsWithinYear,
|
|
415
|
+
bIncludeSpecialDate = (bStartsWithinMonth || bEndsWithinMonth) && (bStartsWithinYear || bEndsWithinYear),
|
|
416
|
+
aTemplateKeys,
|
|
417
|
+
oResolvedDate;
|
|
418
|
+
|
|
419
|
+
if (bIncludeSpecialDate) {
|
|
420
|
+
aTemplateKeys = Object.keys(oConfiguration.specialDate.template);
|
|
421
|
+
var oBindingInfo = {};
|
|
422
|
+
|
|
423
|
+
aTemplateKeys.forEach(function(sKey) {
|
|
424
|
+
oBindingInfo[sKey] = BindingHelper.prependRelativePaths(oConfiguration.specialDate.template[sKey], this._oCalendar.getBindingPath("specialDates") + "/" + i);
|
|
425
|
+
}.bind(this));
|
|
426
|
+
|
|
427
|
+
oResolvedDate = BindingResolver.resolveValue(oBindingInfo, this);
|
|
428
|
+
oResolvedDate.startDate = new Date(oResolvedDate.startDate).toISOString();
|
|
429
|
+
if (oResolvedDate.endDate) {
|
|
430
|
+
oResolvedDate.endDate = new Date(oResolvedDate.endDate).toISOString();
|
|
431
|
+
}
|
|
432
|
+
|
|
433
|
+
aResolvedSpecialDates.push(oResolvedDate);
|
|
434
|
+
}
|
|
435
|
+
}.bind(this));
|
|
436
|
+
|
|
437
|
+
aLegendItems.forEach(function (oItem, i) {
|
|
438
|
+
var aTemplateKeys = Object.keys(oConfiguration.legendItem.template),
|
|
439
|
+
singleAssembledItem = {};
|
|
440
|
+
|
|
441
|
+
aTemplateKeys.forEach(function(sKey) {
|
|
442
|
+
var oBindingInfo = BindingHelper.prependRelativePaths(oConfiguration.legendItem.template[sKey], oLegend.getBindingPath("items") + "/" + i);
|
|
443
|
+
|
|
444
|
+
singleAssembledItem[sKey] = BindingResolver.resolveValue(oBindingInfo, this);
|
|
445
|
+
}.bind(this));
|
|
446
|
+
aResolvedLegendItems.push(singleAssembledItem);
|
|
447
|
+
}.bind(this));
|
|
448
|
+
|
|
449
|
+
aLegendAppointmentItems.forEach(function (oItem, i) {
|
|
450
|
+
var aTemplateKeys = Object.keys(oConfiguration.legendItem.template),
|
|
451
|
+
singleAssembledItem = {};
|
|
452
|
+
|
|
453
|
+
aTemplateKeys.forEach(function(sKey) {
|
|
454
|
+
var oBindingInfo = BindingHelper.prependRelativePaths(oConfiguration.legendItem.template[sKey], oLegend.getBindingPath("items") + "/" + i);
|
|
455
|
+
|
|
456
|
+
singleAssembledItem[sKey] = BindingResolver.resolveValue(oBindingInfo, this);
|
|
457
|
+
}.bind(this));
|
|
458
|
+
aResolvedLegendItems.push(singleAssembledItem);
|
|
459
|
+
}.bind(this));
|
|
460
|
+
|
|
461
|
+
var oStaticConfiguration = {};
|
|
462
|
+
|
|
463
|
+
oStaticConfiguration.items = aResolvedItems;
|
|
464
|
+
oStaticConfiguration.specialDates = aResolvedSpecialDates;
|
|
465
|
+
oStaticConfiguration.legendItems = aResolvedLegendItems;
|
|
466
|
+
oStaticConfiguration.date = sFocusedDateISO;
|
|
467
|
+
oStaticConfiguration.maxItems = iMaxItems;
|
|
468
|
+
oStaticConfiguration.maxLegendItems = iMaxLegendItems;
|
|
469
|
+
oStaticConfiguration.noItemsText = sNoItemsText;
|
|
470
|
+
if (bMoreItems) {
|
|
471
|
+
oStaticConfiguration.moreItems = BindingResolver.resolveValue(oConfiguration.moreItems, this);
|
|
472
|
+
}
|
|
473
|
+
|
|
474
|
+
return oStaticConfiguration;
|
|
475
|
+
};
|
|
476
|
+
|
|
278
477
|
/**
|
|
279
478
|
* Sets values in the parameters' model to be used as a counter in the header part ot the card.
|
|
280
479
|
*
|
|
@@ -556,7 +755,7 @@ sap.ui.define([
|
|
|
556
755
|
* @param {Object} sTime The date template of the configuration object.
|
|
557
756
|
*/
|
|
558
757
|
CalendarContent.prototype._addDate = function (sTime) {
|
|
559
|
-
if (
|
|
758
|
+
if (BindingHelper.isBindingInfo(sTime)) {
|
|
560
759
|
if (!sTime) {
|
|
561
760
|
return;
|
|
562
761
|
}
|
|
@@ -581,7 +780,7 @@ sap.ui.define([
|
|
|
581
780
|
* @param {Object} mMaxItems The mMaxItems template of the configuration object.
|
|
582
781
|
*/
|
|
583
782
|
CalendarContent.prototype._addMaxItems = function (mMaxItems) {
|
|
584
|
-
if (
|
|
783
|
+
if (BindingHelper.isBindingInfo(mMaxItems)) {
|
|
585
784
|
mMaxItems && this.bindProperty("visibleAppointmentsCount", mMaxItems);
|
|
586
785
|
} else {
|
|
587
786
|
this.setVisibleAppointmentsCount(mMaxItems);
|
|
@@ -595,7 +794,7 @@ sap.ui.define([
|
|
|
595
794
|
* @param {Object} mMaxLegendItems The maxLegendItems template of the configuration object.
|
|
596
795
|
*/
|
|
597
796
|
CalendarContent.prototype._addMaxLegendItems = function (mMaxLegendItems) {
|
|
598
|
-
if (
|
|
797
|
+
if (BindingHelper.isBindingInfo(mMaxLegendItems)) {
|
|
599
798
|
mMaxLegendItems && this._oLegend.bindProperty("visibleLegendItemsCount", mMaxLegendItems);
|
|
600
799
|
} else {
|
|
601
800
|
this._oLegend.setVisibleLegendItemsCount(mMaxLegendItems);
|
|
@@ -609,7 +808,7 @@ sap.ui.define([
|
|
|
609
808
|
* @param {Object} mNoItemsText The noItemsText template of the configuration object.
|
|
610
809
|
*/
|
|
611
810
|
CalendarContent.prototype._addNoItemsText = function (mNoItemsText) {
|
|
612
|
-
if (
|
|
811
|
+
if (BindingHelper.isBindingInfo(mNoItemsText)) {
|
|
613
812
|
mNoItemsText && this.bindProperty("noAppointmentsText", mNoItemsText);
|
|
614
813
|
} else {
|
|
615
814
|
this.setNoAppointmentsText(mNoItemsText);
|
|
@@ -35,7 +35,7 @@ sap.ui.define([
|
|
|
35
35
|
* @extends sap.ui.integration.cards.BaseContent
|
|
36
36
|
*
|
|
37
37
|
* @author SAP SE
|
|
38
|
-
* @version 1.
|
|
38
|
+
* @version 1.115.0
|
|
39
39
|
*
|
|
40
40
|
* @experimental
|
|
41
41
|
* @constructor
|
|
@@ -87,11 +87,11 @@ sap.ui.define([
|
|
|
87
87
|
this.fireEvent("_updated");
|
|
88
88
|
}.bind(this),
|
|
89
89
|
componentFailed: function () {
|
|
90
|
-
var oCard =
|
|
90
|
+
var oCard = this.getCardInstance();
|
|
91
91
|
|
|
92
92
|
this.fireEvent("_actionContentReady");
|
|
93
93
|
this.handleError({
|
|
94
|
-
|
|
94
|
+
illustrationType: IllustratedMessageType.ErrorScreen,
|
|
95
95
|
title: oCard.getTranslatedText("CARD_DATA_LOAD_ERROR"),
|
|
96
96
|
description: "Card content failed to create component"
|
|
97
97
|
});
|
|
@@ -9,16 +9,14 @@ sap.ui.define([
|
|
|
9
9
|
"sap/base/util/merge",
|
|
10
10
|
"sap/ui/integration/controls/ActionsStrip",
|
|
11
11
|
"sap/ui/integration/controls/Paginator",
|
|
12
|
-
"sap/ui/integration/util/BindingHelper"
|
|
13
|
-
"sap/ui/integration/util/BindingResolver"
|
|
12
|
+
"sap/ui/integration/util/BindingHelper"
|
|
14
13
|
], function (
|
|
15
14
|
Control,
|
|
16
15
|
Core,
|
|
17
16
|
merge,
|
|
18
17
|
ActionsStrip,
|
|
19
18
|
Paginator,
|
|
20
|
-
BindingHelper
|
|
21
|
-
BindingResolver
|
|
19
|
+
BindingHelper
|
|
22
20
|
) {
|
|
23
21
|
"use strict";
|
|
24
22
|
|
|
@@ -33,7 +31,7 @@ sap.ui.define([
|
|
|
33
31
|
* @extends sap.ui.core.Control
|
|
34
32
|
*
|
|
35
33
|
* @author SAP SE
|
|
36
|
-
* @version 1.
|
|
34
|
+
* @version 1.115.0
|
|
37
35
|
*
|
|
38
36
|
* @constructor
|
|
39
37
|
* @ui5-restricted
|
|
@@ -114,7 +112,7 @@ sap.ui.define([
|
|
|
114
112
|
// to do: if more precise check is needed search recursively
|
|
115
113
|
return (oConfiguration.actionsStrip || []).some(function (oButtonConfig) {
|
|
116
114
|
for (var sKey in oButtonConfig) {
|
|
117
|
-
if (
|
|
115
|
+
if (BindingHelper.isBindingInfo(oButtonConfig[sKey])) {
|
|
118
116
|
return true;
|
|
119
117
|
}
|
|
120
118
|
}
|
|
@@ -42,7 +42,7 @@ sap.ui.define([
|
|
|
42
42
|
* @extends sap.f.cards.Header
|
|
43
43
|
*
|
|
44
44
|
* @author SAP SE
|
|
45
|
-
* @version 1.
|
|
45
|
+
* @version 1.115.0
|
|
46
46
|
*
|
|
47
47
|
* @constructor
|
|
48
48
|
* @private
|
|
@@ -153,7 +153,7 @@ sap.ui.define([
|
|
|
153
153
|
/**
|
|
154
154
|
* @override
|
|
155
155
|
*/
|
|
156
|
-
Header.prototype.
|
|
156
|
+
Header.prototype.isInteractive = function () {
|
|
157
157
|
return this.getInteractive();
|
|
158
158
|
};
|
|
159
159
|
|
|
@@ -9,6 +9,7 @@ sap.ui.define([
|
|
|
9
9
|
"sap/ui/util/openWindow",
|
|
10
10
|
"sap/m/library",
|
|
11
11
|
"sap/m/List",
|
|
12
|
+
"sap/f/cards/loading/ListPlaceholder",
|
|
12
13
|
"sap/ui/integration/controls/ObjectStatus",
|
|
13
14
|
"sap/ui/integration/library",
|
|
14
15
|
"sap/ui/integration/util/BindingHelper",
|
|
@@ -24,6 +25,7 @@ sap.ui.define([
|
|
|
24
25
|
openWindow,
|
|
25
26
|
mLibrary,
|
|
26
27
|
List,
|
|
28
|
+
ListPlaceholder,
|
|
27
29
|
ObjectStatus,
|
|
28
30
|
library,
|
|
29
31
|
BindingHelper,
|
|
@@ -68,7 +70,7 @@ sap.ui.define([
|
|
|
68
70
|
* @extends sap.ui.integration.cards.BaseListContent
|
|
69
71
|
*
|
|
70
72
|
* @author SAP SE
|
|
71
|
-
* @version 1.
|
|
73
|
+
* @version 1.115.0
|
|
72
74
|
*
|
|
73
75
|
* @constructor
|
|
74
76
|
* @private
|
|
@@ -119,6 +121,20 @@ sap.ui.define([
|
|
|
119
121
|
}
|
|
120
122
|
};
|
|
121
123
|
|
|
124
|
+
/**
|
|
125
|
+
* @override
|
|
126
|
+
*/
|
|
127
|
+
ListContent.prototype.createLoadingPlaceholder = function (oConfiguration) {
|
|
128
|
+
var oCard = this.getCardInstance(),
|
|
129
|
+
iContentMinItems = oCard.getContentMinItems(oConfiguration);
|
|
130
|
+
|
|
131
|
+
return new ListPlaceholder({
|
|
132
|
+
minItems: iContentMinItems !== null ? iContentMinItems : 2,
|
|
133
|
+
item: oConfiguration.item,
|
|
134
|
+
itemHeight: ListContentRenderer.getItemMinHeight(oConfiguration, this) + "rem"
|
|
135
|
+
});
|
|
136
|
+
};
|
|
137
|
+
|
|
122
138
|
/**
|
|
123
139
|
* @override
|
|
124
140
|
*/
|
|
@@ -234,6 +250,12 @@ sap.ui.define([
|
|
|
234
250
|
}.bind(this)
|
|
235
251
|
});
|
|
236
252
|
|
|
253
|
+
// remove the custom accessibility announcement from the sap.m.ListBase
|
|
254
|
+
// so the additional elements (like attributes) are also read
|
|
255
|
+
this._oList.onItemFocusIn = function (oItem, oFocusedControl) {
|
|
256
|
+
this._oList._handleStickyItemFocus(oItem.getDomRef());
|
|
257
|
+
}.bind(this);
|
|
258
|
+
|
|
237
259
|
this._oList.addEventDelegate({
|
|
238
260
|
onfocusin: function (oEvent) {
|
|
239
261
|
if (!(oEvent.srcControl instanceof ListContentItem)) {
|
|
@@ -276,6 +298,7 @@ sap.ui.define([
|
|
|
276
298
|
highlightText: mItem.highlightText,
|
|
277
299
|
info: mItem.info && mItem.info.value,
|
|
278
300
|
infoState: mItem.info && mItem.info.state,
|
|
301
|
+
infoVisible: mItem.info && mItem.info.visible,
|
|
279
302
|
showInfoStateIcon: mItem.info && mItem.info.showStateIcon,
|
|
280
303
|
customInfoStatusIcon: mItem.info && mItem.info.customStateIcon,
|
|
281
304
|
attributes: []
|
|
@@ -35,7 +35,7 @@ sap.ui.define([
|
|
|
35
35
|
* @extends sap.f.cards.NumericHeader
|
|
36
36
|
*
|
|
37
37
|
* @author SAP SE
|
|
38
|
-
* @version 1.
|
|
38
|
+
* @version 1.115.0
|
|
39
39
|
*
|
|
40
40
|
* @constructor
|
|
41
41
|
* @private
|
|
@@ -150,7 +150,7 @@ sap.ui.define([
|
|
|
150
150
|
/**
|
|
151
151
|
* @override
|
|
152
152
|
*/
|
|
153
|
-
NumericHeader.prototype.
|
|
153
|
+
NumericHeader.prototype.isInteractive = function () {
|
|
154
154
|
return this.getInteractive();
|
|
155
155
|
};
|
|
156
156
|
|
|
@@ -22,6 +22,7 @@ sap.ui.define([
|
|
|
22
22
|
"sap/m/ComboBox",
|
|
23
23
|
"sap/m/TextArea",
|
|
24
24
|
"sap/m/Input",
|
|
25
|
+
"sap/m/TimePicker",
|
|
25
26
|
"sap/base/Log",
|
|
26
27
|
"sap/base/util/isEmptyObject",
|
|
27
28
|
"sap/base/util/isPlainObject",
|
|
@@ -33,10 +34,12 @@ sap.ui.define([
|
|
|
33
34
|
"sap/ui/integration/util/BindingResolver",
|
|
34
35
|
"sap/ui/integration/util/Utils",
|
|
35
36
|
"sap/ui/integration/util/Form",
|
|
37
|
+
"sap/ui/integration/util/DateRangeHelper",
|
|
36
38
|
"sap/f/AvatarGroup",
|
|
37
39
|
"sap/f/AvatarGroupItem",
|
|
38
40
|
"sap/f/cards/NumericIndicators",
|
|
39
41
|
"sap/f/cards/NumericSideIndicator",
|
|
42
|
+
"sap/f/cards/loading/ObjectPlaceholder",
|
|
40
43
|
"sap/f/library",
|
|
41
44
|
"sap/m/OverflowToolbar",
|
|
42
45
|
"sap/m/OverflowToolbarButton",
|
|
@@ -60,6 +63,7 @@ sap.ui.define([
|
|
|
60
63
|
ComboBox,
|
|
61
64
|
TextArea,
|
|
62
65
|
Input,
|
|
66
|
+
TimePicker,
|
|
63
67
|
Log,
|
|
64
68
|
isEmptyObject,
|
|
65
69
|
isPlainObject,
|
|
@@ -71,10 +75,12 @@ sap.ui.define([
|
|
|
71
75
|
BindingResolver,
|
|
72
76
|
Utils,
|
|
73
77
|
Form,
|
|
78
|
+
DateRangeHelper,
|
|
74
79
|
AvatarGroup,
|
|
75
80
|
AvatarGroupItem,
|
|
76
81
|
NumericIndicators,
|
|
77
82
|
NumericSideIndicator,
|
|
83
|
+
ObjectPlaceholder,
|
|
78
84
|
fLibrary,
|
|
79
85
|
OverflowToolbar,
|
|
80
86
|
OverflowToolbarButton,
|
|
@@ -112,7 +118,7 @@ sap.ui.define([
|
|
|
112
118
|
*
|
|
113
119
|
* @extends sap.ui.integration.cards.BaseContent
|
|
114
120
|
* @author SAP SE
|
|
115
|
-
* @version 1.
|
|
121
|
+
* @version 1.115.0
|
|
116
122
|
*
|
|
117
123
|
* @constructor
|
|
118
124
|
* @since 1.64
|
|
@@ -137,6 +143,13 @@ sap.ui.define([
|
|
|
137
143
|
}
|
|
138
144
|
};
|
|
139
145
|
|
|
146
|
+
/**
|
|
147
|
+
* @override
|
|
148
|
+
*/
|
|
149
|
+
ObjectContent.prototype.createLoadingPlaceholder = function (oConfiguration) {
|
|
150
|
+
return new ObjectPlaceholder();
|
|
151
|
+
};
|
|
152
|
+
|
|
140
153
|
/**
|
|
141
154
|
* Handler for when data is changed.
|
|
142
155
|
*/
|
|
@@ -144,10 +157,10 @@ sap.ui.define([
|
|
|
144
157
|
var oCard = this.getCardInstance();
|
|
145
158
|
|
|
146
159
|
if (this._hasData()) {
|
|
147
|
-
this.
|
|
160
|
+
this.hideNoDataMessage();
|
|
148
161
|
} else {
|
|
149
162
|
this.showNoDataMessage({
|
|
150
|
-
|
|
163
|
+
illustrationType: IllustratedMessageType.NoData,
|
|
151
164
|
title: this.getCardInstance().getTranslatedText("CARD_NO_ITEMS_ERROR_CHART")
|
|
152
165
|
});
|
|
153
166
|
}
|
|
@@ -243,10 +256,10 @@ sap.ui.define([
|
|
|
243
256
|
var oResolvedGroupItem = merge({}, oItem),
|
|
244
257
|
aResolvedItems = [],
|
|
245
258
|
sFullPath = sObjectContentPath + sItemPath,
|
|
246
|
-
|
|
259
|
+
bIsFormInput = ["TextArea", "Input", "ComboBox", "Duration", "DateRange"].includes(oItem.type),
|
|
247
260
|
bHasItemsToResolve = ["ButtonGroup", "IconGroup"].includes(oItem.type);
|
|
248
261
|
|
|
249
|
-
if (
|
|
262
|
+
if (bIsFormInput) {
|
|
250
263
|
oResolvedGroupItem = merge(oResolvedGroupItem, this._getForm().resolveControl(oItem));
|
|
251
264
|
}
|
|
252
265
|
|
|
@@ -365,10 +378,13 @@ sap.ui.define([
|
|
|
365
378
|
|
|
366
379
|
ObjectContent.prototype._createGroupItems = function (oItem, sPath) {
|
|
367
380
|
var vLabel = oItem.label,
|
|
381
|
+
bShowColon = oItem.showColon,
|
|
368
382
|
oLabel,
|
|
369
383
|
vVisible,
|
|
370
384
|
oControl;
|
|
371
385
|
|
|
386
|
+
oItem.showColon = (bShowColon === undefined) ? true : bShowColon;
|
|
387
|
+
|
|
372
388
|
if (typeof oItem.visible == "string") {
|
|
373
389
|
vVisible = !Utils.hasFalsyValueAsString(oItem.visible);
|
|
374
390
|
} else {
|
|
@@ -376,15 +392,12 @@ sap.ui.define([
|
|
|
376
392
|
}
|
|
377
393
|
|
|
378
394
|
if (vLabel) {
|
|
379
|
-
// Checks if the label ends with ":" and if not we just add the ":"
|
|
380
|
-
vLabel = BindingHelper.formattedProperty(vLabel, function (sValue) {
|
|
381
|
-
return sValue && (sValue[sValue.length - 1] === ":" ? sValue : sValue + ":");
|
|
382
|
-
});
|
|
383
395
|
|
|
384
396
|
oLabel = new Label({
|
|
385
397
|
text: vLabel,
|
|
386
398
|
visible: vVisible,
|
|
387
|
-
wrapping: oItem.labelWrapping
|
|
399
|
+
wrapping: oItem.labelWrapping,
|
|
400
|
+
showColon: oItem.showColon
|
|
388
401
|
}).addStyleClass("sapFCardObjectItemLabel");
|
|
389
402
|
|
|
390
403
|
oLabel.addEventDelegate({
|
|
@@ -471,11 +484,17 @@ sap.ui.define([
|
|
|
471
484
|
oControl = this._createRatingIndicatorItem(oItem, vVisible);
|
|
472
485
|
break;
|
|
473
486
|
case "Image":
|
|
474
|
-
oControl = this.
|
|
487
|
+
oControl = this._createImageItem(oItem, vVisible);
|
|
475
488
|
break;
|
|
476
489
|
case "Input":
|
|
477
490
|
oControl = this._createInputItem(oItem, vVisible, oLabel, sPath);
|
|
478
491
|
break;
|
|
492
|
+
case "Duration":
|
|
493
|
+
oControl = this._createDurationItem(oItem, vVisible, oLabel, sPath);
|
|
494
|
+
break;
|
|
495
|
+
case "DateRange":
|
|
496
|
+
oControl = this._createDateRangeItem(oItem, vVisible, oLabel, sPath);
|
|
497
|
+
break;
|
|
479
498
|
|
|
480
499
|
// deprecated types
|
|
481
500
|
case "link":
|
|
@@ -812,6 +831,27 @@ sap.ui.define([
|
|
|
812
831
|
return oControl;
|
|
813
832
|
};
|
|
814
833
|
|
|
834
|
+
ObjectContent.prototype._createDurationItem = function (oItem, vVisible, oLabel, sPath) {
|
|
835
|
+
var oForm = this._getForm(),
|
|
836
|
+
oControl = new TimePicker({
|
|
837
|
+
valueFormat: "HH:mm",
|
|
838
|
+
displayFormat: "HH:mm",
|
|
839
|
+
support2400: true,
|
|
840
|
+
required: oForm.getRequiredValidationValue(oItem),
|
|
841
|
+
value: oItem.value,
|
|
842
|
+
visible: BindingHelper.reuse(vVisible),
|
|
843
|
+
placeholder: oItem.placeholder
|
|
844
|
+
});
|
|
845
|
+
|
|
846
|
+
if (oLabel) {
|
|
847
|
+
oLabel.setLabelFor(oControl);
|
|
848
|
+
}
|
|
849
|
+
|
|
850
|
+
oForm.addControl("change", oControl, oItem, sPath);
|
|
851
|
+
|
|
852
|
+
return oControl;
|
|
853
|
+
};
|
|
854
|
+
|
|
815
855
|
ObjectContent.prototype._createRatingIndicatorItem = function (oItem, vVisible) {
|
|
816
856
|
var oControl = new RatingIndicator({
|
|
817
857
|
editable: false,
|
|
@@ -819,13 +859,14 @@ sap.ui.define([
|
|
|
819
859
|
maxValue: oItem.maxValue,
|
|
820
860
|
value: oItem.value,
|
|
821
861
|
visualMode: oItem.visualMode,
|
|
822
|
-
visible: BindingHelper.reuse(vVisible)
|
|
862
|
+
visible: BindingHelper.reuse(vVisible),
|
|
863
|
+
iconSize: "1rem"
|
|
823
864
|
});
|
|
824
865
|
|
|
825
866
|
return oControl;
|
|
826
867
|
};
|
|
827
868
|
|
|
828
|
-
ObjectContent.prototype.
|
|
869
|
+
ObjectContent.prototype._createImageItem = function (oItem, vVisible) {
|
|
829
870
|
var vSrc = BindingHelper.formattedProperty(oItem.src, function (sValue) {
|
|
830
871
|
return this._oIconFormatter.formatSrc(sValue);
|
|
831
872
|
}.bind(this));
|
|
@@ -844,6 +885,31 @@ sap.ui.define([
|
|
|
844
885
|
return oControl;
|
|
845
886
|
};
|
|
846
887
|
|
|
888
|
+
ObjectContent.prototype._createDateRangeItem = function (oItem, vVisible, oLabel, sPath) {
|
|
889
|
+
var oSettings = {
|
|
890
|
+
options: ["date"],
|
|
891
|
+
value: oItem.value
|
|
892
|
+
};
|
|
893
|
+
var oForm = this._getForm();
|
|
894
|
+
var oControl = DateRangeHelper.createInput(oSettings, this.getCardInstance(), true);
|
|
895
|
+
|
|
896
|
+
if (BindingHelper.isBindingInfo(vVisible)) {
|
|
897
|
+
oControl.bindProperty("visible", BindingHelper.reuse(vVisible));
|
|
898
|
+
} else {
|
|
899
|
+
oControl.setVisible(vVisible);
|
|
900
|
+
}
|
|
901
|
+
|
|
902
|
+
oControl.setRequired(oForm.getRequiredValidationValue(oItem));
|
|
903
|
+
|
|
904
|
+
if (oLabel) {
|
|
905
|
+
oLabel.setLabelFor(oControl);
|
|
906
|
+
}
|
|
907
|
+
|
|
908
|
+
oForm.addControl("change", oControl, oItem, sPath);
|
|
909
|
+
|
|
910
|
+
return oControl;
|
|
911
|
+
};
|
|
912
|
+
|
|
847
913
|
ObjectContent.prototype._createAFLayout = function () {
|
|
848
914
|
var oAlignedFlowLayout = new AlignedFlowLayout();
|
|
849
915
|
|