forked from extern/egroupware
Etemplate: Fix updated entries were sometimes not flagged, clear color after 3 minutes
This commit is contained in:
parent
2491cf16c0
commit
1037acc98c
@ -628,11 +628,17 @@ var et2_nextmatch = /** @class */ (function (_super) {
|
|||||||
this.controller._insertDataRow(entry, true);
|
this.controller._insertDataRow(entry, true);
|
||||||
// Set "new entry" class - but it has to stay so register and re-add it after the data is there
|
// Set "new entry" class - but it has to stay so register and re-add it after the data is there
|
||||||
(_b = (_a = entry.row) === null || _a === void 0 ? void 0 : _a.tr) === null || _b === void 0 ? void 0 : _b.addClass("new_entry");
|
(_b = (_a = entry.row) === null || _a === void 0 ? void 0 : _a.tr) === null || _b === void 0 ? void 0 : _b.addClass("new_entry");
|
||||||
|
var time = new Date().valueOf();
|
||||||
var callback = function (data) {
|
var callback = function (data) {
|
||||||
|
var _a;
|
||||||
if (data) {
|
if (data) {
|
||||||
if (data.class) {
|
if (data.class) {
|
||||||
data.class += " new_entry";
|
data.class += " new_entry";
|
||||||
}
|
}
|
||||||
|
// Don't remove if new data has not arrived
|
||||||
|
var stored = egw.dataGetUIDdata(uid);
|
||||||
|
if (((_a = stored) === null || _a === void 0 ? void 0 : _a.timestamp) >= time)
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
// Server didn't give us our row data
|
// Server didn't give us our row data
|
||||||
|
@ -927,6 +927,7 @@ export class et2_nextmatch extends et2_DOMWidget implements et2_IResizeable, et2
|
|||||||
|
|
||||||
// Set "new entry" class - but it has to stay so register and re-add it after the data is there
|
// Set "new entry" class - but it has to stay so register and re-add it after the data is there
|
||||||
entry.row?.tr?.addClass("new_entry");
|
entry.row?.tr?.addClass("new_entry");
|
||||||
|
let time = new Date().valueOf();
|
||||||
|
|
||||||
let callback = function(data) {
|
let callback = function(data) {
|
||||||
if(data)
|
if(data)
|
||||||
@ -935,6 +936,9 @@ export class et2_nextmatch extends et2_DOMWidget implements et2_IResizeable, et2
|
|||||||
{
|
{
|
||||||
data.class += " new_entry";
|
data.class += " new_entry";
|
||||||
}
|
}
|
||||||
|
// Don't remove if new data has not arrived
|
||||||
|
let stored = egw.dataGetUIDdata(uid);
|
||||||
|
if(stored?.timestamp >= time) return;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -2100,7 +2100,9 @@ table.egwGridView_outer thead tr th.noResize:hover {
|
|||||||
* New entry (via push)
|
* New entry (via push)
|
||||||
*/
|
*/
|
||||||
.et2_nextmatch .new_entry {
|
.et2_nextmatch .new_entry {
|
||||||
animation: new_entry_pulse 5s;
|
animation-name: new_entry_pulse, new_entry_clear;
|
||||||
|
animation-duration: 5s;
|
||||||
|
animation-delay: 0s, 180s;
|
||||||
animation-fill-mode: forwards;
|
animation-fill-mode: forwards;
|
||||||
}
|
}
|
||||||
@keyframes new_entry_pulse {
|
@keyframes new_entry_pulse {
|
||||||
@ -2114,6 +2116,12 @@ table.egwGridView_outer thead tr th.noResize:hover {
|
|||||||
background-color: rgba(255,255,185,0.3);
|
background-color: rgba(255,255,185,0.3);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@keyframes new_entry_clear {
|
||||||
|
100% {
|
||||||
|
background-color: inherit;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* itempicker widget
|
* itempicker widget
|
||||||
*/
|
*/
|
||||||
|
Loading…
Reference in New Issue
Block a user