1
0
forked from test/crm

fix: added translation for timeAgo method

This commit is contained in:
Shariq Ansari 2024-04-15 20:40:13 +05:30
parent bb1b68c7d5
commit 7d5f51d3f3
10 changed files with 15 additions and 15 deletions

View File

@ -68,7 +68,7 @@
</span>
</div>
<div class="text-sm text-gray-600">
{{ timeAgo(n.creation) }}
{{ __(timeAgo(n.creation)) }}
</div>
</div>
</RouterLink>

View File

@ -131,7 +131,7 @@ const rows = computed(() => {
} else if (['modified', 'creation'].includes(row)) {
_rows[row] = {
label: dateFormat(callLog[row], dateTooltipFormat),
timeAgo: timeAgo(callLog[row]),
timeAgo: __(timeAgo(callLog[row])),
}
}
})

View File

@ -363,7 +363,7 @@ function getDealRowObject(deal) {
},
modified: {
label: dateFormat(deal.modified, dateTooltipFormat),
timeAgo: timeAgo(deal.modified),
timeAgo: __(timeAgo(deal.modified)),
},
}
}

View File

@ -127,7 +127,7 @@ const rows = computed(() => {
} else if (['modified', 'creation'].includes(row)) {
_rows[row] = {
label: dateFormat(contact[row], dateTooltipFormat),
timeAgo: timeAgo(contact[row]),
timeAgo: __(timeAgo(contact[row])),
}
}
})

View File

@ -147,7 +147,7 @@ const rows = computed(() => {
? 'green'
: 'orange'
if (value == 'First Response Due') {
value = timeAgo(deal.response_by)
value = __(timeAgo(deal.response_by))
tooltipText = dateFormat(deal.response_by, dateTooltipFormat)
if (new Date(deal.response_by) < new Date()) {
color = 'red'
@ -176,7 +176,7 @@ const rows = computed(() => {
} else if (['modified', 'creation'].includes(row)) {
_rows[row] = {
label: dateFormat(deal[row], dateTooltipFormat),
timeAgo: timeAgo(deal[row]),
timeAgo: __(timeAgo(deal[row])),
}
} else if (
['first_response_time', 'first_responded_on', 'response_by'].includes(
@ -189,7 +189,7 @@ const rows = computed(() => {
timeAgo: deal[row]
? row == 'first_response_time'
? formatTime(deal[row])
: timeAgo(deal[row])
: __(timeAgo(deal[row]))
: '',
}
}

View File

@ -149,7 +149,7 @@ const rows = computed(() => {
? 'green'
: 'orange'
if (value == 'First Response Due') {
value = timeAgo(lead.response_by)
value = __(timeAgo(lead.response_by))
tooltipText = dateFormat(lead.response_by, dateTooltipFormat)
if (new Date(lead.response_by) < new Date()) {
color = 'red'
@ -178,7 +178,7 @@ const rows = computed(() => {
} else if (['modified', 'creation'].includes(row)) {
_rows[row] = {
label: dateFormat(lead[row], dateTooltipFormat),
timeAgo: timeAgo(lead[row]),
timeAgo: __(timeAgo(lead[row])),
}
} else if (
['first_response_time', 'first_responded_on', 'response_by'].includes(
@ -191,7 +191,7 @@ const rows = computed(() => {
timeAgo: lead[row]
? row == 'first_response_time'
? formatTime(lead[row])
: timeAgo(lead[row])
: __(timeAgo(lead[row]))
: '',
}
}

View File

@ -66,7 +66,7 @@
</div>
<Tooltip :text="dateFormat(note.modified, dateTooltipFormat)">
<div class="text-sm text-gray-700">
{{ timeAgo(note.modified) }}
{{ __(timeAgo(note.modified)) }}
</div>
</Tooltip>
</div>

View File

@ -416,7 +416,7 @@ function getDealRowObject(deal) {
},
modified: {
label: dateFormat(deal.modified, dateTooltipFormat),
timeAgo: timeAgo(deal.modified),
timeAgo: __(timeAgo(deal.modified)),
},
}
}
@ -437,7 +437,7 @@ function getContactRowObject(contact) {
},
modified: {
label: dateFormat(contact.modified, dateTooltipFormat),
timeAgo: timeAgo(contact.modified),
timeAgo: __(timeAgo(contact.modified)),
},
}
}

View File

@ -126,7 +126,7 @@ const rows = computed(() => {
} else if (['modified', 'creation'].includes(row)) {
_rows[row] = {
label: dateFormat(organization[row], dateTooltipFormat),
timeAgo: timeAgo(organization[row]),
timeAgo: __(timeAgo(organization[row])),
}
}
})

View File

@ -89,7 +89,7 @@ const rows = computed(() => {
if (['modified', 'creation'].includes(row)) {
_rows[row] = {
label: dateFormat(task[row], dateTooltipFormat),
timeAgo: timeAgo(task[row]),
timeAgo: __(timeAgo(task[row])),
}
} else if (row == 'assigned_to') {
_rows[row] = {