From c21e92e4187d70d0ef0b3ff00859e6b3d7d9117a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B0=8C=E5=85=88=E8=88=9C?= <2499071264@qq.com> Date: Thu, 5 Nov 2026 17:42:34 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E7=96=97=E4=BC=91=E5=85=BBUI=E4=BC=98?= =?UTF-8?q?=E5=8C=962?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ...eRapyRecuperationUnionQueryController.java | 44 ++++--- ...pyRecuperationTravelAgencyServiceImpl.java | 20 +++- .../process/TheRapyQuery.html | 13 +- .../therapyRecuperation/lineList.html | 113 +++++++++++++----- 4 files changed, 140 insertions(+), 50 deletions(-) diff --git a/src/main/java/com/budwk/app/zhgh/staffbenefit/therapyRecuperation/controller/process/TheRapyRecuperationUnionQueryController.java b/src/main/java/com/budwk/app/zhgh/staffbenefit/therapyRecuperation/controller/process/TheRapyRecuperationUnionQueryController.java index d7401e9..d199a0a 100644 --- a/src/main/java/com/budwk/app/zhgh/staffbenefit/therapyRecuperation/controller/process/TheRapyRecuperationUnionQueryController.java +++ b/src/main/java/com/budwk/app/zhgh/staffbenefit/therapyRecuperation/controller/process/TheRapyRecuperationUnionQueryController.java @@ -260,7 +260,7 @@ public class TheRapyRecuperationUnionQueryController { cnd.andEX("enroll.isNormal", "=", true); cnd.andEX("YEAR ( enroll.signingUptime )", "=", year); - if (StrUtil.isNotBlank(lotId)) { + if (!"2".equals(state) && StrUtil.isNotBlank(lotId)) { SqlExpressionGroup seg = new SqlExpressionGroup(); seg.or("line.lotId", "=", lotId); // seg.or("agency.lotId", "=", lotId); @@ -275,7 +275,7 @@ public class TheRapyRecuperationUnionQueryController { } cnd.andEX("enroll.selfUnionId", "=", unionId); } else { - if (StrUtil.isNotBlank(state2)) { + if ("1".equals(state) && StrUtil.isNotBlank(state2)) { //等于1本工会人员看自己工会线路人员 if (state2.equals("1")) { cnd.andEX("enroll.selfUnionId", "=", TherapyContext.getUnionId()); @@ -296,8 +296,10 @@ public class TheRapyRecuperationUnionQueryController { } } cnd.andEX("enroll.selfUnitId", "=", unitId); - cnd.andEX("lineu.lineId", "=", takePartInLineId); - cnd.andEX("lineu.id", "=", selectId); + if (!"2".equals(state)) { + cnd.andEX("lineu.lineId", "=", takePartInLineId); + cnd.andEX("lineu.id", "=", selectId); + } addEnrollTravelAgencyCondition(cnd, agencyId); if (state.equals("1")) { cnd.andEX("line.regionalNature", "=", regionalNature); @@ -305,9 +307,8 @@ public class TheRapyRecuperationUnionQueryController { cnd.and("enroll.takePartInLineId", "!=", ""); sql.setVar("lotSql", ",(select lotName from inclusive_therapy_v3_lot where id = line.lotId) as lotName"); } else if (state.equals("2")) { - cnd.and("enroll.takePartInTravelAgencyId", "is not", null); - cnd.and("enroll.takePartInTravelAgencyId", "!=", ""); - cnd.andEX("enroll.takePartInTravelAgencyId", "=", agencyId); + cnd.and("agency.id", "is not", null); + cnd.andEX("agency.id", "=", agencyId); } else if ("3".equals(state)) { cnd.and("enroll.takePartInBaseManagementId", "is not", null); cnd.andEX("enroll.takePartInBaseManagementId", "=", takePartInBaseManagementId); @@ -338,17 +339,24 @@ public class TheRapyRecuperationUnionQueryController { SELECT agency.*, files AS fileId, - ( SELECT COUNT( 1 ) FROM inclusive_therapy_v3_enroll WHERE agency.id = takePartInTravelAgencyId and isNormal=true and stateId=@stateId $unionCnd $yearCnd) agencyNum + ( SELECT COUNT(1) + FROM inclusive_therapy_v3_enroll enroll + LEFT JOIN inclusive_therapy_v3_line_union_select lineu ON lineu.id = enroll.takePartInLineId + LEFT JOIN inclusive_therapy_v3_line line ON line.id = lineu.lineId + WHERE agency.id = IFNULL(enroll.takePartInTravelAgencyId, IFNULL(lineu.travelAgencyId, line.travelAgencyId)) + AND enroll.isNormal = TRUE AND enroll.stateId = @stateId + $agencyUnionCnd $agencyYearCnd + ) agencyNum FROM inclusive_therapy_v3_travel_agency agency ) agency $condition """).setParam("stateId", TheRapyRecuperationState.PASS); if (!TherapyContext.hasAnyRoles("sysadmin,H06")) { - sql.setVar("unionCnd", "AND selfUnionId = '%s' ".formatted(TherapyContext.getUnionId())); + sql.setVar("agencyUnionCnd", "AND enroll.selfUnionId = '%s' ".formatted(TherapyContext.getUnionId())); } if (StrUtil.isNotBlank(year)) { - sql.setVar("yearCnd", "AND YEAR(signingUptime) = '%s' ".formatted(year)); + sql.setVar("agencyYearCnd", "AND YEAR(enroll.signingUptime) = '%s' ".formatted(year)); } cnd.andEX("agency.`year`", "=", year); cnd.andEX("agency.id", "=", agencyId); @@ -640,8 +648,8 @@ public class TheRapyRecuperationUnionQueryController { //cnd1.and(Cnd.exps("enroll.selfUnionId", "=", Vi.getUnionId())); } } else if (state.equals("2")) { - cnd1.and("enroll.takePartInTravelAgencyId", "is not", null) - .and("enroll.takePartInTravelAgencyId", "!=", "") + cnd1.and("IFNULL(enroll.takePartInTravelAgencyId, IFNULL(lineu.travelAgencyId, line.travelAgencyId))", "is not", null) + .and("IFNULL(enroll.takePartInTravelAgencyId, IFNULL(lineu.travelAgencyId, line.travelAgencyId))", "!=", "") .and("enroll.selfUnionId", "=", TherapyContext.getUnionId()); } else { cnd1.and("enroll.takePartInBaseManagementId", "is not", null).and("enroll.selfUnionId", "=", TherapyContext.getUnionId()); @@ -676,8 +684,8 @@ public class TheRapyRecuperationUnionQueryController { cnd1.and("enroll.takePartInLineId", "is not", null); cnd1.and("enroll.takePartInLineId", "!=", ""); } else if (state.equals("2")) { - cnd1.and("enroll.takePartInTravelAgencyId", "is not", null); - cnd1.and("enroll.takePartInTravelAgencyId", "!=", ""); + cnd1.and("IFNULL(enroll.takePartInTravelAgencyId, IFNULL(lineu.travelAgencyId, line.travelAgencyId))", "is not", null); + cnd1.and("IFNULL(enroll.takePartInTravelAgencyId, IFNULL(lineu.travelAgencyId, line.travelAgencyId))", "!=", ""); cnd1.andEX("enroll.selfUnionId", "=", unionId); } else if (state.equals("3")) { cnd1.and("enroll.takePartInBaseManagementId", "is not", null); @@ -733,8 +741,8 @@ public class TheRapyRecuperationUnionQueryController { //cnd2.and(Cnd.exps("enroll.selfUnionId", "=", Vi.getUnionId())); } } else if (state.equals("2")) { - cnd2.and("enroll.takePartInTravelAgencyId", "is not", null) - .and("enroll.takePartInTravelAgencyId", "!=", "") + cnd2.and("IFNULL(enroll.takePartInTravelAgencyId, IFNULL(lineu.travelAgencyId, line.travelAgencyId))", "is not", null) + .and("IFNULL(enroll.takePartInTravelAgencyId, IFNULL(lineu.travelAgencyId, line.travelAgencyId))", "!=", "") .and("enroll.selfUnionId", "=", TherapyContext.getUnionId()); } else { cnd2.and("enroll.takePartInBaseManagementId", "is not", null).and("enroll.selfUnionId", "=", TherapyContext.getUnionId()); @@ -769,8 +777,8 @@ public class TheRapyRecuperationUnionQueryController { cnd2.and("enroll.takePartInLineId", "is not", null); cnd2.and("enroll.takePartInLineId", "!=", ""); } else if (state.equals("2")) { - cnd2.and("enroll.takePartInTravelAgencyId", "is not", null); - cnd2.and("enroll.takePartInTravelAgencyId", "!=", ""); + cnd2.and("IFNULL(enroll.takePartInTravelAgencyId, IFNULL(lineu.travelAgencyId, line.travelAgencyId))", "is not", null); + cnd2.and("IFNULL(enroll.takePartInTravelAgencyId, IFNULL(lineu.travelAgencyId, line.travelAgencyId))", "!=", ""); cnd2.andEX("enroll.selfUnionId", "=", unionId); } else { cnd2.and("enroll.takePartInBaseManagementId", "is not", null); diff --git a/src/main/java/com/budwk/app/zhgh/staffbenefit/therapyRecuperation/service/impl/TheRapyRecuperationTravelAgencyServiceImpl.java b/src/main/java/com/budwk/app/zhgh/staffbenefit/therapyRecuperation/service/impl/TheRapyRecuperationTravelAgencyServiceImpl.java index 9403bb5..7154845 100644 --- a/src/main/java/com/budwk/app/zhgh/staffbenefit/therapyRecuperation/service/impl/TheRapyRecuperationTravelAgencyServiceImpl.java +++ b/src/main/java/com/budwk/app/zhgh/staffbenefit/therapyRecuperation/service/impl/TheRapyRecuperationTravelAgencyServiceImpl.java @@ -2,6 +2,7 @@ package com.budwk.app.zhgh.staffbenefit.therapyRecuperation.service.impl; import com.budwk.app.base.page.Pagination; import com.budwk.app.zhgh.staffbenefit.therapyRecuperation.support.TherapyContext; +import com.budwk.app.zhgh.staffbenefit.therapyRecuperation.constant.TheRapyRecuperationState; import com.budwk.app.base.param.PageForm; import com.budwk.app.zhgh.staffbenefit.therapyRecuperation.support.TherapyServiceImpl; import com.budwk.app.zhgh.staffbenefit.therapyRecuperation.model.TheRapyRecuperationTravelAgency; @@ -114,11 +115,22 @@ public class TheRapyRecuperationTravelAgencyServiceImpl extends TherapyServiceIm ( SELECT COUNT( 1 ) FROM inclusive_therapy_v3_enroll_companion WHERE trreId = enroll.id AND relation = '亲属' ) isFamily FROM `inclusive_therapy_v3_enroll` enroll - LEFT JOIN inclusive_therapy_v3_travel_agency agency ON agency.id = enroll.takePartInTravelAgencyId + LEFT JOIN inclusive_therapy_v3_line_union_select lineu ON lineu.id = enroll.takePartInLineId + LEFT JOIN inclusive_therapy_v3_line line ON line.id = lineu.lineId + LEFT JOIN inclusive_therapy_v3_travel_agency agency + ON agency.id = IFNULL(enroll.takePartInTravelAgencyId, IFNULL(lineu.travelAgencyId, line.travelAgencyId)) WHERE - enroll.takePartInTravelAgencyId = @takePartInTravelAgencyId - and enroll.selfUnionId = @unionId - """).setParam("takePartInTravelAgencyId", id).setParam("unionId", TherapyContext.getUnionId()); + agency.id = @takePartInTravelAgencyId + AND enroll.isNormal = TRUE + AND enroll.stateId = @stateId + AND YEAR(enroll.signingUptime) = agency.year + $agencyUnionCnd + """).setParam("takePartInTravelAgencyId", id) + .setParam("stateId", TheRapyRecuperationState.PASS); + if (!TherapyContext.hasAnyRoles("sysadmin,H06")) { + sql.setVar("agencyUnionCnd", "AND enroll.selfUnionId = @unionId"); + sql.setParam("unionId", TherapyContext.getUnionId()); + } return listPageMap(pageForm.getPageNumber(), pageForm.getPageSize(), sql); } } diff --git a/src/main/resources/views/platform/zhgh/staffbenefit/therapyRecuperation/process/TheRapyQuery.html b/src/main/resources/views/platform/zhgh/staffbenefit/therapyRecuperation/process/TheRapyQuery.html index c4cab76..2cf4a94 100644 --- a/src/main/resources/views/platform/zhgh/staffbenefit/therapyRecuperation/process/TheRapyQuery.html +++ b/src/main/resources/views/platform/zhgh/staffbenefit/therapyRecuperation/process/TheRapyQuery.html @@ -138,9 +138,13 @@ layout("/platform/zhgh/staffbenefit/therapyRecuperation/layouts/platform.html"){ line-height: 20px; } - #app .branch-query-filters .query-route-hint > span { + .therapy-desktop #app .branch-query-filters .query-row-content > .el-row > .query-route-hint > span:first-child { + flex: 1 1 auto; + min-width: 0; color: inherit; text-align: left; + white-space: normal; + overflow-wrap: anywhere; } @media (max-width: 767px) { @@ -1685,6 +1689,13 @@ layout("/platform/zhgh/staffbenefit/therapyRecuperation/layouts/platform.html"){ checkState(type) { this.$refs.table.clearSelection(); this.pageForm.state = type + if (type === "2") { + this.$set(this.pageForm, 'state2', '') + this.$set(this.pageForm, 'takePartInLineId', '') + this.$set(this.pageForm, 'selectId', '') + this.$set(this.pageForm, 'lotId', '') + this.$set(this.pageForm, 'regionalNature', '') + } if (type === "1") { this.pageForm.lb = 'xl' } else if (type === "2") { diff --git a/src/main/resources/views/platform/zhghh5/staffbenefit/therapyRecuperation/lineList.html b/src/main/resources/views/platform/zhghh5/staffbenefit/therapyRecuperation/lineList.html index 94db1c7..dd68c06 100644 --- a/src/main/resources/views/platform/zhghh5/staffbenefit/therapyRecuperation/lineList.html +++ b/src/main/resources/views/platform/zhghh5/staffbenefit/therapyRecuperation/lineList.html @@ -471,8 +471,8 @@ layout("/platform/zhgh/staffbenefit/therapyRecuperation/layouts/mobile.html"){ } #app.therapy-mobile .list-card > .content { - align-items: center; - padding: 18px 12px; + align-items: flex-start; + padding: 16px 14px; } #app.therapy-mobile .line-thumb { @@ -482,18 +482,82 @@ layout("/platform/zhgh/staffbenefit/therapyRecuperation/layouts/mobile.html"){ #app.therapy-mobile .line-thumb .van-image { width: 100% !important; - height: 126px !important; + height: auto !important; + aspect-ratio: 4 / 3; overflow: hidden; border-radius: 12px; } #app.therapy-mobile .line-thumb img { object-fit: cover; } #app.therapy-mobile .line-title-row { align-items: center; gap: 6px; } - #app.therapy-mobile .line-title-text { color: #101b38; font-size: 15px !important; line-height: 24px; } - #app.therapy-mobile .desc_info > div { line-height: 25px; color: #58627b; } + #app.therapy-mobile .line-title-text { + display: -webkit-box; + -webkit-box-orient: vertical; + -webkit-line-clamp: 2; + white-space: normal; + color: #172033; + font-size: 16px !important; + line-height: 24px; + } + #app.therapy-mobile .desc_info > div { font-size: 13px; line-height: 23px; color: #66758a; } #app.therapy-mobile .group-tag { padding: 3px 6px; font-size: 11px; line-height: 17px; } #app.therapy-mobile .van-list__finished-text { font-size: 14px; color: #8c93a3; } + #app.therapy-mobile .therapy-travel-sheet { + max-height: 80vh; + border-radius: 16px 16px 0 0; + } + + #app.therapy-mobile .therapy-travel-sheet .van-action-sheet__header { + flex-shrink: 0; + color: #172033; + font-size: 18px; + font-weight: 600; + line-height: 52px; + } + + #app.therapy-mobile .therapy-travel-sheet .van-action-sheet__description { + flex-shrink: 0; + padding: 0 20px 16px; + color: #66758a; + font-size: 14px; + line-height: 22px; + overflow-wrap: anywhere; + } + + #app.therapy-mobile .therapy-travel-sheet .van-action-sheet__content { + min-height: 0; + overflow-y: auto; + } + + #app.therapy-mobile .travel-period-list { padding: 12px 14px 4px; } + #app.therapy-mobile .travel-period-card { + margin-bottom: 12px; + padding: 16px; + border: 1px solid #ebedf0; + border-radius: 12px; + background: #f7f8fa; + text-align: left; + overflow-wrap: anywhere; + } + + #app.therapy-mobile .travel-period-title { margin-bottom: 8px; color: #172033; font-size: 16px; font-weight: 600; line-height: 24px; } + #app.therapy-mobile .travel-period-date { margin-bottom: 10px; color: #35445a; font-size: 14px; line-height: 24px; } + #app.therapy-mobile .travel-period-meta { color: #66758a; font-size: 13px; line-height: 22px; } + #app.therapy-mobile .travel-period-actions { display: flex; gap: 12px; margin-top: 16px; } + #app.therapy-mobile .travel-period-actions .van-button { + flex: 1; + min-width: 0; + height: 40px; + border-color: #1989fa; + border-radius: 8px; + font-size: 16px; + } + #app.therapy-mobile .travel-period-actions .van-button--info { background: #1989fa; } + #app.therapy-mobile .travel-period-actions .van-button--plain { color: #1989fa; background: #fff; } + #app.therapy-mobile .therapy-travel-sheet .van-action-sheet__cancel { flex-shrink: 0; color: #66758a; font-size: 16px; } + #app.therapy-mobile .therapy-travel-sheet .van-empty { position: static; width: auto; height: auto; transform: none; background: transparent; } + @media (max-width: 350px) { #app.therapy-mobile .line-type-selector { flex-basis: 100px; } #app.therapy-mobile .line-type-selector .van-dropdown-item__content { width: 100px; right: 10px; } @@ -569,10 +633,10 @@ layout("/platform/zhgh/staffbenefit/therapyRecuperation/layouts/mobile.html"){