dzx пре 2 месеци
родитељ
комит
dfdd094b3e

+ 8 - 3
src/main/java/com/xjrsoft/module/banding/controller/BandingTaskClassController.java

@@ -22,6 +22,7 @@ import com.xjrsoft.module.banding.entity.BandingTaskClass;
 import com.xjrsoft.module.banding.entity.BandingTaskClassStudent;
 import com.xjrsoft.module.banding.service.IBandingTaskClassService;
 import com.xjrsoft.module.banding.service.IBandingTaskClassStudentService;
+import com.xjrsoft.module.banding.service.IBandingTaskService;
 import com.xjrsoft.module.banding.vo.BandingTaskClassExcelVo;
 import com.xjrsoft.module.banding.vo.BandingTaskClassPageVo;
 import com.xjrsoft.module.banding.vo.BandingTaskClassStudentListVo;
@@ -62,7 +63,7 @@ import java.util.Map;
 @AllArgsConstructor
 public class BandingTaskClassController {
 
-
+    private final IBandingTaskService taskService;
     private final IBandingTaskClassService bandingTaskClassService;
     private final IBandingTaskClassStudentService classStudentService;
 
@@ -109,7 +110,9 @@ public class BandingTaskClassController {
     public RT<Boolean> add(@Valid @RequestBody List<AddBandingTaskClassDto> dtoList){
         List<BandingTaskClass> dataList = new ArrayList<>();
         List<String> errorList = new ArrayList<>();
+
         for (AddBandingTaskClassDto dto : dtoList) {
+            BandingTask task = taskService.getById(dto.getBandingTaskId());
             if(dto.getSortCode() != null){
                 List<BandingTaskClass> list = bandingTaskClassService.list(
                         new QueryWrapper<BandingTaskClass>().lambda()
@@ -121,8 +124,10 @@ public class BandingTaskClassController {
                 }
             }
 
-            BandingTaskClass bandingTask = BeanUtil.toBean(dto, BandingTaskClass.class);
-            bandingTask.setCreateDate(new Date());
+            BandingTaskClass bandingTaskClass = BeanUtil.toBean(dto, BandingTaskClass.class);
+            bandingTaskClass.setCreateDate(new Date());
+            bandingTaskClass.setStatus(task.getStatus());
+            dataList.add(bandingTaskClass);
         }
         if(!errorList.isEmpty()){
             return RT.error(errorList.toString().replace("[", "").replace("]", "") + ",分班排序重复");

+ 0 - 1
src/main/java/com/xjrsoft/module/material/service/impl/MaterialTaskServiceImpl.java

@@ -457,7 +457,6 @@ public class MaterialTaskServiceImpl extends MPJBaseServiceImpl<MaterialTaskMapp
                 .eq(Department::getDeleteMark, DeleteMark.NODELETE.getCode())
                 .eq(MaterialTask::getDeleteMark, DeleteMark.NODELETE.getCode())
                 .eq(MaterialTaskAssign::getDeleteMark, DeleteMark.NODELETE.getCode())
-                .eq(MaterialTaskAppendix::getDeleteMark, DeleteMark.NODELETE.getCode())
 //                .select("(\n" +
 //                        "SELECT id FROM xjr_file WHERE id IN (\n" +
 //                        "SELECT file_id FROM material_task_appendix WHERE material_task_id = t.id\n" +