mirror of
https://github.com/InvoiceShelf/InvoiceShelf.git
synced 2026-04-07 13:41:23 +00:00
Invoice time support (#269)
* Changed invoice date to datetime * Fixed code style errors * Update TimeFormatsController.php * Update TimeFormatter.php * Update TimeFormatsController namespace * Fix missing comma in language file * Fix formatting --------- Co-authored-by: troky <troky2001@yahoo.com>
This commit is contained in:
committed by
GitHub
parent
32e03b98a3
commit
f52b73f517
@@ -254,6 +254,14 @@ const carbonFormat = computed(() => {
|
||||
return companyStore.selectedCompanySettings?.carbon_date_format
|
||||
})
|
||||
|
||||
const carbonFormatWithTime = computed(() => {
|
||||
let format = companyStore.selectedCompanySettings?.carbon_date_format
|
||||
if (companyStore.selectedCompanySettings?.invoice_use_time === 'YES') {
|
||||
format += ' ' + companyStore.selectedCompanySettings?.carbon_time_format
|
||||
}
|
||||
return format.replace("g", "h").replace("a", "K");
|
||||
})
|
||||
|
||||
const hasIconSlot = computed(() => {
|
||||
return !!slots.icon
|
||||
})
|
||||
@@ -301,7 +309,7 @@ watch(
|
||||
config.altFormat = carbonFormat.value ? carbonFormat.value : 'd M Y'
|
||||
} else {
|
||||
config.altFormat = carbonFormat.value
|
||||
? `${carbonFormat.value} H:i `
|
||||
? `${carbonFormatWithTime.value}`
|
||||
: 'd M Y H:i'
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user