Commit 527ff3ec authored by zhoucong's avatar zhoucong

注册代码提交

parent 1147951b
...@@ -4,6 +4,7 @@ package com.pangding.web.authority.controller; ...@@ -4,6 +4,7 @@ package com.pangding.web.authority.controller;
import com.pangding.web.authority.service.CompanyAgreementService; import com.pangding.web.authority.service.CompanyAgreementService;
import com.pangding.web.authority.service.CompanyMoneyService; import com.pangding.web.authority.service.CompanyMoneyService;
import com.pangding.web.authority.service.CompanyService; import com.pangding.web.authority.service.CompanyService;
import com.pangding.web.vo.system.pd.company.CompanyVo;
import com.pangding.web.vo.system.req.company.CompanyAgreementReqVo; import com.pangding.web.vo.system.req.company.CompanyAgreementReqVo;
import com.pangding.web.vo.system.req.company.CompanyMoneyReqVo; import com.pangding.web.vo.system.req.company.CompanyMoneyReqVo;
import com.pangding.web.vo.system.req.company.CompanyReqVo; import com.pangding.web.vo.system.req.company.CompanyReqVo;
...@@ -87,6 +88,12 @@ public class CompanyController { ...@@ -87,6 +88,12 @@ public class CompanyController {
CheckerHelper.newInstance().notBlankCheck("id", req.getId()).checkException(); CheckerHelper.newInstance().notBlankCheck("id", req.getId()).checkException();
return ResponseResult.result(companyService.findCompanyInvitationReward(req)); return ResponseResult.result(companyService.findCompanyInvitationReward(req));
} }
@RequestMapping(value = "/findAllCompany")
@ApiOperation(value = "查询所有公司", notes = "查询所有公司")
public ResponseResult<List<CompanyVo>> findAllCompany(@RequestBody CompanyReqVo req){
CheckerHelper.newInstance()
.checkException();
return ResponseResult.result(companyService.findAllCompany(req));
}
} }
...@@ -233,4 +233,5 @@ public interface CompanyService{ ...@@ -233,4 +233,5 @@ public interface CompanyService{
CompanyResVo findCompanyInvitationReward(CompanyReqVo req); CompanyResVo findCompanyInvitationReward(CompanyReqVo req);
List<CompanyVo> findAllCompany(CompanyReqVo req);
} }
...@@ -1584,4 +1584,10 @@ public class CompanyServiceImpl implements CompanyService { ...@@ -1584,4 +1584,10 @@ public class CompanyServiceImpl implements CompanyService {
} }
return companyResVo; return companyResVo;
} }
@Override
public List<CompanyVo> findAllCompany(CompanyReqVo req) {
List<CompanyVo> list = companyDao.loadList(req,CompanyVo.class);
return list;
}
} }
...@@ -214,7 +214,7 @@ public class FinanceServiceImpl implements FinanceService { ...@@ -214,7 +214,7 @@ public class FinanceServiceImpl implements FinanceService {
capitalFlowVo.setOrderId(StringHelper.getNewID()); capitalFlowVo.setOrderId(StringHelper.getNewID());
capitalFlowVo.setCategory(1); capitalFlowVo.setCategory(1);
capitalFlowVo.setOrderFee(withdrawFee + lateFee); capitalFlowVo.setOrderFee(withdrawFee + lateFee);
capitalFlowVo.setServiceCharge(lateFee); // todo...2021.10.9被注释 capitalFlowVo.setServiceCharge(lateFee);
capitalFlowVo.setActualMoney(req.getOrderMoney() - capitalFlowVo.getOrderFee()); capitalFlowVo.setActualMoney(req.getOrderMoney() - capitalFlowVo.getOrderFee());
capitalFlowVo.setTime(DateHelper.getNow()); capitalFlowVo.setTime(DateHelper.getNow());
capitalFlowVo.setStatus(0); capitalFlowVo.setStatus(0);
...@@ -381,7 +381,7 @@ public class FinanceServiceImpl implements FinanceService { ...@@ -381,7 +381,7 @@ public class FinanceServiceImpl implements FinanceService {
updateCompanyMoneyReqVo.setCompanyId(req.getCompanyId()); updateCompanyMoneyReqVo.setCompanyId(req.getCompanyId());
updateCompanyMoneyReqVo.setFrozenMoney(-capitalFlowVo.getOrderMoney()); updateCompanyMoneyReqVo.setFrozenMoney(-capitalFlowVo.getOrderMoney());
updateCompanyMoneyReqVo.setNewWithdrawTotalCash(0d); updateCompanyMoneyReqVo.setNewWithdrawTotalCash(0d);
updateCompanyMoneyReqVo.setLateFee(-capitalFlowVo.getServiceCharge()); // todo...2021.10.9被注释 updateCompanyMoneyReqVo.setLateFee(-capitalFlowVo.getServiceCharge());
companyExtendDao.updateCompanyMoney(updateCompanyMoneyReqVo); companyExtendDao.updateCompanyMoney(updateCompanyMoneyReqVo);
CompanyResVo companyResVo = companyDao.load(capitalFlowVo.getCompanyId(), CompanyResVo.class); CompanyResVo companyResVo = companyDao.load(capitalFlowVo.getCompanyId(), CompanyResVo.class);
......
...@@ -3,6 +3,7 @@ package com.pangding.web.authority.service.impl; ...@@ -3,6 +3,7 @@ package com.pangding.web.authority.service.impl;
import com.pangding.web.authority.dao.*; import com.pangding.web.authority.dao.*;
import com.pangding.web.authority.feign.PayFeign; import com.pangding.web.authority.feign.PayFeign;
import com.pangding.web.authority.feign.StoreFeign; import com.pangding.web.authority.feign.StoreFeign;
import com.pangding.web.authority.mq.CompanyConsumer;
import com.pangding.web.authority.service.*; import com.pangding.web.authority.service.*;
import com.pangding.web.authority.util.*; import com.pangding.web.authority.util.*;
import com.pangding.web.authority.vo.cloudvo.LoginResVo; import com.pangding.web.authority.vo.cloudvo.LoginResVo;
...@@ -11,6 +12,7 @@ import com.pangding.web.authority.vo.resvo.AuthorityListByLevelResVo; ...@@ -11,6 +12,7 @@ import com.pangding.web.authority.vo.resvo.AuthorityListByLevelResVo;
import com.pangding.web.authority.vo.resvo.LoginCompanyResVo; import com.pangding.web.authority.vo.resvo.LoginCompanyResVo;
import com.pangding.web.authority.vo.resvo.SaveCompanyResVo; import com.pangding.web.authority.vo.resvo.SaveCompanyResVo;
import com.pangding.web.constant.CompanyConstant; import com.pangding.web.constant.CompanyConstant;
import com.pangding.web.mq.CompanyProducer;
import com.pangding.web.util.RSAUtils; import com.pangding.web.util.RSAUtils;
import com.pangding.web.vo.product.pd.merchant.MerchantVo; import com.pangding.web.vo.product.pd.merchant.MerchantVo;
import com.pangding.web.vo.system.pd.LoginTokenVo; import com.pangding.web.vo.system.pd.LoginTokenVo;
...@@ -76,6 +78,8 @@ public class RegisterServiceImpl implements RegisterService { ...@@ -76,6 +78,8 @@ public class RegisterServiceImpl implements RegisterService {
private TokenService tokenService; private TokenService tokenService;
@Autowired @Autowired
private CompanyService companyService; private CompanyService companyService;
@Autowired
private CompanyProducer companyProducer;
/** /**
...@@ -125,7 +129,10 @@ public class RegisterServiceImpl implements RegisterService { ...@@ -125,7 +129,10 @@ public class RegisterServiceImpl implements RegisterService {
throw new CodeException("注册编码错误"); throw new CodeException("注册编码错误");
} }
// 判断邀请公司状态 // 判断邀请公司状态
if(0 == companyExtendVo.getInvitationStatus() || 1 != companyExtendVo.getExamineStatus()){ if(StringHelper.isEmpty(companyExtendVo.getInvitationStatus())){
throw new CodeException("用户无邀请状态");
}
if( 0 == companyExtendVo.getInvitationStatus() || 1 != companyExtendVo.getExamineStatus()){
throw new CodeException("用户邀请状态错误:" + companyExtendVo.getInvitationStatus() + ",状态错误:" + companyExtendVo.getExamineStatus()); throw new CodeException("用户邀请状态错误:" + companyExtendVo.getInvitationStatus() + ",状态错误:" + companyExtendVo.getExamineStatus());
} }
// 判断该账户已经邀请的人数 // 判断该账户已经邀请的人数
...@@ -242,7 +249,10 @@ public class RegisterServiceImpl implements RegisterService { ...@@ -242,7 +249,10 @@ public class RegisterServiceImpl implements RegisterService {
req.setId(reqVo.getMerchantId()); req.setId(reqVo.getMerchantId());
} }
SaveCompanyResVo resVo = new SaveCompanyResVo(); SaveCompanyResVo resVo = new SaveCompanyResVo();
ResponseResult<MerchantVo> result1 = storeFeign.merchantCreate(req); ResponseResult<MerchantVo> result1 = storeFeign.merchantCreate(req);
// companyProducer.companyMerchantSave(req);
if (result1.getCode().equals("00")) { if (result1.getCode().equals("00")) {
String merchantId = result1.getData().getId(); String merchantId = result1.getData().getId();
resVo.setMerchantId(merchantId); resVo.setMerchantId(merchantId);
......
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