This commit is contained in:
Guoqs
2024-07-01 10:56:46 +08:00
2 changed files with 9 additions and 7 deletions

View File

@@ -42,7 +42,7 @@ public class PileMerchantInfoController extends BaseController {
@PreAuthorize("@ss.hasPermi('pile:merchant:list')") @PreAuthorize("@ss.hasPermi('pile:merchant:list')")
@GetMapping("/list") @GetMapping("/list")
public TableDataInfo list(PileMerchantInfo pileMerchantInfo) { public TableDataInfo list(PileMerchantInfo pileMerchantInfo) {
startPage(); // startPage();
List<PileMerchantInfo> list = pileMerchantInfoService.selectPileMerchantInfoListWithAuth(pileMerchantInfo); List<PileMerchantInfo> list = pileMerchantInfoService.selectPileMerchantInfoListWithAuth(pileMerchantInfo);
return getDataTable(list); return getDataTable(list);
} }

View File

@@ -10,6 +10,7 @@ import com.jsowell.common.enums.ykc.ReturnCodeEnum;
import com.jsowell.common.exception.BusinessException; import com.jsowell.common.exception.BusinessException;
import com.jsowell.common.util.DateUtils; import com.jsowell.common.util.DateUtils;
import com.jsowell.common.util.DictUtils; import com.jsowell.common.util.DictUtils;
import com.jsowell.common.util.PageUtils;
import com.jsowell.common.util.StringUtils; import com.jsowell.common.util.StringUtils;
import com.jsowell.pile.domain.PileMerchantInfo; import com.jsowell.pile.domain.PileMerchantInfo;
import com.jsowell.pile.dto.CreateMerchantDTO; import com.jsowell.pile.dto.CreateMerchantDTO;
@@ -77,12 +78,12 @@ public class PileMerchantInfoServiceImpl implements PileMerchantInfoService {
*/ */
@Override @Override
public List<PileMerchantInfo> selectPileMerchantInfoListWithAuth(PileMerchantInfo pileMerchantInfo) { public List<PileMerchantInfo> selectPileMerchantInfoListWithAuth(PileMerchantInfo pileMerchantInfo) {
AuthorizedDeptVO authorizedMap = UserUtils.getAuthorizedMap(); // AuthorizedDeptVO authorizedMap = UserUtils.getAuthorizedMap();
if (authorizedMap == null) { // if (authorizedMap == null) {
// 为空表示没有权限,返回空数组 // // 为空表示没有权限,返回空数组
return Lists.newArrayList(); // return Lists.newArrayList();
} // }
pileMerchantInfo.setStationDeptIds(authorizedMap.getStationDeptIds()); // pileMerchantInfo.setStationDeptIds(authorizedMap.getStationDeptIds());
// 当前登录用户的运营商权限列表 // 当前登录用户的运营商权限列表
List<MerchantInfoVO> list = UserUtils.getMerchantInfoVOList(); List<MerchantInfoVO> list = UserUtils.getMerchantInfoVOList();
@@ -90,6 +91,7 @@ public class PileMerchantInfoServiceImpl implements PileMerchantInfoService {
List<String> collect = list.stream().map(MerchantInfoVO::getDeptId).collect(Collectors.toList()); List<String> collect = list.stream().map(MerchantInfoVO::getDeptId).collect(Collectors.toList());
pileMerchantInfo.setMerchantDeptIds(collect); pileMerchantInfo.setMerchantDeptIds(collect);
} }
PageUtils.startPage();
return selectPileMerchantInfoList(pileMerchantInfo); return selectPileMerchantInfoList(pileMerchantInfo);
} }