mirror of
https://github.com/axllent/mailpit.git
synced 2025-07-13 01:20:22 +02:00
UI: Update pagination values when new mail arrives when not on first page
This commit is contained in:
@ -210,12 +210,14 @@ export default {
|
|||||||
}
|
}
|
||||||
// new messages
|
// new messages
|
||||||
if (response.Type == "new" && response.Data) {
|
if (response.Type == "new" && response.Data) {
|
||||||
if (self.start < 1) {
|
if (!self.searching) {
|
||||||
if (!self.searching) {
|
if (self.start < 1) {
|
||||||
self.items.unshift(response.Data);
|
self.items.unshift(response.Data);
|
||||||
if (self.items.length > self.limit) {
|
if (self.items.length > self.limit) {
|
||||||
self.items.pop();
|
self.items.pop();
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
self.start++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
self.total++;
|
self.total++;
|
||||||
|
Reference in New Issue
Block a user