|
@@ -56,6 +56,15 @@ public class StockWaitServiceImpl extends ServiceImpl<StockWaitMapper, StockWait
|
|
|
@Override
|
|
|
public Page<StockWaitVo> getPage(StockWaitSelectDto dto) {
|
|
|
IWrapper<StockWait> wrapper = getWrapper();
|
|
|
+
|
|
|
+ //权限过滤:待出入库-子公司看自己的,总公司看全部
|
|
|
+ Long companyId = SecurityUtils.getCompanyId();
|
|
|
+ if (!Objects.equals(companyId, 100L)) {
|
|
|
+ wrapper.eq("sw", StockWait::getCompanyId, companyId);
|
|
|
+ } else {
|
|
|
+ wrapper.eq("sw", StockWait::getCompanyId, dto.getCompanyId());
|
|
|
+ }
|
|
|
+
|
|
|
//过滤入库/出库
|
|
|
wrapper.eq(StockWait::getType, dto.getType());
|
|
|
wrapper.eq("sw", StockWait::getBusinessType, dto.getBusinessType());
|
|
@@ -67,14 +76,6 @@ public class StockWaitServiceImpl extends ServiceImpl<StockWaitMapper, StockWait
|
|
|
return page;
|
|
|
}
|
|
|
|
|
|
- //权限过滤:待出入库-子公司看自己的,总公司看全部
|
|
|
- Long companyId = SecurityUtils.getCompanyId();
|
|
|
- if (!Objects.equals(companyId, 100L)) {
|
|
|
- wrapper.eq("sw", StockWait::getCompanyId, companyId);
|
|
|
- } else {
|
|
|
- wrapper.eq("sw", StockWait::getCompanyId, dto.getCompanyId());
|
|
|
- }
|
|
|
-
|
|
|
//赋值明细列表
|
|
|
setDetailsInfo(records);
|
|
|
|