ASP.NET Zero Power Tools: 4.2.0 Visual Studio IDE: Community 2022 (64-bit) Version 17.9.0 AppVersion: Upgrading from 10.3.0 -> 13.1.0
There are some error when I try to regenerate some entities with Multi-lingual
Navigation Properties: The class is unable to find, but it is stil on partial class of entity where I put class xxxTranslation When I click ok to open generator and go to tab Navigate Properties. It doesn't show the Display Property. It is happen almost on Translation classes, sometimes it happen with classes doesn't have string field too,
Sometimes, it show error when generate entity
How can we fix it? I want to attach json file so you can check it, but I dont find button to attach json
10 Answer(s)
-
0
Hi @kworkme,
Could you share your JSON as code?
{ "EntityName" : "Category" }
-
0
{ "IsRegenerate": true, "MenuPosition": "main", "RelativeNamespace": "Bots", "EntityName": "AIReply", "EntityNamePlural": "AIReplySet", "TableName": "AIReplySet", "PrimaryKeyType": "Guid", "BaseClass": "FullAuditedEntity", "EntityHistory": true, "AutoMigration": true, "UpdateDatabase": true, "CreateUserInterface": true, "CreateViewOnly": true, "CreateExcelExport": true, "CreateExcelImport": true, "IsNonModalCRUDPage": true, "IsMasterDetailPage": false, "GenerateOverridableEntity": false, "GenerateUnitTest": false, "GenerateUiTest": false, "PagePermission": { "Host": true, "Tenant": true }, "Properties": [ { "Name": "Code", "Type": "string", "MaxLength": 50, "MinLength": 0, "Range": { "IsRangeSet": false, "MinimumValue": 0.0, "MaximumValue": 0.0 }, "Required": false, "Nullable": false, "Regex": "", "IsMultiLingual": false, "UserInterface": { "AdvancedFilter": true, "List": true, "CreateOrUpdate": true }, "ViewType": null, "AdditionalData": {} }, { "Name": "Comment", "Type": "string", "MaxLength": 900, "MinLength": 0, "Range": { "IsRangeSet": false, "MinimumValue": 0.0, "MaximumValue": 0.0 }, "Required": false, "Nullable": false, "Regex": "", "IsMultiLingual": false, "UserInterface": { "AdvancedFilter": true, "List": true, "CreateOrUpdate": true }, "ViewType": null, "AdditionalData": {} }, { "Name": "MinLoopCount", "Type": "int", "MaxLength": -1, "MinLength": -1, "Range": { "IsRangeSet": false, "MinimumValue": 0.0, "MaximumValue": 0.0 }, "Required": false, "Nullable": false, "Regex": "", "IsMultiLingual": false, "UserInterface": { "AdvancedFilter": true, "List": true, "CreateOrUpdate": true }, "ViewType": null, "AdditionalData": {} }, { "Name": "Text", "Type": "string", "MaxLength": -1, "MinLength": -1, "Range": { "IsRangeSet": false, "MinimumValue": 0.0, "MaximumValue": 0.0 }, "Required": false, "Nullable": false, "Regex": "", "IsMultiLingual": false, "UserInterface": { "AdvancedFilter": true, "List": true, "CreateOrUpdate": true }, "ViewType": null, "AdditionalData": {} }, { "Name": "Name", "Type": "string", "MaxLength": 250, "MinLength": 0, "Range": { "IsRangeSet": false, "MinimumValue": 0.0, "MaximumValue": 0.0 }, "Required": false, "Nullable": false, "Regex": "", "IsMultiLingual": false, "UserInterface": { "AdvancedFilter": true, "List": true, "CreateOrUpdate": true }, "ViewType": null, "AdditionalData": {} }, { "Name": "Command", "Type": "string", "MaxLength": 100, "MinLength": 0, "Range": { "IsRangeSet": false, "MinimumValue": 0.0, "MaximumValue": 0.0 }, "Required": false, "Nullable": false, "Regex": "", "IsMultiLingual": false, "UserInterface": { "AdvancedFilter": true, "List": true, "CreateOrUpdate": true }, "ViewType": null, "AdditionalData": {} }, { "Name": "DelayAfter", "Type": "int", "MaxLength": -1, "MinLength": -1, "Range": { "IsRangeSet": false, "MinimumValue": 0.0, "MaximumValue": 0.0 }, "Required": false, "Nullable": true, "Regex": "", "IsMultiLingual": false, "UserInterface": { "AdvancedFilter": true, "List": true, "CreateOrUpdate": true }, "ViewType": null, "AdditionalData": {} }, { "Name": "VariableName", "Type": "string", "MaxLength": 250, "MinLength": 0, "Range": { "IsRangeSet": false, "MinimumValue": 0.0, "MaximumValue": 0.0 }, "Required": false, "Nullable": false, "Regex": "", "IsMultiLingual": false, "UserInterface": { "AdvancedFilter": true, "List": true, "CreateOrUpdate": true }, "ViewType": null, "AdditionalData": {} }, { "Name": "RegexPatternForVariable", "Type": "string", "MaxLength": -1, "MinLength": -1, "Range": { "IsRangeSet": false, "MinimumValue": 0.0, "MaximumValue": 0.0 }, "Required": false, "Nullable": false, "Regex": "", "IsMultiLingual": false, "UserInterface": { "AdvancedFilter": false, "List": true, "CreateOrUpdate": true }, "ViewType": null, "AdditionalData": {} }, { "Name": "NoOfVariableChecking", "Type": "int", "MaxLength": -1, "MinLength": -1, "Range": { "IsRangeSet": false, "MinimumValue": 0.0, "MaximumValue": 0.0 }, "Required": false, "Nullable": false, "Regex": "", "IsMultiLingual": false, "UserInterface": { "AdvancedFilter": false, "List": true, "CreateOrUpdate": true }, "ViewType": null, "AdditionalData": {} }, { "Name": "SkipMessageIfVariableFilled", "Type": "bool", "MaxLength": -1, "MinLength": -1, "Range": { "IsRangeSet": false, "MinimumValue": 0.0, "MaximumValue": 0.0 }, "Required": false, "Nullable": false, "Regex": "", "IsMultiLingual": false, "UserInterface": { "AdvancedFilter": false, "List": true, "CreateOrUpdate": true }, "ViewType": null, "AdditionalData": {} }, { "Name": "EnableAIEditing", "Type": "bool", "MaxLength": -1, "MinLength": -1, "Range": { "IsRangeSet": false, "MinimumValue": 0.0, "MaximumValue": 0.0 }, "Required": false, "Nullable": false, "Regex": "", "IsMultiLingual": false, "UserInterface": { "AdvancedFilter": true, "List": true, "CreateOrUpdate": true }, "ViewType": null, "AdditionalData": {} } ], "NavigationProperties": [ { "Namespace": "Kw.BA.Bots", "ForeignEntityName": "UseCase", "ForeignEntityNamePlural": "UseCases", "IdType": "Guid", "IsNullable": false, "PropertyName": "UseCaseId", "DuplicationNumber": 0, "RelationType": "single", "ViewType": "LookupTable", "DisplayPropertyNameInfos": { "MergeFormat": "{0}", "DisplayPropertyNames": [ "Name" ] } }, { "Namespace": "Kw.BA.Bots", "ForeignEntityName": "AIReplyTranslation", "ForeignEntityNamePlural": "AIReplyTranslations", "IdType": "Guid", "IsNullable": true, "PropertyName": "AIReplyTranslationId", "DuplicationNumber": 0, "RelationType": "single", "ViewType": "LookupTable", "DisplayPropertyNameInfos": { "MergeFormat": "{0}", "DisplayPropertyNames": [ "Text" ] } } ], "NavigationPropertyOneToManyTables": [], "EnumDefinitions": [], "DbContext": null }
-
0
{ "IsRegenerate": true, "MenuPosition": "main", "RelativeNamespace": "Bots", "EntityName": "ScheduleDay", "EntityNamePlural": "ScheduleDaySet", "TableName": "ScheduleDaySet", "PrimaryKeyType": "Guid", "BaseClass": "FullAuditedEntity", "EntityHistory": false, "AutoMigration": true, "UpdateDatabase": true, "CreateUserInterface": true, "CreateViewOnly": true, "CreateExcelExport": true, "CreateExcelImport": true, "IsNonModalCRUDPage": true, "IsMasterDetailPage": false, "GenerateOverridableEntity": false, "GenerateUnitTest": false, "GenerateUiTest": false, "PagePermission": { "Host": true, "Tenant": true }, "Properties": [ { "Name": "WeekDay", "Type": "int", "MaxLength": -1, "MinLength": -1, "Range": { "IsRangeSet": false, "MinimumValue": 0.0, "MaximumValue": 0.0 }, "Required": false, "Nullable": false, "Regex": "", "IsMultiLingual": false, "UserInterface": { "AdvancedFilter": true, "List": true, "CreateOrUpdate": true }, "ViewType": null, "AdditionalData": {} }, { "Name": "TimeStart1", "Type": "DateTime", "MaxLength": -1, "MinLength": -1, "Range": { "IsRangeSet": false, "MinimumValue": 0.0, "MaximumValue": 0.0 }, "Required": false, "Nullable": true, "Regex": "", "IsMultiLingual": false, "UserInterface": { "AdvancedFilter": true, "List": true, "CreateOrUpdate": true }, "ViewType": null, "AdditionalData": {} }, { "Name": "TimeStop1", "Type": "DateTime", "MaxLength": -1, "MinLength": -1, "Range": { "IsRangeSet": false, "MinimumValue": 0.0, "MaximumValue": 0.0 }, "Required": false, "Nullable": true, "Regex": "", "IsMultiLingual": false, "UserInterface": { "AdvancedFilter": true, "List": true, "CreateOrUpdate": true }, "ViewType": null, "AdditionalData": {} }, { "Name": "TimeStart2", "Type": "DateTime", "MaxLength": -1, "MinLength": -1, "Range": { "IsRangeSet": false, "MinimumValue": 0.0, "MaximumValue": 0.0 }, "Required": false, "Nullable": true, "Regex": "", "IsMultiLingual": false, "UserInterface": { "AdvancedFilter": true, "List": true, "CreateOrUpdate": true }, "ViewType": null, "AdditionalData": {} }, { "Name": "TimeStop2", "Type": "DateTime", "MaxLength": -1, "MinLength": -1, "Range": { "IsRangeSet": false, "MinimumValue": 0.0, "MaximumValue": 0.0 }, "Required": false, "Nullable": true, "Regex": "", "IsMultiLingual": false, "UserInterface": { "AdvancedFilter": true, "List": true, "CreateOrUpdate": true }, "ViewType": null, "AdditionalData": {} } ], "NavigationProperties": [ { "Namespace": "Kw.BA.Bots", "ForeignEntityName": "Schedule", "ForeignEntityNamePlural": "Schedules", "IdType": "Guid", "IsNullable": false, "PropertyName": "ScheduleId", "DuplicationNumber": 0, "RelationType": "single", "ViewType": "LookupTable", "DisplayPropertyNameInfos": { "MergeFormat": "{0}", "DisplayPropertyNames": [ "Name" ] } } ], "NavigationPropertyOneToManyTables": [], "EnumDefinitions": [], "DbContext": null }
-
0
Hi @kworkme,
First of all, we do not recommend associating the TranslationEntity created for the translation of an entity with another entity. We will make an improvement to prevent it from showing in Power Tools.
Also, are the entities in the navigation properties still included in your project? Based on the first JSON file you sent, is the
AIReplyTranslation
entity still in your project?Errors related to dbcontext may be related to previous migrations or your current database. I suggest you clean up your migrations.
If you still have problems, we can help you more easily if you share your project with us. [email protected]
-
0
Thank you for quickly support. We have been using version 10.x.x for quite some time now and we have decided to upgrade our project to latest version 13.x.x.
During the upgrading, we are facing some problems. Could you please help to live support via chat (Google Meet)? It seems that there are significant changes from version 10.x.x to 13.x.x. Therefore, I may need you help to review the conflict codes and give recommend about upgrading and implementation to make project work stable and smoothly.
-
0
Hi @kworkme
Unfortunately, we don't provide such support for project upgrades. But, if you share specific problems, we can try to help.
-
0
Hi @kworkme,
Also, are the entities in the navigation properties still included in your project? Based on the first JSON file you sent, is the
AIReplyTranslation
entity still in your project?Yes, it is similar to PreconditionTranslation on screenshot above. It is Multi-lingual entity for AIReply class. If you don't recommend this way, what should I do to fix? I also followed exactly tutorial on https://aspnetboilerplate.com/Pages/Documents/Multi-Lingual-Entities
-
0
Hi @kworkme,
Regenerate entities by removing translation dto's from navigation properties. They automatically have relations between them.
-
0
I'm facing this error everytime open page "CreateOrEdit". It's error at "abp.ajax" to call modal for select (selectedEntityId)
Another issue is about AntiForgeryToken when I click Save button, I'm not sure how to set it on Startup.cs, also tried to add and remove but still not working. Could u help me check this?
-
0
Hi @kworkme,
- Could you verify if the
GetProjectForView
method exists within theProjectsAppService
? - Maybe this problem is related to cookies. Try it open in an incognito window if the problem resolved then clear your cookies in your browser.
- Could you verify if the