增加根据用户获取全部机构树接口,给零售统计增加机构id参数

This commit is contained in:
jishenghua
2024-01-03 23:17:29 +08:00
parent da969b5633
commit 198ca74efa
4 changed files with 58 additions and 8 deletions

View File

@@ -45,6 +45,7 @@ import java.io.File;
import java.math.BigDecimal;
import java.sql.Timestamp;
import java.util.*;
import java.util.stream.Collectors;
import static com.jsh.erp.utils.Tools.getCenternTime;
import static com.jsh.erp.utils.Tools.getNow3;
@@ -276,6 +277,22 @@ public class DepotHeadService {
return creatorArray;
}
/**
* 根据角色类型获取操作员数组
* @param organizationId
* @return
* @throws Exception
*/
public String[] getCreatorArrayByOrg(Long organizationId) throws Exception {
List<Long> userIdList = orgaUserRelService.getUserIdListByOrgId(organizationId);
if(userIdList.size()>0) {
List<String> userIdStrList = userIdList.stream().map(Object::toString).collect(Collectors.toList());
return StringUtil.listToStringArray(userIdStrList);
} else {
return null;
}
}
/**
* 获取机构数组
* @return