Browse Source

Merge branch 'main' into Task/upgrade-class-validator-to-version-0.14.3

pull/6091/head
Thomas Kaul 1 month ago
committed by GitHub
parent
commit
86f7830e87
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 8
      CHANGELOG.md
  2. 2
      apps/api/src/app/platform/platform.controller.ts
  3. 10
      apps/api/src/services/symbol-profile/symbol-profile.service.ts
  4. 7
      apps/client/src/app/components/admin-market-data/asset-profile-dialog/asset-profile-dialog.component.ts
  5. 6
      apps/client/src/app/components/admin-market-data/asset-profile-dialog/asset-profile-dialog.html
  6. 2
      apps/client/src/app/pages/accounts/create-or-update-account-dialog/create-or-update-account-dialog.html
  7. 1
      libs/common/src/lib/interfaces/enhanced-symbol-profile.interface.ts
  8. 3
      libs/common/src/lib/permissions.ts
  9. 6449
      package-lock.json
  10. 68
      package.json

8
CHANGELOG.md

@ -9,9 +9,17 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Changed ### Changed
- Lifted the asset profile identifier editing restriction for `MANUAL` data sources in the asset profile details dialog of the admin control panel
- Upgraded `angular` from version `20.2.4` to `20.3.9`
- Upgraded `class-validator` from version `0.14.2` to `0.14.3` - Upgraded `class-validator` from version `0.14.2` to `0.14.3`
- Upgraded `Nx` from version `21.5.1` to `22.0.4`
- Upgraded `shx` from version `0.3.4` to `0.4.0` - Upgraded `shx` from version `0.3.4` to `0.4.0`
### Fixed
- Added the missing currency suffix to the cash balance field in the create or update account dialog
- Fixed the delete button in the asset profile details dialog of the admin control panel by providing the missing `watchedByCount` parameter
## 2.224.2 - 2025-12-20 ## 2.224.2 - 2025-12-20
### Added ### Added

2
apps/api/src/app/platform/platform.controller.ts

