|
|
@@ -247,14 +247,20 @@ public class OrderController extends BladeController {
|
|
|
List<OrderAcctVO> acct = orderService.getAcctNoPage(acctVO);
|
|
|
|
|
|
String role = AuthUtil.getUserRole();
|
|
|
- System.out.println("role==="+role);
|
|
|
if (role.contains(LandConst.ROLE_KH)) {
|
|
|
List<KhAcctExcel> list = new ArrayList<>();
|
|
|
if (CollectionUtils.isNotEmpty(acct)) {
|
|
|
list = BeanUtil.copy(acct, KhAcctExcel.class);
|
|
|
}
|
|
|
ExcelUtil.export(response, "陆运台账", "陆运台账", list, KhAcctExcel.class);
|
|
|
- } else if (role.contains(LandConst.ROLE_PT) && role.contains(LandConst.ROLE_FGDD)) {
|
|
|
+ } else if (role.contains(LandConst.ROLE_DUZX) || role.contains(LandConst.DDZX_MANAGER)) {
|
|
|
+ List<DdzxAcctExcel> list = new ArrayList<>();
|
|
|
+ if (CollectionUtils.isNotEmpty(acct)) {
|
|
|
+ list = BeanUtil.copy(acct, DdzxAcctExcel.class);
|
|
|
+ }
|
|
|
+ ExcelUtil.export(response, "陆运台账", "陆运台账", list, DdzxAcctExcel.class);
|
|
|
+ }else if (role.contains(LandConst.ROLE_PT) && role.contains(LandConst.ROLE_FGDD)
|
|
|
+ && !role.contains(LandConst.ROLE_DUZX) && !role.contains(LandConst.DDZX_MANAGER)) {
|
|
|
List<PtAcctExcel> list = new ArrayList<>();
|
|
|
if (CollectionUtils.isNotEmpty(acct)) {
|
|
|
list = BeanUtil.copy(acct, PtAcctExcel.class);
|
|
|
@@ -278,13 +284,7 @@ public class OrderController extends BladeController {
|
|
|
list = BeanUtil.copy(acct, PtZddAcctExcel.class);
|
|
|
}
|
|
|
ExcelUtil.export(response, "陆运台账", "陆运台账", list, PtZddAcctExcel.class);
|
|
|
- }else if (role.contains(LandConst.ROLE_DUZX) || role.contains(LandConst.DDZX_MANAGER)) {
|
|
|
- List<DdzxAcctExcel> list = new ArrayList<>();
|
|
|
- if (CollectionUtils.isNotEmpty(acct)) {
|
|
|
- list = BeanUtil.copy(acct, DdzxAcctExcel.class);
|
|
|
- }
|
|
|
- ExcelUtil.export(response, "陆运台账", "陆运台账", list, DdzxAcctExcel.class);
|
|
|
- }else {
|
|
|
+ }{
|
|
|
throw new RuntimeException("用户无导出权限");
|
|
|
}
|
|
|
}
|