Ends in:
6 DAYS
8 HRS
10 MIN
7 SEC
Ends in:
6 D
8 H
10 M
7 S

Activities of "RonaldR"

Question
  • ABP Framework version: v4.2.2

  • UI type: MVC

  • DB provider: EF Core

  • Tiered (MVC) or Identity Server Separated (Angular): no

  • Exception message and stack trace:

  • Steps to reproduce the issue:

  • I am trying to upload a file, should be simple enough. i have this controller:

  • public class SourceOfTruthAttributesAppService : ApplicationService
    

    {

      public async Task<IActionResult> PostUploadFile([FromBody]IFormFile file)
      {
          try
          {
              using (var stream = new MemoryStream())
              {
                  await file.CopyToAsync(stream);
              }
    
              return new OkResult();
          }
          catch (Exception ex)
          {
              return new BadRequestObjectResult(ex.Message);
          }
      }
    

    }

    i have this jquery code: $("#but_upload").click(function () { event.preventDefault();

      alert('begin upload');
    
      if ($('#file').length == 0) {
          alert('No file to upload');
          return;
      }
    
      var fd = new FormData();
      var file = $('#file')[0].files[0];
      fd.append('file', file);
    
      abp.ajax({
          type: 'POST',
          data: fd,
          processData: false,
          contentType: false,
          url: "/api/app/source-of-truth-attributes/upload-file",
      }).then(function (result) {
          alert('your file has been uploaded');
          location.reload();
      });
    

    })

    it works with null in the data, but when i try to pass the file in to the data i get the following error: jquery.js?_v=637504727666307175:9600 POST https://localhost:44355/api/app/source-of-truth-attributes/upload-file 415 send @ jquery.js?_v=637504727666307175:9600 ajax @ jquery.js?_v=637504727666307175:9206 (anonymous) @ abp.jquery.js?_v=637504727661778549:112 Deferred @ jquery.js?_v=637504727666307175:3751 abp.ajax @ abp.jquery.js?_v=637504727661778549:111 (anonymous) @ index.js?_v=637549962657651648:58 dispatch @ jquery.js?_v=637504727666307175:5183 elemData.handle @ jquery.js?_v=637504727666307175:4991

    what am i doing wrong? thanks

  • ABP Framework version: v4.2
  • UI type: MVC
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): no
  • Exception message and stack trace:
  • Steps to reproduce the issue:
  • I have a data class and a model class. i sem calling createMap in the Profile class to set up my mapping. the problem i am having is there is a foreign key to another table and a member of the type for that table. when the data gets to the fron end the site data object is not in there. i added a SiteName field, which is the data i need on the UI. i altered the CreateMap by adding a ForMembet call. still not getting the name in the mapped data. here are the two modeks and the mapping:
public class SubnetDataModel : AuditedAggregateRoot<Guid>, IMultiTenant
{
    public Guid? TenantId { get; set; }
    public string Network { get; set; }
    public string MaskBit { get; set; }
    public string StartRange { get; set; }
    public string EndRange { get; set; }
    //public string Category { get; set; }
    public SiteDataModel SiteData { get; set; }
    [ForeignKey("SiteData")]
    public Guid? SiteId { get;  set; }
}

 public class SubnetModel : AuditedEntityDto<Guid>
{
    public string Network { get; set; }
    public string MaskBit { get; set; }
    public string StartRange { get; set; }
    public string EndRange { get; set; }
    //public SiteModel SiteData { get; set; }
    public Guid? SiteId { get; set; }
    public string SiteName { get; set; }
}

CreateMap<SubnetDataModel, SubnetModel>().ForMember(x => x.SiteName, y => y.MapFrom(src => src.SiteData.Name));
  • ABP Framework version: v4.2
  • UI type: MVC
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): no
  • Exception message and stack trace:
  • Steps to reproduce the issue:
  • I am able to login to the website using a username and password and tenantId. when i go to the api and try to login using /api/account/login
  • { "userNameOrEmailAddress": "Ronald", "password": "1q2w3E*", "rememberMe": true, "tenanId": "39f90dee-0f5e-0845-7356-36a8a3b8496d" }

application/json

when i run this from visual studio i get back a 400 with no data and when i run it from iis i get back a 400 and the response is the body of the html page to display a message: Internal Server Error

when the tenant that belongs to that id is selected and the user name and pasword are entered in the login screen it works fine. we have an extenral application that is trying to login using out applications user login, needs data from a couple of our APIs, so what am i doing wrong?

