mirror of https://github.com/abpframework/abp.git
626 changed files with 65540 additions and 3348 deletions
@ -0,0 +1,26 @@ |
|||
# Nightly Builds |
|||
|
|||
All framework & module packages are deployed to MyGet every night in weekdays. So, you can use or test the latest code without waiting the next release. |
|||
|
|||
## Configure Visual Studio |
|||
|
|||
> Requires Visual Studio 2017+ |
|||
|
|||
1. Go to `Tools > Options > NuGet Package Manager > Package Source`. |
|||
2. Click the green `+` icon. |
|||
3. Set `ABP Nightly` as *Name* and `https://www.myget.org/F/abp-nightly/api/v3/index.json` as the *Source* as shown below: |
|||
 |
|||
4. Click the `Update` button. |
|||
5. Click the `OK` button to save changes. |
|||
|
|||
## Install Package |
|||
|
|||
Now, you can install preview / nightly packages to your project from Nuget Browser or Package Manager Console. |
|||
|
|||
 |
|||
|
|||
1. In the nuget browser, select "Include prereleases". |
|||
2. Change package source to "All". |
|||
3. Search a package. You will see prereleases of the package formatted as `(VERSION)-preview(DATE)` (like *v0.16.0-preview20190401* in this sample). |
|||
4. You can click to the `Install` button to add package to your project. |
|||
|
|||
|
After Width: | Height: | Size: 6.4 KiB |
|
After Width: | Height: | Size: 6.3 KiB |
|
After Width: | Height: | Size: 23 KiB |
|
After Width: | Height: | Size: 29 KiB |
@ -1,9 +1,11 @@ |
|||
{ |
|||
"culture": "pt-BR", |
|||
"texts": { |
|||
"GivenTenantIsNotAvailable": "Tenant não está disponível: {0}", |
|||
"SwitchTenant": "Trocar tenant", |
|||
"GivenTenantIsNotAvailable": "Inquilino não está disponível: {0}", |
|||
"Tenant": "Inquilino", |
|||
"Switch": "trocar", |
|||
"Name": "Nome", |
|||
"SwitchTenantHint": "Deixe o campo de nome em branco para alternar para o lado do host." |
|||
"SwitchTenantHint": "Deixe o campo de nome em branco para alternar para o lado do host.", |
|||
"NotSelected": "Não selecionado" |
|||
} |
|||
} |
|||
@ -0,0 +1,9 @@ |
|||
namespace Volo.Abp.Caching |
|||
{ |
|||
public interface IDistributedCacheSerializer |
|||
{ |
|||
byte[] Serialize<T>(T obj); |
|||
|
|||
T Deserialize<T>(byte[] bytes); |
|||
} |
|||
} |
|||
@ -0,0 +1,26 @@ |
|||
using System.Text; |
|||
using Volo.Abp.DependencyInjection; |
|||
using Volo.Abp.Json; |
|||
|
|||
namespace Volo.Abp.Caching |
|||
{ |
|||
public class Utf8JsonDistributedCacheSerializer : IDistributedCacheSerializer, ITransientDependency |
|||
{ |
|||
protected IJsonSerializer JsonSerializer { get; } |
|||
|
|||
public Utf8JsonDistributedCacheSerializer(IJsonSerializer jsonSerializer) |
|||
{ |
|||
JsonSerializer = jsonSerializer; |
|||
} |
|||
|
|||
public byte[] Serialize<T>(T obj) |
|||
{ |
|||
return Encoding.UTF8.GetBytes(JsonSerializer.Serialize(obj)); |
|||
} |
|||
|
|||
public T Deserialize<T>(byte[] bytes) |
|||
{ |
|||
return (T)JsonSerializer.Deserialize(typeof(T), Encoding.UTF8.GetString(bytes)); |
|||
} |
|||
} |
|||
} |
|||
@ -1,18 +1,14 @@ |
|||
namespace Volo.Abp.Emailing |
|||
using System.Threading.Tasks; |
|||
|
|||
namespace Volo.Abp.Emailing |
|||
{ |
|||
/// <summary>
|
|||
/// Defines configurations used while sending emails.
|
|||
/// </summary>
|
|||
public interface IEmailSenderConfiguration |
|||
{ |
|||
/// <summary>
|
|||
/// Default from address.
|
|||
/// </summary>
|
|||
string DefaultFromAddress { get; } |
|||
|
|||
/// <summary>
|
|||
/// Default display name.
|
|||
/// </summary>
|
|||
string DefaultFromDisplayName { get; } |
|||
Task<string> GetDefaultFromAddressAsync(); |
|||
|
|||
Task<string> GetDefaultFromDisplayNameAsync(); |
|||
} |
|||
} |
|||
@ -0,0 +1,25 @@ |
|||
using System.Security.Claims; |
|||
using JetBrains.Annotations; |
|||
using Volo.Abp.MultiTenancy; |
|||
|
|||
namespace System.Security.Principal |
|||
{ |
|||
public static class AbpMultiTenancyClaimsIdentityExtensions |
|||
{ |
|||
public static MultiTenancySides GetMultiTenancySide([NotNull] this IIdentity identity) |
|||
{ |
|||
var tenantId = identity.FindTenantId(); |
|||
return tenantId.HasValue |
|||
? MultiTenancySides.Tenant |
|||
: MultiTenancySides.Host; |
|||
} |
|||
|
|||
public static MultiTenancySides GetMultiTenancySide([NotNull] this ClaimsPrincipal principal) |
|||
{ |
|||
var tenantId = principal.FindTenantId(); |
|||
return tenantId.HasValue |
|||
? MultiTenancySides.Tenant |
|||
: MultiTenancySides.Host; |
|||
} |
|||
} |
|||
} |
|||
@ -1,28 +0,0 @@ |
|||
using System.Linq; |
|||
using Microsoft.Extensions.DependencyInjection; |
|||
using Volo.Abp.Security.Claims; |
|||
|
|||
namespace Volo.Abp.MultiTenancy |
|||
{ |
|||
public class CurrentClaimsPrincipalTenantResolveContributor : TenantResolveContributorBase |
|||
{ |
|||
public const string ContributorName = "CurrentClaims"; |
|||
|
|||
public override string Name => ContributorName; |
|||
|
|||
public override void Resolve(ITenantResolveContext context) |
|||
{ |
|||
var principal = context.ServiceProvider.GetRequiredService<ICurrentPrincipalAccessor>().Principal; |
|||
if (principal?.Identity?.IsAuthenticated != true) |
|||
{ |
|||
return; |
|||
} |
|||
|
|||
context.Handled = true; |
|||
context.TenantIdOrName = principal |
|||
.Claims |
|||
.FirstOrDefault(c => c.Type == AbpClaimTypes.TenantId) |
|||
?.Value; |
|||
} |
|||
} |
|||
} |
|||
@ -0,0 +1,24 @@ |
|||
using Microsoft.Extensions.DependencyInjection; |
|||
using Volo.Abp.Users; |
|||
|
|||
namespace Volo.Abp.MultiTenancy |
|||
{ |
|||
public class CurrentUserTenantResolveContributor : TenantResolveContributorBase |
|||
{ |
|||
public const string ContributorName = "CurrentUser"; |
|||
|
|||
public override string Name => ContributorName; |
|||
|
|||
public override void Resolve(ITenantResolveContext context) |
|||
{ |
|||
var currentUser = context.ServiceProvider.GetRequiredService<ICurrentUser>(); |
|||
if (currentUser.IsAuthenticated != true) |
|||
{ |
|||
return; |
|||
} |
|||
|
|||
context.Handled = true; |
|||
context.TenantIdOrName = currentUser.TenantId?.ToString(); |
|||
} |
|||
} |
|||
} |
|||
@ -1,9 +1,10 @@ |
|||
using Volo.Abp.MultiTenancy; |
|||
using JetBrains.Annotations; |
|||
|
|||
namespace Volo.Abp.AspNetCore.MultiTenancy |
|||
namespace Volo.Abp.MultiTenancy |
|||
{ |
|||
public interface ITenantResolveResultAccessor |
|||
{ |
|||
[CanBeNull] |
|||
TenantResolveResult Result { get; set; } |
|||
} |
|||
} |
|||
@ -0,0 +1,13 @@ |
|||
using Volo.Abp.DependencyInjection; |
|||
|
|||
namespace Volo.Abp.MultiTenancy |
|||
{ |
|||
public class NullTenantResolveResultAccessor : ITenantResolveResultAccessor, ISingletonDependency |
|||
{ |
|||
public TenantResolveResult Result |
|||
{ |
|||
get => null; |
|||
set { } |
|||
} |
|||
} |
|||
} |
|||
@ -1,9 +1,10 @@ |
|||
using JetBrains.Annotations; |
|||
using System.Threading.Tasks; |
|||
using JetBrains.Annotations; |
|||
|
|||
namespace Volo.Abp.Ui.Navigation.Urls |
|||
{ |
|||
public interface IAppUrlProvider |
|||
{ |
|||
string GetUrl([NotNull] string appName, [CanBeNull] string urlName = null); |
|||
Task<string> GetUrlAsync([NotNull] string appName, [CanBeNull] string urlName = null); |
|||
} |
|||
} |
|||
|
|||
@ -1,6 +1,7 @@ |
|||
{ |
|||
"culture": "pt-BR", |
|||
"texts": { |
|||
"BirthDate": "Aniversário" |
|||
"BirthDate": "Aniversário", |
|||
"Value1": "Valor Um" |
|||
} |
|||
} |
|||
@ -1,6 +1,7 @@ |
|||
{ |
|||
"culture": "en", |
|||
"texts": { |
|||
"USA": "United States of America" |
|||
"USA": "United States of America", |
|||
"Brazil": "Brasil" |
|||
} |
|||
} |
|||
@ -0,0 +1,11 @@ |
|||
using System; |
|||
using System.Collections.Generic; |
|||
using System.Text; |
|||
|
|||
namespace Volo.Abp.AuditLogging.EntityFrameworkCore |
|||
{ |
|||
public class AuditLogRepository_Tests : AuditLogRepository_Tests<AbpAuditLoggingEntityFrameworkCoreTestModule> |
|||
{ |
|||
|
|||
} |
|||
} |
|||
@ -0,0 +1,11 @@ |
|||
using System; |
|||
using System.Collections.Generic; |
|||
using System.Text; |
|||
|
|||
namespace Volo.Abp.AuditLogging.MongoDB |
|||
{ |
|||
public class AuditLogRepository_Tests : AuditLogRepository_Tests<AbpAuditLoggingMongoDbTestModule> |
|||
{ |
|||
|
|||
} |
|||
} |
|||
Some files were not shown because too many files changed in this diff
Loading…
Reference in new issue