diff --git a/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/controller/KhTemplateController.java b/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/controller/KhTemplateController.java index 861ca3c..deab0e5 100644 --- a/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/controller/KhTemplateController.java +++ b/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/controller/KhTemplateController.java @@ -115,6 +115,8 @@ public class KhTemplateController extends BaseController temItem.setTemId(khTemplate.getId()); temItem.setItemName(item.getItemName()); temItem.setKhitemId(item.getId()); + temItem.setType(item.getType()); + temItem.setTypeId(item.getTypeId()); temItemService.insertKhTemItem(temItem); } } diff --git a/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/controller/KhVoteController.java b/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/controller/KhVoteController.java index 3978e4d..d08dffd 100644 --- a/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/controller/KhVoteController.java +++ b/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/controller/KhVoteController.java @@ -136,6 +136,7 @@ public class KhVoteController extends BaseController { voteEmp.setVoteId(khVote.getId()); voteEmp.setVoteTitle(khVote.getVoteTitle()); voteEmp.setPercentage(khVote.getPercentage()); + voteEmp.setKhitemTypeid(khVote.getKhitemTypeid()); voteEmpService.insertKhVoteEmp(voteEmp); } return AjaxResult.success(); diff --git a/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/domain/KhItems.java b/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/domain/KhItems.java index 8edb18a..1f8f7f2 100644 --- a/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/domain/KhItems.java +++ b/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/domain/KhItems.java @@ -23,7 +23,7 @@ public class KhItems extends BaseEntity private String itemName; /** 考核类型id */ - @Excel(name = "考核类型id") + // @Excel(name = "考核类型id") private Long typeId; /** 考核类型 */ diff --git a/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/domain/KhTemItem.java b/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/domain/KhTemItem.java index 8d984d4..49fe383 100644 --- a/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/domain/KhTemItem.java +++ b/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/domain/KhTemItem.java @@ -34,7 +34,31 @@ public class KhTemItem extends BaseEntity @Excel(name = "模板id") private Long temId; - public void setId(Long id) + /** 考核类型id */ + // @Excel(name = "考核类型id") + private Long typeId; + + /** 考核类型 */ + @Excel(name = "考核类型") + private String type; + + public Long getTypeId() { + return typeId; + } + + public void setTypeId(Long typeId) { + this.typeId = typeId; + } + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } + + public void setId(Long id) { this.id = id; } diff --git a/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/domain/KhVoteEmp.java b/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/domain/KhVoteEmp.java index 5ff2fd9..e41df40 100644 --- a/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/domain/KhVoteEmp.java +++ b/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/domain/KhVoteEmp.java @@ -43,6 +43,22 @@ public class KhVoteEmp extends BaseEntity @Excel(name = "选项内容") private String content; + /** 优秀 */ + @Excel(name = "优秀") + private Long optionA; + + /** 合格 */ + @Excel(name = "合格") + private Long optionB; + + /** 基本合格 */ + @Excel(name = "基本合格") + private Long optionC; + + /** 不合格 */ + @Excel(name = "不合格") + private Long optionD; + /** 投票人数 */ @Excel(name = "投票人数") private Long voteNum; @@ -183,6 +199,38 @@ public class KhVoteEmp extends BaseEntity return endScore; } + public Long getOptionA() { + return optionA; + } + + public void setOptionA(Long optionA) { + this.optionA = optionA; + } + + public Long getOptionB() { + return optionB; + } + + public void setOptionB(Long optionB) { + this.optionB = optionB; + } + + public Long getOptionC() { + return optionC; + } + + public void setOptionC(Long optionC) { + this.optionC = optionC; + } + + public Long getOptionD() { + return optionD; + } + + public void setOptionD(Long optionD) { + this.optionD = optionD; + } + @Override public String toString() { return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) @@ -194,6 +242,10 @@ public class KhVoteEmp extends BaseEntity .append("bkhdxName", getBkhdxName()) .append("content", getContent()) .append("voteNum", getVoteNum()) + .append("optionA", getOptionA()) + .append("optionB", getOptionB()) + .append("optionC", getOptionC()) + .append("optionD", getOptionD()) .append("voteScore", getVoteScore()) .append("avgScore", getAvgScore()) .append("percentage", getPercentage()) diff --git a/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/domain/KhVoteItems.java b/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/domain/KhVoteItems.java index c859f6f..86e5ef7 100644 --- a/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/domain/KhVoteItems.java +++ b/ruoyi-kaohe/src/main/java/com/ruoyi/kaohe/domain/KhVoteItems.java @@ -7,9 +7,9 @@ import com.ruoyi.common.core.domain.BaseEntity; /** * 投票项对象 kh_vote_items - * + * * @author hs - * @date 2025-06-24 + * @date 2025-07-03 */ public class KhVoteItems extends BaseEntity { @@ -22,36 +22,51 @@ public class KhVoteItems extends BaseEntity @Excel(name = "投票选项名称") private String vitemName; - public void setId(Long id) + /** 分数 */ + @Excel(name = "分数") + private Long score; + + public void setId(Long id) { this.id = id; } - public Long getId() + public Long getId() { return id; } - public void setVitemName(String vitemName) + public void setVitemName(String vitemName) { this.vitemName = vitemName; } - public String getVitemName() + public String getVitemName() { return vitemName; } + public void setScore(Long score) + { + this.score = score; + } + + public Long getScore() + { + return score; + } + @Override public String toString() { return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) - .append("id", getId()) - .append("vitemName", getVitemName()) - .append("createBy", getCreateBy()) - .append("createTime", getCreateTime()) - .append("updateBy", getUpdateBy()) - .append("updateTime", getUpdateTime()) - .append("remark", getRemark()) - .toString(); + .append("id", getId()) + .append("vitemName", getVitemName()) + .append("score", getScore()) + .append("createBy", getCreateBy()) + .append("createTime", getCreateTime()) + .append("updateBy", getUpdateBy()) + .append("updateTime", getUpdateTime()) + .append("remark", getRemark()) + .toString(); } } diff --git a/ruoyi-kaohe/src/main/resources/mapper/kaohe/KhTemItemMapper.xml b/ruoyi-kaohe/src/main/resources/mapper/kaohe/KhTemItemMapper.xml index 7dbc28c..48dff6a 100644 --- a/ruoyi-kaohe/src/main/resources/mapper/kaohe/KhTemItemMapper.xml +++ b/ruoyi-kaohe/src/main/resources/mapper/kaohe/KhTemItemMapper.xml @@ -10,10 +10,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" + + - select id, tem_name, khitem_id, item_name, tem_id from kh_tem_item + select id, tem_name, khitem_id, item_name, tem_id, type_id, type from kh_tem_item @@ -38,12 +42,16 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" khitem_id, item_name, tem_id, + type_id, + type, #{temName}, #{khitemId}, #{itemName}, #{temId}, + #{typeId}, + #{type}, @@ -54,6 +62,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" khitem_id = #{khitemId}, item_name = #{itemName}, tem_id = #{temId}, + type_id = #{typeId}, + type = #{type}, where id = #{id} diff --git a/ruoyi-kaohe/src/main/resources/mapper/kaohe/KhTemplateMapper.xml b/ruoyi-kaohe/src/main/resources/mapper/kaohe/KhTemplateMapper.xml index 5df4be1..eaa0186 100644 --- a/ruoyi-kaohe/src/main/resources/mapper/kaohe/KhTemplateMapper.xml +++ b/ruoyi-kaohe/src/main/resources/mapper/kaohe/KhTemplateMapper.xml @@ -1,39 +1,43 @@ + PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" + "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + - - - + + + - - + + + + - select id, tem_name, khitem_id, item_name from kh_template + select id, tem_name, khitem_id, item_name + from kh_template - + select ti.khitem_id itemId ,ti.item_name khitemName ,type,type_id from kh_tem_item ti - ti.tem_id = #{id} + ti.tem_id = #{id} - + @@ -38,6 +42,10 @@ and bkhdx_name like concat('%', #{bkhdxName}, '%') and content = #{content} and vote_num = #{voteNum} + and option_a = #{optionA} + and option_b = #{optionB} + and option_c = #{optionC} + and option_d = #{optionD} and vote_score = #{voteScore} and avg_score = #{avgScore} and percentage = #{percentage} @@ -60,6 +68,10 @@ bkhdx_name, content, vote_num, + option_a, + option_b, + option_c, + option_d, vote_score, avg_score, percentage, @@ -78,6 +90,10 @@ #{bkhdxName}, #{content}, #{voteNum}, + #{optionA}, + #{optionB}, + #{optionC}, + #{optionD}, #{voteScore}, #{avgScore}, #{percentage}, @@ -100,6 +116,10 @@ bkhdx_name = #{bkhdxName}, content = #{content}, vote_num = #{voteNum}, + option_a = #{optionA}, + option_b = #{optionB}, + option_c = #{optionC}, + option_d = #{optionD}, vote_score = #{voteScore}, avg_score = #{avgScore}, percentage = #{percentage}, diff --git a/ruoyi-kaohe/src/main/resources/mapper/kaohe/KhVoteItemsMapper.xml b/ruoyi-kaohe/src/main/resources/mapper/kaohe/KhVoteItemsMapper.xml index 18c54d2..589d4c3 100644 --- a/ruoyi-kaohe/src/main/resources/mapper/kaohe/KhVoteItemsMapper.xml +++ b/ruoyi-kaohe/src/main/resources/mapper/kaohe/KhVoteItemsMapper.xml @@ -1,12 +1,13 @@ + PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" + "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + + @@ -15,16 +16,17 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - select id, vitem_name, create_by, create_time, update_by, update_time, remark from kh_vote_items + select id, vitem_name, score, create_by, create_time, update_by, update_time, remark from kh_vote_items - +