2021-04-12 12:48:47.821 -05:00 [INF] Executing endpoint 'Volo.Abp.Account.Public.Web.Areas.Account.Controllers.AccountController.CheckPassword (Volo.Abp.Account.Pro.Public.Web)'
2021-04-12 12:48:47.831 -05:00 [INF] Route matched with {area = "account", controller = "Login", action = "CheckPassword", page = ""}. Executing controller action with signature System.Threading.Tasks.Task`1[Volo.Abp.Account.Public.Web.Areas.Account.Controllers.Models.AbpLoginResult] CheckPassword(Volo.Abp.Account.Public.Web.Areas.Account.Controllers.Models.UserLoginInfo) on controller Volo.Abp.Account.Public.Web.Areas.Account.Controllers.AccountController (Volo.Abp.Account.Pro.Public.Web).
2021-04-12 12:48:47.843 -05:00 [ERR] The required antiforgery header value "RequestVerificationToken" is not present.
2021-04-12 12:48:47.844 -05:00 [INF] Authorization failed for the request at filter 'Volo.Abp.AspNetCore.Mvc.AntiForgery.AbpAutoValidateAntiforgeryTokenAuthorizationFilter'.
2021-04-12 12:48:47.857 -05:00 [INF] Executing HttpStatusCodeResult, setting HTTP status code 400
2021-04-12 12:48:47.857 -05:00 [INF] Executed action Volo.Abp.Account.Public.Web.Areas.Account.Controllers.AccountController.CheckPassword (Volo.Abp.Account.Pro.Public.Web) in 20.2611ms
2021-04-12 12:48:47.857 -05:00 [INF] Executed endpoint 'Volo.Abp.Account.Public.Web.Areas.Account.Controllers.AccountController.CheckPassword (Volo.Abp.Account.Pro.Public.Web)'
2021-04-12 12:48:47.914 -05:00 [INF] Request finished HTTP/1.1 POST http://localhost/api/account/checkPassword application/json 123 - 302 - - 161.6186ms
2021-04-12 12:48:47.927 -05:00 [INF] Request starting HTTP/1.1 GET http://localhost/Error?httpStatusCode=400 - -
2021-04-12 12:48:47.970 -05:00 [INF] Executing endpoint 'Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Controllers.ErrorController.Index (Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared)'
2021-04-12 12:48:47.978 -05:00 [INF] Route matched with {action = "Index", controller = "Error", area = "", page = ""}. Executing controller action with signature System.Threading.Tasks.Task`1[Microsoft.AspNetCore.Mvc.IActionResult] Index(Int32) on controller Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Controllers.ErrorController (Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared).
2021-04-12 12:48:48.808 -05:00 [INF] Executing ViewResult, running view ~/Views/Error/Default.cshtml.
2021-04-12 12:48:48.894 -05:00 [INF] Authorization failed. These requirements were not met:
PermissionRequirement: AbpIdentity.SettingManagement
2021-04-12 12:48:48.897 -05:00 [INF] Authorization failed. These requirements were not met:
PermissionRequirement: LeptonThemeManagement.Settings
2021-04-12 12:48:48.899 -05:00 [INF] Authorization failed. These requirements were not met:
PermissionRequirement: AbpAccount.SettingManagement
2021-04-12 12:48:48.899 -05:00 [INF] Authorization failed. These requirements were not met:
PermissionRequirement: AbpIdentity.Roles
2021-04-12 12:48:48.900 -05:00 [INF] Authorization failed. These requirements were not met:
PermissionRequirement: AbpIdentity.Users
2021-04-12 12:48:48.900 -05:00 [INF] Authorization failed. These requirements were not met:
PermissionRequirement: AbpIdentity.OrganizationUnits
2021-04-12 12:48:48.900 -05:00 [INF] Authorization failed. These requirements were not met:
PermissionRequirement: AbpIdentity.ClaimTypes
2021-04-12 12:48:48.900 -05:00 [INF] Authorization failed. These requirements were not met:
PermissionRequirement: AbpIdentity.SecurityLogs
2021-04-12 12:48:48.900 -05:00 [INF] Authorization failed. These requirements were not met:
PermissionRequirement: AuditLogging.AuditLogs
2021-04-12 12:48:48.902 -05:00 [INF] Authorization failed. These requirements were not met:
PermissionRequirement: Saas.Tenants
2021-04-12 12:48:48.908 -05:00 [INF] Authorization failed. These requirements were not met:
PermissionRequirement: IdentityServer.Client
2021-04-12 12:48:48.909 -05:00 [INF] Authorization failed. These requirements were not met:
PermissionRequirement: IdentityServer.ApiResource
2021-04-12 12:48:48.909 -05:00 [INF] Authorization failed. These requirements were not met:
PermissionRequirement: IdentityServer.IdentityResource
2021-04-12 12:48:48.909 -05:00 [INF] Authorization failed. These requirements were not met:
PermissionRequirement: IdentityServer.ApiScope
2021-04-12 12:48:48.909 -05:00 [INF] Authorization failed. These requirements were not met:
PermissionRequirement: LanguageManagement.Languages
2021-04-12 12:48:48.909 -05:00 [INF] Authorization failed. These requirements were not met:
PermissionRequirement: LanguageManagement.LanguageTexts
2021-04-12 12:48:48.909 -05:00 [INF] Authorization failed. These requirements were not met:
PermissionRequirement: TextTemplateManagement.TextTemplates
2021-04-12 12:48:48.918 -05:00 [INF] Authorization failed. These requirements were not met:
DenyAnonymousAuthorizationRequirement: Requires an authenticated user.
2021-04-12 12:48:48.930 -05:00 [INF] Executed ViewResult - view ~/Views/Error/Default.cshtml executed in 126.0182ms.
2021-04-12 12:48:48.931 -05:00 [INF] Executed action Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Controllers.ErrorController.Index (Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared) in 951.9352ms
2021-04-12 12:48:48.931 -05:00 [INF] Executed endpoint 'Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Controllers.ErrorController.Index (Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared)'
2021-04-12 12:48:48.933 -05:00 [INF] Request finished HTTP/1.1 GET http://localhost/Error?httpStatusCode=400 - - - 400 - text/html;+charset=utf-8 1005.4083ms
  • ABP Framework version: v4.2
  • UI type: MVC
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): yes
  • Exception message and stack trace:
  • Steps to reproduce the issue:
  • When i run in visual studio i am able to log in. when i publish, the login spins and the login page is returned, it is not logging me in. there is no error messge, no errors in the log. i am running on windows in iis. i did install the .net 5 hosting runtime. i doubt it is .net environment, the site is comig up, and i can set the tenant, so it is running and hitting the database. in the app settings i changed the self and the authority to localhost, sine it is using the port 80 website. below find the log file but i do not see any clue a to why it is not working: I could not paste th log here, it is too long, here is a dropbox link to it https://www.dropbox.com/s/twbg1rzu54qp1h3/logs.txt?dl=0

