| 
														
															@@ -12,6 +12,7 @@ using ZhonTai.Admin.Core.Configs; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 using ZhonTai.Admin.Core.Consts; 
														 | 
														
														 | 
														
															 using ZhonTai.Admin.Core.Consts; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 using ZhonTai.Admin.Core.Dto; 
														 | 
														
														 | 
														
															 using ZhonTai.Admin.Core.Dto; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 using ZhonTai.Admin.Domain.User; 
														 | 
														
														 | 
														
															 using ZhonTai.Admin.Domain.User; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+using ZhonTai.Admin.Repositories.KuaKe; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 using ZhonTai.Admin.Repositories.Project; 
														 | 
														
														 | 
														
															 using ZhonTai.Admin.Repositories.Project; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 using ZhonTai.Admin.Repositories.ProjectLink; 
														 | 
														
														 | 
														
															 using ZhonTai.Admin.Repositories.ProjectLink; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 using ZhonTai.Admin.Services.DiTuiAPI.Dto; 
														 | 
														
														 | 
														
															 using ZhonTai.Admin.Services.DiTuiAPI.Dto; 
														 | 
													
												
											
										
											
												
													
														 | 
														
															@@ -35,19 +36,23 @@ namespace ZhonTai.Admin.Services.DiTuiAPI 
														 | 
													
												
											
												
													
														| 
														 | 
														
															         private ProjectPriceRepository _projectPriceRepository; 
														 | 
														
														 | 
														
															         private ProjectPriceRepository _projectPriceRepository; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															         private ProjectStatRepository _projectStatRepository; 
														 | 
														
														 | 
														
															         private ProjectStatRepository _projectStatRepository; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															         private ProjectConfigRepository _projectConfigRepository; 
														 | 
														
														 | 
														
															         private ProjectConfigRepository _projectConfigRepository; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+        private KuaKeRepository _kuaKeRepository; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															  
														 | 
														
														 | 
														
															  
														 | 
													
												
											
												
													
														| 
														 | 
														
															         public ProjectsService( 
														 | 
														
														 | 
														
															         public ProjectsService( 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             ProjectLinkRepository projectLinkRepository, 
														 | 
														
														 | 
														
															             ProjectLinkRepository projectLinkRepository, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             ProjectRepository projectRepository, 
														 | 
														
														 | 
														
															             ProjectRepository projectRepository, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             ProjectPriceRepository projectPriceRepository, 
														 | 
														
														 | 
														
															             ProjectPriceRepository projectPriceRepository, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             ProjectStatRepository projectStatRepository, 
														 | 
														
														 | 
														
															             ProjectStatRepository projectStatRepository, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-            ProjectConfigRepository projectConfigRepository) 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+            ProjectConfigRepository projectConfigRepository, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+            KuaKeRepository kuaKeRepository 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+            ) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															         { 
														 | 
														
														 | 
														
															         { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             _ProjectLinkRepository = projectLinkRepository; 
														 | 
														
														 | 
														
															             _ProjectLinkRepository = projectLinkRepository; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             _projectRepository = projectRepository; 
														 | 
														
														 | 
														
															             _projectRepository = projectRepository; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             _projectPriceRepository = projectPriceRepository; 
														 | 
														
														 | 
														
															             _projectPriceRepository = projectPriceRepository; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             _projectStatRepository = projectStatRepository; 
														 | 
														
														 | 
														
															             _projectStatRepository = projectStatRepository; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             _projectConfigRepository = projectConfigRepository; 
														 | 
														
														 | 
														
															             _projectConfigRepository = projectConfigRepository; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+            _kuaKeRepository = kuaKeRepository; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															         } 
														 | 
														
														 | 
														
															         } 
														 | 
													
												
											
												
													
														| 
														 | 
														
															  
														 | 
														
														 | 
														
															  
														 | 
													
												
											
												
													
														| 
														 | 
														
															         /// <summary> 
														 | 
														
														 | 
														
															         /// <summary> 
														 | 
													
												
											
										
											
												
													
														 | 
														
															@@ -156,7 +161,7 @@ namespace ZhonTai.Admin.Services.DiTuiAPI 
														 | 
													
												
											
												
													
														| 
														 | 
														
															              
														 | 
														
														 | 
														
															              
														 | 
													
												
											
												
													
														| 
														 | 
														
															             var result = await _projectRepository.Select.DisableGlobalFilter() 
														 | 
														
														 | 
														
															             var result = await _projectRepository.Select.DisableGlobalFilter() 
														 | 
													
												
											
												
													
														| 
														 | 
														
															                 .Where(a => a.Id == id) 
														 | 
														
														 | 
														
															                 .Where(a => a.Id == id) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-                .FirstAsync(a => new ProjectDescOutput(a.Id,a.Logo,a.Name,"",a.SettleDay.ToString(),a.Tips,a.ProjectType)); 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                .FirstAsync(a => new ProjectDescOutput(a.Id,a.Logo,a.Name,"", "T+"+a.SettleDay.ToString()+"结算",a.Tips,a.ProjectType)); 
														 | 
													
												
											
												
													
														| 
														 | 
														
															  
														 | 
														
														 | 
														
															  
														 | 
													
												
											
												
													
														| 
														 | 
														
															             var maxPrice = await _projectPriceRepository 
														 | 
														
														 | 
														
															             var maxPrice = await _projectPriceRepository 
														 | 
													
												
											
												
													
														| 
														 | 
														
															                         .Select 
														 | 
														
														 | 
														
															                         .Select 
														 | 
													
												
											
										
											
												
													
														 | 
														
															@@ -313,26 +318,72 @@ namespace ZhonTai.Admin.Services.DiTuiAPI 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             { 
														 | 
														
														 | 
														
															             { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															                 throw ResultOutput.Exception("项目 ID 不可为空"); 
														 | 
														
														 | 
														
															                 throw ResultOutput.Exception("项目 ID 不可为空"); 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             } 
														 | 
														
														 | 
														
															             } 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+            var projectType = await _projectRepository 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                .Select 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                .DisableGlobalFilter(FilterNames.Tenant) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                .Where(a => a.Id == ProjectId) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                .FirstAsync(a => new 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    ProjectType = a.ProjectType 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                }); 
														 | 
													
												
											
												
													
														| 
														 | 
														
															  
														 | 
														
														 | 
														
															  
														 | 
													
												
											
												
													
														| 
														 | 
														
															-            var list = _ProjectLinkRepository.Select.DisableGlobalFilter(FilterNames.Tenant) 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-                .WhereIf(ProjectId.HasValue && ProjectId.Value > 0, a => a.ProjectId == ProjectId) 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-                .WhereIf(Salesman.NotNull(), a => a.Salesman.Contains(Salesman)) 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-                .WhereIf(SalesmanPhone.NotNull(), a => a.SalesmanPhone.Contains(SalesmanPhone)) 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-                .Where(a=> a.IsUse == 1 && a.TenantId == User.TenantId) 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-                .OrderByDescending(a => a.UseTime) 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-            .Count(out var total) 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-            .Page(input.CurrentPage, input.PageSize) 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-            .ToList(m => new ProjectQrcodePageOutput() 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+            // 1 正常项目  2 夸克项目 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+            List<ProjectQrcodePageOutput> list = new List<ProjectQrcodePageOutput>(); 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+            long total = 0; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+            if(projectType.ProjectType == 1) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             { 
														 | 
														
														 | 
														
															             { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-                Id = m.Id, 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-                Salesman = m.Salesman, 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-                UseTime = m.UseTime, 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-                ShortUrl = m.ShortUrl, 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-                Num = m.Num, 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-                ShareCommond = m.ShareCommand, 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-                QrcodeUrl = m.QrcodeUrl, 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-                QueryUrl = m.QueryUrl 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-            }); 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                  list = _ProjectLinkRepository.Select.DisableGlobalFilter(FilterNames.Tenant) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    .WhereIf(ProjectId.HasValue && ProjectId.Value > 0, a => a.ProjectId == ProjectId) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    .WhereIf(Salesman.NotNull(), a => a.Salesman.Contains(Salesman)) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    .WhereIf(SalesmanPhone.NotNull(), a => a.SalesmanPhone.Contains(SalesmanPhone)) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    .Where(a => a.IsUse == 1 && a.TenantId == User.TenantId) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    .OrderByDescending(a => a.UseTime) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                .Count(out total) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                .Page(input.CurrentPage, input.PageSize) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                .ToList(m => new ProjectQrcodePageOutput() 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    Id = m.Id, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    Salesman = m.Salesman, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    UseTime = m.UseTime, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    ShortUrl = m.ShortUrl, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    Num = m.Num, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    ShareCommond = m.ShareCommand, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    QrcodeUrl = m.QrcodeUrl, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    QueryUrl = m.QueryUrl 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                }); 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+            } 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+            else 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+            { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                string kuaKeStatus = null; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                kuaKeStatus = input.Filter?.KuaKeStatus == "0"? null : input.Filter?.KuaKeStatus; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                list = _kuaKeRepository.Select.DisableGlobalFilter(FilterNames.Tenant) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                //list = _ProjectLinkRepository.Select.DisableGlobalFilter(FilterNames.Tenant) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    .WhereIf(ProjectId.HasValue && ProjectId.Value > 0, a => a.ProjectId == ProjectId) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    .WhereIf(Salesman.NotNull(), a => a.Name.Contains(Salesman)) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    .WhereIf(SalesmanPhone.NotNull(), a => a.Phone.Contains(SalesmanPhone)) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    .WhereIf(kuaKeStatus.NotNull(), a => a.Status.ToString().Contains(kuaKeStatus)) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    .Where(a => a.TenantId == User.TenantId) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    .OrderByDescending(a => a.CreatedTime) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                .Count(out total) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                .Page(input.CurrentPage, input.PageSize) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                .ToList(m => new ProjectQrcodePageOutput() 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    Id = m.Id, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    Salesman = m.Name, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    UseTime = m.CreatedTime, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    ShortUrl = "", 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    Num = "", 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    ShareCommond = "", 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    QrcodeUrl = "", 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    QueryUrl = "", 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    KuaKeStatus = m.Status.ToString(), 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    KuaKeStatusColor = m.Status.ToString(), 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    Industry = m.Industry, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                    Platform = m.Platfrom 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+                }); ; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+            } 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+ 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+             
														 | 
													
												
											
												
													
														| 
														 | 
														
															  
														 | 
														
														 | 
														
															  
														 | 
													
												
											
												
													
														| 
														 | 
														
															             var data = new PageOutput<ProjectQrcodePageOutput>() 
														 | 
														
														 | 
														
															             var data = new PageOutput<ProjectQrcodePageOutput>() 
														 | 
													
												
											
												
													
														| 
														 | 
														
															             { 
														 | 
														
														 | 
														
															             { 
														 |