mirror of
https://github.com/mayswind/ezbookkeeping.git
synced 2026-05-21 02:04:26 +08:00
modify date/time format
This commit is contained in:
+16
-10
@@ -9,19 +9,25 @@ export default {
|
|||||||
},
|
},
|
||||||
'format': {
|
'format': {
|
||||||
'date': {
|
'date': {
|
||||||
'long': 'MM/DD/YYYY',
|
'long': 'M/D/YYYY',
|
||||||
'short': 'M/D/YYYY',
|
'short': 'M/D/YYYY'
|
||||||
'year': 'YYYY',
|
|
||||||
'yearMonth': 'YYYY-M',
|
|
||||||
'monthDay': 'M/D',
|
|
||||||
'shortMonthDay': 'M/D'
|
|
||||||
},
|
},
|
||||||
'datetime': {
|
'datetime': {
|
||||||
'long': 'MM/DD/YYYY HH:mm:ss',
|
'long': 'M/D/YYYY HH:mm:ss',
|
||||||
'long-without-second': 'MM/DD/YYYY HH:mm',
|
'long-without-second': 'M/D/YYYY HH:mm',
|
||||||
},
|
},
|
||||||
'time': {
|
'year': {
|
||||||
'hourMinute': 'HH:mm'
|
'long': 'YYYY'
|
||||||
|
},
|
||||||
|
'yearMonth': {
|
||||||
|
'long': 'YYYY-M'
|
||||||
|
},
|
||||||
|
'monthDay': {
|
||||||
|
'long': 'M/D',
|
||||||
|
'short': 'M/D'
|
||||||
|
},
|
||||||
|
'hourMinute': {
|
||||||
|
'long': 'HH:mm'
|
||||||
},
|
},
|
||||||
'currency': {
|
'currency': {
|
||||||
'symbol': '{symbol} {amount}'
|
'symbol': '{symbol} {amount}'
|
||||||
|
|||||||
+16
-10
@@ -9,19 +9,25 @@ export default {
|
|||||||
},
|
},
|
||||||
'format': {
|
'format': {
|
||||||
'date': {
|
'date': {
|
||||||
'long': 'YYYY年MM月DD日',
|
'long': 'YYYY年M月D日',
|
||||||
'short': 'YYYY-M-D',
|
'short': 'YYYY-M-D'
|
||||||
'year': 'YYYY年',
|
|
||||||
'yearMonth': 'YYYY年M月',
|
|
||||||
'monthDay': 'M月D日',
|
|
||||||
'shortMonthDay': 'M-D'
|
|
||||||
},
|
},
|
||||||
'datetime': {
|
'datetime': {
|
||||||
'long': 'YYYY年MM月DD日 HH:mm:ss',
|
'long': 'YYYY年M月D日 HH:mm:ss',
|
||||||
'long-without-second': 'YYYY年MM月DD日 HH:mm',
|
'long-without-second': 'YYYY年M月D日 HH:mm',
|
||||||
},
|
},
|
||||||
'time': {
|
'year': {
|
||||||
'hourMinute': 'HH:mm'
|
'long': 'YYYY年'
|
||||||
|
},
|
||||||
|
'yearMonth': {
|
||||||
|
'long': 'YYYY年M月'
|
||||||
|
},
|
||||||
|
'monthDay': {
|
||||||
|
'long': 'M月D日',
|
||||||
|
'short': 'M-D'
|
||||||
|
},
|
||||||
|
'hourMinute': {
|
||||||
|
'long': 'HH:mm'
|
||||||
},
|
},
|
||||||
'currency': {
|
'currency': {
|
||||||
'symbol': '{symbol} {amount}'
|
'symbol': '{symbol} {amount}'
|
||||||
|
|||||||
@@ -72,10 +72,10 @@
|
|||||||
</div>
|
</div>
|
||||||
<div slot="footer" class="overview-transaction-footer padding-bottom-half">
|
<div slot="footer" class="overview-transaction-footer padding-bottom-half">
|
||||||
<span v-if="loading">MM/DD</span>
|
<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>-</span>
|
||||||
<span v-if="loading">MM/DD</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>
|
||||||
<div slot="after">
|
<div slot="after">
|
||||||
<div class="text-color-red">
|
<div class="text-color-red">
|
||||||
@@ -99,10 +99,10 @@
|
|||||||
</div>
|
</div>
|
||||||
<div slot="footer" class="overview-transaction-footer padding-bottom-half">
|
<div slot="footer" class="overview-transaction-footer padding-bottom-half">
|
||||||
<span v-if="loading">MM/DD</span>
|
<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>-</span>
|
||||||
<span v-if="loading">MM/DD</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>
|
||||||
<div slot="after">
|
<div slot="after">
|
||||||
<div class="text-color-red">
|
<div class="text-color-red">
|
||||||
@@ -126,7 +126,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div slot="footer" class="overview-transaction-footer padding-bottom-half">
|
<div slot="footer" class="overview-transaction-footer padding-bottom-half">
|
||||||
<span v-if="loading">YYYY</span>
|
<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>
|
||||||
<div slot="after">
|
<div slot="after">
|
||||||
<div class="text-color-red">
|
<div class="text-color-red">
|
||||||
|
|||||||
@@ -536,7 +536,7 @@ export default {
|
|||||||
const endTimeYear = this.$utilities.getYear(this.$utilities.parseDateFromUnixTime(query.endTime));
|
const endTimeYear = this.$utilities.getYear(this.$utilities.parseDateFromUnixTime(query.endTime));
|
||||||
|
|
||||||
const displayStartTime = this.$utilities.formatUnixTime(query.startTime, this.$t('format.date.short'));
|
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}`;
|
return `${displayStartTime} ~ ${displayEndTime}`;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -137,7 +137,7 @@
|
|||||||
<f7-card-header>
|
<f7-card-header>
|
||||||
<f7-accordion-toggle class="full-line">
|
<f7-accordion-toggle class="full-line">
|
||||||
<small :style="{ opacity: 0.6 }">
|
<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>
|
||||||
<small class="transaction-amount-statistics" v-if="transactionMonthList.totalAmount">
|
<small class="transaction-amount-statistics" v-if="transactionMonthList.totalAmount">
|
||||||
<span class="text-color-red">
|
<span class="text-color-red">
|
||||||
@@ -193,7 +193,7 @@
|
|||||||
<span>{{ transaction.comment }}</span>
|
<span>{{ transaction.comment }}</span>
|
||||||
</div>
|
</div>
|
||||||
<div slot="footer" class="transaction-footer">
|
<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">·</span>
|
||||||
<span v-if="transaction.sourceAccount">{{ transaction.sourceAccount.name }}</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>
|
<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