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

Activities of "ivanosw1"

Hi, I haven't yet received response to my question, but after many days of real work on framework, I think that your answer This is not the expected behaviour. means a different thing that I supposed.

Further test with Host and Tenant data, seems to confirm that every query against Host data is always executed on initial Host database and never against remote databases.

Can you kindly confirm that ?

I try to explain better because I don't know if is an ABP related behaviour. The scenario is very simple: ABP Clock provider is Unspecified as default. My application doesn't manage any timezone because is used only in the same region. The client is Angular2 and there are 2 methods on application service: one GET and one POST. The DTO is the same with two fields: Id (int) and StartDate (DateTime). Supposed that 'new Date()' is Thu Apr 20 2017 08:52:50 GMT+0200 (ora legale Europa occidentale), the StartDate sent over internet is "2017-04-20T06:52:50.324Z" serialized by JSON.stringify(). On the server side the GET method deserialize correctly in 2017-04-20 08:52:50, while the POST method deserialize in 2017-04-20 06:52:50. It seems the the ISO format is threated differently.

So, the question is: which is the correct way to deserialize the client dates? There is some example explanatory? Thanks Ivano

I don't use UtcClockProvider. My goal is simply to write and read data exactly how client sent to server by an angular2 app.

<a class="postlink" href="http://.../api/services/app/api/getvalues?id=1&StartDate=2017-04-17T22%3A00%3A00.000Z">http://.../api/services/app/api/getvalu ... %3A00.000Z</a> If method receive the dto by querystring, startdate is correctly parsed in 2017-04-18 00:00:00 (Italian time zone) If method receive the dto by post, startdate is the same as input, 2017-04-17 22:00:00.

We are planning to move from local to azure server and we are investigating how deal correctly with date and time.

Thanks

This is the code. A simple list of items shared between host and tenant. Tenant is on separated database. I would like to manage only one host list for every tenant either local or separate. Host and Tenant 1 on DB1 Tenant2 on DB2

// This call is authenticated as Tenant2 and host items are retrived from host table in DB2.

var dtos = new List<DossierStateTypeDto>();

        // Host 
        using (CurrentUnitOfWork.SetTenantId(null)) 
        {
            var hostItems = await dossierStateTypeRepository.GetAllListAsync();
            dtos.AddRange(hostItems.MapTo&lt;List&lt;DossierStateTypeDto&gt;>());
        }

        // Tenant
        var tenantItems = await dossierStateTypeRepository.GetAllListAsync();
        dtos.AddRange(tenantItems.MapTo&lt;List&lt;DossierStateTypeDto&gt;>());

        var result = new ListResultDto&lt;DossierStateTypeDto&gt;(dtos);
        return result;

Thanks, Ivano

Hi,

The module is outside of abpzero template solution (host). The scenario is that many developers build their own plugins and at the end all plugins are deployed on a remote server. Nobody can access to the host solutions.

I've resolved in this manner :

  • created a nuget package from abpzero core module.
  • referenced this package on our core plugin module
  • set DependsOn to abpzero core module

It seems to work fine and when you improve abpzero template, we need only to upgrade the nuget package.

Do you think is a correct way ?

Shure, it's very simple. Only one table CuwPermission. I wuold like to use IRepository<Role>, IRepository<User>, and so on.

public class CartellaUtenteWebContext: AbpDbContext { public virtual DbSet<CuwPermission> CuwPermissions { get; set; }

    /* Default constructor is needed for EF command line tool. */
    public CartellaUtenteWebContext()
        : base(GetConnectionString())
    {

    }

.... omitted ctors code

DomainService where I need Role Repository:

public class CuwRoleDomainService: DomainService, ICuwRoleDomainService { private readonly IRepository<Role> roleRepository; public CuwRoleDomainService(IRepository<Role> roleRepository) { this.roleRepository = roleRepository; }

    public async Task&lt;Role&gt; GetRoleAsync(int roleId)
    {
        var result = await roleRepository.FirstOrDefaultAsync(roleId);
        return result;
    }
}

Thanks

Ok guys. I got it.

Sorry for my inexperience. I didn't know the Google+ API must be enabled on google api manager. Once enabled google auth works like a charm.

Thank you so much.

Thanks for response.

I've changed the code. The call flow is same as before but I can give you more informations:

  • On gapi.auth2.getAuthInstance().isSignedIn.listen((isSignedIn) , isSignedIn is true;
  • this._tokenAuthService is type of TokenAuthServiceProxy
  • post to <a class="postlink" href="http://localhost:22742/api/TokenAuth/ExternalAuthenticate">http://localhost:22742/api/TokenAuth/Ex ... thenticate</a> return http 500 and the server error is System.Net.Http.HttpRequestException: Response status code does not indicate success: 403 (Forbidden). in System.Net.Http.HttpResponseMessage.EnsureSuccessStatusCode() in Softwareuno.unoins.Web.Authentication.External.Google.GoogleAuthProviderApi.<GetUserInfo>d__1.MoveNext() in C:\Uno\Boilerplate\PhoneBook\aspnet-core\src\Softwareuno.unoins.Web.Core\Authentication\External\Google\GoogleAuthProviderApi.cs:riga 30

I hope this can help you. Thanks

Hi, is there something not much clear in my question that nobody can answer ?

How can I obtain support on this issue?

Showing 111 to 119 of 119 entries