Base solution for your next web application
Starts in:
01 DAYS
01 HRS
01 MIN
01 SEC

Activities of "cmthomps"

The odd thing is that sometimes the notification goes through the first time the service is hit. After that, the notifications do not go through.

Thanks Aaron - Still no luck. Any other ideas?

It does. I've also created a button in my application that fires off a notification (as a test). Those get to the user without an issue.

Sorry. No. That is how my code has been. This is basically a fresh download of aspnetzero. We were testing some of the new functionality (I think it's 4.3) so there is not any custom code yet.

Thanks. I think that is what we're doing. I basically just un-commented the code in the startup class. My configure method is below.

public void Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory)
        {
            //Initializes ABP framework.
            app.UseAbp(options =>
            {
                options.UseAbpRequestLocalization = false; //used below: UseAbpRequestLocalization
            });

            if (env.IsDevelopment())
            {
                app.UseDeveloperExceptionPage();
            }
            else
            {
                app.UseStatusCodePagesWithRedirects("~/Error?statusCode={0}");
                app.UseExceptionHandler("/Error");
            }

            AuthConfigurer.Configure(app, _appConfiguration);

            app.UseStaticFiles();

            app.UseAbpRequestLocalization();

#if FEATURE_SIGNALR
            //Integrate to OWIN
            app.UseAppBuilder(ConfigureOwinServices);
#endif

            //Hangfire dashboard & server (Enable to use Hangfire instead of default job manager)
            app.UseHangfireDashboard("/hangfire", new DashboardOptions
            {
                Authorization = new[] { new AbpHangfireAuthorizationFilter(AppPermissions.Pages_Administration_HangfireDashboard) }
            });
            app.UseHangfireServer();

            app.UseMvc(routes =>
            {
                routes.MapRoute(
                    name: "defaultWithArea",
                    template: "{area}/{controller=Home}/{action=Index}/{id?}");

                routes.MapRoute(
                    name: "default",
                    template: "{controller=Home}/{action=Index}/{id?}");
            });

            // Enable middleware to serve generated Swagger as a JSON endpoint
            //app.UseSwagger();
            // Enable middleware to serve swagger-ui assets (HTML, JS, CSS etc.)
            //app.UseSwaggerUI(options =>
            //{
            //    options.SwaggerEndpoint("/swagger/v1/swagger.json", "TestCode API V1");
            //}); //URL: /swagger
        }

Well, I found a workaround but I'm not sure if it's the appropriate solution.

In the _Layout.cshtml file there is this code:

<script type="text/javascript">
    @* This is used to get the application's root path from javascript.
    It's useful if you're running application in a virtual directory under IIS. *@
    var abp = abp || {}; abp.appPath = '@ApplicationPath';
</script>

If I change it to:

<script type="text/javascript">
    @* This is used to get the application's root path from javascript.
    It's useful if you're running application in a virtual directory under IIS. *@
    var abp = abp || {}; abp.appPath = '@ApplicationPath' + 'aspnetzero/';
</script>

It works.

Just to close the loop in case anyone else runs into this issue. The only way I could ultimately get our Continuous Integration process to build the .NET Core version was to install the Visual Studio 2017 on the server and then use the command:

devenv MyProject.sln /build Release

I'm not wild about installing VS 2017 on our build server, but it works for now.

I figured it out. We had two versions of ASP.Net Zero running on the same server. One version is and MVC/jQuery site and the other is a .NET Core/jQuery site. It appears that the .NET Core site sets a couple of anti-forgery tokens that the MVC5 site doesn't like.

Thank you!

Showing 51 to 59 of 59 entries