Преглед изворни кода

Merge remote-tracking branch 'origin/master'

Joburgess пре 4 година
родитељ
комит
d795172fd1

+ 11 - 0
mec-biz/src/main/java/com/ym/mec/biz/dal/entity/StudentGoodsSell.java

@@ -17,6 +17,9 @@ public class StudentGoodsSell {
 	
 	@ApiModelProperty(value = "用户编号",required = true)
 	private Integer userId;
+
+	@ApiModelProperty(value = "学生名称",required = true)
+	private String userName;
 	
 	@ApiModelProperty(value = "教师编号",required = true)
 	private Integer teacherId;
@@ -52,6 +55,14 @@ public class StudentGoodsSell {
 	@ApiModelProperty(value = "分部编号", required = false)
 	private Integer organId;
 
+	public String getUserName() {
+		return userName;
+	}
+
+	public void setUserName(String userName) {
+		this.userName = userName;
+	}
+
 	public Integer getOrganId() {
 		return organId;
 	}

+ 4 - 1
mec-biz/src/main/resources/config/mybatis/StudentGoodsSellMapper.xml

@@ -14,6 +14,7 @@
 		<result column="total_amount_" property="totalAmount" />
 		<result column="market_amount_" property="marketAmount" />
 		<result column="order_no_" property="orderNo" />
+		<result column="username_" property="userName" />
 		<result column="organ_id_" property="organId" />
 		<result column="create_time_" property="createTime" />
 		<result column="update_time_" property="updateTime" />
@@ -21,7 +22,9 @@
 	
 	<!-- 根据主键查询一条记录 -->
 	<select id="get" resultMap="StudentGoodsSell" >
-		SELECT * FROM student_goods_sell WHERE id_ = #{id} 
+		SELECT sgs.*,su.username_ FROM student_goods_sell sgs
+		LEFT JOIN sys_user su ON su.id_ = sgs.user_id_
+		WHERE sgs.id_ = #{id}
 	</select>
 	
 	<!-- 全查询 -->

+ 3 - 2
mec-student/src/main/java/com/ym/mec/student/config/ResourceServerConfig.java

@@ -36,8 +36,9 @@ public class ResourceServerConfig extends ResourceServerConfigurerAdapter {
 				"/degree/*",
 				"/practiceGroup/queryOrderInfo",
 				"/systemDate/query",
-				"/organization/getOrgans," +
-				"/repair/addGoodsSellOrder").permitAll().anyRequest().authenticated().and().httpBasic();
+				"/organization/getOrgans",
+				"/repair/addGoodsSellOrder",
+				"/repair/getStudentGoodsOrder").permitAll().anyRequest().authenticated().and().httpBasic();
 	}
 
 	@Override