mirror of
https://github.com/mayswind/ezbookkeeping.git
synced 2026-05-15 15:37:33 +08:00
modify date/time format
This commit is contained in:
+16
-10
@@ -9,19 +9,25 @@ export default {
|
||||
},
|
||||
'format': {
|
||||
'date': {
|
||||
'long': 'MM/DD/YYYY',
|
||||
'short': 'M/D/YYYY',
|
||||
'year': 'YYYY',
|
||||
'yearMonth': 'YYYY-M',
|
||||
'monthDay': 'M/D',
|
||||
'shortMonthDay': 'M/D'
|
||||
'long': 'M/D/YYYY',
|
||||
'short': 'M/D/YYYY'
|
||||
},
|
||||
'datetime': {
|
||||
'long': 'MM/DD/YYYY HH:mm:ss',
|
||||
'long-without-second': 'MM/DD/YYYY HH:mm',
|
||||
'long': 'M/D/YYYY HH:mm:ss',
|
||||
'long-without-second': 'M/D/YYYY HH:mm',
|
||||
},
|
||||
'time': {
|
||||
'hourMinute': 'HH:mm'
|
||||
'year': {
|
||||
'long': 'YYYY'
|
||||
},
|
||||
'yearMonth': {
|
||||
'long': 'YYYY-M'
|
||||
},
|
||||
'monthDay': {
|
||||
'long': 'M/D',
|
||||
'short': 'M/D'
|
||||
},
|
||||
'hourMinute': {
|
||||
'long': 'HH:mm'
|
||||
},
|
||||
'currency': {
|
||||
'symbol': '{symbol} {amount}'
|
||||
|
||||
+16
-10
@@ -9,19 +9,25 @@ export default {
|
||||
},
|
||||
'format': {
|
||||
'date': {
|
||||
'long': 'YYYY年MM月DD日',
|
||||
'short': 'YYYY-M-D',
|
||||
'year': 'YYYY年',
|
||||
'yearMonth': 'YYYY年M月',
|
||||
'monthDay': 'M月D日',
|
||||
'shortMonthDay': 'M-D'
|
||||
'long': 'YYYY年M月D日',
|
||||
'short': 'YYYY-M-D'
|
||||
},
|
||||
'datetime': {
|
||||
'long': 'YYYY年MM月DD日 HH:mm:ss',
|
||||
'long-without-second': 'YYYY年MM月DD日 HH:mm',
|
||||
'long': 'YYYY年M月D日 HH:mm:ss',
|
||||
'long-without-second': 'YYYY年M月D日 HH:mm',
|
||||
},
|
||||
'time': {
|
||||
'hourMinute': 'HH:mm'
|
||||
'year': {
|
||||
'long': 'YYYY年'
|
||||
},
|
||||
'yearMonth': {
|
||||
'long': 'YYYY年M月'
|
||||
},
|
||||
'monthDay': {
|
||||
'long': 'M月D日',
|
||||
'short': 'M-D'
|
||||
},
|
||||
'hourMinute': {
|
||||
'long': 'HH:mm'
|
||||
},
|
||||
'currency': {
|
||||
'symbol': '{symbol} {amount}'
|
||||
|
||||
@@ -72,10 +72,10 @@
|
||||
</div>
|
||||
<div slot="footer" class="overview-transaction-footer padding-bottom-half">
|
||||
<span v-if="loading">MM/DD</span>
|
||||
<span v-else-if="!loading">{{ dateRange.thisWeek.startTime | moment($t('format.date.monthDay')) }}</span>
|
||||
<span v-else-if="!loading">{{ dateRange.thisWeek.startTime | moment($t('format.monthDay.long')) }}</span>
|
||||
<span>-</span>
|
||||
<span v-if="loading">MM/DD</span>
|
||||
<span v-else-if="!loading">{{ dateRange.thisWeek.endTime | moment($t('format.date.monthDay')) }}</span>
|
||||
<span v-else-if="!loading">{{ dateRange.thisWeek.endTime | moment($t('format.monthDay.long')) }}</span>
|
||||
</div>
|
||||
<div slot="after">
|
||||
<div class="text-color-red">
|
||||
@@ -99,10 +99,10 @@
|
||||
</div>
|
||||
<div slot="footer" class="overview-transaction-footer padding-bottom-half">
|
||||
<span v-if="loading">MM/DD</span>
|
||||
<span v-else-if="!loading">{{ dateRange.thisMonth.startTime | moment($t('format.date.monthDay')) }}</span>
|
||||
<span v-else-if="!loading">{{ dateRange.thisMonth.startTime | moment($t('format.monthDay.long')) }}</span>
|
||||
<span>-</span>
|
||||
<span v-if="loading">MM/DD</span>
|
||||
<span v-else-if="!loading">{{ dateRange.thisMonth.endTime | moment($t('format.date.monthDay')) }}</span>
|
||||
<span v-else-if="!loading">{{ dateRange.thisMonth.endTime | moment($t('format.monthDay.long')) }}</span>
|
||||
</div>
|
||||
<div slot="after">
|
||||
<div class="text-color-red">
|
||||
@@ -126,7 +126,7 @@
|
||||
</div>
|
||||
<div slot="footer" class="overview-transaction-footer padding-bottom-half">
|
||||
<span v-if="loading">YYYY</span>
|
||||
<span v-else-if="!loading">{{ dateRange.thisYear.startTime | moment($t('format.date.year')) }}</span>
|
||||
<span v-else-if="!loading">{{ dateRange.thisYear.startTime | moment($t('format.year.long')) }}</span>
|
||||
</div>
|
||||
<div slot="after">
|
||||
<div class="text-color-red">
|
||||
|
||||
@@ -536,7 +536,7 @@ export default {
|
||||
const endTimeYear = this.$utilities.getYear(this.$utilities.parseDateFromUnixTime(query.endTime));
|
||||
|
||||
const displayStartTime = this.$utilities.formatUnixTime(query.startTime, this.$t('format.date.short'));
|
||||
const displayEndTime = this.$utilities.formatUnixTime(query.endTime, this.$t(startTimeYear !== endTimeYear ? 'format.date.short' : 'format.date.shortMonthDay'));
|
||||
const displayEndTime = this.$utilities.formatUnixTime(query.endTime, this.$t(startTimeYear !== endTimeYear ? 'format.date.short' : 'format.monthDay.short'));
|
||||
|
||||
return `${displayStartTime} ~ ${displayEndTime}`;
|
||||
}
|
||||
|
||||
@@ -137,7 +137,7 @@
|
||||
<f7-card-header>
|
||||
<f7-accordion-toggle class="full-line">
|
||||
<small :style="{ opacity: 0.6 }">
|
||||
<span>{{ transactionMonthList.yearMonth | moment($t('format.date.yearMonth')) }}</span>
|
||||
<span>{{ transactionMonthList.yearMonth | moment($t('format.yearMonth.long')) }}</span>
|
||||
</small>
|
||||
<small class="transaction-amount-statistics" v-if="transactionMonthList.totalAmount">
|
||||
<span class="text-color-red">
|
||||
@@ -193,7 +193,7 @@
|
||||
<span>{{ transaction.comment }}</span>
|
||||
</div>
|
||||
<div slot="footer" class="transaction-footer">
|
||||
<span>{{ transaction.time | moment($t('format.time.hourMinute')) }}</span>
|
||||
<span>{{ transaction.time | moment($t('format.hourMinute.long')) }}</span>
|
||||
<span v-if="transaction.sourceAccount">·</span>
|
||||
<span v-if="transaction.sourceAccount">{{ transaction.sourceAccount.name }}</span>
|
||||
<span v-if="transaction.sourceAccount && transaction.type === $constants.transaction.allTransactionTypes.Transfer && transaction.destinationAccount && transaction.sourceAccount.id !== transaction.destinationAccount.id">→</span>
|
||||
|
||||
Reference in New Issue
Block a user