@schneideress/dashboardframework 0.0.151 → 0.0.153
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/bundles/schneideress-dashboardframework.umd.js +21 -4
- package/bundles/schneideress-dashboardframework.umd.js.map +1 -1
- package/bundles/schneideress-dashboardframework.umd.min.js +1 -1
- package/bundles/schneideress-dashboardframework.umd.min.js.map +1 -1
- package/esm2015/lib/ra-dashboard-area/ra.dashboard.area.js +19 -6
- package/esm2015/lib/ra.dashboard.responsive.service.js +3 -1
- package/esm2015/lib/ra.event.enum.js +3 -1
- package/esm5/lib/ra-dashboard-area/ra.dashboard.area.js +18 -5
- package/esm5/lib/ra.dashboard.responsive.service.js +3 -1
- package/esm5/lib/ra.event.enum.js +3 -1
- package/fesm2015/schneideress-dashboardframework.js +22 -5
- package/fesm2015/schneideress-dashboardframework.js.map +1 -1
- package/fesm5/schneideress-dashboardframework.js +21 -4
- package/fesm5/schneideress-dashboardframework.js.map +1 -1
- package/lib/ra.event.enum.d.ts +3 -1
- package/package.json +1 -1
- package/schneideress-dashboardframework.metadata.json +1 -1
|
@@ -602,6 +602,8 @@
|
|
|
602
602
|
WidgetAdded: "WidgetAdded",
|
|
603
603
|
/**To update global filter site from map widget selected site */
|
|
604
604
|
UpdateGlobalFilterFromMapWidget: "UpdateGlobalFilterFromMapWidget",
|
|
605
|
+
/**To add widget on empty dashboard */
|
|
606
|
+
AddWidgetEmptyDashboard: "AddWidgetEmptyDashboard",
|
|
605
607
|
};
|
|
606
608
|
/** @enum {string} */
|
|
607
609
|
var RAEventKey = {
|
|
@@ -998,6 +1000,8 @@
|
|
|
998
1000
|
function (widget) {
|
|
999
1001
|
/** @type {?} */
|
|
1000
1002
|
var gridsterItem = (/** @type {?} */ ({
|
|
1003
|
+
actCols: widget.width,
|
|
1004
|
+
actRows: widget.height,
|
|
1001
1005
|
cols: this.getWidth(widget.width),
|
|
1002
1006
|
rows: this.getHeight(widget.height),
|
|
1003
1007
|
x: this.IsDesktopView ? widget.position_x : 0,
|
|
@@ -1509,18 +1513,29 @@
|
|
|
1509
1513
|
function (widgetInstanceId, isalertDisabled) {
|
|
1510
1514
|
if (isalertDisabled === void 0) { isalertDisabled = false; }
|
|
1511
1515
|
/** @type {?} */
|
|
1512
|
-
var
|
|
1516
|
+
var gridsterItem = this.widgetList.filter((/**
|
|
1513
1517
|
* @param {?} item
|
|
1514
1518
|
* @return {?}
|
|
1515
1519
|
*/
|
|
1516
1520
|
function (item) {
|
|
1517
1521
|
return item.widgetInfo.widgetInstanceId === widgetInstanceId;
|
|
1518
1522
|
}));
|
|
1519
|
-
if (
|
|
1520
|
-
|
|
1523
|
+
if (gridsterItem.length > 0) {
|
|
1524
|
+
/** @type {?} */
|
|
1525
|
+
var widget = this.userWidgets.filter((/**
|
|
1526
|
+
* @param {?} item
|
|
1527
|
+
* @return {?}
|
|
1528
|
+
*/
|
|
1529
|
+
function (item) {
|
|
1530
|
+
return item.widgetInstanceId === widgetInstanceId;
|
|
1531
|
+
}));
|
|
1532
|
+
if (widget.length > 0) {
|
|
1533
|
+
this.userWidgets.splice(this.userWidgets.indexOf(widget[0]), 1);
|
|
1534
|
+
}
|
|
1535
|
+
this.widgetList.splice(this.widgetList.indexOf(gridsterItem[0]), 1);
|
|
1521
1536
|
this.setAreaHeight();
|
|
1522
1537
|
if (!isalertDisabled) {
|
|
1523
|
-
this.notifier.notify('success', " " + this.translateService.translate('Common.Widgettext') + " " +
|
|
1538
|
+
this.notifier.notify('success', " " + this.translateService.translate('Common.Widgettext') + " " + gridsterItem[0].widgetInfo.widgetTitle + " " + this.translateService.translate('Common.deletedSuccesfully') + " ");
|
|
1524
1539
|
}
|
|
1525
1540
|
}
|
|
1526
1541
|
};
|
|
@@ -1568,6 +1583,7 @@
|
|
|
1568
1583
|
* @return {?}
|
|
1569
1584
|
*/
|
|
1570
1585
|
function (widget) {
|
|
1586
|
+
_this.userWidgets.push(widget);
|
|
1571
1587
|
/** @type {?} */
|
|
1572
1588
|
var gridsterItem = _this.responsiveService.getGridsterItem(widget);
|
|
1573
1589
|
_this.widgetList.push(gridsterItem);
|
|
@@ -1644,6 +1660,7 @@
|
|
|
1644
1660
|
function (widgets) {
|
|
1645
1661
|
}));
|
|
1646
1662
|
}
|
|
1663
|
+
this.userWidgets.push(data);
|
|
1647
1664
|
/** @type {?} */
|
|
1648
1665
|
var gridsterItem = this.responsiveService.getGridsterItem(data);
|
|
1649
1666
|
this.widgetList.push(gridsterItem);
|