Sfoglia il codice sorgente

Merge remote-tracking branch 'origin/master_saas' into master_saas

zouxuan 3 anni fa
parent
commit
458dc9b1a9

+ 2 - 1
mec-biz/src/main/resources/config/mybatis/StudentMapper.xml

@@ -376,7 +376,8 @@
         a.vip_times_,
         a.buy_practice_times_,
         a.music_netWork_times_,
-        p.free_practice_times_
+        p.free_practice_times_,
+        su.phone_
         FROM student s
         LEFT JOIN sys_user su ON s.user_id_ = su.id_
         LEFT JOIN sys_user tsu ON tsu.id_ = s.teacher_id_

+ 4 - 0
mec-biz/src/main/resources/config/mybatis/StudentVisitMapper.xml

@@ -158,6 +158,10 @@
             <if test="visitCyCle != null and visitCyCle != ''">
                 AND CONVERT (VARCHAR,sv.visit_time,120) LIKE CONCAT('%',#{visitCyCle},'%')
             </if>
+            <if test="probStatus != null and probStatus != ''">
+                AND sv.prob_status = #{probStatus}
+            </if>
+
         </where>
     </sql>
     <select id="queryCount" resultType="int">

+ 9 - 6
mec-teacher/src/main/java/com/ym/mec/teacher/controller/VisitController.java

@@ -20,10 +20,7 @@ import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiOperation;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.security.access.prepost.PreAuthorize;
-import org.springframework.web.bind.annotation.GetMapping;
-import org.springframework.web.bind.annotation.PostMapping;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.RestController;
+import org.springframework.web.bind.annotation.*;
 
 import java.util.List;
 
@@ -80,8 +77,14 @@ public class VisitController extends BaseController {
     @ApiOperation(value = "修改问题状态")
     @PostMapping(value = "/updateProbStatus")
     @PreAuthorize("@pcs.hasPermissions('visit/updateProbStatus')")
-    public HttpResponseResult<String> updateProbStatus(Integer id,Integer probStatus) {
-        return succeed(studentVisitService.updateProbStatus(id,probStatus));
+    public HttpResponseResult<String> updateProbStatus(@RequestParam("id")Integer id,@RequestParam("probStatus")Integer probStatus) {
+        String s = studentVisitService.updateProbStatus(id, probStatus);
+        if(s.equals("成功")){
+            return succeed(studentVisitService.updateProbStatus(id,probStatus));
+        }else{
+            return failed(studentVisitService.updateProbStatus(id,probStatus));
+        }
+
     }
 
     @ApiOperation(value = "获取乐团列表")

+ 8 - 2
mec-web/src/main/java/com/ym/mec/web/controller/VisitController.java

@@ -61,8 +61,14 @@ public class VisitController extends BaseController {
     @ApiOperation(value = "修改问题状态")
     @PostMapping(value = "/updateProbStatus")
     @PreAuthorize("@pcs.hasPermissions('visit/updateProbStatus')")
-    public HttpResponseResult<String> updateProbStatus(Integer id,Integer probStatus) {
-        return succeed(studentVisitService.updateProbStatus(id,probStatus));
+    public HttpResponseResult<String> updateProbStatus(@RequestParam("id")Integer id,@RequestParam("probStatus")Integer probStatus) {
+        String s = studentVisitService.updateProbStatus(id, probStatus);
+        if(s.equals("成功")){
+            return succeed(studentVisitService.updateProbStatus(id,probStatus));
+        }else{
+            return failed(studentVisitService.updateProbStatus(id,probStatus));
+        }
+
     }