principalement du format de code
This commit is contained in:
parent
222a0f96d1
commit
ff1444d664
87 changed files with 510 additions and 550 deletions
|
|
@ -16,20 +16,17 @@ namespace Yavsc.ViewComponents
|
|||
{
|
||||
public class BillViewComponent : ViewComponent
|
||||
{
|
||||
ApplicationDbContext dbContext;
|
||||
IBillingService billing;
|
||||
IStringLocalizer<Yavsc.YavscLocalisation> localizer;
|
||||
ILogger logger ;
|
||||
readonly ApplicationDbContext dbContext;
|
||||
readonly IBillingService billing;
|
||||
readonly IStringLocalizer<Yavsc.YavscLocalisation> localizer;
|
||||
|
||||
public BillViewComponent(ApplicationDbContext dbContext,
|
||||
IStringLocalizer<Yavsc.YavscLocalisation> localizer,
|
||||
IBillingService billing,
|
||||
ILoggerFactory loggerFactory)
|
||||
IBillingService billing)
|
||||
{
|
||||
this.billing = billing;
|
||||
this.dbContext = dbContext;
|
||||
this.localizer = localizer;
|
||||
logger = loggerFactory.CreateLogger<BillViewComponent>();
|
||||
}
|
||||
|
||||
public async Task<IViewComponentResult> InvokeAsync(string code, IBillable billable, OutputFormat format, bool asBill)
|
||||
|
|
|
|||
|
|
@ -13,19 +13,11 @@ namespace Yavsc.ViewComponents
|
|||
{
|
||||
public class BlogIndexViewComponent: ViewComponent
|
||||
{
|
||||
ILogger _logger;
|
||||
private ApplicationDbContext _context;
|
||||
private IAuthorizationService _authorizationService;
|
||||
private readonly ApplicationDbContext _context;
|
||||
public BlogIndexViewComponent(
|
||||
ApplicationDbContext context,
|
||||
UserManager<ApplicationUser> userManager,
|
||||
ILoggerFactory loggerFactory,
|
||||
IAuthorizationService authorizationService,
|
||||
IOptions<SiteSettings> siteSettings)
|
||||
ApplicationDbContext context)
|
||||
{
|
||||
_context = context;
|
||||
_logger = loggerFactory.CreateLogger<BlogIndexViewComponent>();
|
||||
_authorizationService = authorizationService;
|
||||
}
|
||||
|
||||
// Renders blog index ofr the specified user by name
|
||||
|
|
|
|||
|
|
@ -8,8 +8,8 @@ namespace Yavsc.ViewComponents
|
|||
{
|
||||
public class CalendarViewComponent : ViewComponent
|
||||
{
|
||||
ApplicationDbContext _dbContext;
|
||||
ICalendarManager _manager;
|
||||
readonly ApplicationDbContext _dbContext;
|
||||
readonly ICalendarManager _manager;
|
||||
|
||||
public CalendarViewComponent (
|
||||
ApplicationDbContext dbContext,
|
||||
|
|
@ -47,4 +47,4 @@ namespace Yavsc.ViewComponents
|
|||
return View(model);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -9,17 +9,14 @@ namespace Yavsc.ViewComponents
|
|||
public class TaggerViewComponent : ViewComponent
|
||||
|
||||
{
|
||||
ApplicationDbContext dbContext;
|
||||
IStringLocalizer<TaggerViewComponent> localizer;
|
||||
ILogger logger ;
|
||||
readonly ApplicationDbContext dbContext;
|
||||
readonly IStringLocalizer<TaggerViewComponent> localizer;
|
||||
public TaggerViewComponent(
|
||||
ApplicationDbContext pdbContext,
|
||||
IStringLocalizer<TaggerViewComponent> pLocalizer,
|
||||
ILoggerFactory loggerFactory)
|
||||
IStringLocalizer<TaggerViewComponent> pLocalizer)
|
||||
{
|
||||
dbContext = pdbContext;
|
||||
this.localizer = pLocalizer;
|
||||
this.logger = loggerFactory.CreateLogger<TaggerViewComponent>();
|
||||
}
|
||||
public IViewComponentResult Invoke(ITaggable<long> longTaggable)
|
||||
{
|
||||
|
|
@ -29,4 +26,4 @@ namespace Yavsc.ViewComponents
|
|||
return View(longTaggable);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue