1、swagger接口文档

beetlsql3-dev
陈沅 1 year ago
parent 47785e49ef
commit f1a5552760

@ -31,4 +31,6 @@ public interface StudentAccountAssetAllocationDao extends BaseMapper<StudentAcco
List<StudentAccountAssetAllocation> getValuesByQueryNotWithPermission(StudentAccountAssetAllocationQuery studentAccountAssetAllocationQuery);
StudentAccountAssetAllocation getByApplicationIdAndStudentId(Long applicationId,Long studentId);
List<StudentAccountAssetAllocation> getInfo(Long studentId);
}

@ -26,6 +26,7 @@ public interface StudentAccountEquityInvestmentSystemDao extends BaseMapper<Stud
List<StudentAccountEquityInvestmentSystem> getValuesByQuery(StudentAccountEquityInvestmentSystemQuery studentAccountEquityInvestmentSystemQuery);
List<StudentAccountEquityInvestmentSystem> getInfo(Long studentId);
void updateByTransfer(BigDecimal initialCapital,BigDecimal initialInvestmentCapital,BigDecimal totalAssets,BigDecimal freeMoney,Long studentId);
void updateByTransfer(BigDecimal initialCapital, BigDecimal initialInvestmentCapital, BigDecimal totalAssets, BigDecimal freeMoney, Long studentId);
}

