mirror of
https://github.com/mayswind/ezbookkeeping.git
synced 2026-05-17 00:12:11 +08:00
support storing geo location in transaction
This commit is contained in:
+4
-2
@@ -266,7 +266,7 @@ export default {
|
||||
getTransaction: ({ id }) => {
|
||||
return axios.get(`v1/transactions/get.json?id=${id}&trim_account=true&trim_category=true&trim_tag=true`);
|
||||
},
|
||||
addTransaction: ({ type, categoryId, time, sourceAccountId, destinationAccountId, sourceAmount, destinationAmount, hideAmount, tagIds, comment, utcOffset }) => {
|
||||
addTransaction: ({ type, categoryId, time, sourceAccountId, destinationAccountId, sourceAmount, destinationAmount, hideAmount, tagIds, comment, geoLocation, utcOffset }) => {
|
||||
return axios.post('v1/transactions/add.json', {
|
||||
type,
|
||||
categoryId,
|
||||
@@ -278,10 +278,11 @@ export default {
|
||||
hideAmount,
|
||||
tagIds,
|
||||
comment,
|
||||
geoLocation,
|
||||
utcOffset
|
||||
});
|
||||
},
|
||||
modifyTransaction: ({ id, type, categoryId, time, sourceAccountId, destinationAccountId, sourceAmount, destinationAmount, hideAmount, tagIds, comment, utcOffset }) => {
|
||||
modifyTransaction: ({ id, type, categoryId, time, sourceAccountId, destinationAccountId, sourceAmount, destinationAmount, hideAmount, tagIds, comment, geoLocation, utcOffset }) => {
|
||||
return axios.post('v1/transactions/modify.json', {
|
||||
id,
|
||||
type,
|
||||
@@ -294,6 +295,7 @@ export default {
|
||||
hideAmount,
|
||||
tagIds,
|
||||
comment,
|
||||
geoLocation,
|
||||
utcOffset
|
||||
});
|
||||
},
|
||||
|
||||
@@ -13,6 +13,7 @@ const defaultSettings = {
|
||||
applicationLock: false,
|
||||
applicationLockWebAuthn: false,
|
||||
autoUpdateExchangeRatesData: true,
|
||||
autoGetCurrentGeoLocation: false,
|
||||
thousandsSeparator: true,
|
||||
currencyDisplayMode: currencyConstants.defaultCurrencyDisplayMode,
|
||||
showAmountInHomePage: true,
|
||||
@@ -140,6 +141,8 @@ export default {
|
||||
setEnableApplicationLockWebAuthn: value => setOption('applicationLockWebAuthn', value),
|
||||
isAutoUpdateExchangeRatesData: () => getOption('autoUpdateExchangeRatesData'),
|
||||
setAutoUpdateExchangeRatesData: value => setOption('autoUpdateExchangeRatesData', value),
|
||||
isAutoGetCurrentGeoLocation: () => getOption('autoGetCurrentGeoLocation'),
|
||||
setAutoGetCurrentGeoLocation: value => setOption('autoGetCurrentGeoLocation', value),
|
||||
isEnableThousandsSeparator: () => getOption('thousandsSeparator'),
|
||||
setEnableThousandsSeparator: value => setOption('thousandsSeparator', value),
|
||||
getCurrencyDisplayMode: () => getOption('currencyDisplayMode'),
|
||||
|
||||
Reference in New Issue
Block a user