Merge branch 'master' of https://gitea.verdnatura.es/verdnatura/salix into test
gitea/salix/pipeline/pr-dev This commit looks good Details
gitea/salix/pipeline/head This commit looks good Details

This commit is contained in:
Alex Moreno 2024-05-20 11:31:03 +02:00
commit f361a07dd5
1 changed files with 2 additions and 2 deletions

View File

@ -47,9 +47,9 @@ class Controller extends Section {
};
this.$http.get(`TicketLogs`, {filter})
.then(res => {
if (res && res.data) {
if (res && res.data && res.data.length) {
const now = Date.vnNew();
const maxDate = new Date(res.data.creationDate);
const maxDate = new Date(res.data[0].creationDate);
maxDate.setHours(maxDate.getHours() + 1);
if (now <= maxDate)
return this.canRestoreTicket = true;