Check the docs before asking a question: https://docs.abp.io/en/commercial/latest/ Check the samples, to see the basic tasks: https://docs.abp.io/en/commercial/latest/samples/index The exact solution to your question may have been answered before, please use the search on the homepage.

  • ABP Framework version: v4.2.2
  • UI type: MVC
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): no
  • Exception message and stack trace:
  • Steps to reproduce the issue:
  • We have a role that is higher than admin. we use admin as an onsite administrator and they can do just about everything. however, we create a system role above that manager for our staff when needing to configure things that we do not want onsite managers to be able to do. what we have seen though is that admins have, and should have, access to the administrator -> identity management section. when they go to a user, though, they have the abiltiy to make someone system, even though that role is above theirs. where can i put my business logic to say system and assign system, admin, and user, but an admin can only assign admin and user?

Check the docs before asking a question: https://docs.abp.io/en/commercial/latest/ Check the samples, to see the basic tasks: https://docs.abp.io/en/commercial/latest/samples/index The exact solution to your question may have been answered before, please use the search on the homepage.

  • ABP Framework version: v4.1.2
  • UI type: MVC
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Seperated (Angular): no
  • Exception message and stack trace:
  • Steps to reproduce the issue:
  • We are using IActionFlters to put performance treacking in out api calls. we need to know the tenant information. i do not see how to get the tenant in there
  • In the WebModule we add this filter
  • context.Services.AddMvc(options => options.Filters.Add(new TrackPerformanceFilter(connStr, configuration)));
  • So it is not using DI, then we have data in the OnActionExecuting
public void OnActionExecuting(ActionExecutingContext context)
{
    var request = context.HttpContext.Request;

    string paramsList = string.Empty;
    foreach (var key in context.RouteData.Values?.Keys)
    {
        paramsList += $"{key}={(string)context.RouteData.Values[key]},";
    }

    if (string.IsNullOrEmpty(paramsList) == false)
    {
        paramsList = paramsList[0..^1];
    }

    PerformanceTrackingModel trackingInfo = new PerformanceTrackingModel
    {
        TenantId = Guid.NewGuid(),
        StartedDateTime = DateTime.UtcNow,
        ProcessName = request.Host.Host,
        UrlPath = request.Path,
        UrlMethod = request.Method,
        UrlParameters = paramsList
    };

    _tracker.StartTracking(trackingInfo);
}

