From 292bc0b6fc241099ea89e85444888f07f86adff9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=BD=87=E9=98=B3=20=E9=82=B9?= Date: Thu, 30 Nov 2023 22:28:43 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E4=B8=80=E4=B8=AA=E5=AD=97?= =?UTF-8?q?=E6=AE=B5=E6=8C=87=E7=A4=BA=E9=A2=84=E7=BA=A6=E8=AE=B0=E5=BD=95?= =?UTF-8?q?=E6=98=AF=E5=90=A6=E5=B7=B2=E7=BB=8F=E5=88=86=E9=85=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Common/LawyerArchivesController.cs | 44 ++++++++++++++++--- .../AppMode/App_LawyerServicesModel.cs | 4 +- 2 files changed, 41 insertions(+), 7 deletions(-) diff --git a/24Hour/Controllers/Common/LawyerArchivesController.cs b/24Hour/Controllers/Common/LawyerArchivesController.cs index cd34011..e4f2ade 100644 --- a/24Hour/Controllers/Common/LawyerArchivesController.cs +++ b/24Hour/Controllers/Common/LawyerArchivesController.cs @@ -362,6 +362,16 @@ namespace _24Hour.Controllers.Common { try { + var lawsvc =await _db.Queryable().Where(x => x.Id == dto.Id).FirstAsync(); + if (lawsvc==null) + { + return Result.Error("预约信息不存在"); + } + if (lawsvc.IsAssigned==true) + { + return Result.Error("当前预约信息已被分配"); + } + var entity = mapper.Map(dto); entity.Id = Guid.NewGuid().ToString(); entity.createrId = _userdata.Id; @@ -369,7 +379,10 @@ namespace _24Hour.Controllers.Common entity.status = 0; entity.copyStatus = 0; entity.IsDeleted = 0; + + lawsvc.IsAssigned = true; _db.BeginTran(); + _db.Updateable(lawsvc).UpdateColumns(x => x.IsAssigned).ExecuteCommand(); var num = await _db.Insertable(entity).ExecuteCommandAsync(); _db.CommitTran(); if (num > 0) @@ -578,7 +591,6 @@ namespace _24Hour.Controllers.Common ///} /// /// - [HttpGet] [Route("QueryDsrList")] public async Task> QueryDsrList(string bmsah, string unitcode, string PartyIdCard) @@ -823,8 +835,13 @@ namespace _24Hour.Controllers.Common { return await twentyClient.Arrange(input); } - - + /// + /// 上传数据只2.0系统 + /// + /// + /// + [HttpPost] + [Route("UploadDataToTwentyfourSys")] public async Task UploadDataToTwentyfourSys(string lawyerarchivesId) { try @@ -833,9 +850,14 @@ namespace _24Hour.Controllers.Common var lawyersvc = await _db.Queryable().Where(x => x.Id == lawyerArchives.Id).FirstAsync(); var lawyer = await _db.Queryable().Where(x => x.Id == lawyerArchives.lawyerId).FirstAsync(); var departmenginfo = await _db.Queryable().Where(x => x.unitCode == _userdata.unitCode).FirstAsync(); + logger.LogInformation($"get lawyerarchivesinfo:{lawyerArchives.ConvertToJsonStr()}"); + logger.LogInformation($"get lawyersvcinfo:{lawyersvc.ConvertToJsonStr()}"); + logger.LogInformation($"get lawyerinfo:{lawyer.ConvertToJsonStr()}"); + logger.LogInformation($"get departmenginfo:{departmenginfo.ConvertToJsonStr()}"); var UnitCode = _userdata.unitCode; var UnitName = departmenginfo.unitjc; var querylawyer = await QueryLsList(lawyer.identitycardId); + #region 数据检查 if (querylawyer.IsSucceed == true) { if (querylawyer.result.content.Count <= 0) @@ -886,6 +908,7 @@ namespace _24Hour.Controllers.Common result.Message = "律师数据不存在"; return result; } + #endregion var registerinforequest = await Register(new RegisterDto() { Bmsah = lawyerArchives.bmsah, @@ -902,7 +925,7 @@ namespace _24Hour.Controllers.Common { "监护人" => "1424000000300", "近亲属" => "1424000000200", - _ => "" + _ => "1424000000100" }, Wtrydsrgxmc = lawyersvc.relationship switch { @@ -991,7 +1014,6 @@ namespace _24Hour.Controllers.Common return result; } } - /// /// PC端根据卷宗id获取卷宗信息 /// @@ -1572,6 +1594,11 @@ namespace _24Hour.Controllers.Common return Task.FromResult(result); } + /// + /// 导入律师信息 + /// + /// + /// [HttpGet] [Route("ImportLawyerArchivesInfo")] public async Task ImportLawyerArchivesInfo(string path) @@ -1767,6 +1794,11 @@ namespace _24Hour.Controllers.Common result.IsSucceed = true; return result; } + /// + /// 导出律师信息 + /// + /// + /// [HttpPost] [Route("ExportLawyerArchivesInfo")] public async Task ExportLawyerArchivesInfo(List ids) @@ -1924,7 +1956,7 @@ namespace _24Hour.Controllers.Common [HttpPost] [Route("UploadSignImage")] /// - /// + /// 上传签字照片 /// /// /// diff --git a/Elight.Entity/AppMode/App_LawyerServicesModel.cs b/Elight.Entity/AppMode/App_LawyerServicesModel.cs index 4e92972..8ff2b33 100644 --- a/Elight.Entity/AppMode/App_LawyerServicesModel.cs +++ b/Elight.Entity/AppMode/App_LawyerServicesModel.cs @@ -180,6 +180,8 @@ namespace Elight.Entity [DataMember] public string? mandatorcardId { get; set; } [DataMember] - public string? relationship { get; set; } + public string? relationship { get; set; } + [DataMember] + public bool? IsAssigned { get; set; } } }