Switch from en-CA to sv-SE for date formatting; en-CA no longer produces yyyy-mm-dd date strings

This commit is contained in:
Jiang Yio 2023-03-08 21:54:20 -05:00
parent f8a50c31b6
commit 2b3f23740b
5 changed files with 8 additions and 8 deletions

View File

@ -111,7 +111,7 @@
computed: {
disp_date: {
get() {
return this.x_date.toLocaleDateString('en-CA');
return this.x_date.toLocaleDateString('sv-SE');
},
set(value) {
if(value.length > 0) {
@ -122,7 +122,7 @@
},
disp_date_end: {
get() {
return this.x_date_end.toLocaleDateString('en-CA');
return this.x_date_end.toLocaleDateString('sv-SE');
},
set(value) {
if(value.length > 0) {

View File

@ -8,7 +8,7 @@
<div class="card mb-3 shadow">
<div class="card-header">{{info.name}} <span :title="info.pid">{{info.pid.slice(-4)}}</span> #{{dfn}}</div>
<div class="card-body row" style="font-family: monospace;">
<div class="col" v-if="info.dob"><strong>DOB:</strong> {{strptime_vista(info.dob).toLocaleDateString('en-CA')}}</div>
<div class="col" v-if="info.dob"><strong>DOB:</strong> {{strptime_vista(info.dob).toLocaleDateString('sv-SE')}}</div>
<div class="col" v-if="info.age"><strong>Age:</strong> {{info.age}}</div>
<div class="col" v-if="info.sex"><strong>Sex:</strong> {{info.sex}}</div>
<div class="col" v-if="info.sc_percentage"><strong>SC%:</strong> {{info.sc_percentage}}</div>

View File

@ -92,7 +92,7 @@
strHashHSL,
strtr_unscramble,
datefmt(date) {
return date ? date.toLocaleDateString('en-CA') : '';
return date ? date.toLocaleDateString('sv-SE') : '';
}
},
created() {

View File

@ -117,7 +117,7 @@
}
function date_header(date) {
var datestr = date.toLocaleDateString('en-CA');
var datestr = date.toLocaleDateString('sv-SE');
var timestr = date.toLocaleTimeString('en-GB');
return {
datestr, timestr,

View File

@ -20,9 +20,9 @@
</td>
<td style="text-align: right;">
<div v-if="item.Sts">{{name_of_status[item.Sts]}}</div>
<div v-if="item.OrdTm">Ordered: {{strptime_vista(item.OrdTm).toLocaleDateString('en-CA')}}</div>
<div v-if="item.StrtTm">Start: {{strptime_vista(item.StrtTm).toLocaleDateString('en-CA')}}</div>
<div v-if="item.StopTm">Stop: {{strptime_vista(item.StopTm).toLocaleDateString('en-CA')}}</div>
<div v-if="item.OrdTm">Ordered: {{strptime_vista(item.OrdTm).toLocaleDateString('sv-SE')}}</div>
<div v-if="item.StrtTm">Start: {{strptime_vista(item.StrtTm).toLocaleDateString('sv-SE')}}</div>
<div v-if="item.StopTm">Stop: {{strptime_vista(item.StopTm).toLocaleDateString('sv-SE')}}</div>
</td>
</tr>
</tbody>