mirror of https://github.com/abpframework/eventhub
601 changed files with 117138 additions and 296 deletions
@ -0,0 +1,33 @@ |
|||
<Project Sdk="Microsoft.NET.Sdk.BlazorWebAssembly"> |
|||
|
|||
<PropertyGroup> |
|||
<TargetFramework>net10.0</TargetFramework> |
|||
<Nullable>disable</Nullable> |
|||
<RootNamespace>EventHub.Admin.Web</RootNamespace> |
|||
<BlazorWebAssemblyLoadAllGlobalizationData>true</BlazorWebAssemblyLoadAllGlobalizationData> |
|||
</PropertyGroup> |
|||
|
|||
<ItemGroup> |
|||
<ProjectReference Include="..\EventHub.Admin.HttpApi.Client\EventHub.Admin.HttpApi.Client.csproj" /> |
|||
<ProjectReference Include="..\..\modules\payment\src\Payment.Admin.Blazor\Payment.Admin.Blazor.csproj" /> |
|||
</ItemGroup> |
|||
|
|||
<ItemGroup> |
|||
<PackageReference Include="Blazorise.Bootstrap5" Version="2.1.3" /> |
|||
<PackageReference Include="Blazorise.Icons.FontAwesome" Version="2.1.3" /> |
|||
<PackageReference Include="Blazorise.Components" Version="2.1.3" /> |
|||
<PackageReference Include="IdentityModel" Version="7.0.0" /> |
|||
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" Version="10.0.9" /> |
|||
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="10.0.9" /> |
|||
</ItemGroup> |
|||
|
|||
<ItemGroup> |
|||
<PackageReference Include="Volo.Abp.AutoMapper" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.Autofac.WebAssembly" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.AspNetCore.Components.WebAssembly.BasicTheme" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.Identity.Blazor.WebAssembly" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.SettingManagement.Blazor.WebAssembly" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.FeatureManagement.Blazor.WebAssembly" Version="10.4.1" /> |
|||
</ItemGroup> |
|||
|
|||
</Project> |
|||
@ -0,0 +1,107 @@ |
|||
using System; |
|||
using System.Net.Http; |
|||
using Blazorise.Bootstrap5; |
|||
using Blazorise.Icons.FontAwesome; |
|||
using EventHub.Admin.Web.Menus; |
|||
using Microsoft.AspNetCore.Components.WebAssembly.Hosting; |
|||
using Microsoft.Extensions.Configuration; |
|||
using Microsoft.Extensions.DependencyInjection; |
|||
using Payment.Admin; |
|||
using Volo.Abp.AspNetCore.Components.Web; |
|||
using Volo.Abp.AspNetCore.Components.Web.Theming.Routing; |
|||
using Volo.Abp.AspNetCore.Components.WebAssembly; |
|||
using Volo.Abp.AspNetCore.Components.WebAssembly.BasicTheme; |
|||
using Volo.Abp.Autofac.WebAssembly; |
|||
using Volo.Abp.AutoMapper; |
|||
using Volo.Abp.FeatureManagement.Blazor.WebAssembly; |
|||
using Volo.Abp.Identity.Blazor.WebAssembly; |
|||
using Volo.Abp.Modularity; |
|||
using Volo.Abp.SettingManagement.Blazor.WebAssembly; |
|||
using Volo.Abp.UI.Navigation; |
|||
|
|||
namespace EventHub.Admin.Web |
|||
{ |
|||
[DependsOn( |
|||
typeof(AbpAutofacWebAssemblyModule), |
|||
typeof(EventHubAdminHttpApiClientModule), |
|||
typeof(AbpAspNetCoreComponentsWebAssemblyBasicThemeModule), |
|||
typeof(AbpIdentityBlazorWebAssemblyModule), |
|||
typeof(AbpSettingManagementBlazorWebAssemblyModule), |
|||
typeof(AbpFeatureManagementBlazorWebAssemblyModule), |
|||
typeof(PaymentAdminBlazorModule), |
|||
typeof(AbpAutoMapperModule) |
|||
)] |
|||
public class EventHubBlazorClientModule : AbpModule |
|||
{ |
|||
public override void PreConfigureServices(ServiceConfigurationContext context) |
|||
{ |
|||
PreConfigure<AbpAspNetCoreComponentsWebOptions>(options => |
|||
{ |
|||
options.IsBlazorWebApp = true; |
|||
}); |
|||
} |
|||
|
|||
public override void ConfigureServices(ServiceConfigurationContext context) |
|||
{ |
|||
var environment = context.Services.GetSingletonInstance<IWebAssemblyHostEnvironment>(); |
|||
var builder = context.Services.GetSingletonInstance<WebAssemblyHostBuilder>(); |
|||
|
|||
ConfigureAuthentication(builder); |
|||
ConfigureHttpClient(context, environment); |
|||
ConfigureBlazorise(context); |
|||
ConfigureRouter(context); |
|||
ConfigureMenu(context); |
|||
ConfigureAutoMapper(context); |
|||
} |
|||
|
|||
private void ConfigureRouter(ServiceConfigurationContext context) |
|||
{ |
|||
Configure<AbpRouterOptions>(options => |
|||
{ |
|||
options.AppAssembly = typeof(EventHubBlazorClientModule).Assembly; |
|||
options.AdditionalAssemblies.Add(typeof(EventHubBlazorClientModule).Assembly); |
|||
}); |
|||
} |
|||
|
|||
private void ConfigureMenu(ServiceConfigurationContext context) |
|||
{ |
|||
Configure<AbpNavigationOptions>(options => |
|||
{ |
|||
options.MenuContributors.Add(new EventHubMenuContributor(context.Services.GetConfiguration())); |
|||
}); |
|||
} |
|||
|
|||
private void ConfigureBlazorise(ServiceConfigurationContext context) |
|||
{ |
|||
context.Services |
|||
.AddBootstrap5Providers() |
|||
.AddFontAwesomeIcons(); |
|||
} |
|||
|
|||
private static void ConfigureAuthentication(WebAssemblyHostBuilder builder) |
|||
{ |
|||
builder.Services.AddBlazorWebAppServices(); |
|||
} |
|||
|
|||
private static void ConfigureHttpClient(ServiceConfigurationContext context, IWebAssemblyHostEnvironment environment) |
|||
{ |
|||
context.Services.AddTransient(sp => new HttpClient |
|||
{ |
|||
BaseAddress = new Uri(environment.BaseAddress) |
|||
}); |
|||
} |
|||
|
|||
private void ConfigureAutoMapper(ServiceConfigurationContext context) |
|||
{ |
|||
Configure<AbpAutoMapperOptions>(options => |
|||
{ |
|||
options.AddMaps<EventHubBlazorClientModule>(); |
|||
}); |
|||
|
|||
// Some depended-on ABP modules migrated to Mapperly and replace the default
|
|||
// IAutoObjectMappingProvider. Re-assert AutoMapper as this app's default so
|
|||
// the application's own AutoMapper profiles keep working regardless of load order.
|
|||
context.Services.AddAutoMapperObjectMapper(); |
|||
} |
|||
} |
|||
} |
|||
@ -0,0 +1,24 @@ |
|||
using System.Threading.Tasks; |
|||
using Microsoft.AspNetCore.Components.WebAssembly.Hosting; |
|||
|
|||
namespace EventHub.Admin.Web |
|||
{ |
|||
public class Program |
|||
{ |
|||
public static async Task Main(string[] args) |
|||
{ |
|||
var builder = WebAssemblyHostBuilder.CreateDefault(args); |
|||
|
|||
var application = await builder.AddApplicationAsync<EventHubBlazorClientModule>(options => |
|||
{ |
|||
options.UseAutofac(); |
|||
}); |
|||
|
|||
var host = builder.Build(); |
|||
|
|||
await application.InitializeApplicationAsync(host.Services); |
|||
|
|||
await host.RunAsync(); |
|||
} |
|||
} |
|||
} |
|||
@ -0,0 +1,13 @@ |
|||
@using Volo.Abp.AspNetCore.Components.Web.BasicTheme.Themes.Basic |
|||
@using Volo.Abp.AspNetCore.Components.Web.Theming.Routing |
|||
@using Microsoft.Extensions.Options |
|||
@inject IOptions<AbpRouterOptions> RouterOptions |
|||
<Router AppAssembly="typeof(Program).Assembly" AdditionalAssemblies="RouterOptions.Value.AdditionalAssemblies"> |
|||
<Found Context="routeData"> |
|||
<AuthorizeRouteView RouteData="routeData" DefaultLayout="typeof(MainLayout)"> |
|||
<NotAuthorized> |
|||
<RedirectToLogin /> |
|||
</NotAuthorized> |
|||
</AuthorizeRouteView> |
|||
</Found> |
|||
</Router> |
|||
@ -0,0 +1,17 @@ |
|||
@using System.Net.Http |
|||
@using Microsoft.AspNetCore.Authorization |
|||
@using Microsoft.AspNetCore.Components.Authorization |
|||
@using Microsoft.AspNetCore.Components.Forms |
|||
@using Microsoft.AspNetCore.Components.Routing |
|||
@using Microsoft.AspNetCore.Components.Web |
|||
@using static Microsoft.AspNetCore.Components.Web.RenderMode |
|||
@using Microsoft.AspNetCore.Components.WebAssembly.Http |
|||
@using Microsoft.JSInterop |
|||
@using Volo.Abp.AspNetCore.Components.Web |
|||
@using Volo.Abp.AspNetCore.Components.WebAssembly |
|||
@using EventHub.Admin.Web |
|||
@using Blazorise |
|||
@using Blazorise.DataGrid |
|||
@using Blazorise.Components |
|||
@using Volo.Abp.BlazoriseUI |
|||
@using Volo.Abp.BlazoriseUI.Components |
|||
@ -0,0 +1,11 @@ |
|||
{ |
|||
"AuthServer": { |
|||
"Authority": "https://localhost:44313", |
|||
"ClientId": "EventHub_Blazor" |
|||
}, |
|||
"RemoteServices": { |
|||
"Default": { |
|||
"BaseUrl": "https://localhost:44305" |
|||
} |
|||
} |
|||
} |
|||
@ -0,0 +1,60 @@ |
|||
@using System.Globalization |
|||
@using Microsoft.Extensions.Hosting |
|||
@using Volo.Abp.AspNetCore.Components.Server.BasicTheme.Bundling |
|||
@using Volo.Abp.Localization |
|||
@using Volo.Abp.AspNetCore.Components.Web.Theming.Bundling |
|||
@inject IHostEnvironment Env |
|||
@{ |
|||
var rtl = CultureHelper.IsRtl ? "rtl" : string.Empty; |
|||
} |
|||
|
|||
<!DOCTYPE html> |
|||
<html lang="@CultureInfo.CurrentCulture.Name" dir="@rtl"> |
|||
<head> |
|||
<meta charset="utf-8" /> |
|||
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> |
|||
<title>EventHub Admin</title> |
|||
<base href="/" /> |
|||
|
|||
<AbpStyles BundleName="@BlazorBasicThemeBundles.Styles.Global" WebAssemblyStyleFiles="GlobalStyles" @rendermode="InteractiveAuto" /> |
|||
|
|||
<link href="EventHub.Admin.Web.styles.css" rel="stylesheet" /> |
|||
<link href="EventHub.Admin.Web.Client.styles.css" rel="stylesheet" /> |
|||
|
|||
<HeadOutlet @rendermode="InteractiveAuto" /> |
|||
</head> |
|||
<body class="abp-application-layout @rtl"> |
|||
|
|||
<Routes @rendermode="InteractiveAuto" /> |
|||
|
|||
<div id="blazor-error-ui"> |
|||
@if (Env.IsDevelopment()) |
|||
{ |
|||
<text>An unhandled exception has occurred. See browser dev tools for details.</text> |
|||
} |
|||
else |
|||
{ |
|||
<text>An error has occurred. This application may no longer respond until reloaded.</text> |
|||
} |
|||
<a href="" class="reload">Reload</a> |
|||
<a class="dismiss">×</a> |
|||
</div> |
|||
|
|||
<AbpScripts BundleName="@BlazorBasicThemeBundles.Scripts.Global" WebAssemblyScriptFiles="GlobalScripts" @rendermode="InteractiveAuto" /> |
|||
|
|||
<script src="_framework/blazor.web.js"></script> |
|||
|
|||
</body> |
|||
</html> |
|||
|
|||
@code{ |
|||
private List<string> GlobalStyles => |
|||
[ |
|||
"global.css" |
|||
]; |
|||
|
|||
private List<string> GlobalScripts => |
|||
[ |
|||
"global.js" |
|||
]; |
|||
} |
|||
@ -0,0 +1,27 @@ |
|||
using Microsoft.AspNetCore.Authentication; |
|||
using Microsoft.AspNetCore.Authentication.Cookies; |
|||
using Microsoft.AspNetCore.Authentication.OpenIdConnect; |
|||
using Microsoft.AspNetCore.Mvc; |
|||
using Volo.Abp.AspNetCore.Mvc; |
|||
|
|||
namespace EventHub.Admin.Web.Controllers |
|||
{ |
|||
[Route("[controller]/[action]")]
|
|||
public class AccountController : AbpController |
|||
{ |
|||
[HttpGet] |
|||
public IActionResult Login(string returnUrl = "/") |
|||
{ |
|||
return Challenge(new AuthenticationProperties { RedirectUri = returnUrl }, OpenIdConnectDefaults.AuthenticationScheme); |
|||
} |
|||
|
|||
[HttpGet] |
|||
public IActionResult Logout(string returnUrl = "/") |
|||
{ |
|||
return SignOut( |
|||
new AuthenticationProperties { RedirectUri = returnUrl }, |
|||
CookieAuthenticationDefaults.AuthenticationScheme, |
|||
OpenIdConnectDefaults.AuthenticationScheme); |
|||
} |
|||
} |
|||
} |
|||
@ -1,3 +1,4 @@ |
|||
{ |
|||
"role": "host.mvc" |
|||
"role": "host.mvc", |
|||
"projectId": "11b93e0c-ad7e-4f77-84db-8a7cb08cbfd7" |
|||
} |
|||
@ -1,32 +1,53 @@ |
|||
<Project Sdk="Microsoft.NET.Sdk.BlazorWebAssembly"> |
|||
<Project Sdk="Microsoft.NET.Sdk.Web"> |
|||
|
|||
<PropertyGroup> |
|||
<TargetFramework>net10.0</TargetFramework> |
|||
<BlazorWebAssemblyLoadAllGlobalizationData>true</BlazorWebAssemblyLoadAllGlobalizationData> |
|||
<Nullable>disable</Nullable> |
|||
<AspNetCoreHostingModel>InProcess</AspNetCoreHostingModel> |
|||
<PreserveCompilationReferences>true</PreserveCompilationReferences> |
|||
</PropertyGroup> |
|||
|
|||
<ItemGroup> |
|||
<ProjectReference Include="..\EventHub.Admin.Web.Client\EventHub.Admin.Web.Client.csproj" /> |
|||
<ProjectReference Include="..\EventHub.Admin.HttpApi.Client\EventHub.Admin.HttpApi.Client.csproj" /> |
|||
<ProjectReference Include="..\..\modules\payment\src\Payment.Admin.Blazor\Payment.Admin.Blazor.csproj" /> |
|||
</ItemGroup> |
|||
|
|||
<ItemGroup> |
|||
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.Server" Version="10.0.9" /> |
|||
<PackageReference Include="Blazorise.Bootstrap5" Version="2.1.3" /> |
|||
<PackageReference Include="Blazorise.Icons.FontAwesome" Version="2.1.3" /> |
|||
<PackageReference Include="IdentityModel" Version="7.0.0" /> |
|||
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" Version="10.0.9" /> |
|||
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="10.0.9" /> |
|||
<PackageReference Include="Serilog.AspNetCore" Version="9.0.0" /> |
|||
<PackageReference Include="Serilog.Sinks.Async" Version="2.1.0" /> |
|||
</ItemGroup> |
|||
|
|||
<ItemGroup> |
|||
<PackageReference Include="Volo.Abp.Autofac" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.AutoMapper" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.Autofac.WebAssembly" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.AspNetCore.Components.WebAssembly.BasicTheme" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.Identity.Blazor.WebAssembly" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.SettingManagement.Blazor.WebAssembly" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.Swashbuckle" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.AspNetCore.Serilog" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.AspNetCore.Authentication.OpenIdConnect" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.AspNetCore.Mvc.Client" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.Http.Client.Web" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.Http.Client.IdentityModel.Web" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.Account.HttpApi.Client" Version="10.4.1" /> |
|||
</ItemGroup> |
|||
|
|||
<ItemGroup> |
|||
<EmbeddedResource Include="wwwroot\**\*.*" /> |
|||
<PackageReference Include="Volo.Abp.Identity.Blazor.Server" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.SettingManagement.Blazor.Server" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.FeatureManagement.Blazor.Server" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.AspNetCore.Components.Server.BasicTheme" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.AspNetCore.Components.WebAssembly.BasicTheme.Bundling" Version="10.4.1" /> |
|||
<PackageReference Include="Volo.Abp.AspNetCore.Mvc.UI.Theme.Basic" Version="10.4.1" /> |
|||
</ItemGroup> |
|||
|
|||
<ItemGroup> |
|||
<Compile Remove="Logs\**" /> |
|||
<Content Remove="Logs\**" /> |
|||
<EmbeddedResource Remove="Logs\**" /> |
|||
<None Remove="Logs\**" /> |
|||
</ItemGroup> |
|||
|
|||
</Project> |
|||
|
|||
@ -1,16 +0,0 @@ |
|||
using Volo.Abp.Bundling; |
|||
|
|||
namespace EventHub.Admin.Web |
|||
{ |
|||
public class EventHubBundleContributor : IBundleContributor |
|||
{ |
|||
public void AddScripts(BundleContext context) |
|||
{ |
|||
} |
|||
|
|||
public void AddStyles(BundleContext context) |
|||
{ |
|||
context.Add("main.css", true); |
|||
} |
|||
} |
|||
} |
|||
@ -1,24 +1,55 @@ |
|||
using System; |
|||
using System.Threading.Tasks; |
|||
using Microsoft.AspNetCore.Components.WebAssembly.Hosting; |
|||
using Microsoft.AspNetCore.Builder; |
|||
using Microsoft.Extensions.DependencyInjection; |
|||
using Microsoft.Extensions.Hosting; |
|||
using Serilog; |
|||
using Volo.Abp; |
|||
|
|||
namespace EventHub.Admin.Web |
|||
{ |
|||
public class Program |
|||
{ |
|||
public static async Task Main(string[] args) |
|||
public async static Task<int> Main(string[] args) |
|||
{ |
|||
var builder = WebAssemblyHostBuilder.CreateDefault(args); |
|||
Log.Logger = new LoggerConfiguration() |
|||
.WriteTo.Async(c => c.File("Logs/logs.txt")) |
|||
.WriteTo.Async(c => c.Console()) |
|||
.CreateBootstrapLogger(); |
|||
|
|||
var application = builder.AddApplication<EventHubBlazorModule>(options => |
|||
try |
|||
{ |
|||
options.UseAutofac(); |
|||
}); |
|||
|
|||
var host = builder.Build(); |
|||
|
|||
await application.InitializeAsync(host.Services); |
|||
Log.Information("Starting web host."); |
|||
var builder = WebApplication.CreateBuilder(args); |
|||
builder.Host |
|||
.AddAppSettingsSecretsJson() |
|||
.UseAutofac() |
|||
.UseSerilog((context, services, loggerConfiguration) => |
|||
{ |
|||
loggerConfiguration |
|||
.ReadFrom.Configuration(context.Configuration) |
|||
.ReadFrom.Services(services); |
|||
}); |
|||
await builder.AddApplicationAsync<EventHubBlazorModule>(); |
|||
var app = builder.Build(); |
|||
await app.InitializeApplicationAsync(); |
|||
await app.RunAsync(); |
|||
return 0; |
|||
} |
|||
catch (Exception ex) |
|||
{ |
|||
if (ex is HostAbortedException) |
|||
{ |
|||
throw; |
|||
} |
|||
|
|||
await host.RunAsync(); |
|||
Log.Fatal(ex, "Host terminated unexpectedly!"); |
|||
return 1; |
|||
} |
|||
finally |
|||
{ |
|||
Log.CloseAndFlush(); |
|||
} |
|||
} |
|||
} |
|||
} |
|||
|
|||
@ -1,12 +1,15 @@ |
|||
@using System.Net.Http |
|||
@using System.Net.Http |
|||
@using Microsoft.AspNetCore.Authorization |
|||
@using Microsoft.AspNetCore.Components.Authorization |
|||
@using Microsoft.AspNetCore.Components.Forms |
|||
@using Microsoft.AspNetCore.Components.Routing |
|||
@using Microsoft.AspNetCore.Components.Web |
|||
@using Microsoft.AspNetCore.Components.WebAssembly.Http |
|||
@using Microsoft.AspNetCore.Components.Web.Virtualization |
|||
@using static Microsoft.AspNetCore.Components.Web.RenderMode |
|||
@using Microsoft.JSInterop |
|||
@using Volo.Abp.AspNetCore.Components.Web |
|||
@using EventHub.Admin.Web |
|||
@using EventHub.Admin.Web.Components |
|||
@using Blazorise |
|||
@using Blazorise.DataGrid |
|||
@using Volo.Abp.BlazoriseUI |
|||
@using Volo.Abp.BlazoriseUI.Components |
|||
@using Volo.Abp.BlazoriseUI.Components |
|||
|
|||
@ -0,0 +1,8 @@ |
|||
module.exports = { |
|||
aliases: { |
|||
}, |
|||
clean: [ |
|||
], |
|||
mappings: { |
|||
} |
|||
}; |
|||
@ -0,0 +1,12 @@ |
|||
{ |
|||
"version": "1.0.0", |
|||
"name": "eventhub-admin-web", |
|||
"private": true, |
|||
"dependencies": { |
|||
"@abp/aspnetcore.mvc.ui.theme.basic": "~10.4.1", |
|||
"@abp/aspnetcore.components.server.basictheme": "~10.4.1" |
|||
}, |
|||
"resolutions": { |
|||
"jquery": "3.7.1" |
|||
} |
|||
} |
|||
@ -1,13 +0,0 @@ |
|||
{ |
|||
"App": { |
|||
"SelfUrl": "https://admin.openeventhub.com" |
|||
}, |
|||
"AuthServer": { |
|||
"Authority": "https://account.openeventhub.com" |
|||
}, |
|||
"RemoteServices": { |
|||
"Default": { |
|||
"BaseUrl": "https://admin-api.openeventhub.com" |
|||
} |
|||
} |
|||
} |
|||
@ -1,13 +0,0 @@ |
|||
{ |
|||
"App": { |
|||
"SelfUrl": "https://eh-st-admin" |
|||
}, |
|||
"AuthServer": { |
|||
"Authority": "https://eh-st-account" |
|||
}, |
|||
"RemoteServices": { |
|||
"Default": { |
|||
"BaseUrl": "https://eh-st-admin-api" |
|||
} |
|||
} |
|||
} |
|||
@ -0,0 +1 @@ |
|||
/* Your Global Scripts */ |
|||
@ -0,0 +1,14 @@ |
|||
#blazor-error-ui { |
|||
background: lightyellow; |
|||
color: #212529; |
|||
bottom: 0; |
|||
box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2); |
|||
display: none; |
|||
left: 0; |
|||
padding: 0.6rem 1.25rem 0.7rem 1.25rem; |
|||
position: fixed; |
|||
width: 100%; |
|||
z-index: 1030; |
|||
} |
|||
#blazor-error-ui .reload { color: #0d6efd; text-decoration: underline; } |
|||
#blazor-error-ui .dismiss { cursor: pointer; position: absolute; right: 0.75rem; top: 0.5rem; } |
|||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -1,29 +0,0 @@ |
|||
<!DOCTYPE html> |
|||
<html> |
|||
|
|||
<head> |
|||
<meta charset="utf-8" /> |
|||
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" /> |
|||
<title>EventHub.Blazor</title> |
|||
<base href="/" /> |
|||
|
|||
<!--ABP:Styles--> |
|||
<link href="global.css?_v=638687548943400301" rel="stylesheet"/> |
|||
<link href="main.css" rel="stylesheet"/> |
|||
<!--/ABP:Styles--> |
|||
</head> |
|||
|
|||
<body class="abp-application-layout bg-light"> |
|||
<div id="ApplicationContainer"> |
|||
<div class="spinner"> |
|||
<div class="double-bounce1"></div> |
|||
<div class="double-bounce2"></div> |
|||
</div> |
|||
</div> |
|||
|
|||
<!--ABP:Scripts--> |
|||
<script src="global.js?_v=638687548945897695"></script> |
|||
<!--/ABP:Scripts--> |
|||
|
|||
</body> |
|||
</html> |
|||
File diff suppressed because it is too large
File diff suppressed because it is too large
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -0,0 +1,56 @@ |
|||
@keyframes spin { |
|||
0% { |
|||
transform: translateZ(0) rotate(0deg); |
|||
} |
|||
|
|||
100% { |
|||
transform: translateZ(0) rotate(360deg); |
|||
} |
|||
} |
|||
|
|||
.abp-block-area { |
|||
position: fixed; |
|||
top: 0; |
|||
left: 0; |
|||
width: 100%; |
|||
height: 100%; |
|||
z-index: 102; |
|||
background-color: #fff; |
|||
opacity: .8; |
|||
transition: opacity .25s; |
|||
} |
|||
|
|||
.abp-block-area.abp-block-area-disappearing { |
|||
opacity: 0; |
|||
} |
|||
|
|||
.abp-block-area.abp-block-area-busy:after { |
|||
content: attr(data-text); |
|||
display: block; |
|||
max-width: 125px; |
|||
position: absolute; |
|||
top: 50%; |
|||
left: 50%; |
|||
transform: translate(-50%, -50%); |
|||
font-size: 20px; |
|||
font-family: sans-serif; |
|||
color: #343a40; |
|||
text-align: center; |
|||
text-transform: uppercase; |
|||
} |
|||
|
|||
.abp-block-area.abp-block-area-busy:before { |
|||
content: ""; |
|||
display: block; |
|||
width: 150px; |
|||
height: 150px; |
|||
border-radius: 50%; |
|||
border-width: 2px; |
|||
border-style: solid; |
|||
border-color: transparent #228ae6 #228ae6 #228ae6; |
|||
position: absolute; |
|||
top: calc(50% - 75px); |
|||
left: calc(50% - 75px); |
|||
will-change: transform; |
|||
animation: spin .75s infinite ease-in-out; |
|||
} |
|||
@ -0,0 +1,882 @@ |
|||
var abp = abp || {}; |
|||
(function () { |
|||
|
|||
/* Application paths *****************************************/ |
|||
|
|||
//Current application root path (including virtual directory if exists).
|
|||
var baseElement = document.querySelector('base'); |
|||
var baseHref = baseElement ? baseElement.getAttribute('href') : null; |
|||
abp.appPath = baseHref || abp.appPath || '/'; |
|||
|
|||
abp.pageLoadTime = new Date(); |
|||
|
|||
//Converts given path to absolute path using abp.appPath variable.
|
|||
abp.toAbsAppPath = function (path) { |
|||
if (path.indexOf('/') == 0) { |
|||
path = path.substring(1); |
|||
} |
|||
|
|||
return abp.appPath + path; |
|||
}; |
|||
|
|||
/* LOGGING ***************************************************/ |
|||
//Implements Logging API that provides secure & controlled usage of console.log
|
|||
|
|||
abp.log = abp.log || {}; |
|||
|
|||
abp.log.levels = { |
|||
DEBUG: 1, |
|||
INFO: 2, |
|||
WARN: 3, |
|||
ERROR: 4, |
|||
FATAL: 5 |
|||
}; |
|||
|
|||
abp.log.level = abp.log.levels.DEBUG; |
|||
|
|||
abp.log.log = function (logObject, logLevel) { |
|||
if (!window.console || !window.console.log) { |
|||
return; |
|||
} |
|||
|
|||
if (logLevel != undefined && logLevel < abp.log.level) { |
|||
return; |
|||
} |
|||
|
|||
console.log(logObject); |
|||
}; |
|||
|
|||
abp.log.debug = function (logObject) { |
|||
abp.log.log("DEBUG: ", abp.log.levels.DEBUG); |
|||
abp.log.log(logObject, abp.log.levels.DEBUG); |
|||
}; |
|||
|
|||
abp.log.info = function (logObject) { |
|||
abp.log.log("INFO: ", abp.log.levels.INFO); |
|||
abp.log.log(logObject, abp.log.levels.INFO); |
|||
}; |
|||
|
|||
abp.log.warn = function (logObject) { |
|||
abp.log.log("WARN: ", abp.log.levels.WARN); |
|||
abp.log.log(logObject, abp.log.levels.WARN); |
|||
}; |
|||
|
|||
abp.log.error = function (logObject) { |
|||
abp.log.log("ERROR: ", abp.log.levels.ERROR); |
|||
abp.log.log(logObject, abp.log.levels.ERROR); |
|||
}; |
|||
|
|||
abp.log.fatal = function (logObject) { |
|||
abp.log.log("FATAL: ", abp.log.levels.FATAL); |
|||
abp.log.log(logObject, abp.log.levels.FATAL); |
|||
}; |
|||
|
|||
/* LOCALIZATION ***********************************************/ |
|||
|
|||
abp.localization = abp.localization || {}; |
|||
abp.localization.internal = abp.localization.internal || {}; |
|||
abp.localization.values = abp.localization.values || {}; |
|||
abp.localization.resources = abp.localization.resources || {}; |
|||
|
|||
abp.localization.internal.getResource = function (resourceName) { |
|||
var resource = abp.localization.resources[resourceName]; |
|||
if (resource) { |
|||
return resource; |
|||
} |
|||
|
|||
var legacySource = abp.localization.values[resourceName]; |
|||
if (legacySource) { |
|||
return { |
|||
texts: abp.localization.values[resourceName], |
|||
baseResources: [] |
|||
}; |
|||
} |
|||
|
|||
abp.log.warn('Could not find localization source: ' + resourceName); |
|||
return null; |
|||
}; |
|||
|
|||
abp.localization.internal.localize = function (key, sourceName) { |
|||
var resource = abp.localization.internal.getResource(sourceName); |
|||
if (!resource){ |
|||
return { |
|||
value: key, |
|||
found: false |
|||
}; |
|||
} |
|||
|
|||
var value = resource.texts[key]; |
|||
if (value === undefined) { |
|||
for (var i = 0; i < resource.baseResources.length; i++){ |
|||
var basedArguments = Array.prototype.slice.call(arguments, 0); |
|||
basedArguments[1] = resource.baseResources[i]; |
|||
|
|||
var result = abp.localization.internal.localize.apply(this, basedArguments); |
|||
if (result.found){ |
|||
return result; |
|||
} |
|||
} |
|||
|
|||
return { |
|||
value: key, |
|||
found: false |
|||
}; |
|||
} |
|||
|
|||
var copiedArguments = Array.prototype.slice.call(arguments, 0); |
|||
copiedArguments.splice(1, 1); |
|||
copiedArguments[0] = value; |
|||
|
|||
return { |
|||
value: abp.utils.formatString.apply(this, copiedArguments), |
|||
found: true |
|||
}; |
|||
}; |
|||
|
|||
abp.localization.localize = function (key, sourceName) { |
|||
if (sourceName === '_') { //A convention to suppress the localization
|
|||
return key; |
|||
} |
|||
|
|||
if (sourceName) { |
|||
return abp.localization.internal.localize.apply(this, arguments).value; |
|||
} |
|||
|
|||
if (!abp.localization.defaultResourceName) { |
|||
abp.log.warn('Localization source name is not specified and the defaultResourceName was not defined!'); |
|||
return key; |
|||
} |
|||
|
|||
var copiedArguments = Array.prototype.slice.call(arguments, 0); |
|||
copiedArguments.splice(1, 1, abp.localization.defaultResourceName); |
|||
|
|||
return abp.localization.internal.localize.apply(this, copiedArguments).value; |
|||
}; |
|||
|
|||
abp.localization.isLocalized = function (key, sourceName) { |
|||
if (sourceName === '_') { //A convention to suppress the localization
|
|||
return true; |
|||
} |
|||
|
|||
sourceName = sourceName || abp.localization.defaultResourceName; |
|||
if (!sourceName) { |
|||
return false; |
|||
} |
|||
|
|||
return abp.localization.internal.localize(key, sourceName).found; |
|||
}; |
|||
|
|||
abp.localization.getResource = function (name) { |
|||
return function () { |
|||
var copiedArguments = Array.prototype.slice.call(arguments, 0); |
|||
copiedArguments.splice(1, 0, name); |
|||
return abp.localization.localize.apply(this, copiedArguments); |
|||
}; |
|||
}; |
|||
|
|||
abp.localization.defaultResourceName = undefined; |
|||
abp.localization.currentCulture = { |
|||
cultureName: undefined |
|||
}; |
|||
|
|||
var getMapValue = function (packageMaps, packageName, language) { |
|||
language = language || abp.localization.currentCulture.name; |
|||
if (!packageMaps || !packageName || !language) { |
|||
return language; |
|||
} |
|||
|
|||
var packageMap = packageMaps[packageName]; |
|||
if (!packageMap) { |
|||
return language; |
|||
} |
|||
|
|||
for (var i = 0; i < packageMap.length; i++) { |
|||
var map = packageMap[i]; |
|||
if (map.name === language){ |
|||
return map.value; |
|||
} |
|||
} |
|||
|
|||
return language; |
|||
}; |
|||
|
|||
abp.localization.getLanguagesMap = function (packageName, language) { |
|||
return getMapValue(abp.localization.languagesMap, packageName, language); |
|||
}; |
|||
|
|||
abp.localization.getLanguageFilesMap = function (packageName, language) { |
|||
return getMapValue(abp.localization.languageFilesMap, packageName, language); |
|||
}; |
|||
|
|||
/* AUTHORIZATION **********************************************/ |
|||
|
|||
abp.auth = abp.auth || {}; |
|||
|
|||
abp.auth.grantedPolicies = abp.auth.grantedPolicies || {}; |
|||
|
|||
abp.auth.isGranted = function (policyName) { |
|||
return abp.auth.grantedPolicies[policyName] != undefined; |
|||
}; |
|||
|
|||
abp.auth.isAnyGranted = function () { |
|||
if (!arguments || arguments.length <= 0) { |
|||
return true; |
|||
} |
|||
|
|||
for (var i = 0; i < arguments.length; i++) { |
|||
if (abp.auth.isGranted(arguments[i])) { |
|||
return true; |
|||
} |
|||
} |
|||
|
|||
return false; |
|||
}; |
|||
|
|||
abp.auth.areAllGranted = function () { |
|||
if (!arguments || arguments.length <= 0) { |
|||
return true; |
|||
} |
|||
|
|||
for (var i = 0; i < arguments.length; i++) { |
|||
if (!abp.auth.isGranted(arguments[i])) { |
|||
return false; |
|||
} |
|||
} |
|||
|
|||
return true; |
|||
}; |
|||
|
|||
abp.auth.tokenCookieName = 'Abp.AuthToken'; |
|||
|
|||
abp.auth.setToken = function (authToken, expireDate) { |
|||
abp.utils.setCookieValue(abp.auth.tokenCookieName, authToken, expireDate, abp.appPath, abp.domain); |
|||
}; |
|||
|
|||
abp.auth.getToken = function () { |
|||
return abp.utils.getCookieValue(abp.auth.tokenCookieName); |
|||
} |
|||
|
|||
abp.auth.clearToken = function () { |
|||
abp.auth.setToken(); |
|||
} |
|||
|
|||
/* SETTINGS *************************************************/ |
|||
|
|||
abp.setting = abp.setting || {}; |
|||
|
|||
abp.setting.values = abp.setting.values || {}; |
|||
|
|||
abp.setting.get = function (name) { |
|||
return abp.setting.values[name]; |
|||
}; |
|||
|
|||
abp.setting.getBoolean = function (name) { |
|||
var value = abp.setting.get(name); |
|||
return value == 'true' || value == 'True'; |
|||
}; |
|||
|
|||
abp.setting.getInt = function (name) { |
|||
return parseInt(abp.setting.values[name]); |
|||
}; |
|||
|
|||
/* NOTIFICATION *********************************************/ |
|||
//Defines Notification API, not implements it
|
|||
|
|||
abp.notify = abp.notify || {}; |
|||
|
|||
abp.notify.success = function (message, title, options) { |
|||
abp.log.warn('abp.notify.success is not implemented!'); |
|||
}; |
|||
|
|||
abp.notify.info = function (message, title, options) { |
|||
abp.log.warn('abp.notify.info is not implemented!'); |
|||
}; |
|||
|
|||
abp.notify.warn = function (message, title, options) { |
|||
abp.log.warn('abp.notify.warn is not implemented!'); |
|||
}; |
|||
|
|||
abp.notify.error = function (message, title, options) { |
|||
abp.log.warn('abp.notify.error is not implemented!'); |
|||
}; |
|||
|
|||
/* MESSAGE **************************************************/ |
|||
//Defines Message API, not implements it
|
|||
|
|||
abp.message = abp.message || {}; |
|||
|
|||
abp.message._showMessage = function (message, title) { |
|||
alert((title || '') + ' ' + message); |
|||
}; |
|||
|
|||
abp.message.info = function (message, title) { |
|||
abp.log.warn('abp.message.info is not implemented!'); |
|||
return abp.message._showMessage(message, title); |
|||
}; |
|||
|
|||
abp.message.success = function (message, title) { |
|||
abp.log.warn('abp.message.success is not implemented!'); |
|||
return abp.message._showMessage(message, title); |
|||
}; |
|||
|
|||
abp.message.warn = function (message, title) { |
|||
abp.log.warn('abp.message.warn is not implemented!'); |
|||
return abp.message._showMessage(message, title); |
|||
}; |
|||
|
|||
abp.message.error = function (message, title) { |
|||
abp.log.warn('abp.message.error is not implemented!'); |
|||
return abp.message._showMessage(message, title); |
|||
}; |
|||
|
|||
abp.message.confirm = function (message, titleOrCallback, callback) { |
|||
abp.log.warn('abp.message.confirm is not properly implemented!'); |
|||
|
|||
if (titleOrCallback && !(typeof titleOrCallback == 'string')) { |
|||
callback = titleOrCallback; |
|||
} |
|||
|
|||
var result = confirm(message); |
|||
callback && callback(result); |
|||
}; |
|||
|
|||
abp.message.prompt = function (message, titleOrOptionsOrCallback, callback) { |
|||
abp.log.warn('abp.message.prompt is not properly implemented!'); |
|||
|
|||
if (titleOrOptionsOrCallback && !(typeof titleOrOptionsOrCallback == 'string')) { |
|||
callback = titleOrOptionsOrCallback; |
|||
} |
|||
|
|||
var result = prompt(message); |
|||
callback && callback(result); |
|||
}; |
|||
|
|||
/* UI *******************************************************/ |
|||
|
|||
abp.ui = abp.ui || {}; |
|||
|
|||
/* UI BLOCK */ |
|||
//Defines UI Block API and implements basically
|
|||
|
|||
var $abpBlockArea = document.createElement('div'); |
|||
$abpBlockArea.classList.add('abp-block-area'); |
|||
|
|||
/* opts: { //Can be an object with options or a string for query a selector |
|||
* elm: a query selector (optional - default: document.body) |
|||
* busy: boolean (optional - default: false) |
|||
* promise: A promise with always or finally handler (optional - auto unblocks the ui if provided) |
|||
* } |
|||
*/ |
|||
abp.ui.block = function (opts) { |
|||
if (!opts) { |
|||
opts = {}; |
|||
} else if (typeof opts == 'string') { |
|||
opts = { |
|||
elm: opts |
|||
}; |
|||
} |
|||
|
|||
var $elm = document.querySelector(opts.elm) || document.body; |
|||
|
|||
if (opts.busy) { |
|||
$abpBlockArea.classList.add('abp-block-area-busy'); |
|||
} else { |
|||
$abpBlockArea.classList.remove('abp-block-area-busy'); |
|||
} |
|||
|
|||
if (document.querySelector(opts.elm)) { |
|||
$abpBlockArea.style.position = 'absolute'; |
|||
} else { |
|||
$abpBlockArea.style.position = 'fixed'; |
|||
} |
|||
|
|||
$elm.appendChild($abpBlockArea); |
|||
|
|||
if (opts.promise) { |
|||
if (opts.promise.always) { //jQuery.Deferred style
|
|||
opts.promise.always(function () { |
|||
abp.ui.unblock({ |
|||
$elm: opts.elm |
|||
}); |
|||
}); |
|||
} else if (opts.promise['finally']) { //Q style
|
|||
opts.promise['finally'](function () { |
|||
abp.ui.unblock({ |
|||
$elm: opts.elm |
|||
}); |
|||
}); |
|||
} |
|||
} |
|||
}; |
|||
|
|||
/* opts: { |
|||
* |
|||
* } |
|||
*/ |
|||
abp.ui.unblock = function (opts) { |
|||
var element = document.querySelector('.abp-block-area'); |
|||
if (element) { |
|||
element.classList.add('abp-block-area-disappearing'); |
|||
setTimeout(function () { |
|||
if (element) { |
|||
element.classList.remove('abp-block-area-disappearing'); |
|||
if (element.parentElement) { |
|||
element.parentElement.removeChild(element); |
|||
} |
|||
} |
|||
}, 250); |
|||
} |
|||
}; |
|||
|
|||
/* UI BUSY */ |
|||
//Defines UI Busy API, not implements it
|
|||
|
|||
abp.ui.setBusy = function (opts) { |
|||
if (!opts) { |
|||
opts = { |
|||
busy: true |
|||
}; |
|||
} else if (typeof opts == 'string') { |
|||
opts = { |
|||
elm: opts, |
|||
busy: true |
|||
}; |
|||
} |
|||
|
|||
abp.ui.block(opts); |
|||
}; |
|||
|
|||
abp.ui.clearBusy = function (opts) { |
|||
abp.ui.unblock(opts); |
|||
}; |
|||
|
|||
/* SIMPLE EVENT BUS *****************************************/ |
|||
|
|||
abp.event = (function () { |
|||
|
|||
var _callbacks = {}; |
|||
|
|||
var on = function (eventName, callback) { |
|||
if (!_callbacks[eventName]) { |
|||
_callbacks[eventName] = []; |
|||
} |
|||
|
|||
_callbacks[eventName].push(callback); |
|||
}; |
|||
|
|||
var off = function (eventName, callback) { |
|||
var callbacks = _callbacks[eventName]; |
|||
if (!callbacks) { |
|||
return; |
|||
} |
|||
|
|||
var index = -1; |
|||
for (var i = 0; i < callbacks.length; i++) { |
|||
if (callbacks[i] === callback) { |
|||
index = i; |
|||
break; |
|||
} |
|||
} |
|||
|
|||
if (index < 0) { |
|||
return; |
|||
} |
|||
|
|||
_callbacks[eventName].splice(index, 1); |
|||
}; |
|||
|
|||
var trigger = function (eventName) { |
|||
var callbacks = _callbacks[eventName]; |
|||
if (!callbacks || !callbacks.length) { |
|||
return; |
|||
} |
|||
|
|||
var args = Array.prototype.slice.call(arguments, 1); |
|||
for (var i = 0; i < callbacks.length; i++) { |
|||
try { |
|||
callbacks[i].apply(this, args); |
|||
} catch(e) { |
|||
console.error(e); |
|||
} |
|||
} |
|||
}; |
|||
|
|||
// Public interface ///////////////////////////////////////////////////
|
|||
|
|||
return { |
|||
on: on, |
|||
off: off, |
|||
trigger: trigger |
|||
}; |
|||
})(); |
|||
|
|||
|
|||
/* UTILS ***************************************************/ |
|||
|
|||
abp.utils = abp.utils || {}; |
|||
|
|||
/* Creates a name namespace. |
|||
* Example: |
|||
* var taskService = abp.utils.createNamespace(abp, 'services.task'); |
|||
* taskService will be equal to abp.services.task |
|||
* first argument (root) must be defined first |
|||
************************************************************/ |
|||
abp.utils.createNamespace = function (root, ns) { |
|||
var parts = ns.split('.'); |
|||
for (var i = 0; i < parts.length; i++) { |
|||
if (typeof root[parts[i]] == 'undefined') { |
|||
root[parts[i]] = {}; |
|||
} |
|||
|
|||
root = root[parts[i]]; |
|||
} |
|||
|
|||
return root; |
|||
}; |
|||
|
|||
/* Find and replaces a string (search) to another string (replacement) in |
|||
* given string (str). |
|||
* Example: |
|||
* abp.utils.replaceAll('This is a test string', 'is', 'X') = 'ThX X a test string' |
|||
************************************************************/ |
|||
abp.utils.replaceAll = function (str, search, replacement) { |
|||
var fix = search.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"); |
|||
return str.replace(new RegExp(fix, 'g'), replacement); |
|||
}; |
|||
|
|||
/* Formats a string just like string.format in C#. |
|||
* Example: |
|||
* abp.utils.formatString('Hello {0}','Tuana') = 'Hello Tuana' |
|||
************************************************************/ |
|||
abp.utils.formatString = function () { |
|||
if (arguments.length < 1) { |
|||
return null; |
|||
} |
|||
|
|||
var str = arguments[0]; |
|||
|
|||
for (var i = 1; i < arguments.length; i++) { |
|||
var placeHolder = '{' + (i - 1) + '}'; |
|||
str = abp.utils.replaceAll(str, placeHolder, arguments[i]); |
|||
} |
|||
|
|||
return str; |
|||
}; |
|||
|
|||
abp.utils.toPascalCase = function (str) { |
|||
if (!str || !str.length) { |
|||
return str; |
|||
} |
|||
|
|||
if (str.length === 1) { |
|||
return str.charAt(0).toUpperCase(); |
|||
} |
|||
|
|||
return str.charAt(0).toUpperCase() + str.substr(1); |
|||
} |
|||
|
|||
abp.utils.toCamelCase = function (str) { |
|||
if (!str || !str.length) { |
|||
return str; |
|||
} |
|||
|
|||
if (str.length === 1) { |
|||
return str.charAt(0).toLowerCase(); |
|||
} |
|||
|
|||
return str.charAt(0).toLowerCase() + str.substr(1); |
|||
} |
|||
|
|||
abp.utils.truncateString = function (str, maxLength) { |
|||
if (!str || !str.length || str.length <= maxLength) { |
|||
return str; |
|||
} |
|||
|
|||
return str.substr(0, maxLength); |
|||
}; |
|||
|
|||
abp.utils.truncateStringWithPostfix = function (str, maxLength, postfix) { |
|||
postfix = postfix || '...'; |
|||
|
|||
if (!str || !str.length || str.length <= maxLength) { |
|||
return str; |
|||
} |
|||
|
|||
if (maxLength <= postfix.length) { |
|||
return postfix.substr(0, maxLength); |
|||
} |
|||
|
|||
return str.substr(0, maxLength - postfix.length) + postfix; |
|||
}; |
|||
|
|||
abp.utils.isFunction = function (obj) { |
|||
return !!(obj && obj.constructor && obj.call && obj.apply); |
|||
}; |
|||
|
|||
/** |
|||
* parameterInfos should be an array of { name, value } objects |
|||
* where name is query string parameter name and value is it's value. |
|||
* includeQuestionMark is true by default. |
|||
*/ |
|||
abp.utils.buildQueryString = function (parameterInfos, includeQuestionMark) { |
|||
if (includeQuestionMark === undefined) { |
|||
includeQuestionMark = true; |
|||
} |
|||
|
|||
var qs = ''; |
|||
|
|||
function addSeperator() { |
|||
if (!qs.length) { |
|||
if (includeQuestionMark) { |
|||
qs = qs + '?'; |
|||
} |
|||
} else { |
|||
qs = qs + '&'; |
|||
} |
|||
} |
|||
|
|||
for (var i = 0; i < parameterInfos.length; ++i) { |
|||
var parameterInfo = parameterInfos[i]; |
|||
if (parameterInfo.value === undefined) { |
|||
continue; |
|||
} |
|||
|
|||
if (parameterInfo.value === null) { |
|||
parameterInfo.value = ''; |
|||
} |
|||
|
|||
addSeperator(); |
|||
|
|||
if (parameterInfo.value.toJSON && typeof parameterInfo.value.toJSON === "function") { |
|||
qs = qs + parameterInfo.name + '=' + encodeURIComponent(parameterInfo.value.toJSON()); |
|||
} else if (Array.isArray(parameterInfo.value) && parameterInfo.value.length) { |
|||
for (var j = 0; j < parameterInfo.value.length; j++) { |
|||
if (j > 0) { |
|||
addSeperator(); |
|||
} |
|||
|
|||
qs = qs + parameterInfo.name + '[' + j + ']=' + encodeURIComponent(parameterInfo.value[j]); |
|||
} |
|||
} else { |
|||
qs = qs + parameterInfo.name + '=' + encodeURIComponent(parameterInfo.value); |
|||
} |
|||
} |
|||
|
|||
return qs; |
|||
} |
|||
|
|||
/** |
|||
* Sets a cookie value for given key. |
|||
* This is a simple implementation created to be used by ABP. |
|||
* Please use a complete cookie library if you need. |
|||
* @param {string} key |
|||
* @param {string} value |
|||
* @param {Date} expireDate (optional). If not specified the cookie will expire at the end of session. |
|||
* @param {string} path (optional) |
|||
*/ |
|||
abp.utils.setCookieValue = function (key, value, expireDate, path) { |
|||
var cookieValue = encodeURIComponent(key) + '='; |
|||
|
|||
if (value) { |
|||
cookieValue = cookieValue + encodeURIComponent(value); |
|||
} |
|||
|
|||
if (expireDate) { |
|||
cookieValue = cookieValue + "; expires=" + expireDate.toUTCString(); |
|||
} |
|||
|
|||
if (path) { |
|||
cookieValue = cookieValue + "; path=" + path; |
|||
} |
|||
|
|||
document.cookie = cookieValue; |
|||
}; |
|||
|
|||
/** |
|||
* Gets a cookie with given key. |
|||
* This is a simple implementation created to be used by ABP. |
|||
* Please use a complete cookie library if you need. |
|||
* @param {string} key |
|||
* @returns {string} Cookie value or null |
|||
*/ |
|||
abp.utils.getCookieValue = function (key) { |
|||
var equalities = document.cookie.split('; '); |
|||
for (var i = 0; i < equalities.length; i++) { |
|||
if (!equalities[i]) { |
|||
continue; |
|||
} |
|||
|
|||
var splitted = equalities[i].split('='); |
|||
if (splitted.length != 2) { |
|||
continue; |
|||
} |
|||
|
|||
if (decodeURIComponent(splitted[0]) === key) { |
|||
return decodeURIComponent(splitted[1] || ''); |
|||
} |
|||
} |
|||
|
|||
return null; |
|||
}; |
|||
|
|||
/** |
|||
* Deletes cookie for given key. |
|||
* This is a simple implementation created to be used by ABP. |
|||
* Please use a complete cookie library if you need. |
|||
* @param {string} key |
|||
* @param {string} path (optional) |
|||
*/ |
|||
abp.utils.deleteCookie = function (key, path) { |
|||
var cookieValue = encodeURIComponent(key) + '='; |
|||
|
|||
cookieValue = cookieValue + "; expires=" + (new Date(new Date().getTime() - 86400000)).toUTCString(); |
|||
|
|||
if (path) { |
|||
cookieValue = cookieValue + "; path=" + path; |
|||
} |
|||
|
|||
document.cookie = cookieValue; |
|||
} |
|||
|
|||
/** |
|||
* Escape HTML to help prevent XSS attacks. |
|||
*/ |
|||
abp.utils.htmlEscape = function (html) { |
|||
return typeof html === 'string' ? html.replace(/&/g, '&').replace(/</g, '<').replace(/>/g, '>').replace(/"/g, '"') : html; |
|||
} |
|||
|
|||
/* SECURITY ***************************************/ |
|||
abp.security = abp.security || {}; |
|||
abp.security.antiForgery = abp.security.antiForgery || {}; |
|||
|
|||
abp.security.antiForgery.tokenCookieName = 'XSRF-TOKEN'; |
|||
abp.security.antiForgery.tokenHeaderName = 'RequestVerificationToken'; |
|||
|
|||
abp.security.antiForgery.getToken = function () { |
|||
return abp.utils.getCookieValue(abp.security.antiForgery.tokenCookieName); |
|||
}; |
|||
|
|||
/* CLOCK *****************************************/ |
|||
abp.clock = abp.clock || {}; |
|||
|
|||
abp.clock.kind = 'Unspecified'; |
|||
|
|||
abp.clock.supportsMultipleTimezone = function () { |
|||
return abp.clock.kind === 'Utc'; |
|||
} |
|||
|
|||
abp.clock.timeZone = function () { |
|||
return abp.setting.get('Abp.Timing.TimeZone') || abp.clock.browserTimeZone(); |
|||
} |
|||
|
|||
// Normalize Date object or date string to standard string format that will be sent to server
|
|||
abp.clock.normalizeToString = function (date) { |
|||
if (!date) { |
|||
return date; |
|||
} |
|||
|
|||
var dateObj = date instanceof Date ? date : new Date(date); |
|||
if (isNaN(dateObj)) { |
|||
return date; |
|||
} |
|||
|
|||
function padZero(num) { |
|||
return num < 10 ? '0' + num : num; |
|||
} |
|||
|
|||
var addZulu = false; |
|||
if (abp.clock.supportsMultipleTimezone()) { |
|||
var timeZone = abp.clock.timeZone(); |
|||
var now = new Date(); |
|||
var formattedDate = now.toLocaleString('en-US', { timeZone: timeZone, timeZoneName: 'longOffset' }); |
|||
var match = formattedDate.match(/GMT([+-]\d+)/); |
|||
var targetOffsetHours = match ? parseInt(match[1], 10) : 0; |
|||
dateObj = new Date(dateObj.getTime() - (targetOffsetHours * 60 * 60 * 1000)); |
|||
addZulu = true; |
|||
} |
|||
|
|||
// yyyy-MM-DDTHH:mm:ss
|
|||
return dateObj.getFullYear() + '-' + |
|||
padZero(dateObj.getMonth() + 1) + '-' + |
|||
padZero(dateObj.getDate()) + 'T' + |
|||
padZero(dateObj.getHours()) + ':' + |
|||
padZero(dateObj.getMinutes()) + ':' + |
|||
padZero(dateObj.getSeconds()) + (addZulu ? 'Z' : ''); |
|||
}; |
|||
|
|||
// Default options for toLocaleString
|
|||
abp.clock.toLocaleStringOptions = abp.clock.toLocaleStringOptions || { |
|||
"year": "numeric", |
|||
"month": "long", |
|||
"day": "numeric", |
|||
"hour": "numeric", |
|||
"minute": "numeric", |
|||
"second": "numeric" |
|||
}; |
|||
|
|||
// Normalize date string to locale date string that will be displayed to user
|
|||
abp.clock.normalizeToLocaleString = function (dateString, options) { |
|||
if (!dateString) { |
|||
return dateString; |
|||
} |
|||
|
|||
var date = new Date(dateString); |
|||
if (isNaN(date)) { |
|||
return dateString; |
|||
} |
|||
|
|||
var culture = abp.localization.currentCulture.cultureName; |
|||
options = options || abp.clock.toLocaleStringOptions; |
|||
if (abp.clock.supportsMultipleTimezone()) { |
|||
var timezone = abp.clock.timeZone(); |
|||
if (timezone) { |
|||
return date.toLocaleString(culture, Object.assign({}, options, { timeZone: timezone })); |
|||
} |
|||
} |
|||
return date.toLocaleString(culture, options); |
|||
} |
|||
|
|||
abp.clock.browserTimeZone = function () { |
|||
return Intl.DateTimeFormat().resolvedOptions().timeZone; |
|||
} |
|||
|
|||
abp.clock.trySetBrowserTimeZoneToCookie = true; |
|||
|
|||
abp.clock.setBrowserTimeZoneToCookie = function () { |
|||
if (!abp.clock.trySetBrowserTimeZoneToCookie || !abp.clock.supportsMultipleTimezone()) { |
|||
return; |
|||
} |
|||
|
|||
abp.utils.setCookieValue('__timezone', abp.clock.browserTimeZone(), new Date(new Date().setFullYear(new Date().getFullYear() + 1)), '/'); |
|||
} |
|||
|
|||
abp.event.on('abp.configurationInitialized', function () { |
|||
abp.clock.setBrowserTimeZoneToCookie(); |
|||
}); |
|||
|
|||
/* FEATURES *************************************************/ |
|||
|
|||
abp.features = abp.features || {}; |
|||
|
|||
abp.features.values = abp.features.values || {}; |
|||
|
|||
abp.features.isEnabled = function(name){ |
|||
var value = abp.features.get(name); |
|||
return value == 'true' || value == 'True'; |
|||
} |
|||
|
|||
abp.features.get = function (name) { |
|||
return abp.features.values[name]; |
|||
}; |
|||
|
|||
/* GLOBAL FEATURES *************************************************/ |
|||
|
|||
abp.globalFeatures = abp.globalFeatures || {}; |
|||
|
|||
abp.globalFeatures.enabledFeatures = abp.globalFeatures.enabledFeatures || []; |
|||
|
|||
abp.globalFeatures.isEnabled = function(name){ |
|||
return abp.globalFeatures.enabledFeatures.indexOf(name) != -1; |
|||
} |
|||
|
|||
})(); |
|||
@ -0,0 +1,411 @@ |
|||
var abp = abp || {}; |
|||
(function($) { |
|||
|
|||
if (!$) { |
|||
throw "abp/jquery library requires the jquery library included to the page!"; |
|||
} |
|||
|
|||
// ABP CORE OVERRIDES /////////////////////////////////////////////////////
|
|||
|
|||
abp.message._showMessage = function (message, title) { |
|||
alert((title || '') + ' ' + message); |
|||
|
|||
return $.Deferred(function ($dfd) { |
|||
$dfd.resolve(); |
|||
}); |
|||
}; |
|||
|
|||
abp.message.confirm = function (message, titleOrCallback, callback) { |
|||
if (titleOrCallback && !(typeof titleOrCallback == 'string')) { |
|||
callback = titleOrCallback; |
|||
} |
|||
|
|||
var result = confirm(message); |
|||
callback && callback(result); |
|||
|
|||
return $.Deferred(function ($dfd) { |
|||
$dfd.resolve(result); |
|||
}); |
|||
}; |
|||
|
|||
abp.utils.isFunction = function (obj) { |
|||
return $.isFunction(obj); |
|||
}; |
|||
|
|||
// JQUERY EXTENSIONS //////////////////////////////////////////////////////
|
|||
|
|||
$.fn.findWithSelf = function (selector) { |
|||
return this.filter(selector).add(this.find(selector)); |
|||
}; |
|||
|
|||
// DOM ////////////////////////////////////////////////////////////////////
|
|||
|
|||
abp.dom = abp.dom || {}; |
|||
|
|||
abp.dom.onNodeAdded = function (callback) { |
|||
abp.event.on('abp.dom.nodeAdded', callback); |
|||
}; |
|||
|
|||
abp.dom.onNodeRemoved = function (callback) { |
|||
abp.event.on('abp.dom.nodeRemoved', callback); |
|||
}; |
|||
|
|||
var mutationObserverCallback = function (mutationsList) { |
|||
for (var i = 0; i < mutationsList.length; i++) { |
|||
var mutation = mutationsList[i]; |
|||
if (mutation.type === 'childList') { |
|||
if (mutation.addedNodes && mutation.removedNodes.length) { |
|||
for (var k = 0; k < mutation.removedNodes.length; k++) { |
|||
abp.event.trigger( |
|||
'abp.dom.nodeRemoved', |
|||
{ |
|||
$el: $(mutation.removedNodes[k]) |
|||
} |
|||
); |
|||
} |
|||
} |
|||
|
|||
if (mutation.addedNodes && mutation.addedNodes.length) { |
|||
for (var j = 0; j < mutation.addedNodes.length; j++) { |
|||
abp.event.trigger( |
|||
'abp.dom.nodeAdded', |
|||
{ |
|||
$el: $(mutation.addedNodes[j]) |
|||
} |
|||
); |
|||
} |
|||
} |
|||
} |
|||
} |
|||
}; |
|||
|
|||
$(function(){ |
|||
new MutationObserver(mutationObserverCallback).observe( |
|||
$('body')[0], |
|||
{ |
|||
subtree: true, |
|||
childList: true |
|||
} |
|||
); |
|||
}); |
|||
|
|||
// AJAX ///////////////////////////////////////////////////////////////////
|
|||
|
|||
abp.ajax = function (userOptions) { |
|||
userOptions = userOptions || {}; |
|||
|
|||
var options = $.extend(true, {}, abp.ajax.defaultOpts, userOptions); |
|||
|
|||
options.success = undefined; |
|||
options.error = undefined; |
|||
|
|||
var xhr = null; |
|||
var promise = $.Deferred(function ($dfd) { |
|||
xhr = $.ajax(options) |
|||
.done(function (data, textStatus, jqXHR) { |
|||
$dfd.resolve(data); |
|||
userOptions.success && userOptions.success(data); |
|||
}).fail(function (jqXHR) { |
|||
if(jqXHR.statusText === 'abort') { |
|||
//ajax request is abort, ignore error handle.
|
|||
return; |
|||
} |
|||
if (jqXHR.getResponseHeader('_AbpErrorFormat') === 'true') { |
|||
abp.ajax.handleAbpErrorResponse(jqXHR, userOptions, $dfd); |
|||
} else { |
|||
abp.ajax.handleNonAbpErrorResponse(jqXHR, userOptions, $dfd); |
|||
} |
|||
}); |
|||
}).promise(); |
|||
|
|||
promise['jqXHR'] = xhr; |
|||
|
|||
return promise; |
|||
}; |
|||
|
|||
$.extend(abp.ajax, { |
|||
defaultOpts: { |
|||
dataType: 'json', |
|||
type: 'POST', |
|||
contentType: 'application/json', |
|||
headers: { |
|||
'X-Requested-With': 'XMLHttpRequest' |
|||
} |
|||
}, |
|||
|
|||
defaultError: { |
|||
message: 'An error has occurred!', |
|||
details: 'Error detail not sent by server.' |
|||
}, |
|||
|
|||
defaultError401: { |
|||
message: 'You are not authenticated!', |
|||
details: 'You should be authenticated (sign in) in order to perform this operation.' |
|||
}, |
|||
|
|||
defaultError403: { |
|||
message: 'You are not authorized!', |
|||
details: 'You are not allowed to perform this operation.' |
|||
}, |
|||
|
|||
defaultError404: { |
|||
message: 'Resource not found!', |
|||
details: 'The resource requested could not found on the server.' |
|||
}, |
|||
|
|||
logError: function (error) { |
|||
abp.log.error(error); |
|||
}, |
|||
|
|||
showError: function (error) { |
|||
if (error.details) { |
|||
return abp.message.error(error.details, error.message); |
|||
} else { |
|||
return abp.message.error(error.message || abp.ajax.defaultError.message); |
|||
} |
|||
}, |
|||
|
|||
handleTargetUrl: function (targetUrl) { |
|||
if (!targetUrl) { |
|||
location.href = abp.appPath; |
|||
} else { |
|||
location.href = targetUrl; |
|||
} |
|||
}, |
|||
|
|||
handleErrorStatusCode: function (status) { |
|||
switch (status) { |
|||
case 401: |
|||
abp.ajax.handleUnAuthorizedRequest( |
|||
abp.ajax.showError(abp.ajax.defaultError401), |
|||
abp.appPath |
|||
); |
|||
break; |
|||
case 403: |
|||
abp.ajax.showError(abp.ajax.defaultError403); |
|||
break; |
|||
case 404: |
|||
abp.ajax.showError(abp.ajax.defaultError404); |
|||
break; |
|||
default: |
|||
abp.ajax.showError(abp.ajax.defaultError); |
|||
break; |
|||
} |
|||
}, |
|||
|
|||
handleNonAbpErrorResponse: function (jqXHR, userOptions, $dfd) { |
|||
if (userOptions.abpHandleError !== false) { |
|||
abp.ajax.handleErrorStatusCode(jqXHR.status); |
|||
} |
|||
|
|||
$dfd.reject.apply(this, arguments); |
|||
userOptions.error && userOptions.error.apply(this, arguments); |
|||
}, |
|||
|
|||
handleAbpErrorResponse: function (jqXHR, userOptions, $dfd) { |
|||
var messagePromise = null; |
|||
|
|||
var responseJSON = jqXHR.responseJSON ? jqXHR.responseJSON : JSON.parse(jqXHR.responseText); |
|||
|
|||
if (userOptions.abpHandleError !== false) { |
|||
messagePromise = abp.ajax.showError(responseJSON.error); |
|||
} |
|||
|
|||
abp.ajax.logError(responseJSON.error); |
|||
|
|||
$dfd && $dfd.reject(responseJSON.error, jqXHR); |
|||
userOptions.error && userOptions.error(responseJSON.error, jqXHR); |
|||
|
|||
if (jqXHR.status === 401 && userOptions.abpHandleError !== false) { |
|||
abp.ajax.handleUnAuthorizedRequest(messagePromise); |
|||
} |
|||
}, |
|||
|
|||
handleUnAuthorizedRequest: function (messagePromise, targetUrl) { |
|||
if (messagePromise) { |
|||
messagePromise.done(function () { |
|||
abp.ajax.handleTargetUrl(targetUrl); |
|||
}); |
|||
} else { |
|||
abp.ajax.handleTargetUrl(targetUrl); |
|||
} |
|||
}, |
|||
|
|||
blockUI: function (options) { |
|||
if (options.blockUI) { |
|||
if (options.blockUI === true) { //block whole page
|
|||
abp.ui.setBusy(); |
|||
} else { //block an element
|
|||
abp.ui.setBusy(options.blockUI); |
|||
} |
|||
} |
|||
}, |
|||
|
|||
unblockUI: function (options) { |
|||
if (options.blockUI) { |
|||
if (options.blockUI === true) { //unblock whole page
|
|||
abp.ui.clearBusy(); |
|||
} else { //unblock an element
|
|||
abp.ui.clearBusy(options.blockUI); |
|||
} |
|||
} |
|||
}, |
|||
|
|||
ajaxSendHandler: function (event, request, settings) { |
|||
var token = abp.security.antiForgery.getToken(); |
|||
if (!token) { |
|||
return; |
|||
} |
|||
|
|||
if (!settings.headers || settings.headers[abp.security.antiForgery.tokenHeaderName] === undefined) { |
|||
request.setRequestHeader(abp.security.antiForgery.tokenHeaderName, token); |
|||
} |
|||
} |
|||
}); |
|||
|
|||
$(document).ajaxSend(function (event, request, settings) { |
|||
return abp.ajax.ajaxSendHandler(event, request, settings); |
|||
}); |
|||
|
|||
abp.event.on('abp.configurationInitialized', function () { |
|||
var l = abp.localization.getResource('AbpUi'); |
|||
|
|||
abp.ajax.defaultError.message = l('DefaultErrorMessage'); |
|||
abp.ajax.defaultError.details = l('DefaultErrorMessageDetail'); |
|||
abp.ajax.defaultError401.message = l('DefaultErrorMessage401'); |
|||
abp.ajax.defaultError401.details = l('DefaultErrorMessage401Detail'); |
|||
abp.ajax.defaultError403.message = l('DefaultErrorMessage403'); |
|||
abp.ajax.defaultError403.details = l('DefaultErrorMessage403Detail'); |
|||
abp.ajax.defaultError404.message = l('DefaultErrorMessage404'); |
|||
abp.ajax.defaultError404.details = l('DefaultErrorMessage404Detail'); |
|||
}); |
|||
|
|||
// RESOURCE LOADER ////////////////////////////////////////////////////////
|
|||
|
|||
/* UrlStates enum */ |
|||
var UrlStates = { |
|||
LOADING: 'LOADING', |
|||
LOADED: 'LOADED', |
|||
FAILED: 'FAILED' |
|||
}; |
|||
|
|||
/* UrlInfo class */ |
|||
function UrlInfo(url) { |
|||
this.url = url; |
|||
this.state = UrlStates.LOADING; |
|||
this.loadCallbacks = []; |
|||
this.failCallbacks = []; |
|||
} |
|||
|
|||
UrlInfo.prototype.succeed = function () { |
|||
this.state = UrlStates.LOADED; |
|||
for (var i = 0; i < this.loadCallbacks.length; i++) { |
|||
this.loadCallbacks[i](); |
|||
} |
|||
}; |
|||
|
|||
UrlInfo.prototype.failed = function () { |
|||
this.state = UrlStates.FAILED; |
|||
for (var i = 0; i < this.failCallbacks.length; i++) { |
|||
this.failCallbacks[i](); |
|||
} |
|||
}; |
|||
|
|||
UrlInfo.prototype.handleCallbacks = function (loadCallback, failCallback) { |
|||
switch (this.state) { |
|||
case UrlStates.LOADED: |
|||
loadCallback && loadCallback(); |
|||
break; |
|||
case UrlStates.FAILED: |
|||
failCallback && failCallback(); |
|||
break; |
|||
case UrlStates.LOADING: |
|||
this.addCallbacks(loadCallback, failCallback); |
|||
break; |
|||
} |
|||
}; |
|||
|
|||
UrlInfo.prototype.addCallbacks = function (loadCallback, failCallback) { |
|||
loadCallback && this.loadCallbacks.push(loadCallback); |
|||
failCallback && this.failCallbacks.push(failCallback); |
|||
}; |
|||
|
|||
/* ResourceLoader API */ |
|||
|
|||
abp.ResourceLoader = (function () { |
|||
|
|||
var _urlInfos = {}; |
|||
|
|||
function getCacheKey(url) { |
|||
return url; |
|||
} |
|||
|
|||
function appendTimeToUrl(url) { |
|||
|
|||
if (url.indexOf('?') < 0) { |
|||
url += '?'; |
|||
} else { |
|||
url += '&'; |
|||
} |
|||
|
|||
url += '_=' + new Date().getTime(); |
|||
|
|||
return url; |
|||
} |
|||
|
|||
var _loadFromUrl = function (url, loadCallback, failCallback, serverLoader) { |
|||
|
|||
var cacheKey = getCacheKey(url); |
|||
|
|||
var urlInfo = _urlInfos[cacheKey]; |
|||
|
|||
if (urlInfo) { |
|||
urlInfo.handleCallbacks(loadCallback, failCallback); |
|||
return; |
|||
} |
|||
|
|||
_urlInfos[cacheKey] = urlInfo = new UrlInfo(url); |
|||
urlInfo.addCallbacks(loadCallback, failCallback); |
|||
|
|||
serverLoader(urlInfo); |
|||
}; |
|||
|
|||
var _loadScript = function (url, loadCallback, failCallback) { |
|||
var nonce = document.body.nonce || document.body.getAttribute('nonce'); |
|||
_loadFromUrl(url, loadCallback, failCallback, function (urlInfo) { |
|||
$.get({ |
|||
url: url, |
|||
dataType: 'text' |
|||
}) |
|||
.done(function (script) { |
|||
if(nonce){ |
|||
$.globalEval(script, { nonce: nonce}); |
|||
}else{ |
|||
$.globalEval(script); |
|||
} |
|||
urlInfo.succeed(); |
|||
}) |
|||
.fail(function () { |
|||
urlInfo.failed(); |
|||
}); |
|||
}); |
|||
}; |
|||
|
|||
var _loadStyle = function (url) { |
|||
_loadFromUrl(url, undefined, undefined, function (urlInfo) { |
|||
|
|||
$('<link/>', { |
|||
rel: 'stylesheet', |
|||
type: 'text/css', |
|||
href: appendTimeToUrl(url) |
|||
}).appendTo('head'); |
|||
}); |
|||
}; |
|||
|
|||
return { |
|||
loadScript: _loadScript, |
|||
loadStyle: _loadStyle |
|||
} |
|||
})(); |
|||
|
|||
})(jQuery); |
|||
@ -0,0 +1,102 @@ |
|||
var abp = abp || {}; |
|||
(function () { |
|||
|
|||
if (!luxon) { |
|||
throw "abp/luxon library requires the luxon library included to the page!"; |
|||
} |
|||
|
|||
/* TIMING *************************************************/ |
|||
|
|||
abp.timing = abp.timing || {}; |
|||
|
|||
var setObjectValue = function (obj, property, value) { |
|||
if (typeof property === "string") { |
|||
property = property.split('.'); |
|||
} |
|||
|
|||
if (property.length > 1) { |
|||
var p = property.shift(); |
|||
setObjectValue(obj[p], property, value); |
|||
} else { |
|||
obj[property[0]] = value; |
|||
} |
|||
} |
|||
|
|||
var getObjectValue = function (obj, property) { |
|||
return property.split('.').reduce((a, v) => a[v], obj) |
|||
} |
|||
|
|||
abp.timing.convertFieldsToIsoDate = function (form, fields) { |
|||
for (var field of fields) { |
|||
var dateTime = luxon.DateTime |
|||
.fromFormat( |
|||
getObjectValue(form, field), |
|||
abp.localization.currentCulture.dateTimeFormat.shortDatePattern, |
|||
{ locale: abp.localization.currentCulture.cultureName } |
|||
); |
|||
|
|||
if (!dateTime.invalid) { |
|||
setObjectValue(form, field, dateTime.toFormat("yyyy-MM-dd HH:mm:ss")) |
|||
} |
|||
} |
|||
|
|||
return form; |
|||
} |
|||
|
|||
// Normalize Date object or date string to standard string format that will be sent to server
|
|||
abp.clock.normalizeToString = function (date) { |
|||
if (!date) { |
|||
return date; |
|||
} |
|||
|
|||
var dateObj = date instanceof Date ? date : new Date(date); |
|||
if (isNaN(dateObj)) { |
|||
return date; |
|||
} |
|||
|
|||
var timeZone = abp.clock.timeZone(); |
|||
if (abp.clock.supportsMultipleTimezone() && timeZone) { |
|||
return luxon.DateTime.fromObject({ |
|||
year: dateObj.getFullYear(), |
|||
month: dateObj.getMonth() + 1, |
|||
day: dateObj.getDate(), |
|||
hour: dateObj.getHours(), |
|||
minute: dateObj.getMinutes(), |
|||
second: dateObj.getSeconds() |
|||
}, { zone: timeZone }).setZone("utc").toISO(); |
|||
} else { |
|||
return luxon.DateTime.fromJSDate(dateObj).toFormat("yyyy-MM-dd'T'HH:mm:ss"); |
|||
} |
|||
}; |
|||
|
|||
// Normalize date string to locale date string that will be displayed to user
|
|||
abp.clock.normalizeToLocaleString = function (dateString, options) { |
|||
if (!dateString) { |
|||
return dateString; |
|||
} |
|||
|
|||
var date = new Date(dateString); |
|||
if (isNaN(date)) { |
|||
return dateString; |
|||
} |
|||
|
|||
options = options || abp.clock.toLocaleStringOptions; |
|||
if (abp.clock.supportsMultipleTimezone()) { |
|||
var timezone = abp.clock.timeZone(); |
|||
if (timezone) { |
|||
return luxon.DateTime.fromJSDate(date) |
|||
.setZone(timezone) |
|||
.setLocale(abp.localization.currentCulture.cultureName) |
|||
.toLocaleString(options); |
|||
} |
|||
} |
|||
|
|||
return luxon.DateTime.fromJSDate(date) |
|||
.setLocale(abp.localization.currentCulture.cultureName) |
|||
.toLocaleString(options); |
|||
} |
|||
|
|||
abp.clock.browserTimeZone = function () { |
|||
return luxon.DateTime.local().zoneName; |
|||
} |
|||
})(jQuery); |
|||
@ -0,0 +1,694 @@ |
|||
(function (global, factory) { |
|||
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('just-compare')) : |
|||
typeof define === 'function' && define.amd ? define('@abp/utils', ['exports', 'just-compare'], factory) : |
|||
(global = global || self, factory((global.abp = global.abp || {}, global.abp.utils = global.abp.utils || {}, global.abp.utils.common = {}), global.compare)); |
|||
}(this, (function (exports, compare) { 'use strict'; |
|||
|
|||
compare = compare && Object.prototype.hasOwnProperty.call(compare, 'default') ? compare['default'] : compare; |
|||
|
|||
/*! ***************************************************************************** |
|||
Copyright (c) Microsoft Corporation. |
|||
|
|||
Permission to use, copy, modify, and/or distribute this software for any |
|||
purpose with or without fee is hereby granted. |
|||
|
|||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH |
|||
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY |
|||
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, |
|||
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM |
|||
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR |
|||
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR |
|||
PERFORMANCE OF THIS SOFTWARE. |
|||
***************************************************************************** */ |
|||
/* global Reflect, Promise */ |
|||
var extendStatics = function (d, b) { |
|||
extendStatics = Object.setPrototypeOf || |
|||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || |
|||
function (d, b) { for (var p in b) |
|||
if (b.hasOwnProperty(p)) |
|||
d[p] = b[p]; }; |
|||
return extendStatics(d, b); |
|||
}; |
|||
function __extends(d, b) { |
|||
extendStatics(d, b); |
|||
function __() { this.constructor = d; } |
|||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); |
|||
} |
|||
var __assign = function () { |
|||
__assign = Object.assign || function __assign(t) { |
|||
for (var s, i = 1, n = arguments.length; i < n; i++) { |
|||
s = arguments[i]; |
|||
for (var p in s) |
|||
if (Object.prototype.hasOwnProperty.call(s, p)) |
|||
t[p] = s[p]; |
|||
} |
|||
return t; |
|||
}; |
|||
return __assign.apply(this, arguments); |
|||
}; |
|||
function __rest(s, e) { |
|||
var t = {}; |
|||
for (var p in s) |
|||
if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) |
|||
t[p] = s[p]; |
|||
if (s != null && typeof Object.getOwnPropertySymbols === "function") |
|||
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) { |
|||
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) |
|||
t[p[i]] = s[p[i]]; |
|||
} |
|||
return t; |
|||
} |
|||
function __decorate(decorators, target, key, desc) { |
|||
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d; |
|||
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") |
|||
r = Reflect.decorate(decorators, target, key, desc); |
|||
else |
|||
for (var i = decorators.length - 1; i >= 0; i--) |
|||
if (d = decorators[i]) |
|||
r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r; |
|||
return c > 3 && r && Object.defineProperty(target, key, r), r; |
|||
} |
|||
function __param(paramIndex, decorator) { |
|||
return function (target, key) { decorator(target, key, paramIndex); }; |
|||
} |
|||
function __metadata(metadataKey, metadataValue) { |
|||
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") |
|||
return Reflect.metadata(metadataKey, metadataValue); |
|||
} |
|||
function __awaiter(thisArg, _arguments, P, generator) { |
|||
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } |
|||
return new (P || (P = Promise))(function (resolve, reject) { |
|||
function fulfilled(value) { try { |
|||
step(generator.next(value)); |
|||
} |
|||
catch (e) { |
|||
reject(e); |
|||
} } |
|||
function rejected(value) { try { |
|||
step(generator["throw"](value)); |
|||
} |
|||
catch (e) { |
|||
reject(e); |
|||
} } |
|||
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } |
|||
step((generator = generator.apply(thisArg, _arguments || [])).next()); |
|||
}); |
|||
} |
|||
function __generator(thisArg, body) { |
|||
var _ = { label: 0, sent: function () { if (t[0] & 1) |
|||
throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g; |
|||
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function () { return this; }), g; |
|||
function verb(n) { return function (v) { return step([n, v]); }; } |
|||
function step(op) { |
|||
if (f) |
|||
throw new TypeError("Generator is already executing."); |
|||
while (_) |
|||
try { |
|||
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) |
|||
return t; |
|||
if (y = 0, t) |
|||
op = [op[0] & 2, t.value]; |
|||
switch (op[0]) { |
|||
case 0: |
|||
case 1: |
|||
t = op; |
|||
break; |
|||
case 4: |
|||
_.label++; |
|||
return { value: op[1], done: false }; |
|||
case 5: |
|||
_.label++; |
|||
y = op[1]; |
|||
op = [0]; |
|||
continue; |
|||
case 7: |
|||
op = _.ops.pop(); |
|||
_.trys.pop(); |
|||
continue; |
|||
default: |
|||
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { |
|||
_ = 0; |
|||
continue; |
|||
} |
|||
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { |
|||
_.label = op[1]; |
|||
break; |
|||
} |
|||
if (op[0] === 6 && _.label < t[1]) { |
|||
_.label = t[1]; |
|||
t = op; |
|||
break; |
|||
} |
|||
if (t && _.label < t[2]) { |
|||
_.label = t[2]; |
|||
_.ops.push(op); |
|||
break; |
|||
} |
|||
if (t[2]) |
|||
_.ops.pop(); |
|||
_.trys.pop(); |
|||
continue; |
|||
} |
|||
op = body.call(thisArg, _); |
|||
} |
|||
catch (e) { |
|||
op = [6, e]; |
|||
y = 0; |
|||
} |
|||
finally { |
|||
f = t = 0; |
|||
} |
|||
if (op[0] & 5) |
|||
throw op[1]; |
|||
return { value: op[0] ? op[1] : void 0, done: true }; |
|||
} |
|||
} |
|||
var __createBinding = Object.create ? (function (o, m, k, k2) { |
|||
if (k2 === undefined) |
|||
k2 = k; |
|||
Object.defineProperty(o, k2, { enumerable: true, get: function () { return m[k]; } }); |
|||
}) : (function (o, m, k, k2) { |
|||
if (k2 === undefined) |
|||
k2 = k; |
|||
o[k2] = m[k]; |
|||
}); |
|||
function __exportStar(m, exports) { |
|||
for (var p in m) |
|||
if (p !== "default" && !exports.hasOwnProperty(p)) |
|||
__createBinding(exports, m, p); |
|||
} |
|||
function __values(o) { |
|||
var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0; |
|||
if (m) |
|||
return m.call(o); |
|||
if (o && typeof o.length === "number") |
|||
return { |
|||
next: function () { |
|||
if (o && i >= o.length) |
|||
o = void 0; |
|||
return { value: o && o[i++], done: !o }; |
|||
} |
|||
}; |
|||
throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined."); |
|||
} |
|||
function __read(o, n) { |
|||
var m = typeof Symbol === "function" && o[Symbol.iterator]; |
|||
if (!m) |
|||
return o; |
|||
var i = m.call(o), r, ar = [], e; |
|||
try { |
|||
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) |
|||
ar.push(r.value); |
|||
} |
|||
catch (error) { |
|||
e = { error: error }; |
|||
} |
|||
finally { |
|||
try { |
|||
if (r && !r.done && (m = i["return"])) |
|||
m.call(i); |
|||
} |
|||
finally { |
|||
if (e) |
|||
throw e.error; |
|||
} |
|||
} |
|||
return ar; |
|||
} |
|||
function __spread() { |
|||
for (var ar = [], i = 0; i < arguments.length; i++) |
|||
ar = ar.concat(__read(arguments[i])); |
|||
return ar; |
|||
} |
|||
function __spreadArrays() { |
|||
for (var s = 0, i = 0, il = arguments.length; i < il; i++) |
|||
s += arguments[i].length; |
|||
for (var r = Array(s), k = 0, i = 0; i < il; i++) |
|||
for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++) |
|||
r[k] = a[j]; |
|||
return r; |
|||
} |
|||
; |
|||
function __await(v) { |
|||
return this instanceof __await ? (this.v = v, this) : new __await(v); |
|||
} |
|||
function __asyncGenerator(thisArg, _arguments, generator) { |
|||
if (!Symbol.asyncIterator) |
|||
throw new TypeError("Symbol.asyncIterator is not defined."); |
|||
var g = generator.apply(thisArg, _arguments || []), i, q = []; |
|||
return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i; |
|||
function verb(n) { if (g[n]) |
|||
i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; } |
|||
function resume(n, v) { try { |
|||
step(g[n](v)); |
|||
} |
|||
catch (e) { |
|||
settle(q[0][3], e); |
|||
} } |
|||
function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); } |
|||
function fulfill(value) { resume("next", value); } |
|||
function reject(value) { resume("throw", value); } |
|||
function settle(f, v) { if (f(v), q.shift(), q.length) |
|||
resume(q[0][0], q[0][1]); } |
|||
} |
|||
function __asyncDelegator(o) { |
|||
var i, p; |
|||
return i = {}, verb("next"), verb("throw", function (e) { throw e; }), verb("return"), i[Symbol.iterator] = function () { return this; }, i; |
|||
function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === "return" } : f ? f(v) : v; } : f; } |
|||
} |
|||
function __asyncValues(o) { |
|||
if (!Symbol.asyncIterator) |
|||
throw new TypeError("Symbol.asyncIterator is not defined."); |
|||
var m = o[Symbol.asyncIterator], i; |
|||
return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i); |
|||
function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; } |
|||
function settle(resolve, reject, d, v) { Promise.resolve(v).then(function (v) { resolve({ value: v, done: d }); }, reject); } |
|||
} |
|||
function __makeTemplateObject(cooked, raw) { |
|||
if (Object.defineProperty) { |
|||
Object.defineProperty(cooked, "raw", { value: raw }); |
|||
} |
|||
else { |
|||
cooked.raw = raw; |
|||
} |
|||
return cooked; |
|||
} |
|||
; |
|||
var __setModuleDefault = Object.create ? (function (o, v) { |
|||
Object.defineProperty(o, "default", { enumerable: true, value: v }); |
|||
}) : function (o, v) { |
|||
o["default"] = v; |
|||
}; |
|||
function __importStar(mod) { |
|||
if (mod && mod.__esModule) |
|||
return mod; |
|||
var result = {}; |
|||
if (mod != null) |
|||
for (var k in mod) |
|||
if (Object.hasOwnProperty.call(mod, k)) |
|||
__createBinding(result, mod, k); |
|||
__setModuleDefault(result, mod); |
|||
return result; |
|||
} |
|||
function __importDefault(mod) { |
|||
return (mod && mod.__esModule) ? mod : { default: mod }; |
|||
} |
|||
function __classPrivateFieldGet(receiver, privateMap) { |
|||
if (!privateMap.has(receiver)) { |
|||
throw new TypeError("attempted to get private field on non-instance"); |
|||
} |
|||
return privateMap.get(receiver); |
|||
} |
|||
function __classPrivateFieldSet(receiver, privateMap, value) { |
|||
if (!privateMap.has(receiver)) { |
|||
throw new TypeError("attempted to set private field on non-instance"); |
|||
} |
|||
privateMap.set(receiver, value); |
|||
return value; |
|||
} |
|||
|
|||
var ListNode = /** @class */ (function () { |
|||
function ListNode(value) { |
|||
this.value = value; |
|||
} |
|||
return ListNode; |
|||
}()); |
|||
var LinkedList = /** @class */ (function () { |
|||
function LinkedList() { |
|||
this.size = 0; |
|||
} |
|||
Object.defineProperty(LinkedList.prototype, "head", { |
|||
get: function () { |
|||
return this.first; |
|||
}, |
|||
enumerable: false, |
|||
configurable: true |
|||
}); |
|||
Object.defineProperty(LinkedList.prototype, "tail", { |
|||
get: function () { |
|||
return this.last; |
|||
}, |
|||
enumerable: false, |
|||
configurable: true |
|||
}); |
|||
Object.defineProperty(LinkedList.prototype, "length", { |
|||
get: function () { |
|||
return this.size; |
|||
}, |
|||
enumerable: false, |
|||
configurable: true |
|||
}); |
|||
LinkedList.prototype.attach = function (value, previousNode, nextNode) { |
|||
if (!previousNode) |
|||
return this.addHead(value); |
|||
if (!nextNode) |
|||
return this.addTail(value); |
|||
var node = new ListNode(value); |
|||
node.previous = previousNode; |
|||
previousNode.next = node; |
|||
node.next = nextNode; |
|||
nextNode.previous = node; |
|||
this.size++; |
|||
return node; |
|||
}; |
|||
LinkedList.prototype.attachMany = function (values, previousNode, nextNode) { |
|||
if (!values.length) |
|||
return []; |
|||
if (!previousNode) |
|||
return this.addManyHead(values); |
|||
if (!nextNode) |
|||
return this.addManyTail(values); |
|||
var list = new LinkedList(); |
|||
list.addManyTail(values); |
|||
list.first.previous = previousNode; |
|||
previousNode.next = list.first; |
|||
list.last.next = nextNode; |
|||
nextNode.previous = list.last; |
|||
this.size += values.length; |
|||
return list.toNodeArray(); |
|||
}; |
|||
LinkedList.prototype.detach = function (node) { |
|||
if (!node.previous) |
|||
return this.dropHead(); |
|||
if (!node.next) |
|||
return this.dropTail(); |
|||
node.previous.next = node.next; |
|||
node.next.previous = node.previous; |
|||
this.size--; |
|||
return node; |
|||
}; |
|||
LinkedList.prototype.add = function (value) { |
|||
var _this = this; |
|||
return { |
|||
after: function () { |
|||
var _a; |
|||
var params = []; |
|||
for (var _i = 0; _i < arguments.length; _i++) { |
|||
params[_i] = arguments[_i]; |
|||
} |
|||
return (_a = _this.addAfter).call.apply(_a, __spread([_this, value], params)); |
|||
}, |
|||
before: function () { |
|||
var _a; |
|||
var params = []; |
|||
for (var _i = 0; _i < arguments.length; _i++) { |
|||
params[_i] = arguments[_i]; |
|||
} |
|||
return (_a = _this.addBefore).call.apply(_a, __spread([_this, value], params)); |
|||
}, |
|||
byIndex: function (position) { return _this.addByIndex(value, position); }, |
|||
head: function () { return _this.addHead(value); }, |
|||
tail: function () { return _this.addTail(value); }, |
|||
}; |
|||
}; |
|||
LinkedList.prototype.addMany = function (values) { |
|||
var _this = this; |
|||
return { |
|||
after: function () { |
|||
var _a; |
|||
var params = []; |
|||
for (var _i = 0; _i < arguments.length; _i++) { |
|||
params[_i] = arguments[_i]; |
|||
} |
|||
return (_a = _this.addManyAfter).call.apply(_a, __spread([_this, values], params)); |
|||
}, |
|||
before: function () { |
|||
var _a; |
|||
var params = []; |
|||
for (var _i = 0; _i < arguments.length; _i++) { |
|||
params[_i] = arguments[_i]; |
|||
} |
|||
return (_a = _this.addManyBefore).call.apply(_a, __spread([_this, values], params)); |
|||
}, |
|||
byIndex: function (position) { return _this.addManyByIndex(values, position); }, |
|||
head: function () { return _this.addManyHead(values); }, |
|||
tail: function () { return _this.addManyTail(values); }, |
|||
}; |
|||
}; |
|||
LinkedList.prototype.addAfter = function (value, previousValue, compareFn) { |
|||
if (compareFn === void 0) { compareFn = compare; } |
|||
var previous = this.find(function (node) { return compareFn(node.value, previousValue); }); |
|||
return previous ? this.attach(value, previous, previous.next) : this.addTail(value); |
|||
}; |
|||
LinkedList.prototype.addBefore = function (value, nextValue, compareFn) { |
|||
if (compareFn === void 0) { compareFn = compare; } |
|||
var next = this.find(function (node) { return compareFn(node.value, nextValue); }); |
|||
return next ? this.attach(value, next.previous, next) : this.addHead(value); |
|||
}; |
|||
LinkedList.prototype.addByIndex = function (value, position) { |
|||
if (position < 0) |
|||
position += this.size; |
|||
else if (position >= this.size) |
|||
return this.addTail(value); |
|||
if (position <= 0) |
|||
return this.addHead(value); |
|||
var next = this.get(position); |
|||
return this.attach(value, next.previous, next); |
|||
}; |
|||
LinkedList.prototype.addHead = function (value) { |
|||
var node = new ListNode(value); |
|||
node.next = this.first; |
|||
if (this.first) |
|||
this.first.previous = node; |
|||
else |
|||
this.last = node; |
|||
this.first = node; |
|||
this.size++; |
|||
return node; |
|||
}; |
|||
LinkedList.prototype.addTail = function (value) { |
|||
var node = new ListNode(value); |
|||
if (this.first) { |
|||
node.previous = this.last; |
|||
this.last.next = node; |
|||
this.last = node; |
|||
} |
|||
else { |
|||
this.first = node; |
|||
this.last = node; |
|||
} |
|||
this.size++; |
|||
return node; |
|||
}; |
|||
LinkedList.prototype.addManyAfter = function (values, previousValue, compareFn) { |
|||
if (compareFn === void 0) { compareFn = compare; } |
|||
var previous = this.find(function (node) { return compareFn(node.value, previousValue); }); |
|||
return previous ? this.attachMany(values, previous, previous.next) : this.addManyTail(values); |
|||
}; |
|||
LinkedList.prototype.addManyBefore = function (values, nextValue, compareFn) { |
|||
if (compareFn === void 0) { compareFn = compare; } |
|||
var next = this.find(function (node) { return compareFn(node.value, nextValue); }); |
|||
return next ? this.attachMany(values, next.previous, next) : this.addManyHead(values); |
|||
}; |
|||
LinkedList.prototype.addManyByIndex = function (values, position) { |
|||
if (position < 0) |
|||
position += this.size; |
|||
if (position <= 0) |
|||
return this.addManyHead(values); |
|||
if (position >= this.size) |
|||
return this.addManyTail(values); |
|||
var next = this.get(position); |
|||
return this.attachMany(values, next.previous, next); |
|||
}; |
|||
LinkedList.prototype.addManyHead = function (values) { |
|||
var _this = this; |
|||
return values.reduceRight(function (nodes, value) { |
|||
nodes.unshift(_this.addHead(value)); |
|||
return nodes; |
|||
}, []); |
|||
}; |
|||
LinkedList.prototype.addManyTail = function (values) { |
|||
var _this = this; |
|||
return values.map(function (value) { return _this.addTail(value); }); |
|||
}; |
|||
LinkedList.prototype.drop = function () { |
|||
var _this = this; |
|||
return { |
|||
byIndex: function (position) { return _this.dropByIndex(position); }, |
|||
byValue: function () { |
|||
var params = []; |
|||
for (var _i = 0; _i < arguments.length; _i++) { |
|||
params[_i] = arguments[_i]; |
|||
} |
|||
return _this.dropByValue.apply(_this, params); |
|||
}, |
|||
byValueAll: function () { |
|||
var params = []; |
|||
for (var _i = 0; _i < arguments.length; _i++) { |
|||
params[_i] = arguments[_i]; |
|||
} |
|||
return _this.dropByValueAll.apply(_this, params); |
|||
}, |
|||
head: function () { return _this.dropHead(); }, |
|||
tail: function () { return _this.dropTail(); }, |
|||
}; |
|||
}; |
|||
LinkedList.prototype.dropMany = function (count) { |
|||
var _this = this; |
|||
return { |
|||
byIndex: function (position) { return _this.dropManyByIndex(count, position); }, |
|||
head: function () { return _this.dropManyHead(count); }, |
|||
tail: function () { return _this.dropManyTail(count); }, |
|||
}; |
|||
}; |
|||
LinkedList.prototype.dropByIndex = function (position) { |
|||
if (position < 0) |
|||
position += this.size; |
|||
var current = this.get(position); |
|||
return current ? this.detach(current) : undefined; |
|||
}; |
|||
LinkedList.prototype.dropByValue = function (value, compareFn) { |
|||
if (compareFn === void 0) { compareFn = compare; } |
|||
var position = this.findIndex(function (node) { return compareFn(node.value, value); }); |
|||
return position < 0 ? undefined : this.dropByIndex(position); |
|||
}; |
|||
LinkedList.prototype.dropByValueAll = function (value, compareFn) { |
|||
if (compareFn === void 0) { compareFn = compare; } |
|||
var dropped = []; |
|||
for (var current = this.first, position = 0; current; position++, current = current.next) { |
|||
if (compareFn(current.value, value)) { |
|||
dropped.push(this.dropByIndex(position - dropped.length)); |
|||
} |
|||
} |
|||
return dropped; |
|||
}; |
|||
LinkedList.prototype.dropHead = function () { |
|||
var head = this.first; |
|||
if (head) { |
|||
this.first = head.next; |
|||
if (this.first) |
|||
this.first.previous = undefined; |
|||
else |
|||
this.last = undefined; |
|||
this.size--; |
|||
return head; |
|||
} |
|||
return undefined; |
|||
}; |
|||
LinkedList.prototype.dropTail = function () { |
|||
var tail = this.last; |
|||
if (tail) { |
|||
this.last = tail.previous; |
|||
if (this.last) |
|||
this.last.next = undefined; |
|||
else |
|||
this.first = undefined; |
|||
this.size--; |
|||
return tail; |
|||
} |
|||
return undefined; |
|||
}; |
|||
LinkedList.prototype.dropManyByIndex = function (count, position) { |
|||
if (count <= 0) |
|||
return []; |
|||
if (position < 0) |
|||
position = Math.max(position + this.size, 0); |
|||
else if (position >= this.size) |
|||
return []; |
|||
count = Math.min(count, this.size - position); |
|||
var dropped = []; |
|||
while (count--) { |
|||
var current = this.get(position); |
|||
dropped.push(this.detach(current)); |
|||
} |
|||
return dropped; |
|||
}; |
|||
LinkedList.prototype.dropManyHead = function (count) { |
|||
if (count <= 0) |
|||
return []; |
|||
count = Math.min(count, this.size); |
|||
var dropped = []; |
|||
while (count--) |
|||
dropped.unshift(this.dropHead()); |
|||
return dropped; |
|||
}; |
|||
LinkedList.prototype.dropManyTail = function (count) { |
|||
if (count <= 0) |
|||
return []; |
|||
count = Math.min(count, this.size); |
|||
var dropped = []; |
|||
while (count--) |
|||
dropped.push(this.dropTail()); |
|||
return dropped; |
|||
}; |
|||
LinkedList.prototype.find = function (predicate) { |
|||
for (var current = this.first, position = 0; current; position++, current = current.next) { |
|||
if (predicate(current, position, this)) |
|||
return current; |
|||
} |
|||
return undefined; |
|||
}; |
|||
LinkedList.prototype.findIndex = function (predicate) { |
|||
for (var current = this.first, position = 0; current; position++, current = current.next) { |
|||
if (predicate(current, position, this)) |
|||
return position; |
|||
} |
|||
return -1; |
|||
}; |
|||
LinkedList.prototype.forEach = function (iteratorFn) { |
|||
for (var node = this.first, position = 0; node; position++, node = node.next) { |
|||
iteratorFn(node, position, this); |
|||
} |
|||
}; |
|||
LinkedList.prototype.get = function (position) { |
|||
return this.find(function (_, index) { return position === index; }); |
|||
}; |
|||
LinkedList.prototype.indexOf = function (value, compareFn) { |
|||
if (compareFn === void 0) { compareFn = compare; } |
|||
return this.findIndex(function (node) { return compareFn(node.value, value); }); |
|||
}; |
|||
LinkedList.prototype.toArray = function () { |
|||
var array = new Array(this.size); |
|||
this.forEach(function (node, index) { return (array[index] = node.value); }); |
|||
return array; |
|||
}; |
|||
LinkedList.prototype.toNodeArray = function () { |
|||
var array = new Array(this.size); |
|||
this.forEach(function (node, index) { return (array[index] = node); }); |
|||
return array; |
|||
}; |
|||
LinkedList.prototype.toString = function (mapperFn) { |
|||
if (mapperFn === void 0) { mapperFn = JSON.stringify; } |
|||
return this.toArray() |
|||
.map(function (value) { return mapperFn(value); }) |
|||
.join(' <-> '); |
|||
}; |
|||
// Cannot use Generator type because of ng-packagr
|
|||
LinkedList.prototype[Symbol.iterator] = function () { |
|||
var node, position; |
|||
return __generator(this, function (_a) { |
|||
switch (_a.label) { |
|||
case 0: |
|||
node = this.first, position = 0; |
|||
_a.label = 1; |
|||
case 1: |
|||
if (!node) return [3 /*break*/, 4]; |
|||
return [4 /*yield*/, node.value]; |
|||
case 2: |
|||
_a.sent(); |
|||
_a.label = 3; |
|||
case 3: |
|||
position++, node = node.next; |
|||
return [3 /*break*/, 1]; |
|||
case 4: return [2 /*return*/]; |
|||
} |
|||
}); |
|||
}; |
|||
return LinkedList; |
|||
}()); |
|||
|
|||
/* |
|||
* Public API Surface of utils |
|||
*/ |
|||
|
|||
/** |
|||
* Generated bundle index. Do not edit. |
|||
*/ |
|||
|
|||
exports.LinkedList = LinkedList; |
|||
exports.ListNode = ListNode; |
|||
|
|||
Object.defineProperty(exports, '__esModule', { value: true }); |
|||
|
|||
}))); |
|||
//# sourceMappingURL=abp-utils.umd.js.map
|
|||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates["en-CA"]={days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],daysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],daysMin:["Su","Mo","Tu","We","Th","Fr","Sa"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],monthsShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],today:"Today",monthsTitle:"Months",clear:"Clear",weekStart:0,format:"yyyy-mm-dd"},a.fn.datepicker.deprecated("This filename doesn't follow the convention, use bootstrap-datepicker.en-CA.js instead.")}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates["ar-DZ"]={days:["الأحد","الاثنين","الثلاثاء","الأربعاء","الخميس","الجمعة","السبت","الأحد"],daysShort:["أحد","اثنين","ثلاثاء","أربعاء","خميس","جمعة","سبت","أحد"],daysMin:["ح","ن","ث","ع","خ","ج","س","ح"],months:["جانفي","فيفري","مارس","أفريل","ماي","جوان","جويليه","أوت","سبتمبر","أكتوبر","نوفمبر","ديسمبر"],monthsShort:["جانفي","فيفري","مارس","أفريل","ماي","جوان","جويليه","أوت","سبتمبر","أكتوبر","نوفمبر","ديسمبر"],today:"هذا اليوم",rtl:!0,monthsTitle:"أشهر",clear:"إزالة",format:"yyyy/mm/dd",weekStart:0}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates["ar-tn"]={days:["الأحد","الاثنين","الثلاثاء","الأربعاء","الخميس","الجمعة","السبت","الأحد"],daysShort:["أحد","اثنين","ثلاثاء","أربعاء","خميس","جمعة","سبت","أحد"],daysMin:["ح","ن","ث","ع","خ","ج","س","ح"],months:["جانفي","فيفري","مارس","أفريل","ماي","جوان","جويليه","أوت","سبتمبر","أكتوبر","نوفمبر","ديسمبر"],monthsShort:["جانفي","فيفري","مارس","أفريل","ماي","جوان","جويليه","أوت","سبتمبر","أكتوبر","نوفمبر","ديسمبر"],today:"هذا اليوم",rtl:!0}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.ar={days:["الأحد","الاثنين","الثلاثاء","الأربعاء","الخميس","الجمعة","السبت","الأحد"],daysShort:["أحد","اثنين","ثلاثاء","أربعاء","خميس","جمعة","سبت","أحد"],daysMin:["ح","ن","ث","ع","خ","ج","س","ح"],months:["يناير","فبراير","مارس","أبريل","مايو","يونيو","يوليو","أغسطس","سبتمبر","أكتوبر","نوفمبر","ديسمبر"],monthsShort:["يناير","فبراير","مارس","أبريل","مايو","يونيو","يوليو","أغسطس","سبتمبر","أكتوبر","نوفمبر","ديسمبر"],today:"هذا اليوم",rtl:!0}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.az={days:["Bazar","Bazar ertəsi","Çərşənbə axşamı","Çərşənbə","Cümə axşamı","Cümə","Şənbə"],daysShort:["B.","B.e","Ç.a","Ç.","C.a","C.","Ş."],daysMin:["B.","B.e","Ç.a","Ç.","C.a","C.","Ş."],months:["Yanvar","Fevral","Mart","Aprel","May","İyun","İyul","Avqust","Sentyabr","Oktyabr","Noyabr","Dekabr"],monthsShort:["Yan","Fev","Mar","Apr","May","İyun","İyul","Avq","Sen","Okt","Noy","Dek"],today:"Bu gün",weekStart:1,clear:"Təmizlə",monthsTitle:"Aylar"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.bg={days:["Неделя","Понеделник","Вторник","Сряда","Четвъртък","Петък","Събота"],daysShort:["Нед","Пон","Вто","Сря","Чет","Пет","Съб"],daysMin:["Н","П","В","С","Ч","П","С"],months:["Януари","Февруари","Март","Април","Май","Юни","Юли","Август","Септември","Октомври","Ноември","Декември"],monthsShort:["Ян","Фев","Мар","Апр","Май","Юни","Юли","Авг","Сеп","Окт","Ное","Дек"],today:"днес"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.bm={days:["Kari","Ntɛnɛn","Tarata","Araba","Alamisa","Juma","Sibiri"],daysShort:["Kar","Ntɛ","Tar","Ara","Ala","Jum","Sib"],daysMin:["Ka","Nt","Ta","Ar","Al","Ju","Si"],months:["Zanwuyekalo","Fewuruyekalo","Marisikalo","Awirilikalo","Mɛkalo","Zuwɛnkalo","Zuluyekalo","Utikalo","Sɛtanburukalo","ɔkutɔburukalo","Nowanburukalo","Desanburukalo"],monthsShort:["Zan","Few","Mar","Awi","Mɛ","Zuw","Zul","Uti","Sɛt","ɔku","Now","Des"],today:"Bi",monthsTitle:"Kalo",clear:"Ka jɔsi",weekStart:1,format:"dd/mm/yyyy"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.bn={days:["রবিবার","সোমবার","মঙ্গলবার","বুধবার","বৃহস্পতিবার","শুক্রবার","শনিবার"],daysShort:["রবিবার","সোমবার","মঙ্গলবার","বুধবার","বৃহস্পতিবার","শুক্রবার","শনিবার"],daysMin:["রবি","সোম","মঙ্গল","বুধ","বৃহস্পতি","শুক্র","শনি"],months:["জানুয়ারী","ফেব্রুয়ারি","মার্চ","এপ্রিল","মে","জুন","জুলাই","অগাস্ট","সেপ্টেম্বর","অক্টোবর","নভেম্বর","ডিসেম্বর"],monthsShort:["জানুয়ারী","ফেব্রুয়ারি","মার্চ","এপ্রিল","মে","জুন","জুলাই","অগাস্ট","সেপ্টেম্বর","অক্টোবর","নভেম্বর","ডিসেম্বর"],today:"আজ",monthsTitle:"মাস",clear:"পরিষ্কার",weekStart:0,format:"mm/dd/yyyy"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.br={days:["Sul","Lun","Meurzh","Merc'her","Yaou","Gwener","Sadorn"],daysShort:["Sul","Lun","Meu.","Mer.","Yao.","Gwe.","Sad."],daysMin:["Su","L","Meu","Mer","Y","G","Sa"],months:["Genver","C'hwevrer","Meurzh","Ebrel","Mae","Mezheven","Gouere","Eost","Gwengolo","Here","Du","Kerzu"],monthsShort:["Genv.","C'hw.","Meur.","Ebre.","Mae","Mezh.","Goue.","Eost","Gwen.","Here","Du","Kerz."],today:"Hiziv",monthsTitle:"Miz",clear:"Dilemel",weekStart:1,format:"dd/mm/yyyy"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.bs={days:["Nedjelja","Ponedjeljak","Utorak","Srijeda","Četvrtak","Petak","Subota"],daysShort:["Ned","Pon","Uto","Sri","Čet","Pet","Sub"],daysMin:["N","Po","U","Sr","Č","Pe","Su"],months:["Januar","Februar","Mart","April","Maj","Juni","Juli","August","Septembar","Oktobar","Novembar","Decembar"],monthsShort:["Jan","Feb","Mar","Apr","Maj","Jun","Jul","Aug","Sep","Okt","Nov","Dec"],today:"Danas",weekStart:1,format:"dd.mm.yyyy"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.ca={days:["diumenge","dilluns","dimarts","dimecres","dijous","divendres","dissabte"],daysShort:["dg.","dl.","dt.","dc.","dj.","dv.","ds."],daysMin:["dg","dl","dt","dc","dj","dv","ds"],months:["gener","febrer","març","abril","maig","juny","juliol","agost","setembre","octubre","novembre","desembre"],monthsShort:["gen.","febr.","març","abr.","maig","juny","jul.","ag.","set.","oct.","nov.","des."],today:"Avui",monthsTitle:"Mesos",clear:"Esborra",weekStart:1,format:"dd/mm/yyyy"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.cs={days:["Neděle","Pondělí","Úterý","Středa","Čtvrtek","Pátek","Sobota"],daysShort:["Ned","Pon","Úte","Stř","Čtv","Pát","Sob"],daysMin:["Ne","Po","Út","St","Čt","Pá","So"],months:["Leden","Únor","Březen","Duben","Květen","Červen","Červenec","Srpen","Září","Říjen","Listopad","Prosinec"],monthsShort:["Led","Úno","Bře","Dub","Kvě","Čer","Čnc","Srp","Zář","Říj","Lis","Pro"],today:"Dnes",clear:"Vymazat",monthsTitle:"Měsíc",weekStart:1,format:"dd.mm.yyyy"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.cy={days:["Sul","Llun","Mawrth","Mercher","Iau","Gwener","Sadwrn"],daysShort:["Sul","Llu","Maw","Mer","Iau","Gwe","Sad"],daysMin:["Su","Ll","Ma","Me","Ia","Gwe","Sa"],months:["Ionawr","Chewfror","Mawrth","Ebrill","Mai","Mehefin","Gorfennaf","Awst","Medi","Hydref","Tachwedd","Rhagfyr"],monthsShort:["Ion","Chw","Maw","Ebr","Mai","Meh","Gor","Aws","Med","Hyd","Tach","Rha"],today:"Heddiw"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.da={days:["Søndag","Mandag","Tirsdag","Onsdag","Torsdag","Fredag","Lørdag"],daysShort:["Søn","Man","Tir","Ons","Tor","Fre","Lør"],daysMin:["Sø","Ma","Ti","On","To","Fr","Lø"],months:["Januar","Februar","Marts","April","Maj","Juni","Juli","August","September","Oktober","November","December"],monthsShort:["Jan","Feb","Mar","Apr","Maj","Jun","Jul","Aug","Sep","Okt","Nov","Dec"],today:"I Dag",weekStart:1,clear:"Nulstil",format:"dd/mm/yyyy",monthsTitle:"Måneder"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.de={days:["Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag"],daysShort:["So","Mo","Di","Mi","Do","Fr","Sa"],daysMin:["So","Mo","Di","Mi","Do","Fr","Sa"],months:["Januar","Februar","März","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"],monthsShort:["Jan","Feb","Mär","Apr","Mai","Jun","Jul","Aug","Sep","Okt","Nov","Dez"],today:"Heute",monthsTitle:"Monate",clear:"Löschen",weekStart:1,format:"dd.mm.yyyy"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.el={days:["Κυριακή","Δευτέρα","Τρίτη","Τετάρτη","Πέμπτη","Παρασκευή","Σάββατο"],daysShort:["Κυρ","Δευ","Τρι","Τετ","Πεμ","Παρ","Σαβ"],daysMin:["Κυ","Δε","Τρ","Τε","Πε","Πα","Σα"],months:["Ιανουάριος","Φεβρουάριος","Μάρτιος","Απρίλιος","Μάιος","Ιούνιος","Ιούλιος","Αύγουστος","Σεπτέμβριος","Οκτώβριος","Νοέμβριος","Δεκέμβριος"],monthsShort:["Ιαν","Φεβ","Μαρ","Απρ","Μάι","Ιουν","Ιουλ","Αυγ","Σεπ","Οκτ","Νοε","Δεκ"],today:"Σήμερα",clear:"Καθαρισμός",weekStart:1,format:"d/m/yyyy"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates["en-AU"]={days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],daysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],daysMin:["Su","Mo","Tu","We","Th","Fr","Sa"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],monthsShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],today:"Today",monthsTitle:"Months",clear:"Clear",weekStart:1,format:"d/mm/yyyy"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates["en-CA"]={days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],daysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],daysMin:["Su","Mo","Tu","We","Th","Fr","Sa"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],monthsShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],today:"Today",monthsTitle:"Months",clear:"Clear",weekStart:0,format:"yyyy-mm-dd"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates["en-GB"]={days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],daysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],daysMin:["Su","Mo","Tu","We","Th","Fr","Sa"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],monthsShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],today:"Today",monthsTitle:"Months",clear:"Clear",weekStart:1,format:"dd/mm/yyyy"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates["en-IE"]={days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],daysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],daysMin:["Su","Mo","Tu","We","Th","Fr","Sa"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],monthsShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],today:"Today",monthsTitle:"Months",clear:"Clear",weekStart:1,format:"dd/mm/yyyy"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates["en-NZ"]={days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],daysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],daysMin:["Su","Mo","Tu","We","Th","Fr","Sa"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],monthsShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],today:"Today",monthsTitle:"Months",clear:"Clear",weekStart:1,format:"d/mm/yyyy"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates["en-US"]={days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],daysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],daysMin:["Su","Mo","Tu","We","Th","Fr","Sa"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],monthsShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],today:"Today",monthsTitle:"Months",clear:"Clear",weekStart:0,format:"m/d/yyyy"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates["en-ZA"]={days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],daysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],daysMin:["Su","Mo","Tu","We","Th","Fr","Sa"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],monthsShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],today:"Today",monthsTitle:"Months",clear:"Clear",weekStart:1,format:"yyyy/mm/d"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.eo={days:["dimanĉo","lundo","mardo","merkredo","ĵaŭdo","vendredo","sabato"],daysShort:["dim.","lun.","mar.","mer.","ĵaŭ.","ven.","sam."],daysMin:["d","l","ma","me","ĵ","v","s"],months:["januaro","februaro","marto","aprilo","majo","junio","julio","aŭgusto","septembro","oktobro","novembro","decembro"],monthsShort:["jan.","feb.","mar.","apr.","majo","jun.","jul.","aŭg.","sep.","okt.","nov.","dec."],today:"Hodiaŭ",clear:"Nuligi",weekStart:1,format:"yyyy-mm-dd"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.es={days:["Domingo","Lunes","Martes","Miércoles","Jueves","Viernes","Sábado"],daysShort:["Dom","Lun","Mar","Mié","Jue","Vie","Sáb"],daysMin:["Do","Lu","Ma","Mi","Ju","Vi","Sa"],months:["Enero","Febrero","Marzo","Abril","Mayo","Junio","Julio","Agosto","Septiembre","Octubre","Noviembre","Diciembre"],monthsShort:["Ene","Feb","Mar","Abr","May","Jun","Jul","Ago","Sep","Oct","Nov","Dic"],today:"Hoy",monthsTitle:"Meses",clear:"Borrar",weekStart:1,format:"dd/mm/yyyy"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.et={days:["Pühapäev","Esmaspäev","Teisipäev","Kolmapäev","Neljapäev","Reede","Laupäev"],daysShort:["Pühap","Esmasp","Teisip","Kolmap","Neljap","Reede","Laup"],daysMin:["P","E","T","K","N","R","L"],months:["Jaanuar","Veebruar","Märts","Aprill","Mai","Juuni","Juuli","August","September","Oktoober","November","Detsember"],monthsShort:["Jaan","Veebr","Märts","Apr","Mai","Juuni","Juuli","Aug","Sept","Okt","Nov","Dets"],today:"Täna",clear:"Tühjenda",weekStart:1,format:"dd.mm.yyyy"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.eu={days:["Igandea","Astelehena","Asteartea","Asteazkena","Osteguna","Ostirala","Larunbata"],daysShort:["Ig","Al","Ar","Az","Og","Ol","Lr"],daysMin:["Ig","Al","Ar","Az","Og","Ol","Lr"],months:["Urtarrila","Otsaila","Martxoa","Apirila","Maiatza","Ekaina","Uztaila","Abuztua","Iraila","Urria","Azaroa","Abendua"],monthsShort:["Urt","Ots","Mar","Api","Mai","Eka","Uzt","Abu","Ira","Urr","Aza","Abe"],today:"Gaur",monthsTitle:"Hilabeteak",clear:"Ezabatu",weekStart:1,format:"yyyy/mm/dd"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.fa={days:["یکشنبه","دوشنبه","سهشنبه","چهارشنبه","پنجشنبه","جمعه","شنبه","یکشنبه"],daysShort:["یک","دو","سه","چهار","پنج","جمعه","شنبه","یک"],daysMin:["ی","د","س","چ","پ","ج","ش","ی"],months:["ژانویه","فوریه","مارس","آوریل","مه","ژوئن","ژوئیه","اوت","سپتامبر","اکتبر","نوامبر","دسامبر"],monthsShort:["ژان","فور","مار","آور","مه","ژون","ژوی","اوت","سپت","اکت","نوا","دسا"],today:"امروز",clear:"پاک کن",weekStart:1,format:"yyyy/mm/dd"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.fi={days:["sunnuntai","maanantai","tiistai","keskiviikko","torstai","perjantai","lauantai"],daysShort:["sun","maa","tii","kes","tor","per","lau"],daysMin:["su","ma","ti","ke","to","pe","la"],months:["tammikuu","helmikuu","maaliskuu","huhtikuu","toukokuu","kesäkuu","heinäkuu","elokuu","syyskuu","lokakuu","marraskuu","joulukuu"],monthsShort:["tammi","helmi","maalis","huhti","touko","kesä","heinä","elo","syys","loka","marras","joulu"],today:"tänään",clear:"Tyhjennä",weekStart:1,format:"d.m.yyyy"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.fo={days:["Sunnudagur","Mánadagur","Týsdagur","Mikudagur","Hósdagur","Fríggjadagur","Leygardagur"],daysShort:["Sun","Mán","Týs","Mik","Hós","Frí","Ley"],daysMin:["Su","Má","Tý","Mi","Hó","Fr","Le"],months:["Januar","Februar","Marts","Apríl","Mei","Juni","Juli","August","Septembur","Oktobur","Novembur","Desembur"],monthsShort:["Jan","Feb","Mar","Apr","Mei","Jun","Jul","Aug","Sep","Okt","Nov","Des"],today:"Í Dag",clear:"Reinsa"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.fr={days:["Dimanche","Lundi","Mardi","Mercredi","Jeudi","Vendredi","Samedi"],daysShort:["Dim","Lun","Mar","Mer","Jeu","Ven","Sam"],daysMin:["D","L","Ma","Me","J","V","S"],months:["Janvier","Février","Mars","Avril","Mai","Juin","Juillet","Août","Septembre","Octobre","Novembre","Décembre"],monthsShort:["Jan","Fév","Mar","Avr","Mai","Jui","Jul","Aou","Sep","Oct","Nov","Déc"],today:"Aujourd'hui",monthsTitle:"Mois",clear:"Effacer",weekStart:1,format:"dd.mm.yyyy"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.fr={days:["dimanche","lundi","mardi","mercredi","jeudi","vendredi","samedi"],daysShort:["dim.","lun.","mar.","mer.","jeu.","ven.","sam."],daysMin:["d","l","ma","me","j","v","s"],months:["janvier","février","mars","avril","mai","juin","juillet","août","septembre","octobre","novembre","décembre"],monthsShort:["janv.","févr.","mars","avril","mai","juin","juil.","août","sept.","oct.","nov.","déc."],today:"Aujourd'hui",monthsTitle:"Mois",clear:"Effacer",weekStart:1,format:"dd/mm/yyyy"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.gl={days:["Domingo","Luns","Martes","Mércores","Xoves","Venres","Sábado"],daysShort:["Dom","Lun","Mar","Mér","Xov","Ven","Sáb"],daysMin:["Do","Lu","Ma","Me","Xo","Ve","Sa"],months:["Xaneiro","Febreiro","Marzo","Abril","Maio","Xuño","Xullo","Agosto","Setembro","Outubro","Novembro","Decembro"],monthsShort:["Xan","Feb","Mar","Abr","Mai","Xun","Xul","Ago","Sep","Out","Nov","Dec"],today:"Hoxe",clear:"Limpar",weekStart:1,format:"dd/mm/yyyy"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.he={days:["ראשון","שני","שלישי","רביעי","חמישי","שישי","שבת","ראשון"],daysShort:["א","ב","ג","ד","ה","ו","ש","א"],daysMin:["א","ב","ג","ד","ה","ו","ש","א"],months:["ינואר","פברואר","מרץ","אפריל","מאי","יוני","יולי","אוגוסט","ספטמבר","אוקטובר","נובמבר","דצמבר"],monthsShort:["ינו","פבר","מרץ","אפר","מאי","יונ","יול","אוג","ספט","אוק","נוב","דצמ"],today:"היום",rtl:!0}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.hi={days:["रविवार","सोमवार","मंगलवार","बुधवार","गुरुवार","शुक्रवार","शनिवार"],daysShort:["सूर्य","सोम","मंगल","बुध","गुरु","शुक्र","शनि"],daysMin:["र","सो","मं","बु","गु","शु","श"],months:["जनवरी","फ़रवरी","मार्च","अप्रैल","मई","जून","जुलाई","अगस्त","सितम्बर","अक्टूबर","नवंबर","दिसम्बर"],monthsShort:["जन","फ़रवरी","मार्च","अप्रैल","मई","जून","जुलाई","अगस्त","सितं","अक्टूबर","नवं","दिसम्बर"],today:"आज",monthsTitle:"महीने",clear:"साफ",weekStart:1,format:"dd / mm / yyyy"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.hr={days:["Nedjelja","Ponedjeljak","Utorak","Srijeda","Četvrtak","Petak","Subota"],daysShort:["Ned","Pon","Uto","Sri","Čet","Pet","Sub"],daysMin:["Ne","Po","Ut","Sr","Če","Pe","Su"],months:["Siječanj","Veljača","Ožujak","Travanj","Svibanj","Lipanj","Srpanj","Kolovoz","Rujan","Listopad","Studeni","Prosinac"],monthsShort:["Sij","Velj","Ožu","Tra","Svi","Lip","Srp","Kol","Ruj","Lis","Stu","Pro"],today:"Danas"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.hu={days:["vasárnap","hétfő","kedd","szerda","csütörtök","péntek","szombat"],daysShort:["vas","hét","ked","sze","csü","pén","szo"],daysMin:["V","H","K","Sze","Cs","P","Szo"],months:["január","február","március","április","május","június","július","augusztus","szeptember","október","november","december"],monthsShort:["jan","feb","már","ápr","máj","jún","júl","aug","sze","okt","nov","dec"],today:"ma",weekStart:1,clear:"töröl",titleFormat:"yyyy. MM",format:"yyyy.mm.dd"}}(jQuery); |
|||
@ -0,0 +1 @@ |
|||
!function(a){a.fn.datepicker.dates.hy={days:["Կիրակի","Երկուշաբթի","Երեքշաբթի","Չորեքշաբթի","Հինգշաբթի","Ուրբաթ","Շաբաթ"],daysShort:["Կիր","Երկ","Երե","Չոր","Հին","Ուրբ","Շաբ"],daysMin:["Կի","Եկ","Եք","Չո","Հի","Ու","Շա"],months:["Հունվար","Փետրվար","Մարտ","Ապրիլ","Մայիս","Հունիս","Հուլիս","Օգոստոս","Սեպտեմբեր","Հոկտեմբեր","Նոյեմբեր","Դեկտեմբեր"],monthsShort:["Հնվ","Փետ","Մար","Ապր","Մայ","Հուն","Հուլ","Օգս","Սեպ","Հոկ","Նոյ","Դեկ"],today:"Այսօր",clear:"Ջնջել",format:"dd.mm.yyyy",weekStart:1,monthsTitle:"Ամիսնէր"}}(jQuery); |
|||
Some files were not shown because too many files changed in this diff
Loading…
Reference in new issue