| | |
| | | using cylsg.Core; |
| | | using cylsg.Model.OrderModel; |
| | | using cylsg.Model.UserModel; |
| | | using EzTencentCloud; |
| | | using Furion.LinqBuilder; |
| | | using MapsterMapper; |
| | | using Org.BouncyCastle.Asn1.X509; |
| | | using SqlSugar.Extensions; |
| | | using System; |
| | | using System.Collections.Generic; |
| | | using System.Linq; |
| | |
| | | private readonly ISystemService _systemService; |
| | | private ISqlSugarClient _sqlSugarClient; |
| | | private IMapper _mapper; |
| | | public OrderWorkerAppService(ISystemService systemService, ISqlSugarClient sqlSugarClient, IMapper mapper) |
| | | private readonly ITencentCloudService _tencentCloudService; |
| | | public OrderWorkerAppService(ISystemService systemService, ISqlSugarClient sqlSugarClient, IMapper mapper,ITencentCloudService tencentCloudService) |
| | | { |
| | | _systemService = systemService; |
| | | _sqlSugarClient = sqlSugarClient; |
| | | _mapper = mapper; |
| | | _tencentCloudService = tencentCloudService; |
| | | } |
| | | |
| | | |
| | |
| | | |
| | | return result; |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | |
| | | { |
| | | throw Oops.Oh("该打卡记录已经审批,不能打卡!"); |
| | | } |
| | | //人脸识别 |
| | | if (App.Configuration["VerifyFace:Enable"].ObjToBool()) |
| | | { |
| | | if (string.IsNullOrWhiteSpace(dakaDto.FaceImg)) |
| | | { |
| | | throw Oops.Oh("未识别人脸"); |
| | | } |
| | | |
| | | var UserWorkRes = await new BaseRepository<UserWorker>().GetFirstAsync(x => x.UserId == userid); |
| | | if (UserWorkRes == null) |
| | | { |
| | | throw Oops.Oh("员工未注册成工人"); |
| | | } |
| | | var faseres = _tencentCloudService.VerifyFace(dakaDto.FaceImg, UserWorkRes.IAIPersonId); |
| | | |
| | | if (faseres.IsMatch != true) |
| | | { |
| | | throw Oops.Oh("不是本人"); |
| | | } |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | if(orderBiddingDetail == null) |
| | | { |
| | | orderBiddingDetail = new OrderBiddingDetail(); |