ABP Framework version: v8.0.1
UI Type: MVC
Database System: EF Core (SQL Server
Tiered (for MVC) or Auth Server Separated (for Angular): no
Exception message and full stack trace:
Steps to reproduce the issue:
1、use abp suite build entity A,Master type 2、use abp suite build entity B,Child type,set parent is A 3、run system. Create A , And then Create B,but the B save button is no response
4 Answer(s)
-
0
Hi, I could reproduce the problem that you mentioned and created an internal issue for it. This occurs if your master entity has a name such as
EntityA
(I mean a pascalcase name). For a quick workaround, you can search in your application the word$(this).data("<yourentityname>-id")
and replace the<yourentityname>
placeholder with your entity name as lowercase.BTW, I refunded your ticket, thanks for reporting this problem.
-
0
hi
Please use English to describe the problem. Our suite colleagues will check the problem.
ABP Framework version: v8.0.1
UI Type: MVC
Database System: EF Core (SQL Server
Tiered (for MVC) or Auth Server Separated (for Angular): no
Exception message and full stack trace:
Steps to reproduce the issue:
1、use abp suite build entity A,Master type 2、use abp suite build entity B,Child type,set parent is A 3、run system. Create A , And then Create B,but the B save button is no response
when I search in my application the word $(this).data("projectFlowing-id") and replace the projectflowing placeholder with your entity name as lowercase. the save function can response, but has one inner exception.
2024-01-11 17:44:13.980 +08:00 [ERR] An error occurred while saving the entity changes. See the inner exception for details. Microsoft.EntityFrameworkCore.DbUpdateException: An error occurred while saving the entity changes. See the inner exception for details. ---> Microsoft.Data.SqlClient.SqlException (0x80131904): INSERT 语句与 FOREIGN KEY 约束"FK_AppFlowingReports_AppProjectFlowings_ProjectFlowingId"冲突。该冲突发生于数据库"ProjectReward",表"dbo.AppProjectFlowings", column 'Id'。 语句已终止。
AppProjectFlowings is Parent Table。 AppFlowingReports is child Table。
-
0
I have opened a PR to fix this problem:
2024-01-11 17:44:13.980 +08:00 [ERR] An error occurred while saving the entity changes. See the inner exception for details. Microsoft.EntityFrameworkCore.DbUpdateException: An error occurred while saving the entity changes. See the inner exception for details. ---> Microsoft.Data.SqlClient.SqlException (0x80131904): INSERT 语句与 FOREIGN KEY 约束"FK_AppFlowingReports_AppProjectFlowings_ProjectFlowingId"冲突。该冲突发生于数据库"ProjectReward",表"dbo.AppProjectFlowings", column 'Id'。 语句已终止。
From the stack trace, it seems it can't add a record because it violates foreign key constraint, please check your entity configuration and the database.
-
0
I have opened a PR to fix this problem:
2024-01-11 17:44:13.980 +08:00 [ERR] An error occurred while saving the entity changes. See the inner exception for details. Microsoft.EntityFrameworkCore.DbUpdateException: An error occurred while saving the entity changes. See the inner exception for details. ---> Microsoft.Data.SqlClient.SqlException (0x80131904): INSERT 语句与 FOREIGN KEY 约束"FK_AppFlowingReports_AppProjectFlowings_ProjectFlowingId"冲突。该冲突发生于数据库"ProjectReward",表"dbo.AppProjectFlowings", column 'Id'。 语句已终止。
From the stack trace, it seems it can't add a record because it violates foreign key constraint, please check your entity configuration and the database.
ok,thks