asp.net-boilerplate

Error: Failed to complete negotiation with the server: Error: Not Found

不羁的心 提交于 2020-06-17 15:51:38
问题 I'm using SignalR with ASP.NET Boilerplate .NET Core 3.1 but I encounterd this problem Error: Failed to complete negotiation with the server: Error: Not Found How could I resolve this problem without skip negotiate (solution mentioned here ) zone-evergreen.js:2845 POST http://localhost:21021/signalr/negotiate?enc_auth_token=wNYmO41%2F Show 162 more frames signalr.min.js:16 [2020-06-07T10:17:31.634Z] Error: Failed to start the connection: Error: Not Found here is Angular Code: ngOnInit(): void

Mvc.ExceptionHandling.AbpExceptionFilter - No Component found

╄→гoц情女王★ 提交于 2020-06-17 13:16:49
问题 this is a follow-up question to the one posted here earlier today InvalidCastException on an LDAP implementation in ASP Boilerplate as suggested by just.another.programmer I seem to be running into another issue this time having no component supported as described here in the logs The code from before LdapAuthentication.cs: public abstract class LdapAuthenticationSource<TTenant, TUser> : DefaultExternalAuthenticationSource<TTenant, TUser>, ITransientDependency where TTenant : AbpTenant<TUser>

InvalidCastException on an LDAP implementation in ASP Boilerplate

ぐ巨炮叔叔 提交于 2020-06-17 09:08:50
问题 Good day all, recently had to implement an Active Directory for our application and we have come across an InvalidCastException when trying to log into the site for the past few days I have been at our wits end trying to figure out what is causing this error. The code does seems to run fine as there are no errors when loading LdapAuthentication.cs: public abstract class LdapAuthenticationSource<TTenant, TUser> : DefaultExternalAuthenticationSource<TTenant, TUser>, ITransientDependency where

The instance of entity type 'Product' cannot be tracked because another instance with the same key value is already being tracked

醉酒当歌 提交于 2020-01-10 05:11:14
问题 I made a test with code below to update the Product : var existing = await _productRepository.FirstOrDefaultAsync(c => c.Id == input.Id); if (existing == null) throw new UserFriendlyException(L("ProductNotExist")); var updatedEntity = ObjectMapper.Map<Product>(input); var entity = await _productRepository.UpdateAsync(updatedEntity); But it throws an exception: Mvc.ExceptionHandling.AbpExceptionFilter - The instance of entity type 'Product' cannot be tracked because another instance with the

How to work wirth WCF services in ASP.Net Boilerplate?

半腔热情 提交于 2019-12-25 09:01:14
问题 I want to do CRUD by web-services(WCF), but i am using boilerplate framework , my question is how to work with web-services(WCF) in boilerplate?? any helpful link or tutorial?? 回答1: Create a new project in your solution with WCF application, add wcf service in this new project, use entity framework and then write services you need, then in YourProject.Web project add service reference and get the service you need. Create object of the service in your controller and get or post data according

Can't create component as it has dependencies to be satisfied

自古美人都是妖i 提交于 2019-12-18 15:53:41
问题 I am learning DDD, n-Tier, Repositoriess and the likes. Someone pointed me to ASP.NET Boilerplate and I decided to start a test project using that. I have never dealt with dependency injection so this is all new to me, but the DI dependency it uses ius Castle Windsor. Now, I created a Model and from this Model I created an interface. I also added a Service. Whenever I fire up the app it gives me this error: Can't create component 'TestApp.Services.MemberInfo.MemberAppService' as it has

Asp.Net Boilerplate… How to update a record in Existing tables in Database using Async methods?

社会主义新天地 提交于 2019-12-13 10:07:27
问题 I am working with ASP.Net Boilerplate . I want to send isActive=true to the AbpUser table when a user is confirmed by email. How can I access the database and do a query on that? As you know Boilerplate doesn't provide entity classes so I am working with extensions on those classes. I don't know how queries on those classes access the database. Any idea? 回答1: I wrote a sample code to show you how you can update a field of user with IRepository. public interface IUserAppService:

Add-Migration not working with MySQL

梦想与她 提交于 2019-12-13 00:27:23
问题 I have downloaded Asp.Net MVC 5.x Single page web application from https://aspnetboilerplate.com/Templates. I'm using MySQL and followed the steps mentioned in link https://aspnetboilerplate.com/Pages/Documents/EF-MySql-Integration. But when I run the Add-Migration command it gives the error. MyCompany.MyProject.Web\Web.Config: <add name="Default" connectionString="Server=127.0.0.1;port=3306;Database=SparTestDb;uid=root;password=root" providerName="MySql.Data.MySqlClient"/> MyCompany

Cannot delete record from table which has Identity column

↘锁芯ラ 提交于 2019-12-12 04:04:11
问题 I have a table which has the code as primary key instead of Id, When I call DeleteAsync method I get the exception Message = "Cannot update identity column 'Id'." . [Table("Test")] public class Test: FullAuditedEntity<int> { [DatabaseGenerated(DatabaseGeneratedOption.Identity)] new public int Id { get; set; } [Key] [DatabaseGenerated(DatabaseGeneratedOption.None)] public virtual int Code { get; set; } public async Task DeleteTest(int code) { try { await _supplierRepository.DeleteAsync(p => p

Invalid Tenancy Name

北慕城南 提交于 2019-12-09 07:20:18
问题 I am working on an ASP.NET Boilerplate service project. When I am saving a client, it returns an error: Tenancy Name is not valid The tenancy name contains spaces. TenantDto maps to Tenant object without any error. Database table TenancyName column is nvarchar(64) . Error occurs when it is saving. 回答1: From the documentation on Tenant Management: AbpTenant class defines some base properties, most important ones are: TenancyName : This is unique name of a tenant in the application. It should