Browse Source

Merge branch 'test' of http://110.188.24.182:10023/Fengwo/hotline into test

qinchaoyue 3 weeks ago
parent
commit
7cecb1e97e

+ 3 - 0
src/Hotline.Api/Controllers/OrderController.cs

@@ -1769,6 +1769,7 @@ public class OrderController : BaseController
     /// <param name="dto"></param>
     /// <param name="dto"></param>
     /// <returns></returns>
     /// <returns></returns>
     [HttpPost("visit/judge")]
     [HttpPost("visit/judge")]
+    [LogFilterAlpha("扭转满意度")]
     public async Task<JudgeVisitRsp> JudgeVisit([FromBody] JudgeVisitReq dto)
     public async Task<JudgeVisitRsp> JudgeVisit([FromBody] JudgeVisitReq dto)
     {
     {
         int error = 0;
         int error = 0;
@@ -1792,6 +1793,7 @@ public class OrderController : BaseController
     /// <param name="dto"></param>
     /// <param name="dto"></param>
     /// <returns></returns>
     /// <returns></returns>
     [HttpPost("visit/migration")]
     [HttpPost("visit/migration")]
+    [LogFilterAlpha("回访平移")]
     public async Task VisitMigrationBatch([FromBody] DistributionVisitDto dto)
     public async Task VisitMigrationBatch([FromBody] DistributionVisitDto dto)
     {
     {
         var visits = await _orderVisitRepository.Queryable()
         var visits = await _orderVisitRepository.Queryable()
@@ -1838,6 +1840,7 @@ public class OrderController : BaseController
     /// <param name="dto"></param>
     /// <param name="dto"></param>
     /// <returns></returns>
     /// <returns></returns>
     [HttpPut("visit/put_through")]
     [HttpPut("visit/put_through")]
+    [LogFilterAlpha("设置未接通")]
     public async Task VisitPutThrough([FromBody] VisitPutThroughDto dto)
     public async Task VisitPutThrough([FromBody] VisitPutThroughDto dto)
     {
     {
         await _orderVisitRepository.Updateable().SetColumns(x => new OrderVisit { IsPutThrough = false }).Where(x => x.Id == dto.id)
         await _orderVisitRepository.Updateable().SetColumns(x => new OrderVisit { IsPutThrough = false }).Where(x => x.Id == dto.id)

+ 1 - 1
src/Hotline.Application/Exam/Service/Practices/PracticeService.cs

@@ -596,7 +596,7 @@ namespace Hotline.Application.Exam.Service.Practices
             var questionRepository = new ExamRepository<ExamQuestion>(_uow, _dataPermissionFilterBuilder, _serviceProvider);
             var questionRepository = new ExamRepository<ExamQuestion>(_uow, _dataPermissionFilterBuilder, _serviceProvider);
 
 
             var questionTagTable = questionTagRepostiory.Queryable();
             var questionTagTable = questionTagRepostiory.Queryable();
-            var questionTable = questionRepository.Queryable();
+            var questionTable = questionRepository.Queryable().Where(x=>!(x.QuestionType == Share.Enums.Exams.EQuestionType.Single && x.QuestionType == Share.Enums.Exams.EQuestionType.Multi || x.QuestionType == Share.Enums.Exams.EQuestionType.Judge));
 
 
             // 按照标签获取试题,至少取一道
             // 按照标签获取试题,至少取一道
             if (actionRequest.Count < actionRequest.PracticeTagDtos.Count)
             if (actionRequest.Count < actionRequest.PracticeTagDtos.Count)

+ 4 - 1
src/Hotline.Application/OrderApp/OrderApplication.cs

@@ -2579,7 +2579,8 @@ public class OrderApplication : IOrderApplication, IScopeDependency
             .Where(x => x.OrderVisit.VisitTime >= dto.StartTime.Value && x.OrderVisit.VisitTime <= dto.EndTime.Value &&
             .Where(x => x.OrderVisit.VisitTime >= dto.StartTime.Value && x.OrderVisit.VisitTime <= dto.EndTime.Value &&
                         x.VisitTarget == EVisitTarget.Org && x.OrderVisit.VisitState == EVisitState.Visited && !string.IsNullOrEmpty(x.VisitOrgCode))
                         x.VisitTarget == EVisitTarget.Org && x.OrderVisit.VisitState == EVisitState.Visited && !string.IsNullOrEmpty(x.VisitOrgCode))
             .WhereIF(string.IsNullOrEmpty(dto.OrgName) == false, x => x.VisitOrgName.Contains(dto.OrgName))
             .WhereIF(string.IsNullOrEmpty(dto.OrgName) == false, x => x.VisitOrgName.Contains(dto.OrgName))
-            .WhereIF(string.IsNullOrEmpty(dto.LineNum) == false, x => x.OrderVisit.Order.CallRecord.Gateway.Contains(dto.LineNum))
+            .WhereIF(string.IsNullOrEmpty(dto.LineNum) == false && _appOptions.Value.IsYiBin == true, x => x.OrderVisit.Order.CallRecord.Gateway.Contains(dto.LineNum))
+            .WhereIF(string.IsNullOrEmpty(dto.LineNum) == false && _appOptions.Value.IsYiBin == false, x => x.OrderVisit.Order.FwCallRecord.ToNo.Contains(dto.LineNum))
             .WhereIF(dto.TypeCode != null && dto.TypeCode == 1, x => x.OrderVisit.Order.IdentityType == EIdentityType.Citizen)
             .WhereIF(dto.TypeCode != null && dto.TypeCode == 1, x => x.OrderVisit.Order.IdentityType == EIdentityType.Citizen)
             .WhereIF(dto.TypeCode != null && dto.TypeCode == 2, x => x.OrderVisit.Order.IdentityType == EIdentityType.Enterprise)
             .WhereIF(dto.TypeCode != null && dto.TypeCode == 2, x => x.OrderVisit.Order.IdentityType == EIdentityType.Enterprise)
             .WhereIF(IsCenter == false, x => x.VisitOrgCode.StartsWith(_sessionContext.OrgId))
             .WhereIF(IsCenter == false, x => x.VisitOrgCode.StartsWith(_sessionContext.OrgId))
@@ -4585,6 +4586,7 @@ public class OrderApplication : IOrderApplication, IScopeDependency
              .Includes(d => d.Order, d => d.OrderTags)
              .Includes(d => d.Order, d => d.OrderTags)
              .Includes(d => d.Employee)
              .Includes(d => d.Employee)
              .Includes(d => d.OrderVisitDetails)
              .Includes(d => d.OrderVisitDetails)
+             .Includes(d => d.Order, d => d.OrderVisits.Where(x => x.VisitState == EVisitState.Visited))
              .Where(d => d.VisitTime >= dto.StartTime && d.VisitTime <= dto.EndTime && d.VisitType != null && d.EmployeeId != "" && d.EmployeeId != null)
              .Where(d => d.VisitTime >= dto.StartTime && d.VisitTime <= dto.EndTime && d.VisitType != null && d.EmployeeId != "" && d.EmployeeId != null)
              .WhereIF(!string.IsNullOrEmpty(dto.UserID), d => !string.IsNullOrEmpty(d.EmployeeId) && d.EmployeeId == dto.UserID)
              .WhereIF(!string.IsNullOrEmpty(dto.UserID), d => !string.IsNullOrEmpty(d.EmployeeId) && d.EmployeeId == dto.UserID)
              .WhereIF(!string.IsNullOrEmpty(dto.UserName), d => d.Employee.Name == dto.UserName)
              .WhereIF(!string.IsNullOrEmpty(dto.UserName), d => d.Employee.Name == dto.UserName)
@@ -4642,6 +4644,7 @@ public class OrderApplication : IOrderApplication, IScopeDependency
         var query = _orderVisitRecordRepository.Queryable()
         var query = _orderVisitRecordRepository.Queryable()
             .Includes(d => d.Order, d => d.OrderTags)
             .Includes(d => d.Order, d => d.OrderTags)
             .Includes(d => d.Employee)
             .Includes(d => d.Employee)
+            .Includes(d => d.Order, d => d.OrderVisits.Where(x => x.VisitState == EVisitState.Visited))
             .WhereIF(!string.IsNullOrEmpty(dto.UserID), d => !string.IsNullOrEmpty(d.EmployeeId) && d.EmployeeId == dto.UserID)
             .WhereIF(!string.IsNullOrEmpty(dto.UserID), d => !string.IsNullOrEmpty(d.EmployeeId) && d.EmployeeId == dto.UserID)
             .WhereIF(!string.IsNullOrEmpty(dto.UserName), d => d.Employee.Name == dto.UserName)
             .WhereIF(!string.IsNullOrEmpty(dto.UserName), d => d.Employee.Name == dto.UserName)
             .WhereIF(dto.StartTime != null, d => d.VisitTime >= dto.StartTime && d.VisitType != null && d.EmployeeId != "" && d.EmployeeId != null)
             .WhereIF(dto.StartTime != null, d => d.VisitTime >= dto.StartTime && d.VisitType != null && d.EmployeeId != "" && d.EmployeeId != null)

+ 5 - 0
src/Hotline.Share/Dtos/Trains/TrainPracticeOptionsDto.cs

@@ -92,5 +92,10 @@ namespace Hotline.Share.Dtos.Trains
         [Description("是否选择")]
         [Description("是否选择")]
         public bool IsSelected { get; set; }
         public bool IsSelected { get; set; }
 
 
+        /// <summary>
+        /// 是否正确答案
+        /// </summary>
+        [Description("是否正确答案")]
+        public bool IsAnswer { get; set; }
     }
     }
 }
 }