| | |
| | | import com.zy.crm.manager.entity.CstmrFoll; |
| | | import com.zy.crm.manager.entity.Order; |
| | | import com.zy.crm.manager.entity.OrderFoll; |
| | | import com.zy.crm.manager.entity.Plan; |
| | | import com.zy.crm.manager.service.OrderFollService; |
| | | import com.zy.crm.manager.service.OrderService; |
| | | import com.zy.crm.manager.service.PlanService; |
| | | import com.zy.crm.system.entity.Role; |
| | | import com.zy.crm.system.entity.User; |
| | | import com.zy.crm.system.service.UserService; |
| | |
| | | |
| | | @Autowired |
| | | private OrderService orderService; |
| | | @Autowired |
| | | private PlanService planService; |
| | | |
| | | @RequestMapping(value = "/order/{id}/auth") |
| | | @ManagerAuth |
| | |
| | | @ManagerAuth(memo = "删除跟踪项目") |
| | | public R delete(@RequestParam(value="ids[]") Long[] ids){ |
| | | for (Long id : ids){ |
| | | int plan = planService.selectCount(new EntityWrapper<Plan>().eq("order_id", id)); |
| | | if (plan!=0){ |
| | | return R.error("存在关联的规划单,禁止删除!!!"); |
| | | } |
| | | orderService.deleteById(id); |
| | | } |
| | | return R.ok(); |