BankAccountController.java
1.32 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
package com.glsx.usedcar.web.api;
import com.glsx.usedcar.module.finance.entity.BankAccount;
import com.glsx.usedcar.module.finance.service.BankAccountService;
import jakarta.annotation.Resource;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
/**
* 银行账户(BankAccount) PI接口
*
* @since 2025-10-19 11:05:09
*/
@Slf4j
@RestController
@RequestMapping("/api/bankAccount")
public class BankAccountController {
/**
* BankAccount服务对象
*/
@Resource
private BankAccountService bankAccountService;
/**
* 根据id查询银行账户
*
* @param accountId
* @return
*/
@GetMapping("getBankAccountById")
public BankAccount getBankAccountById(@RequestParam int accountId) {
return bankAccountService.getBankAccountById(accountId);
}
/**
* 查询全部启用$银行账户
*
* @return
*/
@GetMapping("getEnableBankAccount")
public BankAccount getEnableBankAccount(@RequestParam BankAccount.AccountType accountType) {
return bankAccountService.getEnabledBankAccountByType(accountType);
}
}