|
@@ -1,7 +1,5 @@
|
|
|
package com.usky.dxtop.controller.web;
|
|
|
|
|
|
-import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|
|
-import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
|
|
import com.usky.dxtop.common.core.domain.AjaxResult;
|
|
|
import com.usky.dxtop.model.Dept;
|
|
|
import com.usky.dxtop.model.Staff;
|
|
@@ -111,18 +109,17 @@ public class StaffController {
|
|
|
return AjaxResult.success(staffService.one(id,phone,card));
|
|
|
}
|
|
|
|
|
|
- @GetMapping("send")
|
|
|
- public String sendDeptAndStaff(@RequestParam Long staffId,
|
|
|
- @RequestParam String card,
|
|
|
- @RequestParam Integer type){
|
|
|
- Staff staff = staffService.getById(staffId);
|
|
|
- staff.setCardId(card);
|
|
|
- LambdaQueryWrapper<Dept> queryWrapper = Wrappers.lambdaQuery();
|
|
|
- queryWrapper.eq(Dept::getId,staff.getDeptId());
|
|
|
- Dept dept = deptService.getOne(queryWrapper);
|
|
|
- smJob.deptSendMessage(dept);
|
|
|
+ @GetMapping("sendDept")
|
|
|
+ public String sendDeptAndStaff(@RequestParam Long id){
|
|
|
+ Dept byId = deptService.getById(id);
|
|
|
+ smJob.deptSendMessage(byId);
|
|
|
+ return "sucess";
|
|
|
+ }
|
|
|
+
|
|
|
+ @GetMapping("sendPerson")
|
|
|
+ public String sendPerson(Long id,Integer type){
|
|
|
+ Staff staff = staffService.getById(id);
|
|
|
smJob.personSendMessage(staff,type);
|
|
|
- smJob.faceSendMessage(staff);
|
|
|
return "sucess";
|
|
|
}
|
|
|
|