diff --git a/YavscLib/Workflow/IAccountBalance.cs b/Yavsc.Abstract/Billing/IAccountBalance.cs similarity index 88% rename from YavscLib/Workflow/IAccountBalance.cs rename to Yavsc.Abstract/Billing/IAccountBalance.cs index d22d3edf..17ee9248 100644 --- a/YavscLib/Workflow/IAccountBalance.cs +++ b/Yavsc.Abstract/Billing/IAccountBalance.cs @@ -1,4 +1,4 @@ -namespace YavscLib +namespace Yavsc { public interface IAccountBalance { diff --git a/YavscLib/Billing/IBillItem.cs b/Yavsc.Abstract/Billing/IBillItem.cs similarity index 90% rename from YavscLib/Billing/IBillItem.cs rename to Yavsc.Abstract/Billing/IBillItem.cs index 045ff9a8..e9d7330d 100644 --- a/YavscLib/Billing/IBillItem.cs +++ b/Yavsc.Abstract/Billing/IBillItem.cs @@ -1,4 +1,4 @@ -namespace YavscLib.Billing +namespace Yavsc.Billing { public interface IBillItem { string Name { get; set; } diff --git a/YavscLib/Billing/IBillable.cs b/Yavsc.Abstract/Billing/IBillable.cs similarity index 87% rename from YavscLib/Billing/IBillable.cs rename to Yavsc.Abstract/Billing/IBillable.cs index c54b6a9e..41a9ba11 100644 --- a/YavscLib/Billing/IBillable.cs +++ b/Yavsc.Abstract/Billing/IBillable.cs @@ -1,6 +1,6 @@ using System.Collections.Generic; -namespace YavscLib.Billing +namespace Yavsc.Billing { public interface IBillable { string Description { get; set; } diff --git a/YavscLib/Billing/IBillingImpacter.cs b/Yavsc.Abstract/Billing/IBillingImpacter.cs similarity index 78% rename from YavscLib/Billing/IBillingImpacter.cs rename to Yavsc.Abstract/Billing/IBillingImpacter.cs index 6aaf5d55..52de8163 100644 --- a/YavscLib/Billing/IBillingImpacter.cs +++ b/Yavsc.Abstract/Billing/IBillingImpacter.cs @@ -1,5 +1,5 @@ -namespace YavscLib.Billing +namespace Yavsc.Billing { public interface IBillingImpacter {  decimal Impact(decimal orgValue); diff --git a/YavscLib/ICommandLine.cs b/Yavsc.Abstract/Billing/ICommandLine.cs similarity index 90% rename from YavscLib/ICommandLine.cs rename to Yavsc.Abstract/Billing/ICommandLine.cs index 311a0506..70bbd700 100644 --- a/YavscLib/ICommandLine.cs +++ b/Yavsc.Abstract/Billing/ICommandLine.cs @@ -1,4 +1,5 @@ -namespace YavscLib.Billing + +namespace Yavsc.Billing { public interface ICommandLine : IBillItem diff --git a/YavscLib/IEstimate.cs b/Yavsc.Abstract/Billing/IEstimate.cs similarity index 93% rename from YavscLib/IEstimate.cs rename to Yavsc.Abstract/Billing/IEstimate.cs index a2038093..05e52451 100644 --- a/YavscLib/IEstimate.cs +++ b/Yavsc.Abstract/Billing/IEstimate.cs @@ -1,4 +1,4 @@ -namespace YavscLib.Workflow +namespace Yavsc { using System.Collections.Generic; public interface IEstimate @@ -14,4 +14,4 @@ string Title { get; set; } } -} \ No newline at end of file +} diff --git a/YavscLib/Blogspot/IBlog.cs b/Yavsc.Abstract/Blogspot/IBlog.cs similarity index 84% rename from YavscLib/Blogspot/IBlog.cs rename to Yavsc.Abstract/Blogspot/IBlog.cs index d840bd8a..3aaf66f2 100644 --- a/YavscLib/Blogspot/IBlog.cs +++ b/Yavsc.Abstract/Blogspot/IBlog.cs @@ -1,7 +1,7 @@  -using YavscLib.Interfaces; -namespace YavscLib + +namespace Yavsc { public interface IBlog : IBaseTrackedEntity, IIdentified, IRating, ITitle { diff --git a/YavscLib/IBaseTrackedEntity.cs b/Yavsc.Abstract/IBaseTrackedEntity.cs similarity index 92% rename from YavscLib/IBaseTrackedEntity.cs rename to Yavsc.Abstract/IBaseTrackedEntity.cs index 2d4703e8..64da6cdd 100644 --- a/YavscLib/IBaseTrackedEntity.cs +++ b/Yavsc.Abstract/IBaseTrackedEntity.cs @@ -1,6 +1,6 @@ using System; -namespace YavscLib +namespace Yavsc { public interface IBaseTrackedEntity { diff --git a/YavscLib/IIdentified.cs b/Yavsc.Abstract/IIdentified.cs similarity index 98% rename from YavscLib/IIdentified.cs rename to Yavsc.Abstract/IIdentified.cs index 1a00aa4e..550a030a 100644 --- a/YavscLib/IIdentified.cs +++ b/Yavsc.Abstract/IIdentified.cs @@ -19,7 +19,7 @@ // You should have received a copy of the GNU Lesser General Public License // along with this program. If not, see . -namespace YavscLib +namespace Yavsc { /// /// I identified. diff --git a/YavscLib/IT/ICode.cs b/Yavsc.Abstract/IT/ICode.cs similarity index 96% rename from YavscLib/IT/ICode.cs rename to Yavsc.Abstract/IT/ICode.cs index 25cf54ab..925a7f9f 100644 --- a/YavscLib/IT/ICode.cs +++ b/Yavsc.Abstract/IT/ICode.cs @@ -1,6 +1,6 @@ using System.Collections.Generic; -namespace YavscLib +namespace Yavsc { public interface ILetter : IEqualityComparer { } @@ -19,4 +19,4 @@ namespace YavscLib IWord CreateWord(TLetter letter); } -} \ No newline at end of file +} diff --git a/YavscLib/ITitle.cs b/Yavsc.Abstract/ITitle.cs similarity index 97% rename from YavscLib/ITitle.cs rename to Yavsc.Abstract/ITitle.cs index 1df21e59..7a7a8462 100644 --- a/YavscLib/ITitle.cs +++ b/Yavsc.Abstract/ITitle.cs @@ -18,7 +18,7 @@ // // You should have received a copy of the GNU Lesser General Public License // along with this program. If not, see . -namespace YavscLib +namespace Yavsc { public interface ITitle { diff --git a/YavscLib/Identity/IApplicationUser.cs b/Yavsc.Abstract/Identity/IApplicationUser.cs similarity index 93% rename from YavscLib/Identity/IApplicationUser.cs rename to Yavsc.Abstract/Identity/IApplicationUser.cs index 214b377e..4caafa64 100644 --- a/YavscLib/Identity/IApplicationUser.cs +++ b/Yavsc.Abstract/Identity/IApplicationUser.cs @@ -1,4 +1,4 @@ -namespace YavscLib +namespace Yavsc { public interface IApplicationUser { diff --git a/YavscLib/Identity/IChatUserInfo.cs b/Yavsc.Abstract/Identity/IChatUserInfo.cs similarity index 95% rename from YavscLib/Identity/IChatUserInfo.cs rename to Yavsc.Abstract/Identity/IChatUserInfo.cs index 0ad66a1c..507836c9 100644 --- a/YavscLib/Identity/IChatUserInfo.cs +++ b/Yavsc.Abstract/Identity/IChatUserInfo.cs @@ -1,4 +1,4 @@ -namespace YavscLib +namespace Yavsc { public interface IConnection { @@ -18,4 +18,4 @@ namespace YavscLib string[] Roles { get; set; } } -} \ No newline at end of file +} diff --git a/YavscLib/Identity/Security/ICircleAuthorization.cs b/Yavsc.Abstract/Identity/Security/ICircleAuthorization.cs similarity index 69% rename from YavscLib/Identity/Security/ICircleAuthorization.cs rename to Yavsc.Abstract/Identity/Security/ICircleAuthorization.cs index 43565278..38b40d86 100644 --- a/YavscLib/Identity/Security/ICircleAuthorization.cs +++ b/Yavsc.Abstract/Identity/Security/ICircleAuthorization.cs @@ -1,8 +1,8 @@ -namespace YavscLib +namespace Yavsc { - + public interface ICircleAuthorization - { + { long CircleId { get; set; } } -} \ No newline at end of file +} diff --git a/YavscLib/Identity/Security/ICircleAuthorized.cs b/Yavsc.Abstract/Identity/Security/ICircleAuthorized.cs similarity index 71% rename from YavscLib/Identity/Security/ICircleAuthorized.cs rename to Yavsc.Abstract/Identity/Security/ICircleAuthorized.cs index f68c1ee3..04f1d1fc 100644 --- a/YavscLib/Identity/Security/ICircleAuthorized.cs +++ b/Yavsc.Abstract/Identity/Security/ICircleAuthorized.cs @@ -1,11 +1,11 @@ -namespace YavscLib +namespace Yavsc { public interface ICircleAuthorized { long Id { get; set; } string GetOwnerId (); bool AuthorizeCircle(long circleId); - ICircleAuthorization [] GetACL(); + ICircleAuthorization [] GetACL(); } -} \ No newline at end of file +} diff --git a/YavscLib/Identity/UserInfo.cs b/Yavsc.Abstract/Identity/UserInfo.cs similarity index 100% rename from YavscLib/Identity/UserInfo.cs rename to Yavsc.Abstract/Identity/UserInfo.cs diff --git a/YavscLib/MarkdownParser.y b/Yavsc.Abstract/MarkdownParser.y similarity index 100% rename from YavscLib/MarkdownParser.y rename to Yavsc.Abstract/MarkdownParser.y diff --git a/YavscLib/Properties/AssemblyInfo.cs b/Yavsc.Abstract/Properties/AssemblyInfo.cs similarity index 100% rename from YavscLib/Properties/AssemblyInfo.cs rename to Yavsc.Abstract/Properties/AssemblyInfo.cs diff --git a/YavscLib/Workflow/IActivity.cs b/Yavsc.Abstract/Workflow/IActivity.cs similarity index 97% rename from YavscLib/Workflow/IActivity.cs rename to Yavsc.Abstract/Workflow/IActivity.cs index ffbce358..45781b28 100644 --- a/YavscLib/Workflow/IActivity.cs +++ b/Yavsc.Abstract/Workflow/IActivity.cs @@ -1,6 +1,6 @@ using System; -namespace YavscLib +namespace Yavsc { public interface IActivity { diff --git a/YavscLib/Workflow/IBlackListed.cs b/Yavsc.Abstract/Workflow/IBlackListed.cs similarity index 100% rename from YavscLib/Workflow/IBlackListed.cs rename to Yavsc.Abstract/Workflow/IBlackListed.cs diff --git a/YavscLib/Workflow/ICircle.cs b/Yavsc.Abstract/Workflow/ICircle.cs similarity index 100% rename from YavscLib/Workflow/ICircle.cs rename to Yavsc.Abstract/Workflow/ICircle.cs diff --git a/YavscLib/Workflow/ICoWorking.cs b/Yavsc.Abstract/Workflow/ICoWorking.cs similarity index 84% rename from YavscLib/Workflow/ICoWorking.cs rename to Yavsc.Abstract/Workflow/ICoWorking.cs index f9412664..6ac3062e 100644 --- a/YavscLib/Workflow/ICoWorking.cs +++ b/Yavsc.Abstract/Workflow/ICoWorking.cs @@ -1,10 +1,10 @@ -namespace YavscLib +namespace Yavsc { public interface ICoWorking { long Id {get; set; } string PerformerId { get; set; } string WorkingForId { get; set; } - + } -} \ No newline at end of file +} diff --git a/YavscLib/Workflow/ICommandForm.cs b/Yavsc.Abstract/Workflow/ICommandForm.cs similarity index 70% rename from YavscLib/Workflow/ICommandForm.cs rename to Yavsc.Abstract/Workflow/ICommandForm.cs index 2b50e082..8f862d31 100644 --- a/YavscLib/Workflow/ICommandForm.cs +++ b/Yavsc.Abstract/Workflow/ICommandForm.cs @@ -1,11 +1,11 @@ -namespace YavscLib +namespace Yavsc { public interface ICommandForm { long Id { get; set; } string ActionName { get; set; } - string Title { get; set; } + string Title { get; set; } string ActivityCode { get; set; } - + } -} \ No newline at end of file +} diff --git a/YavscLib/Workflow/IContact.cs b/Yavsc.Abstract/Workflow/IContact.cs similarity index 88% rename from YavscLib/Workflow/IContact.cs rename to Yavsc.Abstract/Workflow/IContact.cs index a6ce2853..68fda053 100644 --- a/YavscLib/Workflow/IContact.cs +++ b/Yavsc.Abstract/Workflow/IContact.cs @@ -1,4 +1,4 @@ -namespace YavscLib +namespace Yavsc { public interface IContact { diff --git a/YavscLib/Workflow/IEvent.cs b/Yavsc.Abstract/Workflow/IEvent.cs similarity index 100% rename from YavscLib/Workflow/IEvent.cs rename to Yavsc.Abstract/Workflow/IEvent.cs diff --git a/YavscLib/Workflow/IGoogleCloudMobileDeclaration.cs b/Yavsc.Abstract/Workflow/IGoogleCloudMobileDeclaration.cs similarity index 96% rename from YavscLib/Workflow/IGoogleCloudMobileDeclaration.cs rename to Yavsc.Abstract/Workflow/IGoogleCloudMobileDeclaration.cs index 401d43f5..a5e2d2a8 100644 --- a/YavscLib/Workflow/IGoogleCloudMobileDeclaration.cs +++ b/Yavsc.Abstract/Workflow/IGoogleCloudMobileDeclaration.cs @@ -1,24 +1,24 @@ // Copyright (C) 2016 Paul Schneider -// +// // This file is part of yavsc. -// +// // yavsc is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 2 of the License, or // (at your option) any later version. -// +// // yavsc is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. -// +// // You should have received a copy of the GNU General Public License // along with yavsc. If not, see . -// +// using System; -namespace YavscLib +namespace Yavsc { public interface IGCMDeclaration { diff --git a/YavscLib/Workflow/ILocation.cs b/Yavsc.Abstract/Workflow/ILocation.cs similarity index 83% rename from YavscLib/Workflow/ILocation.cs rename to Yavsc.Abstract/Workflow/ILocation.cs index 10aa4249..926b56bd 100644 --- a/YavscLib/Workflow/ILocation.cs +++ b/Yavsc.Abstract/Workflow/ILocation.cs @@ -1,4 +1,4 @@ -namespace YavscLib +namespace Yavsc { public interface ILocation { diff --git a/YavscLib/Workflow/IPerformerProfile.cs b/Yavsc.Abstract/Workflow/IPerformerProfile.cs similarity index 94% rename from YavscLib/Workflow/IPerformerProfile.cs rename to Yavsc.Abstract/Workflow/IPerformerProfile.cs index 35ef6f8b..e53583a5 100644 --- a/YavscLib/Workflow/IPerformerProfile.cs +++ b/Yavsc.Abstract/Workflow/IPerformerProfile.cs @@ -1,4 +1,4 @@ -namespace YavscLib.Workflow +namespace Yavsc.Workflow { public interface IPerformerProfile { @@ -14,4 +14,4 @@ namespace YavscLib.Workflow int? MinDailyCost { get; set; } int Rate { get; set; } } -} \ No newline at end of file +} diff --git a/YavscLib/Workflow/IPosition.cs b/Yavsc.Abstract/Workflow/IPosition.cs similarity index 100% rename from YavscLib/Workflow/IPosition.cs rename to Yavsc.Abstract/Workflow/IPosition.cs diff --git a/YavscLib/Workflow/IQuery.cs b/Yavsc.Abstract/Workflow/IQuery.cs similarity index 67% rename from YavscLib/Workflow/IQuery.cs rename to Yavsc.Abstract/Workflow/IQuery.cs index 09f679be..dec24f3e 100644 --- a/YavscLib/Workflow/IQuery.cs +++ b/Yavsc.Abstract/Workflow/IQuery.cs @@ -1,7 +1,7 @@ -namespace YavscLib.Workflow +namespace Yavsc.Workflow { - using YavscLib; - using YavscLib.Billing; + using Yavsc; + using Yavsc.Billing; public interface IQuery: IBaseTrackedEntity, IBillable { diff --git a/YavscLib/Workflow/IRating.cs b/Yavsc.Abstract/Workflow/IRating.cs similarity index 97% rename from YavscLib/Workflow/IRating.cs rename to Yavsc.Abstract/Workflow/IRating.cs index 7cd51812..bc45f9a9 100644 --- a/YavscLib/Workflow/IRating.cs +++ b/Yavsc.Abstract/Workflow/IRating.cs @@ -19,7 +19,7 @@ // You should have received a copy of the GNU Lesser General Public License // along with this program. If not, see . -namespace YavscLib.Interfaces +namespace Yavsc { /// diff --git a/YavscLib/Workflow/IRequisition.cs b/Yavsc.Abstract/Workflow/IRequisition.cs similarity index 100% rename from YavscLib/Workflow/IRequisition.cs rename to Yavsc.Abstract/Workflow/IRequisition.cs diff --git a/YavscLib/Workflow/ISpecializationSettings.cs b/Yavsc.Abstract/Workflow/ISpecializationSettings.cs similarity index 83% rename from YavscLib/Workflow/ISpecializationSettings.cs rename to Yavsc.Abstract/Workflow/ISpecializationSettings.cs index 6c6aa35f..919e469b 100644 --- a/YavscLib/Workflow/ISpecializationSettings.cs +++ b/Yavsc.Abstract/Workflow/ISpecializationSettings.cs @@ -1,7 +1,7 @@ -namespace YavscLib +namespace Yavsc { public interface ISpecializationSettings { string UserId { get ; set ; } } -} \ No newline at end of file +} diff --git a/YavscLib/Workflow/QueryStatus.cs b/Yavsc.Abstract/Workflow/QueryStatus.cs similarity index 95% rename from YavscLib/Workflow/QueryStatus.cs rename to Yavsc.Abstract/Workflow/QueryStatus.cs index 9adc66a4..e440ebbc 100644 --- a/YavscLib/Workflow/QueryStatus.cs +++ b/Yavsc.Abstract/Workflow/QueryStatus.cs @@ -1,4 +1,4 @@ -namespace YavscLib +namespace Yavsc { /// /// Status, diff --git a/YavscLib/YavscLib.csproj b/Yavsc.Abstract/YavscLib.csproj similarity index 91% rename from YavscLib/YavscLib.csproj rename to Yavsc.Abstract/YavscLib.csproj index 7eba2286..8363091d 100644 --- a/YavscLib/YavscLib.csproj +++ b/Yavsc.Abstract/YavscLib.csproj @@ -8,8 +8,8 @@ {67F9D3A8-F71E-4428-913F-C37AE82CDB24} Library Properties - Yavsc.Client - Yavsc.Client + Yavsc + Yavsc.Abstract v4.5 Profile111 512 @@ -73,11 +73,17 @@ MinimumRecommendedRules.ruleset - - - - + + + + + + + + + + diff --git a/YavscLib/YavscLib.nuget.targets b/Yavsc.Abstract/YavscLib.nuget.targets similarity index 100% rename from YavscLib/YavscLib.nuget.targets rename to Yavsc.Abstract/YavscLib.nuget.targets diff --git a/YavscLib/YavscLib.sln b/Yavsc.Abstract/YavscLib.sln similarity index 100% rename from YavscLib/YavscLib.sln rename to Yavsc.Abstract/YavscLib.sln diff --git a/YavscLib/app.config b/Yavsc.Abstract/app.config similarity index 100% rename from YavscLib/app.config rename to Yavsc.Abstract/app.config diff --git a/YavscLib/packages.config b/Yavsc.Abstract/packages.config similarity index 100% rename from YavscLib/packages.config rename to Yavsc.Abstract/packages.config diff --git a/YavscLib/project.json b/Yavsc.Abstract/project.json similarity index 100% rename from YavscLib/project.json rename to Yavsc.Abstract/project.json diff --git a/YavscLib/project.lock.json b/Yavsc.Abstract/project.lock.json similarity index 100% rename from YavscLib/project.lock.json rename to Yavsc.Abstract/project.lock.json diff --git a/Yavsc/ApiControllers/HairCut/HairCutController.cs b/Yavsc/ApiControllers/HairCut/HairCutController.cs index e3980323..4984f4ab 100644 --- a/Yavsc/ApiControllers/HairCut/HairCutController.cs +++ b/Yavsc/ApiControllers/HairCut/HairCutController.cs @@ -6,7 +6,7 @@ using Microsoft.Extensions.Localization; namespace Yavsc.ApiControllers { - using YavscLib; + using Yavsc; using System; using System.Linq; using System.Security.Claims; diff --git a/Yavsc/Controllers/AccountController.cs b/Yavsc/Controllers/AccountController.cs index 5e0691a0..5bed1730 100644 --- a/Yavsc/Controllers/AccountController.cs +++ b/Yavsc/Controllers/AccountController.cs @@ -20,7 +20,7 @@ using Microsoft.Data.Entity; namespace Yavsc.Controllers { - [AllowAnonymous] + public class AccountController : Controller { private readonly UserManager _userManager; @@ -61,6 +61,13 @@ namespace Yavsc.Controllers _dbContext = dbContext; } + [Authorize(Roles=Constants.AdminGroupName)] + public async Task UserList () + { + return View(await _dbContext.Users.ToArrayAsync()); + } + + [AllowAnonymous] [HttpGet(Constants.LoginPath)] public ActionResult SignIn(string returnUrl = null) { @@ -79,6 +86,7 @@ namespace Yavsc.Controllers */ } + [AllowAnonymous] public ActionResult AccessDenied(string requestUrl = null) { ViewBag.UserIsSignedIn = User.IsSignedIn(); @@ -89,6 +97,7 @@ namespace Yavsc.Controllers return View("AccessDenied",requestUrl); } + [AllowAnonymous] [HttpPost(Constants.LoginPath)] public async Task SignIn(SignInViewModel model) { @@ -169,6 +178,7 @@ namespace Yavsc.Controllers // // GET: /Account/Register + [AllowAnonymous] [HttpGet] public IActionResult Register() { @@ -178,6 +188,7 @@ namespace Yavsc.Controllers // // POST: /Account/Register [HttpPost] + [AllowAnonymous] [ValidateAntiForgeryToken] public async Task Register(RegisterViewModel model) { @@ -220,6 +231,7 @@ namespace Yavsc.Controllers // // GET: /Account/ExternalLoginCallback [HttpGet] + [AllowAnonymous] public async Task ExternalLoginCallback(string returnUrl = null) { var info = await _signInManager.GetExternalLoginInfoAsync(); @@ -285,6 +297,7 @@ namespace Yavsc.Controllers // POST: /Account/ExternalLoginConfirmation [HttpPost] [ValidateAntiForgeryToken] + [AllowAnonymous] public async Task ExternalLoginConfirmation(ExternalLoginConfirmationViewModel model, string returnUrl = null) { if (User.IsSignedIn()) @@ -324,6 +337,7 @@ namespace Yavsc.Controllers // GET: /Account/ConfirmEmail [HttpGet] + [AllowAnonymous] public async Task ConfirmEmail(string userId, string code) { if (userId == null || code == null) @@ -342,6 +356,7 @@ namespace Yavsc.Controllers // // GET: /Account/ForgotPassword [HttpGet] + [AllowAnonymous] public IActionResult ForgotPassword() { return View(); @@ -350,6 +365,7 @@ namespace Yavsc.Controllers // // POST: /Account/ForgotPassword [HttpPost] + [AllowAnonymous] [ValidateAntiForgeryToken] public async Task ForgotPassword(ForgotPasswordViewModel model) { @@ -382,6 +398,7 @@ namespace Yavsc.Controllers // // GET: /Account/ForgotPasswordConfirmation [HttpGet] + [AllowAnonymous] public IActionResult ForgotPasswordConfirmation() { return View(); @@ -390,6 +407,7 @@ namespace Yavsc.Controllers // // GET: /Account/ResetPassword [HttpGet] + [AllowAnonymous] public IActionResult ResetPassword(string UserId, string code = null) { return code == null ? View("Error") : View(); @@ -398,6 +416,7 @@ namespace Yavsc.Controllers // // POST: /Account/ResetPassword [HttpPost] + [AllowAnonymous] [ValidateAntiForgeryToken] public async Task ResetPassword(ResetPasswordViewModel model) { @@ -423,6 +442,7 @@ namespace Yavsc.Controllers // // GET: /Account/ResetPasswordConfirmation [HttpGet] + [AllowAnonymous] public IActionResult ResetPasswordConfirmation() { return View(); @@ -489,6 +509,7 @@ namespace Yavsc.Controllers // // GET: /Account/VerifyCode [HttpGet] + [AllowAnonymous] public async Task VerifyCode(string provider, bool rememberMe, string returnUrl = null) { // Require that the user has already logged in via username/password or external login @@ -503,6 +524,7 @@ namespace Yavsc.Controllers // // POST: /Account/VerifyCode [HttpPost] + [AllowAnonymous] [ValidateAntiForgeryToken] public async Task VerifyCode(VerifyCodeViewModel model) { diff --git a/Yavsc/Controllers/AdministrationController.cs b/Yavsc/Controllers/AdministrationController.cs index 097193cf..ea30b908 100644 --- a/Yavsc/Controllers/AdministrationController.cs +++ b/Yavsc/Controllers/AdministrationController.cs @@ -81,6 +81,7 @@ namespace Yavsc.Controllers { var adminCount = await _userManager.GetUsersInRoleAsync( Constants.AdminGroupName); + var userCount = await context.Users.CountAsync(); var youAreAdmin = await _userManager.IsInRoleAsync( await _userManager.FindByIdAsync(User.GetUserId()), Constants.AdminGroupName); @@ -98,7 +99,8 @@ namespace Yavsc.Controllers { Roles = roles.ToArray(), AdminCount = adminCount.Count, - YouAreAdmin = youAreAdmin + YouAreAdmin = youAreAdmin, + UserCount = userCount }); } diff --git a/Yavsc/Controllers/DoController.cs b/Yavsc/Controllers/DoController.cs index 4a25cb8c..0ab4e57e 100644 --- a/Yavsc/Controllers/DoController.cs +++ b/Yavsc/Controllers/DoController.cs @@ -12,7 +12,7 @@ namespace Yavsc.Controllers using Models.Workflow; using Yavsc.Exceptions; using Yavsc.ViewModels.Workflow; - using YavscLib; + using Yavsc; [Authorize] public class DoController : Controller @@ -22,7 +22,7 @@ namespace Yavsc.Controllers public DoController(ApplicationDbContext context,ILogger logger) { - _context = context; + _context = context; _logger = logger; } @@ -42,7 +42,7 @@ namespace Yavsc.Controllers // GET: Do/Details/5 public IActionResult Details(string id, string activityCode) { - + if (id == null || activityCode == null) { return HttpNotFound(); @@ -54,20 +54,20 @@ namespace Yavsc.Controllers { return HttpNotFound(); } - + bool hasConfigurableSettings = (userActivity.Does.SettingsClassName != null); if (hasConfigurableSettings) { ViewBag.ProfileType = Startup.ProfileTypes.Single(t=>t.FullName==userActivity.Does.SettingsClassName); var dbset = (IQueryable) _context.GetDbSet(userActivity.Does.SettingsClassName); if (dbset == null) throw new InvalidWorkflowModelException($"pas de db set pour {userActivity.Does.SettingsClassName}, vous avez peut-être besoin de décorer votre propriété avec l'attribut [ActivitySettings]"); - return View(new UserActivityViewModel { - Declaration = userActivity, + return View(new UserActivityViewModel { + Declaration = userActivity, HasSettings = dbset.Any(ua=>ua.UserId==id), NeedsSettings = hasConfigurableSettings } ); } - return View(new UserActivityViewModel { - Declaration = userActivity, + return View(new UserActivityViewModel { + Declaration = userActivity, HasSettings = false, NeedsSettings = hasConfigurableSettings } ); diff --git a/Yavsc/Controllers/Generic/SettingsController.cs b/Yavsc/Controllers/Generic/SettingsController.cs index b53f7fb0..cd520610 100644 --- a/Yavsc/Controllers/Generic/SettingsController.cs +++ b/Yavsc/Controllers/Generic/SettingsController.cs @@ -5,7 +5,7 @@ using Microsoft.AspNet.Mvc; using Microsoft.Data.Entity; using Yavsc.Exceptions; using Yavsc.Models; -using YavscLib; +using Yavsc; namespace Yavsc.Controllers.Generic { @@ -15,7 +15,7 @@ namespace Yavsc.Controllers.Generic protected ApplicationDbContext _context; private object dbSet; - protected DbSet Settings { get { + protected DbSet Settings { get { return (DbSet) dbSet; } } @@ -47,7 +47,7 @@ namespace Yavsc.Controllers.Generic return View(profile); } - + // GET: BrusherProfile/Create public IActionResult Create() @@ -71,7 +71,7 @@ namespace Yavsc.Controllers.Generic return View(setting); } - + // GET: BrusherProfile/Delete/5 [ActionName("Delete")] @@ -106,7 +106,7 @@ namespace Yavsc.Controllers.Generic } return View("Edit",settings); } - + // POST: FormationSettings/Edit/5 [HttpPost] [ValidateAntiForgeryToken] @@ -115,7 +115,7 @@ namespace Yavsc.Controllers.Generic if (settings.UserId == null) { settings.UserId = User.GetUserId(); Settings.Add(settings); - } else + } else _context.Update(settings); if (ModelState.IsValid) { @@ -124,7 +124,7 @@ namespace Yavsc.Controllers.Generic } return View(settings); } - + // POST: FormationSettings/Delete/5 [HttpPost, ActionName("Delete")] [ValidateAntiForgeryToken] @@ -137,4 +137,4 @@ namespace Yavsc.Controllers.Generic } } -} \ No newline at end of file +} diff --git a/Yavsc/Controllers/HomeController.cs b/Yavsc/Controllers/HomeController.cs index f5e79fde..2668da72 100644 --- a/Yavsc/Controllers/HomeController.cs +++ b/Yavsc/Controllers/HomeController.cs @@ -14,7 +14,7 @@ using System.Threading.Tasks; namespace Yavsc.Controllers { using Models; - using YavscLib; + using Yavsc; [AllowAnonymous] public class HomeController : Controller diff --git a/Yavsc/Helpers/BillingHelpers.cs b/Yavsc/Helpers/BillingHelpers.cs index fcc85fc2..73f9225b 100644 --- a/Yavsc/Helpers/BillingHelpers.cs +++ b/Yavsc/Helpers/BillingHelpers.cs @@ -1,6 +1,6 @@ using System.Collections.Generic; using System.Linq; -using YavscLib.Billing; +using Yavsc.Billing; namespace Yavsc.Helpers { diff --git a/Yavsc/Helpers/TeXHelpers.cs b/Yavsc/Helpers/TeXHelpers.cs index 39ddf3c7..6d0c3d22 100644 --- a/Yavsc/Helpers/TeXHelpers.cs +++ b/Yavsc/Helpers/TeXHelpers.cs @@ -19,10 +19,10 @@ namespace Yavsc.Helpers public TeXString(string str) : base(str) { - - + + } - + } public class Replacement @@ -41,7 +41,7 @@ namespace Yavsc.Helpers } public static class TeXHelpers { - public static readonly Replacement[] SpecialCharsRendering = + public static readonly Replacement[] SpecialCharsDefaultRendering = { new Replacement("<","\\textless"), new Replacement(">","\\textgreater"), @@ -70,7 +70,7 @@ namespace Yavsc.Helpers public static TeXString ToTeX(this string source) { string result=source; - foreach (var r in SpecialCharsRendering) + foreach (var r in SpecialCharsDefaultRendering) { result = r.Execute(result); } @@ -172,4 +172,4 @@ namespace Yavsc.Helpers } } } -} \ No newline at end of file +} diff --git a/Yavsc/Interfaces/ICircleMember.cs b/Yavsc/Interfaces/ICircleMember.cs index 78b7e1b5..bea08a8b 100644 --- a/Yavsc/Interfaces/ICircleMember.cs +++ b/Yavsc/Interfaces/ICircleMember.cs @@ -1,4 +1,4 @@ -using YavscLib; +using Yavsc namespace Yavsc.Interfaces { @@ -7,4 +7,4 @@ namespace Yavsc.Interfaces ICircle Circle { get; set; } IApplicationUser Member { get; set; } } -} \ No newline at end of file +} diff --git a/Yavsc/Interfaces/IGoogleCloudMobileDeclaration.cs b/Yavsc/Interfaces/IGoogleCloudMobileDeclaration.cs index 020d38a8..4318a234 100644 --- a/Yavsc/Interfaces/IGoogleCloudMobileDeclaration.cs +++ b/Yavsc/Interfaces/IGoogleCloudMobileDeclaration.cs @@ -1,5 +1,4 @@ -using YavscLib; - + namespace Yavsc.Interfaces { public interface IGCMDeclaration @@ -17,4 +16,4 @@ namespace Yavsc.Interfaces IApplicationUser DeviceOwner { get; set; } string DeviceOwnerId { get; set; } } -} \ No newline at end of file +} diff --git a/Yavsc/Interfaces/Workflow/IBillingClause.cs b/Yavsc/Interfaces/Workflow/IBillingClause.cs index db5bb927..6a1ead65 100644 --- a/Yavsc/Interfaces/Workflow/IBillingClause.cs +++ b/Yavsc/Interfaces/Workflow/IBillingClause.cs @@ -1,4 +1,4 @@ -using YavscLib.Billing; +using Yavsc.Billing; namespace Yavsc.Models.Billing { public interface IBillingClause {  diff --git a/Yavsc/Migrations/20170217221646_bookQueryStatus.cs b/Yavsc/Migrations/20170217221646_bookQueryStatus.cs index 9250ac35..8fa3c649 100644 --- a/Yavsc/Migrations/20170217221646_bookQueryStatus.cs +++ b/Yavsc/Migrations/20170217221646_bookQueryStatus.cs @@ -2,7 +2,7 @@ using Microsoft.Data.Entity.Migrations; namespace Yavsc.Migrations { - using YavscLib; + using Yavsc; public partial class bookQueryStatus : Migration { protected override void Up(MigrationBuilder migrationBuilder) diff --git a/Yavsc/Models/Access/Ban.cs b/Yavsc/Models/Access/Ban.cs index 15b86d03..a5b5d330 100644 --- a/Yavsc/Models/Access/Ban.cs +++ b/Yavsc/Models/Access/Ban.cs @@ -4,13 +4,13 @@ using System.ComponentModel.DataAnnotations.Schema; namespace Yavsc.Models.Access { - using YavscLib; + using Yavsc; public class Ban : IBaseTrackedEntity { public DateTime DateCreated { - get; set; + get; set; } public DateTime DateModified diff --git a/Yavsc/Models/Access/CircleAuthorizationToBlogPost.cs b/Yavsc/Models/Access/CircleAuthorizationToBlogPost.cs index 5da29e12..0e2bfc83 100644 --- a/Yavsc/Models/Access/CircleAuthorizationToBlogPost.cs +++ b/Yavsc/Models/Access/CircleAuthorizationToBlogPost.cs @@ -3,7 +3,7 @@ namespace Yavsc.Models.Access using System.ComponentModel.DataAnnotations.Schema; using Models.Relationship; using Newtonsoft.Json; - using YavscLib; + using Yavsc; public class CircleAuthorizationToBlogPost : ICircleAuthorization { @@ -19,4 +19,4 @@ namespace Yavsc.Models.Access public virtual Circle Allowed { get; set; } } -} \ No newline at end of file +} diff --git a/Yavsc/Models/ApplicationDbContext.cs b/Yavsc/Models/ApplicationDbContext.cs index a1e0e4ed..375a28ee 100644 --- a/Yavsc/Models/ApplicationDbContext.cs +++ b/Yavsc/Models/ApplicationDbContext.cs @@ -12,7 +12,7 @@ namespace Yavsc.Models { using Relationship; using Forms; - using YavscLib; + using Yavsc; using Auth; using Billing; using Musical; diff --git a/Yavsc/Models/Bank/AccountBalance.cs b/Yavsc/Models/Bank/AccountBalance.cs index 573f6589..ab70f777 100644 --- a/Yavsc/Models/Bank/AccountBalance.cs +++ b/Yavsc/Models/Bank/AccountBalance.cs @@ -3,7 +3,7 @@ using System.ComponentModel.DataAnnotations.Schema; namespace Yavsc.Models { - using YavscLib; + using Yavsc; public partial class AccountBalance: IAccountBalance { [Key] diff --git a/Yavsc/Models/Billing/CommandLine.cs b/Yavsc/Models/Billing/CommandLine.cs index e2556e22..2f39c54c 100644 --- a/Yavsc/Models/Billing/CommandLine.cs +++ b/Yavsc/Models/Billing/CommandLine.cs @@ -5,7 +5,7 @@ using Newtonsoft.Json; namespace Yavsc.Models.Billing { - using YavscLib.Billing; + using Yavsc.Billing; public class CommandLine : ICommandLine { diff --git a/Yavsc/Models/Billing/Estimate.cs b/Yavsc/Models/Billing/Estimate.cs index 96bb1f6a..06bbaf4b 100644 --- a/Yavsc/Models/Billing/Estimate.cs +++ b/Yavsc/Models/Billing/Estimate.cs @@ -9,7 +9,7 @@ namespace Yavsc.Models.Billing { using Models.Workflow; using Newtonsoft.Json; - using YavscLib.Workflow; + using Yavsc.Workflow; public partial class Estimate : IEstimate { diff --git a/Yavsc/Models/Billing/FixedImpacter.cs b/Yavsc/Models/Billing/FixedImpacter.cs index 50121342..c6836df3 100644 --- a/Yavsc/Models/Billing/FixedImpacter.cs +++ b/Yavsc/Models/Billing/FixedImpacter.cs @@ -1,4 +1,4 @@ -using YavscLib.Billing; +using Yavsc.Billing; namespace Yavsc.Models.Billing   { public class FixedImpacter : IBillingImpacter diff --git a/Yavsc/Models/Billing/NominativeServiceCommand.cs b/Yavsc/Models/Billing/NominativeServiceCommand.cs index e5b9b1e9..315e4671 100644 --- a/Yavsc/Models/Billing/NominativeServiceCommand.cs +++ b/Yavsc/Models/Billing/NominativeServiceCommand.cs @@ -8,9 +8,9 @@ namespace Yavsc.Models.Billing using Newtonsoft.Json; using Workflow; using Yavsc.Models.Payment; - using YavscLib; - using YavscLib.Billing; - using YavscLib.Workflow; + using Yavsc; + using Yavsc.Billing; + using Yavsc.Workflow; public abstract class NominativeServiceCommand : IBaseTrackedEntity, IQuery, IIdentified { diff --git a/Yavsc/Models/Billing/ProportionalImpacter.cs b/Yavsc/Models/Billing/ProportionalImpacter.cs index 9173cd93..3098ff84 100644 --- a/Yavsc/Models/Billing/ProportionalImpacter.cs +++ b/Yavsc/Models/Billing/ProportionalImpacter.cs @@ -1,4 +1,4 @@ -using YavscLib.Billing; +using Yavsc.Billing; namespace Yavsc.Models.Billing   { public class ProportionalImpacter : IBillingImpacter diff --git a/Yavsc/Models/Billing/ReductionCode.cs b/Yavsc/Models/Billing/ReductionCode.cs index d58a9eed..9093b704 100644 --- a/Yavsc/Models/Billing/ReductionCode.cs +++ b/Yavsc/Models/Billing/ReductionCode.cs @@ -1,7 +1,7 @@ using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; -using YavscLib.Billing; +using Yavsc.Billing; namespace Yavsc.Models.Billing { diff --git a/Yavsc/Models/Blog/Blog.cs b/Yavsc/Models/Blog/Blog.cs index d80cadcf..e5e54b91 100644 --- a/Yavsc/Models/Blog/Blog.cs +++ b/Yavsc/Models/Blog/Blog.cs @@ -5,7 +5,7 @@ using System.ComponentModel.DataAnnotations.Schema; using System.Linq; using Newtonsoft.Json; using Yavsc.Models.Access; -using YavscLib; +using Yavsc; namespace Yavsc.Models { @@ -27,7 +27,7 @@ namespace Yavsc.Models public string AuthorId { get; set; } [Display(Name="Auteur")] - + [ForeignKey("AuthorId"),JsonIgnore] public ApplicationUser Author { set; get; } [Display(Name="Visible")] @@ -56,7 +56,7 @@ namespace Yavsc.Models { get; set; } - + [InverseProperty("Target")] [Display(Name="Liste de contrôle d'accès")] public virtual List ACL { get; set; } diff --git a/Yavsc/Models/Chat/Connection.cs b/Yavsc/Models/Chat/Connection.cs index 2d4f49bf..7eba1860 100644 --- a/Yavsc/Models/Chat/Connection.cs +++ b/Yavsc/Models/Chat/Connection.cs @@ -4,7 +4,7 @@ using Newtonsoft.Json; namespace Yavsc.Models.Chat { - using YavscLib; + using Yavsc; public class Connection : IConnection { @@ -18,5 +18,5 @@ namespace Yavsc.Models.Chat public string UserAgent { get; set; } public bool Connected { get; set; } } - + } diff --git a/Yavsc/Models/HairCut/BrusherProfile.cs b/Yavsc/Models/HairCut/BrusherProfile.cs index 10927829..f663c9cc 100644 --- a/Yavsc/Models/HairCut/BrusherProfile.cs +++ b/Yavsc/Models/HairCut/BrusherProfile.cs @@ -2,7 +2,7 @@ using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; using Newtonsoft.Json; using Yavsc.Models.Workflow; -using YavscLib; +using Yavsc; namespace Yavsc.Models.Haircut { diff --git a/Yavsc/Models/HairCut/HairCutQuery.cs b/Yavsc/Models/HairCut/HairCutQuery.cs index 9a4da247..c58ffeac 100644 --- a/Yavsc/Models/HairCut/HairCutQuery.cs +++ b/Yavsc/Models/HairCut/HairCutQuery.cs @@ -5,7 +5,7 @@ using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; using Yavsc.Models.Billing; using Yavsc.Models.Relationship; -using YavscLib.Billing; +using Yavsc.Billing; namespace Yavsc.Models.Haircut { diff --git a/Yavsc/Models/HairCut/HairMultiCutQuery.cs b/Yavsc/Models/HairCut/HairMultiCutQuery.cs index eea5f75c..b60118e6 100644 --- a/Yavsc/Models/HairCut/HairMultiCutQuery.cs +++ b/Yavsc/Models/HairCut/HairMultiCutQuery.cs @@ -4,7 +4,7 @@ using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; using Yavsc.Models.Billing; using Yavsc.Models.Relationship; -using YavscLib.Billing; +using Yavsc.Billing; namespace Yavsc.Models.Haircut { diff --git a/Yavsc/Models/HairCut/Haircut.cs b/Yavsc/Models/HairCut/Haircut.cs index adb97645..dc7549a3 100644 --- a/Yavsc/Models/HairCut/Haircut.cs +++ b/Yavsc/Models/HairCut/Haircut.cs @@ -1,5 +1,5 @@ using System; -namespace YavscLib.Haircut +namespace Yavsc.Haircut { public interface IProviderInfo { diff --git a/Yavsc/Models/HairCut/IHairPrestation.cs b/Yavsc/Models/HairCut/IHairPrestation.cs index 08e0ff37..dbf0ae17 100644 --- a/Yavsc/Models/HairCut/IHairPrestation.cs +++ b/Yavsc/Models/HairCut/IHairPrestation.cs @@ -1,4 +1,4 @@ -namespace YavscLib +namespace Yavsc { public interface IHairPrestation { diff --git a/Yavsc/Models/HairCut/Views/HaircutQueryInfo.cs b/Yavsc/Models/HairCut/Views/HaircutQueryInfo.cs index 3580f1ec..ed1f270e 100644 --- a/Yavsc/Models/HairCut/Views/HaircutQueryInfo.cs +++ b/Yavsc/Models/HairCut/Views/HaircutQueryInfo.cs @@ -2,7 +2,7 @@ using System; using System.ComponentModel.DataAnnotations; using Yavsc.Models.Auth; using Yavsc.Models.Relationship; -using YavscLib; +using Yavsc; namespace Yavsc.Models.Haircut.Views { diff --git a/Yavsc/Models/IT/Modeling/Code.cs b/Yavsc/Models/IT/Modeling/Code.cs index 3dc54117..1c9cb9b3 100644 --- a/Yavsc/Models/IT/Modeling/Code.cs +++ b/Yavsc/Models/IT/Modeling/Code.cs @@ -1,7 +1,7 @@ using System; using System.Collections; using System.Collections.Generic; -using YavscLib; +using Yavsc; namespace Yavsc.Models.IT.Modeling { @@ -37,4 +37,4 @@ namespace Yavsc.Models.IT.Modeling public abstract IWord CreateWord(TLetter letter); } -} \ No newline at end of file +} diff --git a/Yavsc/Models/IT/Modeling/Letter.cs b/Yavsc/Models/IT/Modeling/Letter.cs index 770c1031..d7519589 100644 --- a/Yavsc/Models/IT/Modeling/Letter.cs +++ b/Yavsc/Models/IT/Modeling/Letter.cs @@ -1,5 +1,5 @@ -using YavscLib; +using Yavsc; namespace Yavsc.Models.IT.Modeling { @@ -13,4 +13,4 @@ namespace Yavsc.Models.IT.Modeling } } -} \ No newline at end of file +} diff --git a/Yavsc/Models/Identity/MobileAppDeclaration.cs b/Yavsc/Models/Identity/MobileAppDeclaration.cs index 09602be6..91b43d66 100644 --- a/Yavsc/Models/Identity/MobileAppDeclaration.cs +++ b/Yavsc/Models/Identity/MobileAppDeclaration.cs @@ -5,19 +5,19 @@ using Newtonsoft.Json; namespace Yavsc.Models.Identity { - using YavscLib; - + using Yavsc; + [JsonObject] - public class GivenGoogleCloudMobileDeclaration : GoogleCloudMobileDeclaration, IGCMDeclaration { + public class GivenGoogleCloudMobileDeclaration : GoogleCloudMobileDeclaration, IGCMDeclaration { public DateTime? LatestActivityUpdate { get; set; } } public class GoogleCloudMobileDeclaration { - + [Required] public string GCMRegistrationId { get; set; } - + [Key,Required] public string DeviceId { get; set; } @@ -27,8 +27,8 @@ namespace Yavsc.Models.Identity public string DeviceOwnerId { get; set; } public DateTime DeclarationDate { get; set; } [JsonIgnore,ForeignKey("DeviceOwnerId")] - public virtual ApplicationUser DeviceOwner { get; set; } - + public virtual ApplicationUser DeviceOwner { get; set; } + } diff --git a/Yavsc/Models/Messaging/BaseEvent.cs b/Yavsc/Models/Messaging/BaseEvent.cs index feea05f1..b8a7ed6f 100644 --- a/Yavsc/Models/Messaging/BaseEvent.cs +++ b/Yavsc/Models/Messaging/BaseEvent.cs @@ -24,7 +24,7 @@ using System.ComponentModel.DataAnnotations; namespace Yavsc.Models.Messaging { using Interfaces.Workflow; - using YavscLib; + using Yavsc; /// /// Base event. diff --git a/Yavsc/Models/Musical/Profiles/DjSettings.cs b/Yavsc/Models/Musical/Profiles/DjSettings.cs index 8ca70a7e..b53ba54c 100644 --- a/Yavsc/Models/Musical/Profiles/DjSettings.cs +++ b/Yavsc/Models/Musical/Profiles/DjSettings.cs @@ -1,6 +1,6 @@ using System.Collections.Generic; using System.ComponentModel.DataAnnotations; -using YavscLib; +using Yavsc; namespace Yavsc.Models.Musical.Profiles { @@ -18,4 +18,4 @@ namespace Yavsc.Models.Musical.Profiles } } -} \ No newline at end of file +} diff --git a/Yavsc/Models/Musical/Profiles/GeneralSettings.cs b/Yavsc/Models/Musical/Profiles/GeneralSettings.cs index 11fa903a..64a4a3d4 100644 --- a/Yavsc/Models/Musical/Profiles/GeneralSettings.cs +++ b/Yavsc/Models/Musical/Profiles/GeneralSettings.cs @@ -1,6 +1,6 @@ using System.Collections.Generic; using System.ComponentModel.DataAnnotations; -using YavscLib; +using Yavsc; namespace Yavsc.Models.Musical.Profiles { @@ -13,4 +13,4 @@ namespace Yavsc.Models.Musical.Profiles get; set; } } -} \ No newline at end of file +} diff --git a/Yavsc/Models/Musical/Profiles/Instrumentation.cs b/Yavsc/Models/Musical/Profiles/Instrumentation.cs index 7606276c..d51d25e1 100644 --- a/Yavsc/Models/Musical/Profiles/Instrumentation.cs +++ b/Yavsc/Models/Musical/Profiles/Instrumentation.cs @@ -1,6 +1,6 @@ using System.ComponentModel.DataAnnotations.Schema; using Yavsc.Models.Workflow; -using YavscLib; +using Yavsc; namespace Yavsc.Models.Musical.Profiles { @@ -10,7 +10,7 @@ namespace Yavsc.Models.Musical.Profiles { get; set; } - + [ForeignKeyAttribute("UserId")] public virtual PerformerProfile User { get; set; } public long InstrumentId { get; set; } @@ -18,4 +18,4 @@ namespace Yavsc.Models.Musical.Profiles [ForeignKeyAttribute("InstrumentId")] public virtual Instrument Tool { get; set; } } -} \ No newline at end of file +} diff --git a/Yavsc/Models/Payment/PaypalPayment.cs b/Yavsc/Models/Payment/PaypalPayment.cs index 0af725f3..be24a4c3 100644 --- a/Yavsc/Models/Payment/PaypalPayment.cs +++ b/Yavsc/Models/Payment/PaypalPayment.cs @@ -4,7 +4,7 @@ using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; namespace Yavsc.Models.Payment { - using YavscLib; + using Yavsc; using Relationship; public class PayPalPayment : IBaseTrackedEntity diff --git a/Yavsc/Models/Workflow/Activity.cs b/Yavsc/Models/Workflow/Activity.cs index ec781cf8..5e4859f8 100644 --- a/Yavsc/Models/Workflow/Activity.cs +++ b/Yavsc/Models/Workflow/Activity.cs @@ -8,7 +8,7 @@ using Newtonsoft.Json; namespace Yavsc.Models.Workflow { using Yavsc.Models.Market; - using YavscLib; + using Yavsc; public class Activity : IBaseTrackedEntity, IActivity { diff --git a/Yavsc/Models/Workflow/CoWorking.cs b/Yavsc/Models/Workflow/CoWorking.cs index f07954a4..7ac3d2d4 100644 --- a/Yavsc/Models/Workflow/CoWorking.cs +++ b/Yavsc/Models/Workflow/CoWorking.cs @@ -3,20 +3,20 @@ using System.ComponentModel.DataAnnotations.Schema; namespace Yavsc.Models.Workflow { - using YavscLib; + using Yavsc; public class CoWorking: ICoWorking { [Key(), DatabaseGenerated(DatabaseGeneratedOption.Identity)] public long Id {get; set; } - + public string PerformerId { get; set; } public string WorkingForId { get; set; } - + [ForeignKey("PerformerId")] public virtual PerformerProfile Performer { get; set; } [ForeignKey("WorkingForId")] public virtual ApplicationUser WorkingFor { get; set; } } -} \ No newline at end of file +} diff --git a/Yavsc/Models/Workflow/CommandForm.cs b/Yavsc/Models/Workflow/CommandForm.cs index 15e769e5..ace25b96 100644 --- a/Yavsc/Models/Workflow/CommandForm.cs +++ b/Yavsc/Models/Workflow/CommandForm.cs @@ -4,7 +4,7 @@ using Newtonsoft.Json; namespace Yavsc.Models.Workflow { - using YavscLib; + using Yavsc; public class CommandForm : ICommandForm { [Key,DatabaseGenerated(DatabaseGeneratedOption.Identity)] @@ -12,12 +12,12 @@ namespace Yavsc.Models.Workflow public string ActionName { get; set; } - public string Title { get; set; } - + public string Title { get; set; } + [Required] public string ActivityCode { get; set; } [ForeignKey("ActivityCode"),JsonIgnore] public virtual Activity Context { get; set; } } -} \ No newline at end of file +} diff --git a/Yavsc/Models/Workflow/PerformerProfile.cs b/Yavsc/Models/Workflow/PerformerProfile.cs index 00fb6c5b..ec04a3af 100644 --- a/Yavsc/Models/Workflow/PerformerProfile.cs +++ b/Yavsc/Models/Workflow/PerformerProfile.cs @@ -6,7 +6,7 @@ namespace Yavsc.Models.Workflow { using System; using Models.Relationship; - using YavscLib.Workflow; + using Yavsc.Workflow; public class PerformerProfile : IPerformerProfile { diff --git a/Yavsc/Models/Workflow/Profiles/FormationSettings.cs b/Yavsc/Models/Workflow/Profiles/FormationSettings.cs index 8ad4a5d9..9b0c7c24 100644 --- a/Yavsc/Models/Workflow/Profiles/FormationSettings.cs +++ b/Yavsc/Models/Workflow/Profiles/FormationSettings.cs @@ -4,11 +4,11 @@ using System.ComponentModel.DataAnnotations; namespace Yavsc.Models.Workflow.Profiles { using Models.Workflow; - using YavscLib; + using Yavsc; public class FormationSettings : ISpecializationSettings { public virtual List CoWorking { get; set; } - + [Key] public string UserId { @@ -16,4 +16,4 @@ namespace Yavsc.Models.Workflow.Profiles } } -} \ No newline at end of file +} diff --git a/Yavsc/Models/Workflow/RdvQuery.cs b/Yavsc/Models/Workflow/RdvQuery.cs index fde3e5ae..4a35e20c 100644 --- a/Yavsc/Models/Workflow/RdvQuery.cs +++ b/Yavsc/Models/Workflow/RdvQuery.cs @@ -7,7 +7,7 @@ namespace Yavsc.Models.Workflow using System.Collections.Generic; using Yavsc.Models.Billing; using Yavsc.Models.Relationship; - using YavscLib.Billing; + using Yavsc.Billing; /// /// Query, for a date, with a given perfomer, at this given place. diff --git a/Yavsc/Startup/Startup.Workflow.cs b/Yavsc/Startup/Startup.Workflow.cs index de990cc6..1c5c9bb4 100644 --- a/Yavsc/Startup/Startup.Workflow.cs +++ b/Yavsc/Startup/Startup.Workflow.cs @@ -6,7 +6,7 @@ using Microsoft.AspNet.Builder; using Microsoft.Extensions.Logging; using Yavsc.Exceptions; using Yavsc.Models; -using YavscLib; +using Yavsc; namespace Yavsc { diff --git a/Yavsc/ViewComponents/CirclesControlViewComponent.cs b/Yavsc/ViewComponents/CirclesControlViewComponent.cs index 3e84a418..f1acabed 100644 --- a/Yavsc/ViewComponents/CirclesControlViewComponent.cs +++ b/Yavsc/ViewComponents/CirclesControlViewComponent.cs @@ -4,7 +4,7 @@ using Microsoft.AspNet.Mvc.Rendering; using Yavsc.Models; using Yavsc.ViewModels.Controls; using Yavsc.ViewModels.Relationship; -using YavscLib; +using Yavsc; namespace Yavsc.ViewComponents { @@ -16,31 +16,31 @@ namespace Yavsc.ViewComponents this.dbContext = dbContext; } - + public IViewComponentResult Invoke (ICircleAuthorized target) { var oid = target.GetOwnerId(); ViewBag.ACL = dbContext.Circle.Where( c=>c.OwnerId == oid) .Select( - c => new SelectListItem - { - Text = c.Name, - Value = c.Id.ToString(), - Selected = target.AuthorizeCircle(c.Id) + c => new SelectListItem + { + Text = c.Name, + Value = c.Id.ToString(), + Selected = target.AuthorizeCircle(c.Id) }  ); - + ViewBag.Access = dbContext.Circle.Where( c=>c.OwnerId == oid) .Select( c=> new AjaxCheckBoxInfo { - Text = c.Name, + Text = c.Name, Checked = target.AuthorizeCircle(c.Id), Value = c.Id.ToString() }); return View(new CirclesViewModel(target)); } } -} \ No newline at end of file +} diff --git a/Yavsc/project.json b/Yavsc/project.json index 776afbca..0d5d9d46 100755 --- a/Yavsc/project.json +++ b/Yavsc/project.json @@ -111,7 +111,7 @@ "Microsoft.AspNet.Mvc.Formatters.Json": "6.0.0-rc1-final", "Microsoft.AspNet.OWin": "1.0.0-rc1-final", "System.Json": "4.0.20126.16343", - "YavscLib": { + "Yavsc.Abstract": { "type": "build", "version": "1.0.0" }, diff --git a/Yavsc/project.lock.json b/Yavsc/project.lock.json index 5937d0f6..56f4b34d 100644 --- a/Yavsc/project.lock.json +++ b/Yavsc/project.lock.json @@ -2851,7 +2851,7 @@ "lib/WebGrease.dll": {} } }, - "YavscLib/1.0.0": { + "Yavsc.Abstract/1.0.0": { "type": "project", "framework": ".NETFramework,Version=v4.5.1", "dependencies": { @@ -5720,7 +5720,7 @@ "lib/WebGrease.dll": {} } }, - "YavscLib/1.0.0": { + "Yavsc.Abstract/1.0.0": { "type": "project", "framework": ".NETFramework,Version=v4.5.1", "dependencies": { @@ -8589,7 +8589,7 @@ "lib/WebGrease.dll": {} } }, - "YavscLib/1.0.0": { + "Yavsc.Abstract/1.0.0": { "type": "project", "framework": ".NETFramework,Version=v4.5.1", "dependencies": { @@ -8611,9 +8611,9 @@ } }, "libraries": { - "YavscLib/1.0.0": { + "Yavsc.Abstract/1.0.0": { "type": "project", - "path": "../YavscLib/project.json" + "path": "../Yavsc.Abstract/project.json" }, "Antlr/3.4.1.9004": { "type": "package", @@ -11622,7 +11622,7 @@ "Microsoft.AspNet.Mvc.Formatters.Json >= 6.0.0-rc1-final", "Microsoft.AspNet.OWin >= 1.0.0-rc1-final", "System.Json >= 4.0.20126.16343", - "YavscLib >= 1.0.0", + "Yavsc.Abstract >= 1.0.0", "Extensions.AspNet.Authentication.Instagram >= 1.0.0-t150809211713", "Microsoft.AspNet.Http.Extensions >= 1.0.0-rc1-final", "Microsoft.DiaSymReader.Native >= 1.5.0", diff --git a/YavscLib/Yavsc.Client.userprefs b/YavscLib/Yavsc.Client.userprefs deleted file mode 100644 index 7c085fc0..00000000 --- a/YavscLib/Yavsc.Client.userprefs +++ /dev/null @@ -1,23 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/ZicMoove.sln b/ZicMoove.sln index e86864ba..31a0551d 100644 --- a/ZicMoove.sln +++ b/ZicMoove.sln @@ -9,7 +9,7 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ZicMoove.iOS", "ZicMoove\Zi EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ZicMoove", "ZicMoove\ZicMoove\ZicMoove.csproj", "{A0815650-0A0A-47B0-8826-771F0E1AD137}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "YavscLib", "YavscLib\YavscLib.csproj", "{67F9D3A8-F71E-4428-913F-C37AE82CDB24}" +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "YavscLib", "Yavsc.Abstract\YavscLib.csproj", "{67F9D3A8-F71E-4428-913F-C37AE82CDB24}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution diff --git a/ZicMoove/ZicMoove/App.xaml.cs b/ZicMoove/ZicMoove/App.xaml.cs index 517c8a6c..46aaeea3 100644 --- a/ZicMoove/ZicMoove/App.xaml.cs +++ b/ZicMoove/ZicMoove/App.xaml.cs @@ -40,7 +40,7 @@ namespace ZicMoove using System.Net.Http; using System.Text; using Pages.ClientPages; - using YavscLib; + using Yavsc; using Model.Musical; public partial class App : Application // superclass new in 1.3 @@ -135,7 +135,7 @@ namespace ZicMoove private void OnAppResumed(object sender, EventArgs e) { StartConnexion(); - // TODO restore the navigation stack + // TODO restore the navigation stack base.OnResume(); foreach (var pageState in DataManager.Instance.AppState) { @@ -153,7 +153,7 @@ namespace ZicMoove DataManager.Instance.AppState.SaveEntity(); } - // FIXME Not called? + // FIXME Not called? private void OnRotation(object sender, EventArgs e) { @@ -179,7 +179,7 @@ namespace ZicMoove public App(IPlatform instance) { // This declaration became obsolete by introduction - // of the XLabs App that + // of the XLabs App that // refers this instance with // its application context property // and is obtained using the `Resolver` @@ -224,7 +224,7 @@ namespace ZicMoove private void BuildMainPage() { // TODO - // in case of App resume, + // in case of App resume, // do not create new BindingContext's, // but use those from the AppState property accChooserPage = new AccountChooserPage(); @@ -285,7 +285,7 @@ namespace ZicMoove masterDetail.Detail = new NavigationPage(homePage); ToolbarItem tiSetts = new ToolbarItem() { - // FIXME what for? Priority = 0, + // FIXME what for? Priority = 0, Text = "Paramètres", Icon = "ic_corp_icon.png", Command = new Command( diff --git a/ZicMoove/ZicMoove/Model/Auth/GCRegIdDeclaration.cs b/ZicMoove/ZicMoove/Model/Auth/GCRegIdDeclaration.cs index aa0f8969..1c8d89f3 100644 --- a/ZicMoove/ZicMoove/Model/Auth/GCRegIdDeclaration.cs +++ b/ZicMoove/ZicMoove/Model/Auth/GCRegIdDeclaration.cs @@ -1,5 +1,5 @@ using System; -using YavscLib; +using Yavsc; namespace ZicMoove.Model.Auth { diff --git a/ZicMoove/ZicMoove/Model/Auth/MobileAppDeclaration.cs b/ZicMoove/ZicMoove/Model/Auth/MobileAppDeclaration.cs index d8e20649..4c4b2896 100644 --- a/ZicMoove/ZicMoove/Model/Auth/MobileAppDeclaration.cs +++ b/ZicMoove/ZicMoove/Model/Auth/MobileAppDeclaration.cs @@ -4,9 +4,9 @@ using System; namespace ZicMoove.Model.Auth.Account { using Yavsc.Models; - using YavscLib; + using Yavsc; - public class GoogleCloudMobileDeclaration + public class GoogleCloudMobileDeclaration { public string GCMRegistrationId { get; set; } public string DeviceId { get; set; } @@ -34,4 +34,4 @@ namespace ZicMoove.Model.Auth.Account set; } } -} \ No newline at end of file +} diff --git a/ZicMoove/ZicMoove/Model/Blog/Blog.cs b/ZicMoove/ZicMoove/Model/Blog/Blog.cs index 00719f02..d387911c 100644 --- a/ZicMoove/ZicMoove/Model/Blog/Blog.cs +++ b/ZicMoove/ZicMoove/Model/Blog/Blog.cs @@ -1,5 +1,5 @@ using System; -using YavscLib; +using Yavsc; namespace ZicMoove.Model.Blog { diff --git a/ZicMoove/ZicMoove/Model/Social/Chat/Connection.cs b/ZicMoove/ZicMoove/Model/Social/Chat/Connection.cs index ef6c958a..820cbdf8 100644 --- a/ZicMoove/ZicMoove/Model/Social/Chat/Connection.cs +++ b/ZicMoove/ZicMoove/Model/Social/Chat/Connection.cs @@ -3,7 +3,7 @@ using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; -using YavscLib; +using Yavsc; namespace ZicMoove.Model.Social.Chat { diff --git a/ZicMoove/ZicMoove/Model/Workflow/Activity.cs b/ZicMoove/ZicMoove/Model/Workflow/Activity.cs index d509c6f6..c8395c1f 100644 --- a/ZicMoove/ZicMoove/Model/Workflow/Activity.cs +++ b/ZicMoove/ZicMoove/Model/Workflow/Activity.cs @@ -4,7 +4,7 @@ using XLabs.Forms.Mvvm; namespace ZicMoove.Model.Workflow { - using YavscLib; + using Yavsc; public class Activity : ViewModel, IActivity { public string Code diff --git a/ZicMoove/ZicMoove/Model/Workflow/CommandForm.cs b/ZicMoove/ZicMoove/Model/Workflow/CommandForm.cs index c686a15b..eeaf6c90 100644 --- a/ZicMoove/ZicMoove/Model/Workflow/CommandForm.cs +++ b/ZicMoove/ZicMoove/Model/Workflow/CommandForm.cs @@ -3,7 +3,7 @@ using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; -using YavscLib; +using Yavsc; namespace ZicMoove.Model.Workflow { diff --git a/ZicMoove/ZicMoove/Model/Workflow/Estimate.cs b/ZicMoove/ZicMoove/Model/Workflow/Estimate.cs index d998cac2..98c91927 100644 --- a/ZicMoove/ZicMoove/Model/Workflow/Estimate.cs +++ b/ZicMoove/ZicMoove/Model/Workflow/Estimate.cs @@ -8,7 +8,7 @@ namespace ZicMoove.Model.Workflow { using Data; using Musical; - using YavscLib.Workflow; + using Yavsc.Workflow; public partial class Estimate : IEstimate { @@ -49,7 +49,7 @@ namespace ZicMoove.Model.Workflow get { return AttachedFiles == null ? null : string.Join(":", AttachedFiles); } set { AttachedFiles = value.Split(':').ToList(); } } - + public string OwnerId { get; set; } [JsonIgnore] public ClientProviderInfo Owner diff --git a/ZicMoove/ZicMoove/Pages/EstimatePages/BillingLine.cs b/ZicMoove/ZicMoove/Pages/EstimatePages/BillingLine.cs index be15cc3a..3134c282 100644 --- a/ZicMoove/ZicMoove/Pages/EstimatePages/BillingLine.cs +++ b/ZicMoove/ZicMoove/Pages/EstimatePages/BillingLine.cs @@ -2,7 +2,7 @@ namespace ZicMoove.Model.Workflow { - using YavscLib.Billing; + using Yavsc.Billing; public class BillingLine : ICommandLine { public long Id { get; set; } diff --git a/ZicMoove/ZicMoove/ViewModels/EstimateAndBilling/BillingLineViewModel.cs b/ZicMoove/ZicMoove/ViewModels/EstimateAndBilling/BillingLineViewModel.cs index 0c511a9f..ad318a46 100644 --- a/ZicMoove/ZicMoove/ViewModels/EstimateAndBilling/BillingLineViewModel.cs +++ b/ZicMoove/ZicMoove/ViewModels/EstimateAndBilling/BillingLineViewModel.cs @@ -3,7 +3,7 @@ using System; using System.Globalization; using System.Windows.Input; using System.ComponentModel; -using YavscLib.Billing; +using Yavsc.Billing; namespace ZicMoove.ViewModels.EstimateAndBilling { @@ -163,7 +163,7 @@ pour décrire la quantité de travail associée à ce type de service")] Data.Duration = this.Duration; } } - + public static readonly string unitCostFormat = "0,.00"; string unitaryCostText; public string UnitaryCostText diff --git a/ZicMoove/ZicMoove/ViewModels/Messaging/ChatUserInfo.cs b/ZicMoove/ZicMoove/ViewModels/Messaging/ChatUserInfo.cs index 5dfb47a0..e3141b2d 100644 --- a/ZicMoove/ZicMoove/ViewModels/Messaging/ChatUserInfo.cs +++ b/ZicMoove/ZicMoove/ViewModels/Messaging/ChatUserInfo.cs @@ -4,7 +4,7 @@ using System.Collections.ObjectModel; using System.Linq; using Xamarin.Forms; using XLabs.Forms.Mvvm; -using YavscLib; +using Yavsc; using System; using Newtonsoft.Json; using ZicMoove.Model.Social.Messaging; @@ -187,7 +187,7 @@ namespace ZicMoove.Model.Social.Chat if (existentcx != null) { this.ObservableConnections.Remove(existentcx); - + if (this.ObservableConnections.Count == 0) NotifyPropertyChanged("IsConnected"); }