mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-08-19 12:55:08 +02:00
Home WIP: Get calendar working
This commit is contained in:
@@ -21,6 +21,7 @@ import shoelace from "../Styles/shoelace";
|
||||
import {Et2Dialog} from "../Et2Dialog/Et2Dialog";
|
||||
import {et2_IResizeable} from "../et2_core_interfaces";
|
||||
import {HomeApp} from "../../../../home/js/app";
|
||||
import {etemplate2} from "../etemplate2";
|
||||
|
||||
/**
|
||||
* Participate in Home
|
||||
@@ -181,13 +182,14 @@ export class Et2Portlet extends Et2Widget(SlCard)
|
||||
this.settings = typeof attrs.settings == "string" ? data.value || data.settings || {} : attrs.settings;
|
||||
|
||||
// Set size & position, if available
|
||||
if(data && (data.row || data.height))
|
||||
// NB: initial load can't find them by entry in array mgr, we check the data directly
|
||||
if(attrs.row || attrs.height || data.row || data.height)
|
||||
{
|
||||
this.style.gridRow = (data.row || "auto") + " / span " + (data.height || 1);
|
||||
this.style.gridRow = (attrs.row || data.row || "auto") + " / span " + (attrs.height || data.height || 1);
|
||||
}
|
||||
if(data && (data.col || data.width))
|
||||
if(attrs.col || attrs.width || data.col || data.width)
|
||||
{
|
||||
this.style.gridColumn = (data.col || "auto") + " / span " + (data.width || 1);
|
||||
this.style.gridColumn = (attrs.col || data.col || "auto") + " / span " + (attrs.width || data.width || 1);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -345,6 +347,9 @@ export class Et2Portlet extends Et2Widget(SlCard)
|
||||
|
||||
// Update position settings
|
||||
this.update_settings({row: row, col: col, width: width, height: height});
|
||||
|
||||
// If there's a full etemplate living inside, make it resize
|
||||
etemplate2.getById(this.id).resize();
|
||||
}
|
||||
|
||||
|
||||
@@ -469,9 +474,6 @@ export class Et2Portlet extends Et2Widget(SlCard)
|
||||
// Only resize once, and only if needed
|
||||
if(data.attributes.width || data.attributes.height)
|
||||
{
|
||||
this.style.columnSpan = data.attributes.width;
|
||||
this.style.rowSpan = data.attributes.height;
|
||||
|
||||
// Tell children
|
||||
try
|
||||
{
|
||||
|
Reference in New Issue
Block a user