|
@@ -14,6 +14,7 @@ using ZhonTai.Admin.Core.Consts;
|
|
|
using ZhonTai.Admin.Core.Dto;
|
|
|
using ZhonTai.Admin.Domain.Project;
|
|
|
using ZhonTai.Admin.Domain.User;
|
|
|
+using ZhonTai.Admin.Repositories;
|
|
|
using ZhonTai.Admin.Repositories.Notice;
|
|
|
using ZhonTai.Admin.Repositories.Project;
|
|
|
using ZhonTai.Admin.Services.DiTuiAPI.Dto;
|
|
@@ -31,11 +32,13 @@ namespace ZhonTai.Admin.Services.DiTuiAPI
|
|
|
{
|
|
|
private ProjectRepository _projectRepository;
|
|
|
private NoticeRepository _noticeRepository;
|
|
|
+ private OrgRepository _orgRepository;
|
|
|
|
|
|
- public IndexService(ProjectRepository projectRepository,NoticeRepository noticeRepository)
|
|
|
+ public IndexService(ProjectRepository projectRepository,NoticeRepository noticeRepository,OrgRepository orgRepository)
|
|
|
{
|
|
|
_projectRepository = projectRepository;
|
|
|
_noticeRepository = noticeRepository;
|
|
|
+ _orgRepository = orgRepository;
|
|
|
}
|
|
|
|
|
|
/// <summary>
|
|
@@ -47,11 +50,15 @@ namespace ZhonTai.Admin.Services.DiTuiAPI
|
|
|
public async Task<IndexOutput> IndexAsync()
|
|
|
{
|
|
|
var uId = User?.Id;
|
|
|
-
|
|
|
-
|
|
|
+ var tenantId = User.TenantId;
|
|
|
+ IndexOutput indexOutPut = await _orgRepository.Select.DisableGlobalFilter()
|
|
|
+ .Where(a => a.TenantId == User.TenantId)
|
|
|
+ .FirstAsync(a => new IndexOutput(a.Id, a.Name));
|
|
|
+
|
|
|
+
|
|
|
|
|
|
- IndexOutput indexOutPut = new IndexOutput();
|
|
|
- indexOutPut.Name = "99地推";
|
|
|
+ //IndexOutput indexOutPut = new IndexOutput();
|
|
|
+ //indexOutPut.Name = "99地推";
|
|
|
indexOutPut.Tips = "推广要求:杜绝任何虚假、作弊、违法行为!";
|
|
|
|
|
|
List<Imgs> imgsList = new List<Imgs>();
|