Commit 3ef0b98c authored by hezhen's avatar hezhen

123

parent ccced6a9
...@@ -11,6 +11,7 @@ import com.github.wxiaoqi.security.admin.vo.InviteMemberVo; ...@@ -11,6 +11,7 @@ import com.github.wxiaoqi.security.admin.vo.InviteMemberVo;
import com.github.wxiaoqi.security.common.msg.ObjectRestResponse; import com.github.wxiaoqi.security.common.msg.ObjectRestResponse;
import com.github.wxiaoqi.security.common.util.process.ResultCode; import com.github.wxiaoqi.security.common.util.process.ResultCode;
import com.github.wxiaoqi.security.common.vo.PageDataVO; import com.github.wxiaoqi.security.common.vo.PageDataVO;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.collections.CollectionUtils; import org.apache.commons.collections.CollectionUtils;
import org.apache.commons.lang.StringUtils; import org.apache.commons.lang.StringUtils;
import org.springframework.aop.framework.AopContext; import org.springframework.aop.framework.AopContext;
...@@ -33,6 +34,7 @@ import java.util.stream.Collectors; ...@@ -33,6 +34,7 @@ import java.util.stream.Collectors;
* @date 2019-07-03 16:36:44 * @date 2019-07-03 16:36:44
*/ */
@Service @Service
@Slf4j
public class AppUserRelationBiz extends BaseBiz<AppUserRelationMapper,AppUserRelation> { public class AppUserRelationBiz extends BaseBiz<AppUserRelationMapper,AppUserRelation> {
@Autowired @Autowired
...@@ -56,6 +58,10 @@ public class AppUserRelationBiz extends BaseBiz<AppUserRelationMapper,AppUserRel ...@@ -56,6 +58,10 @@ public class AppUserRelationBiz extends BaseBiz<AppUserRelationMapper,AppUserRel
* @param parentId * @param parentId
*/ */
public void bindRelation(Integer userId,Integer parentId,Integer type){ public void bindRelation(Integer userId,Integer parentId,Integer type){
if (userId==parentId){
log.info("----userId==="+userId+"----parentId===="+parentId+"----自己不能成为自己的上线");
return;
}
AppUserRelation relation=getMyBiz().getRelationByUserId(parentId); AppUserRelation relation=getMyBiz().getRelationByUserId(parentId);
if(relation==null){ if(relation==null){
relation=new AppUserRelation(); relation=new AppUserRelation();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment