diff --git a/pjcloud-thirdparty/pjcloud-thirdparty-biz/src/main/resources/application.yml b/pjcloud-thirdparty/pjcloud-thirdparty-biz/src/main/resources/application.yml index d75b6bcc3..1abb10c07 100644 --- a/pjcloud-thirdparty/pjcloud-thirdparty-biz/src/main/resources/application.yml +++ b/pjcloud-thirdparty/pjcloud-thirdparty-biz/src/main/resources/application.yml @@ -44,19 +44,20 @@ oauth2: # 正元智慧 # https://gwyc.zj.gov.cn/API/%E7%9C%81%E5%B9%B3%E5%8F%B0API%E5%AF%B9%E6%8E%A5%E6%8E%A5%E5%8F%A3.html zy: - # base-url: http://60.191.37.212:18079 # 测试1 - # app-id: 689C8D6F5059A6F85B8BE45A49001ACB - # app-secret: BD21DA0DEB8F0FC43246B0BD2FCAE6FF + base-url: http://60.191.37.212:18079 + app-id: 689C8D6F5059A6F85B8BE45A49001ACB + app-secret: BD21DA0DEB8F0FC43246B0BD2FCAE6FF # 测试2 + # base-url: http://60.191.37.212:18079 # app-id: FC455B0A788E334AC08FB3E1D8385C75 # app-secret: E9131D0BCC9054808675DA1E2E199023 # 正式 - base-url: https://gwycport.zj.gov.cn - app-id: 0BBF0D9A7F1B4BD5280E59197E259AC6 - app-secret: 434752786ACBB37214F6617CC37AD0E9 + # base-url: https://gwycport.zj.gov.cn + # app-id: 0BBF0D9A7F1B4BD5280E59197E259AC6 + # app-secret: 434752786ACBB37214F6617CC37AD0E9 self-base-url: http://60.191.37.212:18079 diff --git a/pjcloud-wallet/pjcloud-wallet-biz/src/main/java/com/bsd/pjcloud/wallet/controller/WalletTransactionController.java b/pjcloud-wallet/pjcloud-wallet-biz/src/main/java/com/bsd/pjcloud/wallet/controller/WalletTransactionController.java index f2524644a..83e021c26 100644 --- a/pjcloud-wallet/pjcloud-wallet-biz/src/main/java/com/bsd/pjcloud/wallet/controller/WalletTransactionController.java +++ b/pjcloud-wallet/pjcloud-wallet-biz/src/main/java/com/bsd/pjcloud/wallet/controller/WalletTransactionController.java @@ -120,7 +120,8 @@ public class WalletTransactionController { @Operation(summary = "分页查询复杂查询", description = "分页查询复杂查询") @GetMapping("/page-join") - @PreAuthorize("@pms.hasPermission('wallet_walletTransaction_view')") + // TODO 这个比较公用先不加权限 + // @PreAuthorize("@pms.hasPermission('wallet_walletTransaction_view')") public R getWalletTransactionPageJoin(@ParameterObject Page page, @ParameterObject WalletTransactionDto dto) { DataScope dataScope = new DataScope(); return R.ok(walletTransactionService.scopePageList(page, dto, dataScope)); diff --git a/pjcloud-wallet/pjcloud-wallet-biz/src/main/java/com/bsd/pjcloud/wallet/controller/WalletTypeController.java b/pjcloud-wallet/pjcloud-wallet-biz/src/main/java/com/bsd/pjcloud/wallet/controller/WalletTypeController.java index d8e5a71f6..fa6cefce0 100644 --- a/pjcloud-wallet/pjcloud-wallet-biz/src/main/java/com/bsd/pjcloud/wallet/controller/WalletTypeController.java +++ b/pjcloud-wallet/pjcloud-wallet-biz/src/main/java/com/bsd/pjcloud/wallet/controller/WalletTypeController.java @@ -30,50 +30,64 @@ import java.util.Objects; */ @RestController @RequiredArgsConstructor -@RequestMapping("/walletType" ) -@Tag(description = "walletType" , name = "钱包类型管理" ) +@RequestMapping("/walletType") +@Tag(description = "walletType", name = "钱包类型管理") @SecurityRequirement(name = HttpHeaders.AUTHORIZATION) public class WalletTypeController { - private final WalletTypeService walletTypeService; + private final WalletTypeService walletTypeService; /** * 分页查询 - * @param page 分页对象 + * + * @param page 分页对象 * @param walletType 钱包类型 * @return */ - @Operation(summary = "分页查询" , description = "分页查询" ) - @GetMapping("/page" ) - @PreAuthorize("@pms.hasPermission('wallet_walletType_view')" ) + @Operation(summary = "分页查询", description = "分页查询") + @GetMapping("/page") + @PreAuthorize("@pms.hasPermission('wallet_walletType_view')") public R getWalletTypePage(@ParameterObject Page page, @ParameterObject WalletTypeEntity walletType) { LambdaQueryWrapper wrapper = Wrappers.lambdaQuery(); wrapper.orderByDesc(WalletTypeEntity::getCreateTime); return R.ok(walletTypeService.page(page, wrapper)); } + /** + * 查询下拉 + */ + @Operation(summary = "查询下拉", description = "查询下拉") + @GetMapping("/select") + public R> walletList() { + LambdaQueryWrapper wrapper = Wrappers.lambdaQuery(); + wrapper.orderByDesc(WalletTypeEntity::getCreateTime); + return R.ok(walletTypeService.list(wrapper)); + } + /** * 通过id查询钱包类型 + * * @param id id * @return R */ - @Operation(summary = "通过id查询" , description = "通过id查询" ) - @GetMapping("/{id}" ) - @PreAuthorize("@pms.hasPermission('wallet_walletType_view')" ) - public R getById(@PathVariable("id" ) Long id) { + @Operation(summary = "通过id查询", description = "通过id查询") + @GetMapping("/{id}") + @PreAuthorize("@pms.hasPermission('wallet_walletType_view')") + public R getById(@PathVariable("id") Long id) { return R.ok(walletTypeService.getById(id)); } /** * 新增钱包类型 + * * @param dto 钱包类型 * @return R */ - @Operation(summary = "新增钱包类型" , description = "新增钱包类型" ) - @SysLog("新增钱包类型" ) + @Operation(summary = "新增钱包类型", description = "新增钱包类型") + @SysLog("新增钱包类型") @PostMapping - @PreAuthorize("@pms.hasPermission('wallet_walletType_add')" ) + @PreAuthorize("@pms.hasPermission('wallet_walletType_add')") public R save(@RequestBody WalletTypeEntity dto) { walletTypeService.create(dto); return R.ok(true); @@ -81,13 +95,14 @@ public class WalletTypeController { /** * 修改钱包类型 + * * @param dto 钱包类型 * @return R */ - @Operation(summary = "修改钱包类型" , description = "修改钱包类型" ) - @SysLog("修改钱包类型" ) + @Operation(summary = "修改钱包类型", description = "修改钱包类型") + @SysLog("修改钱包类型") @PutMapping - @PreAuthorize("@pms.hasPermission('wallet_walletType_edit')" ) + @PreAuthorize("@pms.hasPermission('wallet_walletType_edit')") public R updateById(@RequestBody WalletTypeEntity dto) { walletTypeService.edit(dto); return R.ok(true); @@ -95,13 +110,14 @@ public class WalletTypeController { /** * 通过id删除钱包类型 + * * @param ids id列表 * @return R */ - @Operation(summary = "通过id删除钱包类型" , description = "通过id删除钱包类型" ) - @SysLog("通过id删除钱包类型" ) + @Operation(summary = "通过id删除钱包类型", description = "通过id删除钱包类型") + @SysLog("通过id删除钱包类型") @DeleteMapping - @PreAuthorize("@pms.hasPermission('wallet_walletType_del')" ) + @PreAuthorize("@pms.hasPermission('wallet_walletType_del')") public R removeById(@RequestBody Long[] ids) { return R.ok(walletTypeService.removeBatchByIds(CollUtil.toList(ids))); } @@ -109,14 +125,15 @@ public class WalletTypeController { /** * 导出excel 表格 + * * @param walletType 查询条件 - * @param ids 导出指定ID + * @param ids 导出指定ID * @return excel 文件流 */ @ResponseExcel @GetMapping("/export") - @PreAuthorize("@pms.hasPermission('wallet_walletType_export')" ) - public List export(WalletTypeEntity walletType,Long[] ids) { + @PreAuthorize("@pms.hasPermission('wallet_walletType_export')") + public List export(WalletTypeEntity walletType, Long[] ids) { return walletTypeService.list(Wrappers.lambdaQuery(walletType).in(ArrayUtil.isNotEmpty(ids), WalletTypeEntity::getId, ids)); } } \ No newline at end of file