@ -25,7 +25,7 @@ export class PlatformController {
public constructor(private readonly platformService: PlatformService) {} public constructor(private readonly platformService: PlatformService) {}
@Get() @Get()
@HasPermission(permissions.readPlatforms) @HasPermission(permissions.readPlatformsWithAccountCount)
@UseGuards(AuthGuard('jwt'), HasPermissionGuard) @UseGuards(AuthGuard('jwt'), HasPermissionGuard)
public async getPlatforms() { public async getPlatforms() {
return this.platformService.getPlatformsWithAccountCount(); return this.platformService.getPlatformsWithAccountCount();

10
apps/api/src/services/symbol-profile/symbol-profile.service.ts

@ -77,7 +77,7 @@ export class SymbolProfileService {
.findMany({ .findMany({
include: { include: {
_count: { _count: {
select: { activities: true } select: { activities: true, watchedBy: true }
}, },
activities: { activities: {
orderBy: { orderBy: {
@ -109,7 +109,7 @@ export class SymbolProfileService {
.findMany({ .findMany({
include: { include: {
_count: { _count: {
select: { activities: true } select: { activities: true, watchedBy: true }
}, },
SymbolProfileOverrides: true SymbolProfileOverrides: true
}, },
@ -184,7 +184,7 @@ export class SymbolProfileService {
private enhanceSymbolProfiles( private enhanceSymbolProfiles(
symbolProfiles: (SymbolProfile & { symbolProfiles: (SymbolProfile & {
_count: { activities: number }; _count: { activities: number; watchedBy?: number };
activities?: { activities?: {
date: Date; date: Date;
}[]; }[];
@ -206,10 +206,12 @@ export class SymbolProfileService {
sectors: this.getSectors( sectors: this.getSectors(
symbolProfile?.sectors as unknown as Prisma.JsonArray symbolProfile?.sectors as unknown as Prisma.JsonArray
), ),
symbolMapping: this.getSymbolMapping(symbolProfile) symbolMapping: this.getSymbolMapping(symbolProfile),
watchedByCount: 0
}; };
item.activitiesCount = symbolProfile._count.activities; item.activitiesCount = symbolProfile._count.activities;
item.watchedByCount = symbolProfile._count.watchedBy ?? 0;
delete item._count; delete item._count;
item.dateOfFirstActivity = symbolProfile.activities?.[0]?.date; item.dateOfFirstActivity = symbolProfile.activities?.[0]?.date;

7
apps/client/src/app/components/admin-market-data/asset-profile-dialog/asset-profile-dialog.component.ts

@ -260,13 +260,6 @@ export class GfAssetProfileDialogComponent implements OnDestroy, OnInit {
addIcons({ createOutline, ellipsisVertical, readerOutline, serverOutline }); addIcons({ createOutline, ellipsisVertical, readerOutline, serverOutline });
} }
public get canEditAssetProfileIdentifier() {
return (
this.assetProfile?.assetClass &&
!['MANUAL'].includes(this.assetProfile?.dataSource)
);
}
public get canSaveAssetProfileIdentifier() { public get canSaveAssetProfileIdentifier() {
return !this.assetProfileForm.dirty; return !this.assetProfileForm.dirty;
} }

6
apps/client/src/app/components/admin-market-data/asset-profile-dialog/asset-profile-dialog.html

@ -73,7 +73,8 @@
!adminMarketDataService.hasPermissionToDeleteAssetProfile({ !adminMarketDataService.hasPermissionToDeleteAssetProfile({
activitiesCount: assetProfile?.activitiesCount, activitiesCount: assetProfile?.activitiesCount,
isBenchmark: isBenchmark, isBenchmark: isBenchmark,
symbol: data.symbol symbol: data.symbol,
watchedByCount: assetProfile?.watchedByCount
}) })
" "
(click)=" (click)="
@ -186,9 +187,6 @@
mat-button mat-button
type="button" type="button"
[disabled]="!canSaveAssetProfileIdentifier" [disabled]="!canSaveAssetProfileIdentifier"
[ngClass]="{
'd-none': !canEditAssetProfileIdentifier
}"
(click)="onSetEditAssetProfileIdentifierMode()" (click)="onSetEditAssetProfileIdentifierMode()"
> >
<ion-icon name="create-outline" /> <ion-icon name="create-outline" />

2
apps/client/src/app/pages/accounts/create-or-update-account-dialog/create-or-update-account-dialog.html

@ -39,7 +39,7 @@
(keydown.enter)="$event.stopPropagation()" (keydown.enter)="$event.stopPropagation()"
/> />
<span class="ml-2" matTextSuffix>{{ <span class="ml-2" matTextSuffix>{{
accountForm.get('currency')?.value?.value accountForm.get('currency')?.value
}}</span> }}</span>
</mat-form-field> </mat-form-field>
</div> </div>

1
libs/common/src/lib/interfaces/enhanced-symbol-profile.interface.ts

@ -33,4 +33,5 @@ export interface EnhancedSymbolProfile {
updatedAt: Date; updatedAt: Date;
url?: string; url?: string;
userId?: string; userId?: string;
watchedByCount?: number;
} }

3
libs/common/src/lib/permissions.ts

@ -45,6 +45,7 @@ export const permissions = {
readMarketDataOfMarkets: 'readMarketDataOfMarkets', readMarketDataOfMarkets: 'readMarketDataOfMarkets',
readMarketDataOfOwnAssetProfile: 'readMarketDataOfOwnAssetProfile', readMarketDataOfOwnAssetProfile: 'readMarketDataOfOwnAssetProfile',
readPlatforms: 'readPlatforms', readPlatforms: 'readPlatforms',
readPlatformsWithAccountCount: 'readPlatformsWithAccountCount',
readTags: 'readTags', readTags: 'readTags',
readWatchlist: 'readWatchlist', readWatchlist: 'readWatchlist',
reportDataGlitch: 'reportDataGlitch', reportDataGlitch: 'reportDataGlitch',
@ -92,7 +93,7 @@ export function getPermissions(aRole: Role): string[] {
permissions.readAiPrompt, permissions.readAiPrompt,
permissions.readMarketData, permissions.readMarketData,
permissions.readMarketDataOfOwnAssetProfile, permissions.readMarketDataOfOwnAssetProfile,
permissions.readPlatforms, permissions.readPlatformsWithAccountCount,
permissions.readTags, permissions.readTags,
permissions.readWatchlist, permissions.readWatchlist,
permissions.updateAccount, permissions.updateAccount,

6449
package-lock.json

File diff suppressed because it is too large

68
package.json

@ -54,17 +54,17 @@
"workspace-generator": "nx workspace-generator" "workspace-generator": "nx workspace-generator"
}, },
"dependencies": { "dependencies": {
"@angular/animations": "20.2.4", "@angular/animations": "20.3.9",
"@angular/cdk": "20.2.2", "@angular/cdk": "20.2.9",
"@angular/common": "20.2.4", "@angular/common": "20.3.9",
"@angular/compiler": "20.2.4", "@angular/compiler": "20.3.9",
"@angular/core": "20.2.4", "@angular/core": "20.3.9",
"@angular/forms": "20.2.4", "@angular/forms": "20.3.9",
"@angular/material": "20.2.2", "@angular/material": "20.2.9",
"@angular/platform-browser": "20.2.4", "@angular/platform-browser": "20.3.9",
"@angular/platform-browser-dynamic": "20.2.4", "@angular/platform-browser-dynamic": "20.3.9",
"@angular/router": "20.2.4", "@angular/router": "20.3.9",
"@angular/service-worker": "20.2.4", "@angular/service-worker": "20.3.9",
"@codewithdan/observable-store": "2.2.15", "@codewithdan/observable-store": "2.2.15",
"@date-fns/utc": "2.1.0", "@date-fns/utc": "2.1.0",
"@internationalized/number": "3.6.5", "@internationalized/number": "3.6.5",
@ -138,32 +138,32 @@
"zone.js": "0.15.1" "zone.js": "0.15.1"
}, },
"devDependencies": { "devDependencies": {
"@angular-devkit/build-angular": "20.2.2", "@angular-devkit/build-angular": "20.3.9",
"@angular-devkit/core": "20.2.2", "@angular-devkit/core": "20.3.9",
"@angular-devkit/schematics": "20.2.2", "@angular-devkit/schematics": "20.3.9",
"@angular-eslint/eslint-plugin": "20.2.0", "@angular-eslint/eslint-plugin": "20.7.0",
"@angular-eslint/eslint-plugin-template": "20.2.0", "@angular-eslint/eslint-plugin-template": "20.7.0",
"@angular-eslint/template-parser": "20.2.0", "@angular-eslint/template-parser": "20.7.0",
"@angular/cli": "20.2.2", "@angular/cli": "20.3.9",
"@angular/compiler-cli": "20.2.4", "@angular/compiler-cli": "20.3.9",
"@angular/language-service": "20.2.4", "@angular/language-service": "20.3.9",
"@angular/localize": "20.2.4", "@angular/localize": "20.3.9",
"@angular/pwa": "20.2.2", "@angular/pwa": "20.3.9",
"@eslint/eslintrc": "3.3.1", "@eslint/eslintrc": "3.3.1",
"@eslint/js": "9.35.0", "@eslint/js": "9.35.0",
"@nestjs/schematics": "11.0.9", "@nestjs/schematics": "11.0.9",
"@nestjs/testing": "11.1.8", "@nestjs/testing": "11.1.8",
"@nx/angular": "21.5.1", "@nx/angular": "22.0.4",
"@nx/eslint-plugin": "21.5.1", "@nx/eslint-plugin": "22.0.4",
"@nx/jest": "21.5.1", "@nx/jest": "22.0.4",
"@nx/js": "21.5.1", "@nx/js": "22.0.4",
"@nx/module-federation": "21.5.1", "@nx/module-federation": "22.0.4",
"@nx/nest": "21.5.1", "@nx/nest": "22.0.4",
"@nx/node": "21.5.1", "@nx/node": "22.0.4",
"@nx/storybook": "21.5.1", "@nx/storybook": "22.0.4",
"@nx/web": "21.5.1", "@nx/web": "22.0.4",
"@nx/workspace": "21.5.1", "@nx/workspace": "22.0.4",
"@schematics/angular": "20.2.2", "@schematics/angular": "20.3.9",
"@storybook/addon-docs": "9.1.5", "@storybook/addon-docs": "9.1.5",
"@storybook/angular": "9.1.5", "@storybook/angular": "9.1.5",
"@trivago/prettier-plugin-sort-imports": "5.2.2", "@trivago/prettier-plugin-sort-imports": "5.2.2",
@ -185,7 +185,7 @@
"jest": "29.7.0", "jest": "29.7.0",
"jest-environment-jsdom": "29.7.0", "jest-environment-jsdom": "29.7.0",
"jest-preset-angular": "14.6.0", "jest-preset-angular": "14.6.0",
"nx": "21.5.1", "nx": "22.0.4",
"prettier": "3.7.4", "prettier": "3.7.4",
"prettier-plugin-organize-attributes": "1.0.0", "prettier-plugin-organize-attributes": "1.0.0",
"prisma": "6.19.0", "prisma": "6.19.0",

Loading…
Cancel
Save