@ -666,6 +666,10 @@ public class StudentAccountAssetAllocationService extends CoreBaseService<Studen
}
}
public List<StudentAccountAssetAllocation> getInfoByStudentId(Long studentId){
return studentAccountAssetAllocationDao.getInfo(studentId);
}
public static String sendPostRequest(String url, String postData) {
try {
URL apiUrl = new URL(url);

@ -54,6 +54,10 @@ public class StudentAccountEquityInvestmentSystemService extends CoreBaseService
return studentAccountEquityInvestmentSystemDao.getValuesByQuery(query);
}
public List<StudentAccountEquityInvestmentSystem> getInfo(Long studentId){
return studentAccountEquityInvestmentSystemDao.getInfo(studentId);
}
public void updateByTransfer(BigDecimal initialCapital, BigDecimal initialInvestmentCapital, BigDecimal totalAssets, BigDecimal freeMoney, Long studentId){
studentAccountEquityInvestmentSystemDao.updateByTransfer(initialCapital,initialInvestmentCapital,totalAssets,freeMoney,studentId);
}

@ -144,16 +144,19 @@ public class AccountController {
public void createFund() throws SQLException {
List<Student> students = studentService.getValues(null);
int i =0;
if (students != null && students.size() > 0) {
for (Student student : students) {
Connection connection = openConn();
String username = student.getStudentSn();
StudentAccountAssetAllocationQuery query = new StudentAccountAssetAllocationQuery();
query.setStudentId(student.getStudentId());
// List<StudentAccountAssetAllocation> studentAccountAssetAllocations = studentAccountAssetAllocationService.getValuesByQuery(query);
// List<StudentAccountAssetAllocation> studentAccountAssetAllocations = studentAccountAssetAllocationService.getInfoByStudentId(student.getStudentId());
// if (studentAccountAssetAllocations != null && studentAccountAssetAllocations.size() > 0) {
// continue;
// }
System.out.println("已处理------------->"+i++);
Connection connection = openConn();
String username = student.getStudentSn();
StudentAccountAssetAllocationQuery query = new StudentAccountAssetAllocationQuery();
// query.setStudentId();
String sql = "SELECT\n" +
" EduUsers.UserName,\n" +
" EduAssetAllocation.ApplicationId,\n" +
@ -203,6 +206,10 @@ public class AccountController {
} else if (applicationId == 4) {
allocationQuery.setApplicationId(Long.valueOf(4));
allocationQuery.setName(AccountTypeEnum.P2P_ACCOUNT);
StudentAccountCrowdfundingSystem info = studentAccountCrowdfundingSystemService.getInfo(student.getStudentId());
if(info!=null){
continue;
}
Connection connection1 = openConn();
String sql1 = "SELECT\n" +
" ExaP2PAssetAllocation.Id,\n" +
@ -234,6 +241,8 @@ public class AccountController {
PreparedStatement preparedStatement1 = connection1.prepareStatement(sql1);
ResultSet resultSet1 = preparedStatement1.executeQuery();
while (resultSet1.next()) {
StudentAccountP2pSystem studentAccountP2pSystem = new StudentAccountP2pSystem();
BigDecimal InitialCapital1 = resultSet1.getBigDecimal("InitialCapital");
BigDecimal InitialInvestmentCapital1 = resultSet1.getBigDecimal("InitialInvestmentCapital");
@ -276,6 +285,10 @@ public class AccountController {
} else if (applicationId == 5) {
allocationQuery.setApplicationId(Long.valueOf(5));
allocationQuery.setName(AccountTypeEnum.CROWDFUNDING_ACCOUNT);
StudentAccountCrowdfundingSystem info = studentAccountCrowdfundingSystemService.getInfo(student.getStudentId());
if(info!=null)continue;
Connection connection1 = openConn();
String sql1 = "SELECT\n" +
" ExaTheRaiseAssetAllocation.Id,\n" +
@ -341,6 +354,9 @@ public class AccountController {
} else if (applicationId == 16) {
allocationQuery.setApplicationId(Long.valueOf(16));
allocationQuery.setName(AccountTypeEnum.EQUITY_FUND_INVESTMENT_ACCOUNT);
// List<StudentAccountMockTradingSystem> byStudentId = studentAccountMockTradingSystemService.getByStudentId(student.getStudentId());
// if(byStudentId!=null&&byStudentId.size()>0)continue;
Connection connection1 = openConn();
String sql1 = "SELECT\n" +
" ExaMNJYAssetAllocation.Id,\n" +
@ -419,6 +435,10 @@ public class AccountController {
allocationQuery.setApplicationId(Long.valueOf(18));
allocationQuery.setName(AccountTypeEnum.EQUITY_INVESTMENT_ACCOUNT);
StudentAccountEquityInvestmentSystemQuery query1 = new StudentAccountEquityInvestmentSystemQuery();
query1.setStudentId(student.getStudentId());
// List<StudentAccountEquityInvestmentSystem> valuesByQuery = studentAccountEquityInvestmentSystemService.getInfo(student.getStudentId());
// if (valuesByQuery != null && valuesByQuery.size() > 0) continue;
Connection connection1 = openConn();
String sql1 = "SELECT\n" +
" ExaPEVCAssetAllocation.Id,\n" +

@ -2218,4 +2218,4 @@ select student.student_sn as studentNo,student.student_name as name,school_class
getStudentByStudentNoAndOrgId
===
select * from student where student_sn = #studentNo# and org_id = #orgId#
select * from student where student_sn = #studentNo# and org_id = #orgId#

@ -778,3 +778,6 @@ getByApplicationIdAndStudentId
select * from student_account_asset_allocation where
application_id =#applicationId# and student_id=#studentId#
getInfo
===
select * from student_account_asset_allocation where student_id=#studentId#

@ -206,4 +206,9 @@ getValuesByQueryNotWithPermission
updateByTransfer
====
update student_account_equity_investment_system set initial_capital =#initialCapital# ,initial_investment_capital =#initialInvestmentCapital# ,total_assets=#initialInvestmentCapital# , own_funds = #initialInvestmentCapital# where student_id = #studentId#
update student_account_equity_investment_system set initial_capital =#initialCapital# ,initial_investment_capital =#initialInvestmentCapital# ,total_assets=#initialInvestmentCapital# , own_funds = #initialInvestmentCapital# where student_id = #studentId#
getInfo
===
select * from student_account_equity_investment_system where student_id = #studentId#
Loading…
Cancel
Save