diff --git a/YLErpDAL/Modules/ClientModule/ClientDutyService.cs b/YLErpDAL/Modules/ClientModule/ClientDutyService.cs index 39ced04a..e2087d0d 100644 --- a/YLErpDAL/Modules/ClientModule/ClientDutyService.cs +++ b/YLErpDAL/Modules/ClientModule/ClientDutyService.cs @@ -98,7 +98,7 @@ namespace YLErp.Modules.ClientModule //针对法人,授权协议签署人才做唯一性判断,有效期结束后可新增 if ((contactType == contactypelist.FirstOrDefault(x => x.ContactType == "法人")?.id || (contactType == contactypelist.FirstOrDefault(x => x.ContactType == "授权协议签署人")?.id && PS.Config.Company == Configuration.CompanyEnum.国泰君安)) && DbContext.clientduty.Any(x => x.ApprovalOrder < 1 && x.ClientId == req.ClientId && x.ContactTypeId.Contains(contactType.ToString()) && (x.DeadLine >= DateTime.Now || !x.DeadLine.HasValue)) - && !PS.Config.Is浙期) + && !PS.Config.Is浙期 && PS.Config.Company != Configuration.CompanyEnum.国联) { throw new ServiceException("法人在有效期内必须唯一,授权协议签署人必须唯一"); } @@ -113,7 +113,7 @@ namespace YLErp.Modules.ClientModule //针对法人,授权协议签署人才做唯一性判断,有效期结束后可新增 if ((contactType == contactypelist.FirstOrDefault(x => x.ContactType == "法人")?.id || contactType == contactypelist.FirstOrDefault(x => x.ContactType == "授权协议签署人")?.id) && DbContext.clientduty.Any(x => x.ApprovalOrder < 1 && x.ClientId == req.ClientId && x.ContactTypeId.Contains(contactType.ToString()) && x.id != req.id && (x.DeadLine >= DateTime.Now || !x.DeadLine.HasValue)) - && !PS.Config.Is浙期) + && !PS.Config.Is浙期 && PS.Config.Company != Configuration.CompanyEnum.国联) { throw new ServiceException("法人在有效期内必须唯一,授权协议签署人必须唯一"); } @@ -208,7 +208,8 @@ namespace YLErp.Modules.ClientModule var clientCount = yldb.approvalprocess.Where(x => x.processType == "ClientProcess").Count(); if (dbmodel.ApprovalOrder == 0) { - if (clientCount > 0 && client.ProcessStatus == "已开户" && PS.Config.Is浙期) + if (clientCount > 0 && client.ProcessStatus == "已开户" + && (PS.Config.Is浙期 || PS.Config.Company == Configuration.CompanyEnum.国联)) { if (!isAdd) { @@ -397,7 +398,9 @@ namespace YLErp.Modules.ClientModule var clientCount = yldb.approvalprocess.Where(x => x.processType == "ClientProcess").Count(); - if (clientCount > 0 && client.ProcessStatus == "已开户" && PS.Config.Is浙期 && clientDuty.ApprovalOrder == 0) + if (clientCount > 0 && client.ProcessStatus == "已开户" + && (PS.Config.Is浙期 || PS.Config.Company == Configuration.CompanyEnum.国联) + && clientDuty.ApprovalOrder == 0) { clientDuty.ApprovalOrder = (int)ApprovalOrderEnum.删除; if (isDirectSubApp) diff --git a/YLErpDAL/Modules/ClientModule/ClientFileService.cs b/YLErpDAL/Modules/ClientModule/ClientFileService.cs index b4eab2ac..7999e682 100644 --- a/YLErpDAL/Modules/ClientModule/ClientFileService.cs +++ b/YLErpDAL/Modules/ClientModule/ClientFileService.cs @@ -1102,7 +1102,8 @@ namespace YLErp.Modules.ClientModule public bool resetClientProcess(client_file file, ApprovalOrderEnum orderEnum) { - if (string.IsNullOrWhiteSpace(file.ProtocolNumber) && file.ApprovalOrder == (int)ApprovalOrderEnum.无需审批 && !PS.Config.Is浙期) + if (string.IsNullOrWhiteSpace(file.ProtocolNumber) && file.ApprovalOrder == (int)ApprovalOrderEnum.无需审批 + && !PS.Config.Is浙期 && PS.Config.Company != Configuration.CompanyEnum.国联) { return false; } @@ -1539,4 +1540,4 @@ namespace YLErp.Modules.ClientModule public ThisUnitOpreateHandle thisUnitOpreate; public ThisUnitBackHandle thisUnitBack; } -} \ No newline at end of file +} diff --git a/YLErpDAL/Modules/ClientModule/ClientImportService.cs b/YLErpDAL/Modules/ClientModule/ClientImportService.cs index 1e2843f9..62537337 100644 --- a/YLErpDAL/Modules/ClientModule/ClientImportService.cs +++ b/YLErpDAL/Modules/ClientModule/ClientImportService.cs @@ -1777,7 +1777,8 @@ namespace YLErp.Modules.ClientModule var processlist = yldb.approvalprocess.Where(x => x.processType == "ClientProcess"); - if (processlist.Count() > 0 && client.ProcessStatus == "已开户" && PS.Config.Is浙期) + if (processlist.Count() > 0 && client.ProcessStatus == "已开户" + && (PS.Config.Is浙期 || PS.Config.Company == Configuration.CompanyEnum.国联)) { clientDuty.ApprovalOrder = (int)ApprovalOrderEnum.导入;