Commit d2c4492d authored by liuzicheng's avatar liuzicheng

优化

parent f22fca9b
...@@ -11,7 +11,7 @@ import com.jqtx.windows.web.request.SyncCreditResultRequest; ...@@ -11,7 +11,7 @@ import com.jqtx.windows.web.request.SyncCreditResultRequest;
import com.jqtx.windows.web.response.JsonResult; import com.jqtx.windows.web.response.JsonResult;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
public class SyncCreditResult extends AbstractCommand { public class SyncCreditCommand extends AbstractCommand {
@Autowired @Autowired
private CreditResultComponent creditResultComponent; private CreditResultComponent creditResultComponent;
......
package com.jqtx.windows.web.config; package com.jqtx.windows.web.config;
import com.jqtx.windows.command.CreditSubmitCommand; import com.jqtx.windows.command.*;
import com.jqtx.windows.command.GetCreditCommand;
import com.jqtx.windows.command.LoanStatusCommand;
import com.jqtx.windows.command.LoanSubmitCommand;
import com.jqtx.windows.common.factory.AbstractCommand; import com.jqtx.windows.common.factory.AbstractCommand;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.CommandLineRunner; import org.springframework.boot.CommandLineRunner;
import org.springframework.stereotype.Component; import org.springframework.stereotype.Component;
import java.util.HashMap; import java.util.HashMap;
@Component @Component
...@@ -21,13 +17,19 @@ public class RouterConfig implements CommandLineRunner { ...@@ -21,13 +17,19 @@ public class RouterConfig implements CommandLineRunner {
private CreditSubmitCommand creditSubmitCommand; private CreditSubmitCommand creditSubmitCommand;
@Autowired @Autowired
private LoanSubmitCommand loanSubmitCommand; private LoanSubmitCommand loanSubmitCommand;
@Autowired @Autowired
private LoanStatusCommand loanStatusCommand; private LoanStatusCommand loanStatusCommand;
@Autowired @Autowired
private GetCreditCommand getCreditCommand; private GetCreditCommand getCreditCommand;
@Autowired @Autowired
private SignContractCommand signContractCommand; private SignContractCommand signContractCommand;
@Autowired
private SyncCreditCommand syncCreditCommand;
@Autowired
private SyncLoanCommand syncLoanCommand;
@Autowired
private SaveProtocolCommand saveProtocolCommand;
private static HashMap<String, AbstractCommand> commandHashMap = new HashMap<>(); private static HashMap<String, AbstractCommand> commandHashMap = new HashMap<>();
...@@ -45,5 +47,8 @@ public class RouterConfig implements CommandLineRunner { ...@@ -45,5 +47,8 @@ public class RouterConfig implements CommandLineRunner {
commandHashMap.put("getLoanResult", loanStatusCommand); commandHashMap.put("getLoanResult", loanStatusCommand);
commandHashMap.put("getCredit",getCreditCommand); commandHashMap.put("getCredit",getCreditCommand);
commandHashMap.put("signContract",signContractCommand); commandHashMap.put("signContract",signContractCommand);
commandHashMap.put("syncCredit",syncCreditCommand);
commandHashMap.put("syncLoan",syncLoanCommand);
commandHashMap.put("saveProtocol",saveProtocolCommand);
} }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment