add transaction hour of day to axis / category / series in insights explorer
This commit is contained in:
@@ -191,6 +191,7 @@ export enum TransactionExplorerDataDimensionType {
|
||||
DateTimeByDayOfMonth = 'dateTimeByDayOfMonth',
|
||||
DateTimeByMonthOfYear = 'dateTimeByMonthOfYear',
|
||||
DateTimeByQuarterOfYear = 'dateTimeByQuarterOfYear',
|
||||
DateTimeByHourOfDay = 'dateTimeByHourOfDay',
|
||||
TransactionType = 'transactionType',
|
||||
SourceAccount = 'sourceAccount',
|
||||
SourceAccountCategory = 'sourceAccountCategory',
|
||||
@@ -220,6 +221,7 @@ export class TransactionExplorerDataDimension implements NameValue {
|
||||
public static readonly DateTimeByDayOfMonth = new TransactionExplorerDataDimension('Transaction Day of Month', TransactionExplorerDataDimensionType.DateTimeByDayOfMonth);
|
||||
public static readonly DateTimeByMonthOfYear = new TransactionExplorerDataDimension('Transaction Month of Year', TransactionExplorerDataDimensionType.DateTimeByMonthOfYear);
|
||||
public static readonly DateTimeByQuarterOfYear = new TransactionExplorerDataDimension('Transaction Quarter of Year', TransactionExplorerDataDimensionType.DateTimeByQuarterOfYear);
|
||||
public static readonly DateTimeByHourOfDay = new TransactionExplorerDataDimension('Transaction Hour of Day', TransactionExplorerDataDimensionType.DateTimeByHourOfDay);
|
||||
public static readonly TransactionType = new TransactionExplorerDataDimension('Transaction Type', TransactionExplorerDataDimensionType.TransactionType);
|
||||
public static readonly SourceAccount = new TransactionExplorerDataDimension('Source Account', TransactionExplorerDataDimensionType.SourceAccount);
|
||||
public static readonly SourceAccountCategory = new TransactionExplorerDataDimension('Source Account Category', TransactionExplorerDataDimensionType.SourceAccountCategory);
|
||||
|
||||
@@ -1776,6 +1776,7 @@
|
||||
"Transaction Day of Month": "Transaction Day of Month",
|
||||
"Transaction Month of Year": "Transaction Month of Year",
|
||||
"Transaction Quarter of Year": "Transaction Quarter of Year",
|
||||
"Transaction Hour of Day": "Transaction Hour of Day",
|
||||
"Source Account Category": "Source Account Category",
|
||||
"Source Account Currency": "Source Account Currency",
|
||||
"Destination Account Category": "Destination Account Category",
|
||||
|
||||
@@ -1776,6 +1776,7 @@
|
||||
"Transaction Day of Month": "Transaction Day of Month",
|
||||
"Transaction Month of Year": "Transaction Month of Year",
|
||||
"Transaction Quarter of Year": "Transaction Quarter of Year",
|
||||
"Transaction Hour of Day": "Transaction Hour of Day",
|
||||
"Source Account Category": "Source Account Category",
|
||||
"Source Account Currency": "Source Account Currency",
|
||||
"Destination Account Category": "Destination Account Category",
|
||||
|
||||
@@ -1776,6 +1776,7 @@
|
||||
"Transaction Day of Month": "Día del mes de la transacción",
|
||||
"Transaction Month of Year": "Mes del año de la transacción",
|
||||
"Transaction Quarter of Year": "Trimestre de la transacción",
|
||||
"Transaction Hour of Day": "Transaction Hour of Day",
|
||||
"Source Account Category": "Categoría de la cuenta de origen",
|
||||
"Source Account Currency": "Moneda de la cuenta de origen",
|
||||
"Destination Account Category": "Categoría de la cuenta de destino",
|
||||
|
||||
@@ -1776,6 +1776,7 @@
|
||||
"Transaction Day of Month": "Transaction Day of Month",
|
||||
"Transaction Month of Year": "Transaction Month of Year",
|
||||
"Transaction Quarter of Year": "Transaction Quarter of Year",
|
||||
"Transaction Hour of Day": "Transaction Hour of Day",
|
||||
"Source Account Category": "Source Account Category",
|
||||
"Source Account Currency": "Source Account Currency",
|
||||
"Destination Account Category": "Destination Account Category",
|
||||
|
||||
@@ -1776,6 +1776,7 @@
|
||||
"Transaction Day of Month": "Transaction Day of Month",
|
||||
"Transaction Month of Year": "Transaction Month of Year",
|
||||
"Transaction Quarter of Year": "Transaction Quarter of Year",
|
||||
"Transaction Hour of Day": "Transaction Hour of Day",
|
||||
"Source Account Category": "Source Account Category",
|
||||
"Source Account Currency": "Source Account Currency",
|
||||
"Destination Account Category": "Destination Account Category",
|
||||
|
||||
@@ -1776,6 +1776,7 @@
|
||||
"Transaction Day of Month": "Transaction Day of Month",
|
||||
"Transaction Month of Year": "Transaction Month of Year",
|
||||
"Transaction Quarter of Year": "Transaction Quarter of Year",
|
||||
"Transaction Hour of Day": "Transaction Hour of Day",
|
||||
"Source Account Category": "Source Account Category",
|
||||
"Source Account Currency": "Source Account Currency",
|
||||
"Destination Account Category": "Destination Account Category",
|
||||
|
||||
@@ -1776,6 +1776,7 @@
|
||||
"Transaction Day of Month": "Transaction Day of Month",
|
||||
"Transaction Month of Year": "Transaction Month of Year",
|
||||
"Transaction Quarter of Year": "Transaction Quarter of Year",
|
||||
"Transaction Hour of Day": "Transaction Hour of Day",
|
||||
"Source Account Category": "Source Account Category",
|
||||
"Source Account Currency": "Source Account Currency",
|
||||
"Destination Account Category": "Destination Account Category",
|
||||
|
||||
@@ -1776,6 +1776,7 @@
|
||||
"Transaction Day of Month": "거래 일자",
|
||||
"Transaction Month of Year": "거래 월",
|
||||
"Transaction Quarter of Year": "거래 분기",
|
||||
"Transaction Hour of Day": "Transaction Hour of Day",
|
||||
"Source Account Category": "출처 계좌 분류",
|
||||
"Source Account Currency": "출처 계좌 통화",
|
||||
"Destination Account Category": "목적지 계좌 분류",
|
||||
|
||||
@@ -1776,6 +1776,7 @@
|
||||
"Transaction Day of Month": "Transaction Day of Month",
|
||||
"Transaction Month of Year": "Transaction Month of Year",
|
||||
"Transaction Quarter of Year": "Transaction Quarter of Year",
|
||||
"Transaction Hour of Day": "Transaction Hour of Day",
|
||||
"Source Account Category": "Source Account Category",
|
||||
"Source Account Currency": "Source Account Currency",
|
||||
"Destination Account Category": "Destination Account Category",
|
||||
|
||||
@@ -1776,6 +1776,7 @@
|
||||
"Transaction Day of Month": "Transaction Day of Month",
|
||||
"Transaction Month of Year": "Transaction Month of Year",
|
||||
"Transaction Quarter of Year": "Transaction Quarter of Year",
|
||||
"Transaction Hour of Day": "Transaction Hour of Day",
|
||||
"Source Account Category": "Source Account Category",
|
||||
"Source Account Currency": "Source Account Currency",
|
||||
"Destination Account Category": "Destination Account Category",
|
||||
|
||||
@@ -1776,6 +1776,7 @@
|
||||
"Transaction Day of Month": "День месяца транзакции",
|
||||
"Transaction Month of Year": "Месяц года транзакции",
|
||||
"Transaction Quarter of Year": "Квартал транзакции",
|
||||
"Transaction Hour of Day": "Transaction Hour of Day",
|
||||
"Source Account Category": "Категория исходного счёта",
|
||||
"Source Account Currency": "Валюта исходного счёта",
|
||||
"Destination Account Category": "Категория целевого счёта",
|
||||
|
||||
@@ -1776,6 +1776,7 @@
|
||||
"Transaction Day of Month": "Dan v mesecu transakcije",
|
||||
"Transaction Month of Year": "Mesec v letu transakcije",
|
||||
"Transaction Quarter of Year": "Četrtletje v letu transakcije",
|
||||
"Transaction Hour of Day": "Transaction Hour of Day",
|
||||
"Source Account Category": "Kategorija izvornega računa",
|
||||
"Source Account Currency": "Valuta izvornega računa",
|
||||
"Destination Account Category": "Kategorija ciljnega računa",
|
||||
|
||||
@@ -1776,6 +1776,7 @@
|
||||
"Transaction Day of Month": "பரிவர்த்தனை மாதத்தின் நாள்",
|
||||
"Transaction Month of Year": "பரிவர்த்தனை ஆண்டின் மாதம்",
|
||||
"Transaction Quarter of Year": "பரிவர்த்தனை ஆண்டின் காலாண்டு",
|
||||
"Transaction Hour of Day": "Transaction Hour of Day",
|
||||
"Source Account Category": "மூல கணக்கு வகை",
|
||||
"Source Account Currency": "மூல கணக்கு நாணயம்",
|
||||
"Destination Account Category": "இலக்கு கணக்கு வகை",
|
||||
|
||||
@@ -1776,6 +1776,7 @@
|
||||
"Transaction Day of Month": "Transaction Day of Month",
|
||||
"Transaction Month of Year": "Transaction Month of Year",
|
||||
"Transaction Quarter of Year": "Transaction Quarter of Year",
|
||||
"Transaction Hour of Day": "Transaction Hour of Day",
|
||||
"Source Account Category": "Source Account Category",
|
||||
"Source Account Currency": "Source Account Currency",
|
||||
"Destination Account Category": "Destination Account Category",
|
||||
|
||||
@@ -1776,6 +1776,7 @@
|
||||
"Transaction Day of Month": "Transaction Day of Month",
|
||||
"Transaction Month of Year": "Transaction Month of Year",
|
||||
"Transaction Quarter of Year": "Transaction Quarter of Year",
|
||||
"Transaction Hour of Day": "Transaction Hour of Day",
|
||||
"Source Account Category": "Source Account Category",
|
||||
"Source Account Currency": "Source Account Currency",
|
||||
"Destination Account Category": "Destination Account Category",
|
||||
|
||||
@@ -1776,6 +1776,7 @@
|
||||
"Transaction Day of Month": "Transaction Day of Month",
|
||||
"Transaction Month of Year": "Transaction Month of Year",
|
||||
"Transaction Quarter of Year": "Transaction Quarter of Year",
|
||||
"Transaction Hour of Day": "Transaction Hour of Day",
|
||||
"Source Account Category": "Source Account Category",
|
||||
"Source Account Currency": "Source Account Currency",
|
||||
"Destination Account Category": "Destination Account Category",
|
||||
|
||||
@@ -1776,6 +1776,7 @@
|
||||
"Transaction Day of Month": "Transaction Day of Month",
|
||||
"Transaction Month of Year": "Transaction Month of Year",
|
||||
"Transaction Quarter of Year": "Transaction Quarter of Year",
|
||||
"Transaction Hour of Day": "Transaction Hour of Day",
|
||||
"Source Account Category": "Source Account Category",
|
||||
"Source Account Currency": "Source Account Currency",
|
||||
"Destination Account Category": "Destination Account Category",
|
||||
|
||||
@@ -1776,6 +1776,7 @@
|
||||
"Transaction Day of Month": "交易月内日",
|
||||
"Transaction Month of Year": "交易月份",
|
||||
"Transaction Quarter of Year": "交易季度",
|
||||
"Transaction Hour of Day": "交易小时",
|
||||
"Source Account Category": "来源账户分类",
|
||||
"Source Account Currency": "来源账户货币",
|
||||
"Destination Account Category": "目标账户分类",
|
||||
|
||||
@@ -1776,6 +1776,7 @@
|
||||
"Transaction Day of Month": "交易月內日",
|
||||
"Transaction Month of Year": "交易月份",
|
||||
"Transaction Quarter of Year": "交易季度",
|
||||
"Transaction Hour of Day": "交易小時",
|
||||
"Source Account Category": "來源帳戶分類",
|
||||
"Source Account Currency": "來源帳戶貨幣",
|
||||
"Destination Account Category": "目標帳戶分類",
|
||||
|
||||
@@ -279,6 +279,15 @@ export const useExplorersStore = defineStore('explorers', () => {
|
||||
categoryIdType: TransactionExplorerDimensionType.Other,
|
||||
categoryDisplayOrders: [dateTime.getGregorianCalendarQuarter()]
|
||||
};
|
||||
} else if (dimension === TransactionExplorerDataDimension.DateTimeByHourOfDay) {
|
||||
const dateTime = isDefined(transactionTimeUtfOffset) ? parseDateTimeFromUnixTimeWithTimezoneOffset(transaction.time, transactionTimeUtfOffset) : parseDateTimeFromUnixTime(transaction.time);
|
||||
|
||||
return {
|
||||
categoryName: dateTime.getHour().toString(10),
|
||||
categoryId: dateTime.getHour().toString(10),
|
||||
categoryIdType: TransactionExplorerDimensionType.Other,
|
||||
categoryDisplayOrders: [dateTime.getHour()]
|
||||
};
|
||||
} else if (dimension === TransactionExplorerDataDimension.TransactionType) {
|
||||
let transactionTypeName = 'Unknown';
|
||||
|
||||
|
||||
Reference in New Issue
Block a user