Commit 114b3bfb by guojx

如果前端传了门店id,后端不再处理

parent ea66f3df
......@@ -140,16 +140,20 @@ public class DataController {
if (StringUtils.isNotBlank(qo.getEnterpriseId())) {
jsonObject.put("enterpriseId", qo.getEnterpriseId());
}
List<String> storeIdList = new ArrayList<>();
String storeId = qo.getStoreId();
if (StringUtils.isBlank(storeId)) {
storeIdList = storeAuthUtils.queryClerkStoreIds(qo.getClerkId(), qo.getWxEnterpriseId());
} else {
storeIdList.add(storeId);
}
if (CollectionUtils.isNotEmpty(storeIdList)) {
//区经有全部门店权限
jsonObject.put("storeId", storeIdList.stream().collect(Collectors.joining(",")));
String storeIdParam = jsonObject.getString("storeId");
boolean hasStoreId = StringUtils.isNotBlank(storeIdParam);
if (!hasStoreId) {
List<String> storeIdList = new ArrayList<>();
String storeId = qo.getStoreId();
if (StringUtils.isBlank(storeId)) {
storeIdList = storeAuthUtils.queryClerkStoreIds(qo.getClerkId(), qo.getWxEnterpriseId());
} else {
storeIdList.add(storeId);
}
if (CollectionUtils.isNotEmpty(storeIdList)) {
//区经有全部门店权限
jsonObject.put("storeId", storeIdList.stream().collect(Collectors.joining(",")));
}
}
Map<String, Object> res = DataApiUtils.http(jsonObject.toJSONString(), qo.getApolloKey());
......
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