From 265f38a3f69276ae97690da64fb8e42be3a940e5 Mon Sep 17 00:00:00 2001 From: username@email.com <yzy2002yzy@163.com> Date: 星期五, 16 七月 2021 14:02:28 +0800 Subject: [PATCH] 提交 --- zhengcaioa/zhengcaioa/Timer/TimerGetShopUsersService.cs | 15 +++++++++++++++ 1 files changed, 15 insertions(+), 0 deletions(-) diff --git a/zhengcaioa/zhengcaioa/Timer/TimerGetShopUsersService.cs b/zhengcaioa/zhengcaioa/Timer/TimerGetShopUsersService.cs index 8b61db4..859c2e8 100644 --- a/zhengcaioa/zhengcaioa/Timer/TimerGetShopUsersService.cs +++ b/zhengcaioa/zhengcaioa/Timer/TimerGetShopUsersService.cs @@ -1,5 +1,6 @@ 锘縰sing DTO; using IServices; +using Microsoft.EntityFrameworkCore; using Microsoft.Extensions.Configuration; using Microsoft.Extensions.DependencyInjection; using Microsoft.Extensions.Hosting; @@ -25,6 +26,7 @@ private readonly IConfiguration _configuration; private readonly ILiaotianService _liaotianService; private readonly IHttpClientFactory _clientFactory; + private readonly IDtChannelArticleNewsService _dtChannelArticleNewsService; public TimerGetShopUsersService(ILogger<TimerGetShopUsersService> logger, IServiceScopeFactory factory) { @@ -32,6 +34,7 @@ _configuration = factory.CreateScope().ServiceProvider.GetRequiredService<IConfiguration>(); _liaotianService = factory.CreateScope().ServiceProvider.GetRequiredService<ILiaotianService>(); _clientFactory = factory.CreateScope().ServiceProvider.GetRequiredService<IHttpClientFactory>(); + _dtChannelArticleNewsService = factory.CreateScope().ServiceProvider.GetRequiredService<IDtChannelArticleNewsService>(); } protected override async Task ExecuteAsync(CancellationToken stoppingToken) @@ -52,6 +55,7 @@ try { + await this.huoquhuiyuanAsync(); } @@ -76,6 +80,17 @@ { base.Dispose(); } + public void ceshi() + { + DtChannelArticleNewsDTOSearch searchEntity = new DtChannelArticleNewsDTOSearch(); + searchEntity.EndTime = DateTime.Parse("2021-07-15 12:06:30.893"); + searchEntity.AddTime = DateTime.Parse("2021-07-01 12:06:30.893"); + searchEntity.UserName = "yangjiameng"; + searchEntity.CategoryId = 85; + var dtChannelArticleNewsDTOs = _dtChannelArticleNewsService.GetList(searchEntity); + + _logger.LogInformation("dtChannelArticleNewsDTOs锛�"+ dtChannelArticleNewsDTOs.Count); + } public async Task huoquhuiyuanAsync() { -- Gitblit v1.9.1