mirror of
https://github.com/whekin/household-bot.git
synced 2026-03-31 20:34:03 +00:00
feat(finance): add settlement currency and cycle fx rates
This commit is contained in:
@@ -118,6 +118,7 @@ function onboardingRepository(): HouseholdConfigurationRepository {
|
||||
: null,
|
||||
getHouseholdBillingSettings: async (householdId) => ({
|
||||
householdId,
|
||||
settlementCurrency: 'GEL',
|
||||
rentAmountMinor: 70000n,
|
||||
rentCurrency: 'USD',
|
||||
rentDueDay: 20,
|
||||
@@ -128,6 +129,7 @@ function onboardingRepository(): HouseholdConfigurationRepository {
|
||||
}),
|
||||
updateHouseholdBillingSettings: async (input) => ({
|
||||
householdId: input.householdId,
|
||||
settlementCurrency: 'GEL',
|
||||
rentAmountMinor: input.rentAmountMinor ?? 70000n,
|
||||
rentCurrency: input.rentCurrency ?? 'USD',
|
||||
rentDueDay: input.rentDueDay ?? 20,
|
||||
@@ -370,6 +372,7 @@ describe('createMiniAppSettingsHandler', () => {
|
||||
authorized: true,
|
||||
settings: {
|
||||
householdId: 'household-1',
|
||||
settlementCurrency: 'GEL',
|
||||
rentAmountMinor: '70000',
|
||||
rentCurrency: 'USD',
|
||||
rentDueDay: 20,
|
||||
@@ -452,6 +455,7 @@ describe('createMiniAppUpdateSettingsHandler', () => {
|
||||
authorized: true,
|
||||
settings: {
|
||||
householdId: 'household-1',
|
||||
settlementCurrency: 'GEL',
|
||||
rentAmountMinor: '75000',
|
||||
rentCurrency: 'USD',
|
||||
rentDueDay: 22,
|
||||
|
||||
Reference in New Issue
Block a user