|
@@ -12,6 +12,7 @@ import com.ruixuan.isc.entity.KuaishouPromoter;
|
|
|
import com.ruixuan.isc.mapper.KuaishouPromoterMapper;
|
|
|
import com.ruixuan.isc.service.IKuaishouPromoterService;
|
|
|
import com.ruixuan.system.service.ISysDeptService;
|
|
|
+import com.ruixuan.system.service.ISysRoleService;
|
|
|
import com.ruixuan.system.service.ISysUserService;
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
@@ -50,6 +51,9 @@ public class KuaishouPromoterServiceImpl implements IKuaishouPromoterService {
|
|
|
private ISysDeptService deptService;
|
|
|
|
|
|
@Autowired
|
|
|
+ private ISysRoleService roleService;
|
|
|
+
|
|
|
+ @Autowired
|
|
|
private RedisUtil redisUtil;
|
|
|
|
|
|
/**
|
|
@@ -69,9 +73,12 @@ public class KuaishouPromoterServiceImpl implements IKuaishouPromoterService {
|
|
|
// 渠道经理、社群经理 可以看到自己创建的以及自己部门人员的达人信息
|
|
|
Long deptId = deptService.getDeptIdByUserId(userId);
|
|
|
userList = deptService.getDeptUserListByDeptId(deptId);
|
|
|
- } else if ("bd".equals(roleKey) || "association".equals(roleKey)) {
|
|
|
- // 渠道、社群 可以看到自己创建的达人信息
|
|
|
+ } else if ("bd".equals(roleKey)) {
|
|
|
+ // 渠道可以看到自己创建的达人信息
|
|
|
userList = Arrays.asList(userId);
|
|
|
+ } else if ("association".equals(roleKey)) {
|
|
|
+ // 社群可以看到所有社群的达人信息
|
|
|
+ userList = sysUserService.getUserIdByRoleKey(roleKey);
|
|
|
} else {
|
|
|
return Collections.emptyList();
|
|
|
}
|