新增教师:支持零业务引用档案安全删除与引用保护

This commit is contained in:
wangzhibiao committed 2026-09-20 16:16:54 +08:00
1 parent 740c59d5dd
commit 2dc22b06f8
10 files changed
+353 -7

No files matched your search

@@ -7,6 +7,7 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
@@ -127,6 +128,17 @@ public class TrainTeacherController extends BaseController
return toAjax(trainTeacherService.updateTrainTeacher(trainTeacher));
}
/**
* 删除教师信息 (DELETE /train/teacher/{tId})
*/
@PreAuthorize("@ss.hasPermi('train:teacher:remove')")
@Log(title = "教师管理", businessType = BusinessType.DELETE)
@DeleteMapping("/{tId}")
public AjaxResult remove(@PathVariable("tId") String tId)
{
return toAjax(trainTeacherService.deleteTrainTeacherByTId(tId));
}
private boolean isValidPhone(String phone)
{
return PHONE_PATTERN.matcher(phone).matches();