username@email.com
2021-06-28 8de9a465342385e0ebee7dc430abadd69a2b67dd
zhengcaioa/zhengcaioa/Controllers/Customer/CooperVisitController.cs
@@ -30,9 +30,11 @@
        private readonly ICooperatecustomCustomerService _cooperatecustomCustomerService;
        private readonly IUserService _userService;
        private readonly ICooperVisitService _cooperVisitService;
        private readonly ICusFangwenjiluService _cusFangwenjiluService;
        public CooperVisitController(ILogger<CooperVisitController> logger, IProjectService projectService, ILiaotianService liaotianService, ICooperatecustomCustomerService cooperatecustomCustomerService, IUserService userService, ICooperVisitService cooperVisitService)
        public CooperVisitController(ILogger<CooperVisitController> logger, IProjectService projectService, ILiaotianService liaotianService, ICooperatecustomCustomerService cooperatecustomCustomerService, IUserService userService, ICooperVisitService cooperVisitService
            , ICusFangwenjiluService cusFangwenjiluService)
        {
            _logger = logger;
            _projectService = projectService;
@@ -40,6 +42,7 @@
            _cooperatecustomCustomerService = cooperatecustomCustomerService;
            _userService = userService;
            _cooperVisitService = cooperVisitService;
            _cusFangwenjiluService = cusFangwenjiluService;
        }
        public IActionResult Index()
@@ -213,8 +216,18 @@
            {
                resultEntity.Result = false;
                resultEntity.Message = "短信发送失败";
                return new JsonResult(resultEntity);
            }
            CusFangwenjiluDTO dto = new CusFangwenjiluDTO();
            dto.Fasongfangshi = "01";
            dto.Fasongneirong = neirong;
            dto.Jieshouren = baifangid;
            dto.RecStatus = "A";
            dto.Creater = curentuser.Id;
            dto.Modifytime = DateTime.Now;
            dto.Modifier = curentuser.Id;
            dto.Createtime = dto.Modifytime;
            resultEntity = _cusFangwenjiluService.save(dto);
            _logger.LogInformation(curentuser.UserName + "发送短信给客户" + customename);
            return new JsonResult(resultEntity);
        }
@@ -284,7 +297,16 @@
            {
                return new JsonResult(resultEntity);
            }
            CusFangwenjiluDTO dto = new CusFangwenjiluDTO();
            dto.Fasongfangshi = "02";
            dto.Fasongneirong = neirong;
            dto.Jieshouren = baifangid;
            dto.RecStatus = "A";
            dto.Creater = curentuser.Id;
            dto.Modifytime = DateTime.Now;
            dto.Modifier = curentuser.Id;
            dto.Createtime = dto.Modifytime;
            resultEntity = _cusFangwenjiluService.save(dto);
            _logger.LogInformation(curentuser.UserName + "发送邮件给客户" + customename);
            return new JsonResult(resultEntity);