diff --git a/Nucleus.sln b/Nucleus.sln index 8aa53ab..df481f0 100644 --- a/Nucleus.sln +++ b/Nucleus.sln @@ -7,8 +7,6 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "test", "test", "{51A63C9A-C EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{CBE903BE-AD0D-4857-98E4-CCA1AD73902E}" EndProject -Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "doc", "doc", "{47DBDDFE-C870-4057-8312-219461BA268C}" -EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Nucleus.Application", "src\Nucleus.Application\Nucleus.Application.csproj", "{788EBFEF-7A50-4AB7-807A-4147D49E237E}" EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Nucleus.EntityFramework", "src\Nucleus.EntityFramework\Nucleus.EntityFramework.csproj", "{73195EBE-BDE4-428C-865D-E7F589F3DD52}" @@ -27,7 +25,7 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Nucleus.Tests.Application", EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Nucleus.Tests.Web.Api", "test\Nucleus.Tests.Web.Api\Nucleus.Tests.Web.Api.csproj", "{E36E92AC-E12D-4B70-A355-6CBC1AFDAB43}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Nucleus.Web.Vue", "src\Nucleus.Web.Vue\Nucleus.Web.Vue.csproj", "{3979C24B-DFE1-4090-9743-8DFA9C52878E}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Nucleus.Web.Vue", "src\Nucleus.Web.Vue\Nucleus.Web.Vue.csproj", "{3979C24B-DFE1-4090-9743-8DFA9C52878E}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution diff --git a/README.md b/README.md index 7cc4e0f..d43fa69 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,12 @@ +Nucleus + # Nucleus Web API startup template with a Vue Client demo. +
+
+ ## How to Start? - Select `Nucleus.Web.Api` project "**Set as Startup Project**" @@ -40,6 +45,63 @@ Web API startup template with a Vue Client demo. Swagger UI +# Document + +## Adding New Language + +- Add json file to store language keys and values to `Nucleus\src\Nucleus.Web.Vue\src\assets\js\locales\tr.json` +- Copy `en.json` content and translate the values to target language. +- Add country flag to `Nucleus.Web.Vue\src\assets\images\icons\flags\tr.png`. Get images from http://www.iconarchive.com/show/flag-icons-by-gosquared.html +- Add language to language selection menu in `Nucleus\src\Nucleus.Web.Vue\src\account\account-layout.vue` and `Nucleus\src\Nucleus.Web.Vue\src\admin\components\menu\top-menu\top-menu.vue` like following + +**account-layout.vue** + +````html + + + + + {{selectedLanguage.languageName}} + arrow_drop_down + + + + + English + + + + Türkçe + + + + +```` + +**top-menu.vue** + +````html + + + + {{selectedLanguage.languageName}} + arrow_drop_down + + + + + English + + + + Türkçe + + + +```` + +### + ### Tags & Technologies - [ASP.NET Core Web API](https://docs.microsoft.com/en-us/aspnet/core/web-api/?view=aspnetcore-2.1) diff --git a/_images/Nucleus.png b/_images/Nucleus.png new file mode 100644 index 0000000..277400c Binary files /dev/null and b/_images/Nucleus.png differ diff --git a/src/Nucleus.Application/Account/Dto/ChangePasswordInput.cs b/src/Nucleus.Application/Account/Dto/ChangePasswordInput.cs index 7c88f63..27cbec7 100644 --- a/src/Nucleus.Application/Account/Dto/ChangePasswordInput.cs +++ b/src/Nucleus.Application/Account/Dto/ChangePasswordInput.cs @@ -1,4 +1,4 @@ -namespace Nucleus.Application.Users.Dto +namespace Nucleus.Application.Account.Dto { public class ChangePasswordInput { diff --git a/src/Nucleus.Application/Account/Dto/LoginInput.cs b/src/Nucleus.Application/Account/Dto/LoginInput.cs index 4d928ae..c66087f 100644 --- a/src/Nucleus.Application/Account/Dto/LoginInput.cs +++ b/src/Nucleus.Application/Account/Dto/LoginInput.cs @@ -1,4 +1,4 @@ -namespace Nucleus.Application.Users.Dto +namespace Nucleus.Application.Account.Dto { public class LoginInput { diff --git a/src/Nucleus.Application/Account/Dto/LoginOutput.cs b/src/Nucleus.Application/Account/Dto/LoginOutput.cs index e9e073a..5d4ab16 100644 --- a/src/Nucleus.Application/Account/Dto/LoginOutput.cs +++ b/src/Nucleus.Application/Account/Dto/LoginOutput.cs @@ -1,4 +1,4 @@ -namespace Nucleus.Application.Users.Dto +namespace Nucleus.Application.Account.Dto { public class LoginOutput { diff --git a/src/Nucleus.Application/Account/Dto/RegisterInput.cs b/src/Nucleus.Application/Account/Dto/RegisterInput.cs index d32a926..6558bc2 100644 --- a/src/Nucleus.Application/Account/Dto/RegisterInput.cs +++ b/src/Nucleus.Application/Account/Dto/RegisterInput.cs @@ -1,4 +1,4 @@ -namespace Nucleus.Application.Users.Dto +namespace Nucleus.Application.Account.Dto { public class RegisterInput { diff --git a/src/Nucleus.Application/Permissions/IPermissionAppService.cs b/src/Nucleus.Application/Permissions/IPermissionAppService.cs index a66ab74..d2c0de0 100644 --- a/src/Nucleus.Application/Permissions/IPermissionAppService.cs +++ b/src/Nucleus.Application/Permissions/IPermissionAppService.cs @@ -1,6 +1,7 @@ using System.Collections.Generic; using System.Threading.Tasks; using Nucleus.Application.Permissions.Dto; +using Nucleus.Core.Permissions; namespace Nucleus.Application.Permissions { @@ -9,5 +10,7 @@ public interface IPermissionAppService Task> GetGrantedPermissionsAsync(string userNameOrEmail); Task IsUserGrantedToPermissionAsync(string userNameOrEmail, string permissionName); + + void InitializePermissions(List permissions); } } \ No newline at end of file diff --git a/src/Nucleus.Application/Permissions/PermissionAppService.cs b/src/Nucleus.Application/Permissions/PermissionAppService.cs index 54ff7c5..2a59c55 100644 --- a/src/Nucleus.Application/Permissions/PermissionAppService.cs +++ b/src/Nucleus.Application/Permissions/PermissionAppService.cs @@ -1,19 +1,14 @@ -using System; -using System.Collections.Generic; +using System.Collections.Generic; using System.Linq; using System.Threading.Tasks; using AutoMapper; using Nucleus.Application.Permissions.Dto; -using Nucleus.Core.Permissions; -using Nucleus.Core.Roles; -using Nucleus.EntityFramework; -using Nucleus.Utilities.Collections; -using Nucleus.Utilities.Extensions.Collections; -using Nucleus.Utilities.Extensions.PrimitiveTypes; -using System.Linq.Dynamic.Core; using Microsoft.AspNetCore.Identity; using Microsoft.EntityFrameworkCore; +using Nucleus.Core.Permissions; +using Nucleus.Core.Roles; using Nucleus.Core.Users; +using Nucleus.EntityFramework; namespace Nucleus.Application.Permissions { @@ -21,14 +16,16 @@ public class PermissionAppService : IPermissionAppService { private readonly UserManager _userManager; private readonly IMapper _mapper; + private readonly NucleusDbContext _dbContext; public PermissionAppService( UserManager userManager, - IMapper mapper - ) + IMapper mapper, + NucleusDbContext dbContext) { _userManager = userManager; _mapper = mapper; + _dbContext = dbContext; } public async Task> GetGrantedPermissionsAsync(string userNameOrEmail) @@ -60,5 +57,30 @@ public async Task IsUserGrantedToPermissionAsync(string userNameOrEmail, s return grantedPermissions.Any(p => p.Name == permissionName); } + + public void InitializePermissions(List permissions) + { + _dbContext.RolePermissions.RemoveRange(_dbContext.RolePermissions.Where(rp => rp.RoleId == DefaultRoles.Admin.Id)); + _dbContext.SaveChanges(); + + _dbContext.Permissions.RemoveRange(_dbContext.Permissions); + _dbContext.SaveChanges(); + + _dbContext.AddRange(permissions); + GrantAllPermissionsToAdminRole(permissions); + _dbContext.SaveChanges(); + } + + private void GrantAllPermissionsToAdminRole(List permissions) + { + foreach (var permission in permissions) + { + _dbContext.RolePermissions.Add(new RolePermission + { + PermissionId = permission.Id, + RoleId = DefaultRoles.Admin.Id + }); + } + } } } diff --git a/src/Nucleus.Application/Roles/RoleAppService.cs b/src/Nucleus.Application/Roles/RoleAppService.cs index 7f2d0f6..6be6fcd 100644 --- a/src/Nucleus.Application/Roles/RoleAppService.cs +++ b/src/Nucleus.Application/Roles/RoleAppService.cs @@ -89,6 +89,7 @@ public async Task EditRoleAsync(CreateOrUpdateRoleInput input) } role.Name = input.Role.Name; role.RolePermissions.Clear(); + var updateRoleResult = await _roleManager.UpdateAsync(role); if (updateRoleResult.Succeeded) { @@ -101,7 +102,6 @@ public async Task EditRoleAsync(CreateOrUpdateRoleInput input) public async Task RemoveRoleAsync(Guid id) { var role = _roleManager.Roles.FirstOrDefault(r => r.Id == id); - if (role == null) { return IdentityResult.Failed(new IdentityError() @@ -128,6 +128,7 @@ public async Task RemoveRoleAsync(Guid id) role.RolePermissions.Clear(); role.UserRoles.Clear(); + return removeRoleResult; } diff --git a/src/Nucleus.Application/Users/UserAppService.cs b/src/Nucleus.Application/Users/UserAppService.cs index 47308be..9dc83fc 100644 --- a/src/Nucleus.Application/Users/UserAppService.cs +++ b/src/Nucleus.Application/Users/UserAppService.cs @@ -107,7 +107,6 @@ public async Task EditUserAsync(CreateOrUpdateUserInput input) public async Task RemoveUserAsync(Guid id) { var user = _userManager.Users.FirstOrDefault(u => u.Id == id); - if (user == null) { return IdentityResult.Failed(new IdentityError @@ -133,6 +132,7 @@ public async Task RemoveUserAsync(Guid id) } user.UserRoles.Clear(); + return removeUserResult; } diff --git a/src/Nucleus.EntityFramework/NucleusDbContext.cs b/src/Nucleus.EntityFramework/NucleusDbContext.cs index 67cb722..3aefaef 100644 --- a/src/Nucleus.EntityFramework/NucleusDbContext.cs +++ b/src/Nucleus.EntityFramework/NucleusDbContext.cs @@ -54,10 +54,6 @@ protected override void OnModelCreating(ModelBuilder modelBuilder) { b.ToTable("UserRole"); - b.HasOne(ur => ur.User) - .WithMany(u => u.UserRoles) - .HasForeignKey(ur => ur.UserId); - b.HasOne(ur => ur.User) .WithMany(u => u.UserRoles) .HasForeignKey(ur => ur.UserId); diff --git a/src/Nucleus.Web.Api/Controller/Account/AccountController.cs b/src/Nucleus.Web.Api/Controller/Account/AccountController.cs index 990803f..ec3e6ea 100644 --- a/src/Nucleus.Web.Api/Controller/Account/AccountController.cs +++ b/src/Nucleus.Web.Api/Controller/Account/AccountController.cs @@ -9,6 +9,7 @@ using Microsoft.AspNetCore.Identity; using Microsoft.AspNetCore.Mvc; using Microsoft.Extensions.Options; +using Nucleus.Application.Account.Dto; using Nucleus.Application.Dto; using Nucleus.Application.Permissions; using Nucleus.Application.Permissions.Dto; diff --git a/src/Nucleus.Web.Api/Program.cs b/src/Nucleus.Web.Api/Program.cs index bac40b1..889e198 100644 --- a/src/Nucleus.Web.Api/Program.cs +++ b/src/Nucleus.Web.Api/Program.cs @@ -1,6 +1,9 @@ using System; using Microsoft.AspNetCore; using Microsoft.AspNetCore.Hosting; +using Microsoft.Extensions.DependencyInjection; +using Nucleus.Application.Permissions; +using Nucleus.Core.Permissions; using Serilog; using Serilog.Events; @@ -26,7 +29,16 @@ public static int Main(string[] args) try { Log.Information("Starting web host"); - BuildWebHost(args).Run(); + + Log.Information("Starting web host"); + var host = BuildWebHost(args); + using (var scope = host.Services.CreateScope()) + { + var permissionAppService = scope.ServiceProvider.GetRequiredService(); + permissionAppService.InitializePermissions(DefaultPermissions.All()); + } + + host.Run(); return 0; } catch (Exception ex) diff --git a/src/Nucleus.Web.Core/Authentication/JwtTokenAuthConfigurer.cs b/src/Nucleus.Web.Core/Authentication/JwtTokenAuthConfigure.cs similarity index 98% rename from src/Nucleus.Web.Core/Authentication/JwtTokenAuthConfigurer.cs rename to src/Nucleus.Web.Core/Authentication/JwtTokenAuthConfigure.cs index 9d241e3..ac2659b 100644 --- a/src/Nucleus.Web.Core/Authentication/JwtTokenAuthConfigurer.cs +++ b/src/Nucleus.Web.Core/Authentication/JwtTokenAuthConfigure.cs @@ -7,7 +7,7 @@ namespace Nucleus.Web.Core.Authentication { - public static class JwtTokenAuthConfigurer + public static class JwtTokenAuthConfigure { private static SymmetricSecurityKey _signingKey; private static JwtTokenConfiguration _jwtTokenConfiguration; diff --git a/src/Nucleus.Web.Core/Extensions/ServiceCollectionExtensions.cs b/src/Nucleus.Web.Core/Extensions/ServiceCollectionExtensions.cs index fe93876..86cbc26 100644 --- a/src/Nucleus.Web.Core/Extensions/ServiceCollectionExtensions.cs +++ b/src/Nucleus.Web.Core/Extensions/ServiceCollectionExtensions.cs @@ -34,7 +34,7 @@ public static void ConfigureAuthentication(this IServiceCollection services, ICo .AddEntityFrameworkStores() .AddDefaultTokenProviders(); - JwtTokenAuthConfigurer.Configure(services, configuration); + JwtTokenAuthConfigure.Configure(services, configuration); services.AddAuthorization(options => { diff --git a/src/Nucleus.Web.Vue/Nucleus.Web.Vue.csproj b/src/Nucleus.Web.Vue/Nucleus.Web.Vue.csproj index ce7a66f..d638d24 100644 --- a/src/Nucleus.Web.Vue/Nucleus.Web.Vue.csproj +++ b/src/Nucleus.Web.Vue/Nucleus.Web.Vue.csproj @@ -7,11 +7,14 @@ - + + + + - + diff --git a/src/Nucleus.Web.Vue/package-lock.json b/src/Nucleus.Web.Vue/package-lock.json index 5e08530..577929c 100644 --- a/src/Nucleus.Web.Vue/package-lock.json +++ b/src/Nucleus.Web.Vue/package-lock.json @@ -911,9 +911,9 @@ } }, "@vue/cli-service": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/@vue/cli-service/-/cli-service-3.1.3.tgz", - "integrity": "sha512-tcMKnzBfUU7Tj2DghL/bhFc1criO7PKYqgh0CqMCth5xpy/wiFKvNr3iBM8FT1jeF1s50I338j2tKeWqhs6M5A==", + "version": "3.1.4", + "resolved": "https://registry.npmjs.org/@vue/cli-service/-/cli-service-3.1.4.tgz", + "integrity": "sha512-dArLh5yd2B2an/jTD+cmkRmyRxKSE+5il9408vhciyqvZGVjkajTN95YjY5VLkBMQvrv/Z+goGSn+7wtnQSOFg==", "dev": true, "requires": { "@intervolga/optimize-cssnano-plugin": "^1.0.5", @@ -2235,7 +2235,7 @@ }, "callsites": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/callsites/-/callsites-2.0.0.tgz", + "resolved": "http://registry.npmjs.org/callsites/-/callsites-2.0.0.tgz", "integrity": "sha1-BuuE8A7qQT2oav/vrL/7Ngk7PFA=", "dev": true }, @@ -2558,7 +2558,7 @@ }, "colors": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/colors/-/colors-1.1.2.tgz", + "resolved": "http://registry.npmjs.org/colors/-/colors-1.1.2.tgz", "integrity": "sha1-FopHAXVran9RoSzgyXv6KMCE7WM=", "dev": true }, @@ -3321,7 +3321,7 @@ "dependencies": { "globby": { "version": "6.1.0", - "resolved": "https://registry.npmjs.org/globby/-/globby-6.1.0.tgz", + "resolved": "http://registry.npmjs.org/globby/-/globby-6.1.0.tgz", "integrity": "sha1-9abXDoOV4hyFj7BInWTfAkJNUGw=", "dev": true, "requires": { @@ -4191,9 +4191,9 @@ } }, "follow-redirects": { - "version": "1.5.9", - "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.5.9.tgz", - "integrity": "sha512-Bh65EZI/RU8nx0wbYF9shkFZlqLP+6WT/5FnA3cE/djNSuKNHJEinGGZgu/cQEkeeb2GdFOgenAmn8qaqYke2w==", + "version": "1.5.10", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.5.10.tgz", + "integrity": "sha512-0V5l4Cizzvqt5D44aTXbFZz+FtyXV1vrDN6qrelxtfYQKW0KO0W2T/hkE8xvGa/540LkZlkaUjO4ailYTFtHVQ==", "dev": true, "requires": { "debug": "=3.1.0" @@ -6314,9 +6314,9 @@ } }, "map-age-cleaner": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/map-age-cleaner/-/map-age-cleaner-0.1.2.tgz", - "integrity": "sha512-UN1dNocxQq44IhJyMI4TU8phc2m9BddacHRPRjKGLYaF0jqd3xLz0jS0skpAU9WgYyoR4gHtUpzytNBS385FWQ==", + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/map-age-cleaner/-/map-age-cleaner-0.1.3.tgz", + "integrity": "sha512-bJzx6nMoP6PDLPBFmg7+xRKeFZvFboMrGlxmNj9ClvX53KrmvM5bXFXEWjbz4cz1AFn+jWJ9z/DJSz7hrs0w3w==", "dev": true, "requires": { "p-defer": "^1.0.0" @@ -6478,9 +6478,9 @@ "dev": true }, "mini-css-extract-plugin": { - "version": "0.4.4", - "resolved": "https://registry.npmjs.org/mini-css-extract-plugin/-/mini-css-extract-plugin-0.4.4.tgz", - "integrity": "sha512-o+Jm+ocb0asEngdM6FsZWtZsRzA8koFUudIDwYUfl94M3PejPHG7Vopw5hN9V8WsMkSFpm3tZP3Fesz89EyrfQ==", + "version": "0.4.5", + "resolved": "https://registry.npmjs.org/mini-css-extract-plugin/-/mini-css-extract-plugin-0.4.5.tgz", + "integrity": "sha512-dqBanNfktnp2hwL2YguV9Jh91PFX7gu7nRLs4TGsbAfAG6WOtlynFRYzwDwmmeSb5uIwHo9nx1ta0f7vAZVp2w==", "dev": true, "requires": { "loader-utils": "^1.1.0", @@ -7458,9 +7458,9 @@ "dev": true }, "postcss": { - "version": "7.0.5", - "resolved": "https://registry.npmjs.org/postcss/-/postcss-7.0.5.tgz", - "integrity": "sha512-HBNpviAUFCKvEh7NZhw1e8MBPivRszIiUnhrJ+sBFVSYSqubrzwX3KG51mYgcRHX8j/cAgZJedONZcm5jTBdgQ==", + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-7.0.6.tgz", + "integrity": "sha512-Nq/rNjnHFcKgCDDZYO0lNsl6YWe6U7tTy+ESN+PnLxebL8uBtYX59HZqvrj7YLK5UCyll2hqDsJOo3ndzEW8Ug==", "dev": true, "requires": { "chalk": "^2.4.1", @@ -9261,7 +9261,7 @@ }, "stream-browserify": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/stream-browserify/-/stream-browserify-2.0.1.tgz", + "resolved": "http://registry.npmjs.org/stream-browserify/-/stream-browserify-2.0.1.tgz", "integrity": "sha1-ZiZu5fm9uZQKTkUUyvtDu3Hlyds=", "dev": true, "requires": { @@ -9422,9 +9422,9 @@ } }, "sweetalert2": { - "version": "7.29.0", - "resolved": "https://registry.npmjs.org/sweetalert2/-/sweetalert2-7.29.0.tgz", - "integrity": "sha512-QYMpgj+W1nmE5I6hQ+Kvj+xSAJ78o5oawNOm65fq+0DRuZqmNPwGNnyfMcA3/porpje6RjXJd41NCJN8Rj83wQ==" + "version": "7.29.1", + "resolved": "https://registry.npmjs.org/sweetalert2/-/sweetalert2-7.29.1.tgz", + "integrity": "sha512-cSq4MTBLTQbU8VvkkgaHcqapTHlXeNJU4iLVcHC3nWL+MvSbKrM6hdfzuiAx7NivaHe/z1xcJGVMNpvEzosvFg==" }, "symbol-tree": { "version": "3.2.2", @@ -9439,9 +9439,9 @@ "dev": true }, "terser": { - "version": "3.10.11", - "resolved": "https://registry.npmjs.org/terser/-/terser-3.10.11.tgz", - "integrity": "sha512-iruZ7j14oBbRYJC5cP0/vTU7YOWjN+J1ZskEGoF78tFzXdkK2hbCL/3TRZN8XB+MuvFhvOHMp7WkOCBO4VEL5g==", + "version": "3.10.12", + "resolved": "https://registry.npmjs.org/terser/-/terser-3.10.12.tgz", + "integrity": "sha512-3ODPC1eVt25EVNb04s/PkHxOmzKBQUF6bwwuR6h2DbEF8/j265Y1UkwNtOk9am/pRxfJ5HPapOlUlO6c16mKQQ==", "dev": true, "requires": { "commander": "~2.17.1", @@ -9931,46 +9931,6 @@ } } }, - "uglifyjs-webpack-plugin": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/uglifyjs-webpack-plugin/-/uglifyjs-webpack-plugin-1.3.0.tgz", - "integrity": "sha512-ovHIch0AMlxjD/97j9AYovZxG5wnHOPkL7T1GKochBADp/Zwc44pEWNqpKl1Loupp1WhFg7SlYmHZRUfdAacgw==", - "dev": true, - "requires": { - "cacache": "^10.0.4", - "find-cache-dir": "^1.0.0", - "schema-utils": "^0.4.5", - "serialize-javascript": "^1.4.0", - "source-map": "^0.6.1", - "uglify-es": "^3.3.4", - "webpack-sources": "^1.1.0", - "worker-farm": "^1.5.2" - }, - "dependencies": { - "commander": { - "version": "2.13.0", - "resolved": "https://registry.npmjs.org/commander/-/commander-2.13.0.tgz", - "integrity": "sha512-MVuS359B+YzaWqjCL/c+22gfryv+mCBPHAv3zyVI2GN8EY6IRP8VwtasXn8jyyhvvq84R4ImN1OKRtcbIasjYA==", - "dev": true - }, - "source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true - }, - "uglify-es": { - "version": "3.3.9", - "resolved": "https://registry.npmjs.org/uglify-es/-/uglify-es-3.3.9.tgz", - "integrity": "sha512-r+MU0rfv4L/0eeW3xZrd16t4NZfK8Ld4SWVglYBb7ez5uXFWHuVRs6xCTrf1yirs9a4j4Y27nn7SRfO6v67XsQ==", - "dev": true, - "requires": { - "commander": "~2.13.0", - "source-map": "~0.6.1" - } - } - } - }, "unicode-canonical-property-names-ecmascript": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/unicode-canonical-property-names-ecmascript/-/unicode-canonical-property-names-ecmascript-1.0.4.tgz", @@ -10333,9 +10293,9 @@ "dev": true }, "vue-i18n": { - "version": "8.3.1", - "resolved": "https://registry.npmjs.org/vue-i18n/-/vue-i18n-8.3.1.tgz", - "integrity": "sha512-EFerdnu7kJh0tgn6JZvaJW11bN2hYn4d4Q84eJG+kvArVH0bCa36fMwdmWPj29rZHvBoVx20fmABt0hKs8Q3NQ==" + "version": "8.3.2", + "resolved": "https://registry.npmjs.org/vue-i18n/-/vue-i18n-8.3.2.tgz", + "integrity": "sha512-MQ06tG1Tl/VL6NDh6XXfGr1uI6KVinb4fuu4alprwmbn5BG0J/a1RIVSSOsDmGkYKKaHlLzvRydiiulnBy2iXQ==" }, "vue-loader": { "version": "15.4.2", @@ -10390,9 +10350,9 @@ "dev": true }, "vuetify": { - "version": "1.3.8", - "resolved": "https://registry.npmjs.org/vuetify/-/vuetify-1.3.8.tgz", - "integrity": "sha512-MWqHEAwVQaKujNoRZBPmEcNE4cbx1nLJp+VHXp8s+umS/DSpW5kYTkvGr8SLm4w7xPlUBmTzawLE3qieYXiJAg==" + "version": "1.3.9", + "resolved": "https://registry.npmjs.org/vuetify/-/vuetify-1.3.9.tgz", + "integrity": "sha512-6cgWRVEBkuUowrfAR9i4lVcTQtwpz9WLM5IcmsMmsmto2GLgf+bi3EfbVFi5xBF3UaV+TC1oHkZq+H/bqgyfhw==" }, "w3c-hr-time": { "version": "1.0.1", @@ -10450,9 +10410,9 @@ "dev": true }, "webpack": { - "version": "4.25.1", - "resolved": "https://registry.npmjs.org/webpack/-/webpack-4.25.1.tgz", - "integrity": "sha512-T0GU/3NRtO4tMfNzsvpdhUr8HnzA4LTdP2zd+e5zd6CdOH5vNKHnAlO+DvzccfhPdzqRrALOFcjYxx7K5DWmvA==", + "version": "4.26.0", + "resolved": "https://registry.npmjs.org/webpack/-/webpack-4.26.0.tgz", + "integrity": "sha512-J/dP9SJIc5OtX2FZ/+U9ikQtd6H6Mcbqt0xeXtmPwYGDKf8nkbOQQA9KL2Y0rJOsN1Al9Pdn+/j63X58ub8gvQ==", "dev": true, "requires": { "@webassemblyjs/ast": "1.7.11", @@ -10476,7 +10436,7 @@ "node-libs-browser": "^2.0.0", "schema-utils": "^0.4.4", "tapable": "^1.1.0", - "uglifyjs-webpack-plugin": "^1.2.4", + "terser-webpack-plugin": "^1.1.0", "watchpack": "^1.5.0", "webpack-sources": "^1.3.0" }, diff --git a/src/Nucleus.Web.Vue/package.json b/src/Nucleus.Web.Vue/package.json index 7f33dfe..b6d95b5 100644 --- a/src/Nucleus.Web.Vue/package.json +++ b/src/Nucleus.Web.Vue/package.json @@ -13,10 +13,10 @@ "vue-class-component": "^6.3.2", "vue-property-decorator": "^7.2.0", "vue-router": "^3.0.1", - "vuetify": "^1.3.8", + "vuetify": "^1.3.9", "material-design-icons-iconfont": "4.0.2", - "sweetalert2": "^7.29.0", - "vue-i18n": "^8.3.1" + "sweetalert2": "^7.29.1", + "vue-i18n": "^8.3.2" }, "devDependencies": { "@types/chai": "^4.1.7", @@ -24,7 +24,7 @@ "@vue/cli-plugin-babel": "^3.1.1", "@vue/cli-plugin-typescript": "^3.1.1", "@vue/cli-plugin-unit-mocha": "^3.1.1", - "@vue/cli-service": "^3.1.3", + "@vue/cli-service": "^3.1.4", "@vue/test-utils": "^1.0.0-beta.25", "@types/query-string": "^6.1.1", "chai": "^4.2.0", diff --git a/src/Nucleus.Web.Vue/src/App.vue b/src/Nucleus.Web.Vue/src/App.vue index 390d9f5..52e9d71 100644 --- a/src/Nucleus.Web.Vue/src/App.vue +++ b/src/Nucleus.Web.Vue/src/App.vue @@ -1,6 +1,16 @@  diff --git a/src/Nucleus.Web.Vue/src/account/views/login/login.vue b/src/Nucleus.Web.Vue/src/account/views/login/login.vue index 3933e40..c8e01f5 100644 --- a/src/Nucleus.Web.Vue/src/account/views/login/login.vue +++ b/src/Nucleus.Web.Vue/src/account/views/login/login.vue @@ -1,5 +1,5 @@