But i do not see how i can get the tenant in this function

Question

Check the docs before asking a question: https://docs.abp.io/en/commercial/latest/ Check the samples, to see the basic tasks: https://docs.abp.io/en/commercial/latest/samples/index The exact solution to your question may have been answered before, please use the search on the homepage.

  • ABP Framework version: v4.1.2
  • UI type: MVC
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Seperated (Angular): yes
  • Exception message and stack trace:
  • Steps to reproduce the issue:
  • So the problem we are habing is we are invoking jobs through hangfire. i am assuming this problem exists everywhere but i know how to recreate it here.
  • In the function we do a lot of database work. we create a job with an id, then give that id to every record processed, then when we are done we update the dtatus of the job.
  • if there is an exception we log it and report the job failed.
  • what we have found is that if it hits the exception, no data is saved. this is partially the expected behavior.
  • When the function to create the job orlog an exception is called, we use an irepositoy, and we call save changes in those functions so that data should be saved.
  • we do not call the save changes at the end of our look unless it is successful.
  • what we find though is if it fails and we do not save changes in the main function and we exit out, none of the data saves, including the job, which we did call save changes after
  • we are not identifying this as unitofwork, andi looked at the backgroundjob interface and did not see execute as unitof work.
  • why would we be getting htis behavior? should anything done prior to the save changes be saved?
Question

Check the docs before asking a question: https://docs.abp.io/en/commercial/latest/ Check the samples, to see the basic tasks: https://docs.abp.io/en/commercial/latest/samples/index The exact solution to your question may have been answered before, please use the search on the homepage.

  • ABP Framework version: v3.0
  • UI type: MVC
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Seperated (Angular): yes
  • Exception message and stack trace:
  • Steps to reproduce the issue:
  • Is there a best practice for building a ui for the db migraor? the initial time we run it there are questions we would like to ask to properly initialize the data with a user and tenant.
  • Also, is there a way that i can invoce the migrator, or parts of it, programaticaly? when a new tenant is added we need to run it in the database to setup menuing ans security for the new tenant, or we need to run it to create the new tenant database. so what we are trying to do is if a new tenant is created, we want to be able to fire off that functionality. is there a best practice for this?

Check the docs before asking a question: https://docs.abp.io/en/commercial/latest/ Check the samples, to see the basic tasks: https://docs.abp.io/en/commercial/latest/samples/index The exact solution to your question may have been answered before, please use the search on the homepage.

  • ABP Framework version: v4.0
  • UI type: MVC
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Seperated (Angular): yes
  • Exception message and stack trace:
  • Steps to reproduce the issue:
  • I am trying to create a connection string resolver. i think inheriting the default one would solve my problem as i dont want to change the logic, i just need to decrypt an encrypted string. where would i implement this? do you have a good sample for me to look at?
Question

Check the docs before asking a question: https://docs.abp.io/en/commercial/latest/ Check the samples, to see the basic tasks: https://docs.abp.io/en/commercial/latest/samples/index The exact solution to your question may have been answered before, please use the search on the homepage.

  • ABP Framework version: v3.3.1
  • UI type: MVC
  • Tiered (MVC) or Identity Server Seperated (Angular): no
  • Exception message and stack trace:
  • Steps to reproduce the issue:
  • When we leave the site inactive for more than 15 minutes or there abouts it loses the identity. if i login then click on a page on the menu, then do nothing for 20 minutes then click on a new menu link, when it tries to rebuild the menus us use CurrentUser in the api to see who it logged in, but there is no user in there.
  • I tried adding this in the TFORMWebModule:
    context.Services.AddAuthentication()
                .AddCookie(options => {
                    options.SlidingExpiration = true;
                    options.ExpireTimeSpan = DateTimeOffset.UtcNow.AddHours(24).Offset;
                })
                .AddJwtBearer(options =>
                {
                    options.Authority = configuration["AuthServer:Authority"];
                    options.RequireHttpsMetadata = false;
                    options.Audience = "TFORM";
                });
        }

The AddJwtBearer was already there, i added the AddCookie setion, but that didnt work.

I alos checked the identity tables the accesstimeout and the identity timeout are all set to 31536000 so they shouldbe be expiring that quickly, i think thats about 8.5 hours, give or take.

so what am i missing?

Showing 1 to 10 of 15 entries
Made with ❤️ on ABP v9.1.0-preview. Updated on November 26, 2024, 12:49