Commit f06b596a by 翁国栋 Committed by 284718418@qq.com

8小时后台--

导入保单时,产品id对应返回
添加失败回滚事务
parent 84517842
...@@ -95,7 +95,8 @@ public class CallBackContorll { ...@@ -95,7 +95,8 @@ public class CallBackContorll {
@PostMapping(value = "/addpPayCallBack") @PostMapping(value = "/addpPayCallBack")
@ApiOperation(value = "11.增员核保回调", httpMethod = "POST", notes = "增员核保回调") @ApiOperation(value = "11.增员核保回调", httpMethod = "POST", notes = "增员核保回调")
private Map addpPayCallBack(HttpServletRequest request, @RequestParam String pid, @RequestParam String sign, @RequestParam String timestamp) throws IOException { @Transactional(rollbackFor = Exception.class)
public Map addpPayCallBack(HttpServletRequest request, @RequestParam String pid, @RequestParam String sign, @RequestParam String timestamp) throws IOException {
/*核保*/ /*核保*/
/*如果是在线支付的话*/ /*如果是在线支付的话*/
Map map = Maps.newHashMap(); Map map = Maps.newHashMap();
...@@ -171,8 +172,8 @@ public class CallBackContorll { ...@@ -171,8 +172,8 @@ public class CallBackContorll {
@PostMapping(value = "/CallBack") @PostMapping(value = "/CallBack")
@ApiOperation(value = "7.保全增员申请回调", httpMethod = "POST", notes = "投保申请回调") @ApiOperation(value = "7.保全增员申请回调", httpMethod = "POST", notes = "投保申请回调")
@ApiOperationSupport(order = 2) @Transactional(rollbackFor = Exception.class)
private Map callBack(HttpServletRequest request, @RequestParam String pid, @RequestParam String sign, @RequestParam String timestamp) throws IOException { public Map callBack(HttpServletRequest request, @RequestParam String pid, @RequestParam String sign, @RequestParam String timestamp) throws IOException {
Map map = Maps.newHashMap(); Map map = Maps.newHashMap();
map.put("status", "error"); map.put("status", "error");
if (StringUtils.isNullOrEmpty(pid) || StringUtils.isNullOrEmpty(sign) && StringUtils.isNullOrEmpty(timestamp)) { if (StringUtils.isNullOrEmpty(pid) || StringUtils.isNullOrEmpty(sign) && StringUtils.isNullOrEmpty(timestamp)) {
...@@ -269,7 +270,8 @@ public class CallBackContorll { ...@@ -269,7 +270,8 @@ public class CallBackContorll {
@GetMapping(value = "/payStatus") @GetMapping(value = "/payStatus")
@ApiOperation(value = "8.支付完成跳转", httpMethod = "GET", notes = "用于支付时跳回我们系统更新状态") @ApiOperation(value = "8.支付完成跳转", httpMethod = "GET", notes = "用于支付时跳回我们系统更新状态")
private ModelAndView callBackPayStatus(HttpServletRequest request, @RequestParam Integer policyId) throws IOException { @Transactional(rollbackFor = Exception.class)
public ModelAndView callBackPayStatus(HttpServletRequest request, @RequestParam Integer policyId) throws IOException {
InsurePolicy insurePolicy = InsurePolicy.builder().id(policyId).build().selectById(); InsurePolicy insurePolicy = InsurePolicy.builder().id(policyId).build().selectById();
InsurePay insurePay = InsurePay.builder().id(insurePolicy.getPayId()).build().selectById(); InsurePay insurePay = InsurePay.builder().id(insurePolicy.getPayId()).build().selectById();
insurePay.setPayTime(new Date()); insurePay.setPayTime(new Date());
...@@ -283,7 +285,8 @@ public class CallBackContorll { ...@@ -283,7 +285,8 @@ public class CallBackContorll {
@PostMapping(value = "/payCallBack") @PostMapping(value = "/payCallBack")
@ApiOperation(value = "9.投保支付收银台回调", httpMethod = "POST", notes = "支付完成跳转") @ApiOperation(value = "9.投保支付收银台回调", httpMethod = "POST", notes = "支付完成跳转")
private Map payCallBack(HttpServletRequest request, @RequestParam String pid, @RequestParam String sign, @RequestParam String timestamp) throws IOException { @Transactional(rollbackFor = Exception.class)
public Map payCallBack(HttpServletRequest request, @RequestParam String pid, @RequestParam String sign, @RequestParam String timestamp) throws IOException {
try { try {
InputStream is = null; InputStream is = null;
is = request.getInputStream(); is = request.getInputStream();
...@@ -339,7 +342,8 @@ public class CallBackContorll { ...@@ -339,7 +342,8 @@ public class CallBackContorll {
@PostMapping(value = "/issueCallback") @PostMapping(value = "/issueCallback")
@ApiOperation(value = "10.保单出单回调", httpMethod = "POST", notes = "支付完成跳转") @ApiOperation(value = "10.保单出单回调", httpMethod = "POST", notes = "支付完成跳转")
private Map issueCallback(HttpServletRequest request, @RequestParam String pid, @RequestParam String sign, @RequestParam String timestamp) throws IOException { @Transactional(rollbackFor = Exception.class)
public Map issueCallback(HttpServletRequest request, @RequestParam String pid, @RequestParam String sign, @RequestParam String timestamp) throws IOException {
try { try {
InputStream is = null; InputStream is = null;
is = request.getInputStream(); is = request.getInputStream();
...@@ -394,7 +398,8 @@ public class CallBackContorll { ...@@ -394,7 +398,8 @@ public class CallBackContorll {
@PostMapping(value = "/batchPayCallback") @PostMapping(value = "/batchPayCallback")
@ApiOperation(value = "增员支付回调-保司接口没启用", httpMethod = "POST", notes = "增员支付回调") @ApiOperation(value = "增员支付回调-保司接口没启用", httpMethod = "POST", notes = "增员支付回调")
private Map batchPayCallback(HttpServletRequest request) throws IOException { @Transactional(rollbackFor = Exception.class)
public Map batchPayCallback(HttpServletRequest request) throws IOException {
try { try {
InputStream is = null; InputStream is = null;
......
...@@ -50,7 +50,8 @@ public class InsureApplicantController { ...@@ -50,7 +50,8 @@ public class InsureApplicantController {
@PostMapping("/insureApplicationSetting") @PostMapping("/insureApplicationSetting")
@ApiOperation(value = "设置投保人", httpMethod = "POST", notes = "投保申请") @ApiOperation(value = "设置投保人", httpMethod = "POST", notes = "投保申请")
private Result<Object> insureApplicationSetting(@RequestBody InsureApplicant params) { @Transactional(rollbackFor = Exception.class)
public Result<Object> insureApplicationSetting(@RequestBody InsureApplicant params) {
try { try {
InsureApplicant insureApplicant = InsureApplicant.builder().build().selectOne(new QueryWrapper<InsureApplicant>().lambda().eq(InsureApplicant::getOrgCode, params.getOrgCode())); InsureApplicant insureApplicant = InsureApplicant.builder().build().selectOne(new QueryWrapper<InsureApplicant>().lambda().eq(InsureApplicant::getOrgCode, params.getOrgCode()));
params.setId(insureApplicant.getId()); params.setId(insureApplicant.getId());
...@@ -65,7 +66,8 @@ public class InsureApplicantController { ...@@ -65,7 +66,8 @@ public class InsureApplicantController {
@GetMapping("/getApplicantAdmin") @GetMapping("/getApplicantAdmin")
@ApiOperation(value = "获取投保人--运营后台", httpMethod = "GET", notes = "获取投保人") @ApiOperation(value = "获取投保人--运营后台", httpMethod = "GET", notes = "获取投保人")
private Result<Object> getApplicant(@RequestParam("orgCode") Integer orgCode) { @Transactional(rollbackFor = Exception.class)
public Result<Object> getApplicant(@RequestParam("orgCode") Integer orgCode) {
try { try {
InsureApplicant insureApplicant = InsureApplicant.builder().build().selectOne(new QueryWrapper<InsureApplicant>().lambda().eq(InsureApplicant::getOrgCode, orgCode)); InsureApplicant insureApplicant = InsureApplicant.builder().build().selectOne(new QueryWrapper<InsureApplicant>().lambda().eq(InsureApplicant::getOrgCode, orgCode));
if (insureApplicant == null) { if (insureApplicant == null) {
...@@ -97,7 +99,8 @@ public class InsureApplicantController { ...@@ -97,7 +99,8 @@ public class InsureApplicantController {
@GetMapping("/getApplicant") @GetMapping("/getApplicant")
@ApiOperation(value = "获取投保人--8小时", httpMethod = "GET", notes = "获取投保人") @ApiOperation(value = "获取投保人--8小时", httpMethod = "GET", notes = "获取投保人")
private Result<Object> getApplicant(@CurrentUser UserBean userBean) { @Transactional(rollbackFor = Exception.class)
public Result<Object> getApplicant(@CurrentUser UserBean userBean) {
try { try {
InsureApplicant insureApplicant = InsureApplicant.builder().build().selectOne(new QueryWrapper<InsureApplicant>().lambda().eq(InsureApplicant::getOrgCode, userBean.getOrgCode())); InsureApplicant insureApplicant = InsureApplicant.builder().build().selectOne(new QueryWrapper<InsureApplicant>().lambda().eq(InsureApplicant::getOrgCode, userBean.getOrgCode()));
if (insureApplicant == null) { if (insureApplicant == null) {
......
...@@ -16,6 +16,7 @@ import org.springframework.beans.factory.annotation.Autowired; ...@@ -16,6 +16,7 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Configuration; import org.springframework.context.annotation.Configuration;
import org.springframework.scheduling.annotation.EnableScheduling; import org.springframework.scheduling.annotation.EnableScheduling;
import org.springframework.scheduling.annotation.Scheduled; import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.transaction.annotation.Transactional;
import java.text.ParseException; import java.text.ParseException;
import java.util.Date; import java.util.Date;
...@@ -37,6 +38,7 @@ public class InsureTaskTiming { ...@@ -37,6 +38,7 @@ public class InsureTaskTiming {
private YgglMainEmpMapper ygglMainEmpMapper; private YgglMainEmpMapper ygglMainEmpMapper;
@Scheduled(cron = "0 0 0 1 * ?")//每月第一天 @Scheduled(cron = "0 0 0 1 * ?")//每月第一天
@Transactional(rollbackFor = Exception.class)
public void updateInsureStatusTask(){ public void updateInsureStatusTask(){
try { try {
......
...@@ -272,7 +272,7 @@ ...@@ -272,7 +272,7 @@
and qy.name like CONCAT('%',#{policy.companyName},'%') and qy.name like CONCAT('%',#{policy.companyName},'%')
</if> </if>
<if test="policy.policyNo!=null and policy.policyNo!=''"> <if test="policy.policyNo!=null and policy.policyNo!=''">
and qy.policy_no like CONCAT('%',#{policy.policyNo},'%') and ip.policy_no like CONCAT('%',#{policy.policyNo},'%')
</if> </if>
</where> </where>
GROUP BY ip.id GROUP BY ip.id
......
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