|
|
|
@ -1,4 +1,5 @@
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.Globalization;
|
|
|
|
|
using Volo.Abp.AspNetCore.Mvc.UI.Bundling;
|
|
|
|
|
using Volo.Abp.AspNetCore.Mvc.UI.Packages.JQuery;
|
|
|
|
|
using Volo.Abp.Modularity;
|
|
|
|
@ -12,5 +13,16 @@ namespace Volo.Abp.AspNetCore.Mvc.UI.Packages.Timeago
|
|
|
|
|
{
|
|
|
|
|
context.Files.AddIfNotContains("/libs/timeago/jquery.timeago.js");
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public override void ConfigureDynamicResources(BundleConfigurationContext context)
|
|
|
|
|
{
|
|
|
|
|
var cultureName = CultureInfo.CurrentUICulture.TwoLetterISOLanguageName;
|
|
|
|
|
var cultureFileName = $"/libs/timeago/locales/jquery.timeago.{cultureName}.js";
|
|
|
|
|
|
|
|
|
|
if (context.FileProvider.GetFileInfo(cultureFileName).Exists)
|
|
|
|
|
{
|
|
|
|
|
context.Files.Add(cultureFileName);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|