change 4 лет назад
Родитель
Сommit
7bb8c7d607

+ 8 - 0
zhongzheng-system/src/main/java/com/zhongzheng/modules/course/vo/CourseHandoutsBusinessVo.java

@@ -56,4 +56,12 @@ public class CourseHandoutsBusinessVo {
 	@Excel(name = "科目名称")
 	@ApiModelProperty("科目名称")
 	private String subjectName;
+	/** 项目名称 */
+	@Excel(name = "项目名称")
+	@ApiModelProperty("项目名称")
+	private String projectName;
+	/** 科目名称 */
+	@Excel(name = "项目id")
+	@ApiModelProperty("项目id")
+	private String projectId;
 }

+ 13 - 8
zhongzheng-system/src/main/resources/mapper/modules/course/CourseHandoutsMapper.xml

@@ -29,20 +29,25 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <result property="businessName" column="business_name"/>
         <result property="handoutsId" column="handouts_id"/>
         <result property="subjectName" column="subject_name"/>
+        <result property="projectName" column="project_name"/>
+        <result property="projectId" column="project_id"/>
     </resultMap>
 
 
     <select id="selectEntity" parameterType="Long"  resultMap="CourseHandoutsBusinessVoResult">
         SELECT
-            h.*,
-            b.business_name,
-            e.education_name,
-            s.subject_name
+        h.*,
+        b.business_name,
+        e.education_name,
+        s.subject_name,
+        t.project_name,
+        t.id as project_id
         FROM
-            course_handouts_business h
-                LEFT JOIN course_business b ON h.business_id = b.id
-                LEFT JOIN course_education_type e ON h.education_id = e.id
-                LEFT JOIN course_subject s on s.id = h.subject_id
+        course_handouts_business h
+        LEFT JOIN course_business b ON h.business_id = b.id
+        LEFT JOIN course_education_type e ON h.education_id = e.id
+        LEFT JOIN course_subject s on s.id = h.subject_id
+        LEFT JOIN course_project_type t on t.id = b.project_id
         where 1=1
 
         <if test="handoutsId != null and handoutsId != ''">