Feature/rename Order to activities in User database schema (#4669)

* Rename Order to activities in User database schema

* Update changelog
This commit is contained in:
Thomas Kaul 2025-05-09 16:19:14 +02:00 committed by GitHub
parent 72ccf47526
commit 037d3b1a60
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 7 additions and 6 deletions

View File

@ -13,6 +13,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Changed
- Renamed `Order` to `activities` in the `User` database schema
- Improved the language localization for Catalan (`ca`)
- Improved the language localization for Italian (`it`)
- Upgraded `nestjs` from version `10.4.15` to `11.0.12`

View File

@ -821,7 +821,7 @@ export class AdminService {
where,
select: {
_count: {
select: { Account: true, Order: true }
select: { Account: true, activities: true }
},
Analytics: {
select: {
@ -869,10 +869,10 @@ export class AdminService {
role,
subscription,
accountCount: _count.Account || 0,
activityCount: _count.activities || 0,
country: Analytics?.country,
dailyApiRequests: Analytics?.dataProviderGhostfolioDailyRequests || 0,
lastActivity: Analytics?.updatedAt,
transactionCount: _count.Order || 0
lastActivity: Analytics?.updatedAt
};
}
);

View File

@ -142,7 +142,7 @@
<gf-value
class="d-inline-block justify-content-end"
[locale]="user?.settings?.locale"
[value]="element.transactionCount"
[value]="element.activityCount"
/>
</td>
</ng-container>

View File

@ -4,6 +4,7 @@ export interface AdminUsers {
count: number;
users: {
accountCount: number;
activityCount: number;
country: string;
createdAt: Date;
dailyApiRequests: number;
@ -11,6 +12,5 @@ export interface AdminUsers {
id: string;
lastActivity: Date;
role: Role;
transactionCount: number;
}[];
}

View File

@ -245,6 +245,7 @@ model Tag {
model User {
accessToken String?
activities Order[]
authChallenge String?
createdAt DateTime @default(now())
id String @id @default(uuid())
@ -260,7 +261,6 @@ model User {
Analytics Analytics?
ApiKey ApiKey[]
AuthDevice AuthDevice[]
Order Order[]
Settings Settings?
SymbolProfile SymbolProfile[]
Tag Tag[]