中扬CRM客户关系管理系统
#
LSH
2023-12-01 09ee5added9d59e90310a2586e846137ea597b19
src/main/java/com/zy/crm/system/service/impl/DeptServiceImpl.java
@@ -3,13 +3,12 @@
import com.baomidou.mybatisplus.mapper.EntityWrapper;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import com.core.exception.CoolException;
import com.zy.crm.manager.entity.Node;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.zy.crm.system.entity.Dept;
import com.zy.crm.system.mapper.DeptMapper;
import com.zy.crm.system.service.DeptService;
import com.zy.crm.system.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.Date;
@@ -20,10 +19,11 @@
    private UserService userService;
    @Override
    public Dept getTop() {
    public Dept getTop(Long hostId) {
        Dept top = this.selectOne(new EntityWrapper<Dept>().eq("level", 0));
        if (top == null) {
            top = new Dept();
            top.setHostId(hostId);
            top.setName("全部");
            top.setUuid("全部");
            top.setLevel(0);