This commit is contained in:
2025-10-29 09:14:00 +08:00
parent a3fd6a1c26
commit 260e4c25ad
21 changed files with 757 additions and 466 deletions
@@ -18,7 +18,7 @@ import java.util.List;
@EqualsAndHashCode(callSuper = true)
@Data
@Comment("体育活动活动项目关联表")
@Table("Activity_school_event")
@Table("activity_school_event")
public class ActivitySchoolEvent extends BaseModel implements Serializable {
@Column
@@ -102,6 +102,7 @@ public class HealthCheckupListController {
hcus.campus,
hcus.subjectId,
hcus.bz,
hcus.receiveAddress,
ca.campusName
FROM
health_checkup_user hcu
@@ -126,7 +126,7 @@ public class HealthCheckupSingleController {
add(new ExcelExportEntity("部门", "unitName", 20));
// add(new ExcelExportEntity("部门编码", "unitCode", 20));
add(new ExcelExportEntity("医院", "subjectName", 20));
// add(new ExcelExportEntity("自选院区", "campusName", 50));
add(new ExcelExportEntity("邮寄地址", "receiveAddress", 50));
}};
List<NutMap> list;
@@ -62,6 +62,12 @@ public class H5HealthCheckupController {
public void list() {
}
@At("/projectManageForm")
@Ok("beetl:/platform/zhghh5/dayofficework/healthCheckup/projectManageForm/index.html")
@SaCheckPermission("h5.healthCheckup.list")
public void projectManageForm() {
}
@At("/mine")
@Ok("beetl:/platform/zhghh5/dayofficework/healthCheckup/mine/index.html")
@SaCheckPermission("h5.healthCheckup.mine")
@@ -114,10 +120,12 @@ public class H5HealthCheckupController {
p.name,
p.choiceTimeStart,
p.choiceTimeEnd,
p.cover
p.cover,
sub.optionName
FROM
health_checkup_user_selection us
LEFT JOIN health_checkup_project p ON us.projectId = p.id
LEFT JOIN health_checkup_project_subject sub on sub.id=us.subjectId
$condition
""");
Cnd cnd = Cnd.NEW();
@@ -1,5 +1,6 @@
package com.budwk.app.zhgh.dayofficework.healthCheckup.model;
import cn.hutool.json.JSONObject;
import com.budwk.app.base.model.BaseModel;
import lombok.Data;
import lombok.EqualsAndHashCode;
@@ -72,6 +73,9 @@ public class HealthCheckupProject extends BaseModel implements Serializable {
private String cover;
@Many(field = "projectId")
private List<HealthCheckupProjectSubject> healthCheckupProjectSubjects;
@@ -1,5 +1,6 @@
package com.budwk.app.zhgh.dayofficework.healthCheckup.model;
import cn.hutool.json.JSONObject;
import com.budwk.app.base.model.BaseModel;
import lombok.Data;
import lombok.EqualsAndHashCode;
@@ -53,6 +54,11 @@ public class HealthCheckupProjectSubject extends BaseModel implements Serializab
@ColDefine(type = ColType.TEXT)
private String description;
@Column
@Comment("医院方提供材料")
@ColDefine(type = ColType.MYSQL_JSON)
private List<JSONObject> files;
@Many(field = "subjectId")
private List<HealthCheckupProjectSubjectMoney> subjectMoneys;
@@ -43,6 +43,11 @@ public class HealthCheckupProjectSubjectMoney extends BaseModel implements Seria
@ColDefine(customType = "decimal(10,2)")
private BigDecimal money;
@Column
@Comment("结算金额")
@ColDefine(customType = "decimal(10,2)")
private BigDecimal settlementMoney;
@Column
@Comment("名称")
@ColDefine(type = ColType.VARCHAR, width = 32)
@@ -70,6 +70,16 @@ public class HealthCheckupUserSelection extends BaseModel implements Serializabl
@ColDefine(type = ColType.VARCHAR,width = 100)
private String bz;
@Column
@Comment("邮寄地址")
@ColDefine(type = ColType.VARCHAR,width = 100)
private String receiveAddress;
@Column
@Comment("邮寄地址模式(1.自己单位2.自己选择)")
@ColDefine(type = ColType.VARCHAR,width = 10)
private String postMethod;
@Many(field = "userSelectionId")
private List<HealthCheckupUserCompanion> companionList;
}
@@ -218,6 +218,7 @@ public class HealthCheckupSingleServiceImpl extends BaseServiceImpl<HealthChecku
u.idCard,
u.mobile,
hcps.optionName subjectName,
hcus.receiveAddress,
hcc.campusName,
(
SELECT
@@ -255,6 +255,7 @@ public class WelfareListController {
// 添加错误记录
excelImportRes.setErrorDetails(excelList.stream().filter(s -> StrUtil.isNotBlank(s.getErrMsg())).collect(Collectors.toList()));
excelImportRes.setFailedCount(excelImportRes.getErrorDetails().size());
excelImportRes.setSuccessCount(excelList.size() - excelImportRes.getFailedCount());
return Result.success(excelImportRes);
}
@@ -7,6 +7,7 @@ import com.budwk.app.base.param.PageForm;
import com.budwk.app.base.result.Result;
import com.budwk.app.web.commons.auth.utils.SecurityUtil;
import com.budwk.app.zhgh.welfare.model.WelfareList;
import com.budwk.app.zhgh.welfare.model.WelfareProject;
import com.budwk.app.zhgh.welfare.model.WelfareUserSelection;
import com.budwk.app.zhgh.welfare.service.WelfareProjectService;
import io.swagger.annotations.ApiOperation;
@@ -22,8 +23,10 @@ import org.nutz.mvc.annotation.At;
import org.nutz.mvc.annotation.Ok;
import org.nutz.mvc.annotation.Param;
import java.util.Arrays;
import java.util.Date;
import java.util.List;
import java.util.Objects;
@IocBean
@Ok("json:full")
@@ -81,9 +84,16 @@ public class WelfareUserSelectController {
@SaCheckPermission("welfare.user.select")
public Result confirmSelect(@Param("selections") WelfareUserSelection[] selections, String projectId) {
int count = dao.count(WelfareList.class, Cnd.where(WelfareList::getProjectId, "=", projectId).and(WelfareList::getUserId, "=", SecurityUtil.getUserId()));
if(count==0){
if (count == 0) {
return Result.error("您没有选择的权限");
}
WelfareProject project = dao.fetch(WelfareProject.class, projectId);
int sum = Arrays.stream(selections).mapToInt(selection -> Objects.requireNonNullElse(selection.getSelectNum(), 0)).sum();
if (sum > project.getMultiSelectNum()) {
return Result.error("选择的数量不能超过" + project.getMultiSelectNum());
}
//删除上次选择的
dao.clear(WelfareUserSelection.class, Cnd.where(WelfareUserSelection::getWelfareId, "=", projectId).and(WelfareUserSelection::getSelectUserId, "=", SecurityUtil.getUserId()));
@@ -42,7 +42,7 @@ public class WelfareProjectServiceImpl extends BaseServiceImpl<WelfareProject> i
@Override
public WelfareProject projectInfo(String projectId) {
WelfareProject project = fetch(projectId);
fetchLinks(project, "options");
fetchLinks(project, "options",Cnd.NEW().asc("optionSort"));
return project;
}