Base solution for your next web application
Open Closed

Original EntityDtos not working in service-proxies.ts #11137


User avatar
0
billyteng created

"version": "11.1.0", Angular net core

Hi Team, My service side is all ok. Swagger browsing is ok. Then I run refresh.bat in command prompt. It is also ok. I created entity using power tool is nice in service-proxies file. I try it again and again. It is showing same error. But after i run npm start in VS code, it is showing me the following bugs.

./src/app/shared/layout/nav/menu-search-bar/menu-search-bar.component.ts:47:35-52 - Error: export 'NameValueOfString' (imported as 'NameValueOfString') was not found in '@shared/service-proxies/service-proxies' ./src/app/shared/layout/notifications/UserNotificationHelper.ts:123:26-41 - Error: export 'EntityDtoOfGuid' (imported as 'EntityDtoOfGuid') was not found in '@shared/service-proxies/service-proxies' Error: src/app/admin/demo-ui-components/demo-ui-selection.component.ts:4:40 - error TS2305: Module '"@shared/service-proxies/service-proxies"' has no exported member 'NameValueOfString'.

4 import { DemoUiComponentsServiceProxy, NameValueOfString } from '@shared/service-proxies/service-proxies'; ~~~~~~~~~~~~~~~~~ Error: src/app/admin/maintenance/maintenance.component.ts:4:31 - error TS2305: Module '"@shared/service-proxies/service-proxies"' has no exported member 'EntityDtoOfString'.

4 import { CachingServiceProxy, EntityDtoOfString, WebLogServiceProxy } from '@shared/service-proxies/service-proxies'; ~~~~~~~~~~~~~~~~~ Error: src/app/admin/organization-units/organization-tree.component.ts:4:5 - error TS2305: Module '"@shared/service-proxies/service-proxies"' has no exported member 'ListResultDtoOfOrganizationUnitDto'.

4 ListResultDtoOfOrganizationUnitDto, ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Error: src/app/admin/tenants/tenants.component.ts:9:5 - error TS2305: Module '"@shared/service-proxies/service-proxies"' has no exported member 'EntityDtoOfInt64'.

9 EntityDtoOfInt64, ~~~~~~~~~~~~~~~~

Error: src/app/admin/users/edit-user-permissions-modal.component.ts:4:5 - error TS2305: Module '"@shared/service-proxies/service-proxies"' has no exported member 'EntityDtoOfInt64'.

4 EntityDtoOfInt64, ~~~~~~~~~~~~~~~~ Error: src/app/admin/users/users.component.ts:7:5 - error TS2305: Module '"@shared/service-proxies/service-proxies"' has no exported member 'EntityDtoOfInt64'.

7 EntityDtoOfInt64, ~~~~~~~~~~~~~~~~

Error: src/app/admin/webhook-subscription/create-or-edit-webhook-subscription-modal.component.ts:6:5 - error TS2305: Module '"@shared/service-proxies/service-proxies"' has no exported member 'NameValueOfString'.

6 NameValueOfString, ~~~~~~~~~~~~~~~~~

Error: src/app/shared/common/lookup/common-lookup-modal.component.ts:4:24 - error TS2305: Module '"@shared/service-proxies/service-proxies"' has no exported member 'PagedResultDtoOfNameValueDto'.

4 import { NameValueDto, PagedResultDtoOfNameValueDto } from '@shared/service-proxies/service-proxies'; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Error: src/app/shared/layout/nav/menu-search-bar/menu-search-bar.component.ts:2:10 - error TS2305: Module '"@shared/service-proxies/service-proxies"' has no exported member 'NameValueOfString'.

2 import { NameValueOfString } from '@shared/service-proxies/service-proxies'; ~~~~~~~~~~~~~~~~~

Error: src/app/shared/layout/notifications/UserNotificationHelper.ts:4:5 - error TS2305: Module '"@shared/service-proxies/service-proxies"' has no exported member 'EntityDtoOfGuid'.

So that, i have been checked with service-proxies file of old project. Old file have export class NameValueOfString implements INameValueOfString { name!: string | undefined; value!: string | undefined; .. .. }

export interface INameValueOfString { name: string | undefined; value: string | undefined; }

Current file export class NameValue_1OfOfStringAndCoreLibAnd_0AndCulture_neutralAndPublicKeyToken_7cec85d7bea7798e implements INameValue_1OfOfStringAndCoreLibAnd_0AndCulture_neutralAndPublicKeyToken_7cec85d7bea7798e { name!: string | undefined; value!: string | undefined; .. .. }

export interface INameValue_1OfOfStringAndCoreLibAnd_0AndCulture_neutralAndPublicKeyToken_7cec85d7bea7798e { name: string | undefined; value: string | undefined; }

Why its happen?

Please help me. Thanks all


3 Answer(s)
  • User Avatar
    0
    ismcagdas created
    Support Team

    Hi,

    Could you apply changes in this Pull Request and see if it fixes your problem ?

    Thanks,

  • User Avatar
    0
    billyteng created

    Hi ismcagdas,

    There have also other bugs. It is still showing error NameValueOfString in DemoUiSelectionComponent. Why service not auto generate this classes EntityDtoOfString,ListResultDtoOfOrganizationUnitDto,EntityDtoOfInt64,PagedResultDtoOfNameValueDto,EntityDtoOfGuid?

    Thanks

  • User Avatar
    0
    ismcagdas created
    Support Team

    Hi @billyteng

    Normally, those classes must be generated. Is it possible for us to access your project ? Could you share it with [email protected] ? We cna cehck the problem and understand it faster that way.