Base solution for your next web application

Activities of "mhrabak"

Hi @ismcagdas, My colleague should sent you sample to [email protected] on 26th February 2020. He used Id of this ticket.

Thanks.

Hi @ismcagdas, No I gave you link to sharing website and you answered me this month ago (just 4 comments above):

Hi @mhrabak

Thank you for sharing the project. I removed the download link since the urls in this website is public and everyone can download the source code. I downloaded the source code. I will check the problem and inform you if you haven't solved the project

Hi guys, How could you close problem which lies on you? I gave you sample project with simulated problem and expect an answer different from closing the issue. Maybe link to another similar related issue where this would be solver or someting like that maybe.

Thanks for answer.

Hi @demirmusa, Sorry for delayed answer. We had lot of work before holidays. I have created a sample for you NgrxSample It was uploaded to our czech sharing website - you can downlaod it using slow download without creating an account. When you will have problem to download the file just tell me I will upload it elsewhere. Steps to simulate:

  • In Visual studio open NgrxSampleDemo.Web.sln
  • Run Update-Database command in Nuget Package Manager console
  • Run NgrxSampleDemo WebAPI
  • Open NgrxSampleDemo angular app
  • Run angular app (npm i, npm start)
  • Login page does not show up and in Developer tools (Ctrl+Shift+I or F12 key) console you can see an error
  • When you comment out line 322 in root.module.ts everything works OK (except dispatching data to ngrx state of course)

Just to mention when we register Effect into lazy loaded module and register it as feature it works OK without any problem but we need to dispatch ngrx store in RootModule too.

Thansk for help.

Thanks for reply. Still it doesn't make sense to me unfortunately. I understandt that when record inherits from ISoftDelete its IsDeleted property is set to true which is independent from filters but in my opinion this functionality should be coupled.

The reason behind this is that what I mentioned earlier - when I delete record using repository I don't expect this record to be loaded from database no matter what. Deleted record should be deleted period.

This condition is not fulfilled when ISoftDelete filter is disabled for example for ApplicationLanguage (yours entity type). User use case:

  • User enter list of languages
  • Delete one language
  • Language is not deleted - yes the reason is disabled ISoftDelete filter

ApplicationLanguageAppService is generated by aspnetzero automatically - DeleteLanguage method recall IApplicationLanguageManager.RemoveAsync method so deletion of ApplicationLanguage record from database is out of our reach - only thing we can do is implement our own implementation of IApplicationLanguageManager where we will use HardDelete or rewrite DeleteLanguage method itself with multitenancy in our minds and call HardDelete.

Sorry but it sounds more like bug to me when I have to rewrite your generated code or create our custom implementation of the manager to be able to delete a record - yes in this particular case it is only one entity type -ApplicationLanguage - which cause us problem but maybe there could be more we just didn't find yet.

Hi guys. Any advices here? I think ngRx is used a lot in Angular so it would be desirable to make this work properly. Thanks in advance.

Ok just sum it up. Your advice is to rework your original tests and your original app services for entities which inherits from ISoftDelete to use HardDelete instead of Delete method to make it work when ISoftDelete filter is disabled? Really? It doesn't make sense to me. Why should I update your codes and tests to make your supported scenario (disable filters) works (logically) right?

For me logical behavior: When I disable ISoftDelete - which is supported scenario based on your documentation - I expect deleted entity will not load from DB - such entity should be hard deleted because ISoftDelete is disabled.

Maybe I missing something but from what I know it shouldn't be such problem. We already implemented our own deleting strategy for our entities and we expect yours will be deleted permanently but without any updates to your codes nor tests.

Thanks for reply.

Hi guys, we are facing an issue when we register ngrx effect with injected service (generateg using nswag). when we register effect into root module angular throws exception because abp config is not yet loaded properly because app_initializer is not probably yet finished or effect is registered earlier we can not find a way how to obtain this issue unfortunately. We are quite new in angular.

Do you have any advices pleaee thanks.

we are using latest aspnetzero web api & angular 8 template.

thanks a lot.

Hi guys, We are trying to configure our app to run as Windows service but we are unable to run aspnetzero as WindopwsService. The error we get when try to run app is this:

ConfigureServices returning an System.IServiceProvider isn't supported.

I found out that this problem occurs because of CastleWindsor which does not support .NET Core 3 approach. Some possible unofficial approach found here: https://github.com/castleproject/Windsor/issues/493 Do you plan to try it out or do you have any advice how to run app as WindowsService in .net core 3? We tried this approach (it is just simplified version to show you the direction nto the path):

public static void Main(string[] args) {
            CreateHostBuilder(args).Build().Run();
        }

        public static IHostBuilder CreateHostBuilder(string[] args) =>
            Host.CreateDefaultBuilder(args)
                .UseWindowsService()             
                .ConfigureWebHostDefaults(webBuilder => {
                    webBuilder.UseStartup<Startup>();
                });
    }

Thanks a lot.

Thanks for answer. I read articles you post and I found out myself what you wrote, but we have our custom filter and interface for deleting records so it is necessary to disable yours (reason is legacy database which has it's own SofDelete mechanics). Problem is that when we disable SoftDelete filter your test starts to fail. For me expected behavior is that when default SoftDelete filter is disabled Abp starts to Hard Delete records because we can not apply our custom SoftDelete interface to entities builded into your assemblies. Expected behavior: We delete ApplicationLanguage record -> It is hard deleted -> test pass successfully Current behavior(for me false) : We delete ApplicationLanguage record -> it is only marked as IsDeleted -> test fails As user I expect when I delet record this record dissapear from list but without SoftDelete filter it is still part of result from repository becasue Abp does not delete the record. Reason behind this is that now when we disable your SoftDelete filter no record - where we are unable to apply our own SoftDelete mechanism - is really deleted.

Showing 1 to 10 of 20 entries