parent
01e0c211ac
commit
968c4848c5
@ -0,0 +1,17 @@
|
||||
package au.com.royalpay.payment.manage.riskbusiness.core;
|
||||
|
||||
/**
|
||||
* @Description:
|
||||
* @Author: lujian
|
||||
* @Date: 2018/11/19 19:40
|
||||
*/
|
||||
|
||||
public interface RiskMaterialService {
|
||||
|
||||
/**
|
||||
* 更新最新一次提交的材料
|
||||
* @param riskId
|
||||
* @param description
|
||||
*/
|
||||
void updateRiskMaterial(String riskId, String description);
|
||||
}
|
@ -0,0 +1,32 @@
|
||||
package au.com.royalpay.payment.manage.riskbusiness.core.impl;
|
||||
|
||||
import au.com.royalpay.payment.manage.mappers.riskbusiness.RiskMaterialMapper;
|
||||
import au.com.royalpay.payment.manage.riskbusiness.core.RiskMaterialService;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Description:
|
||||
* @Author: lujian
|
||||
* @Date: 2018/11/19 19:45
|
||||
*/
|
||||
@Service
|
||||
public class RiskMaterialServiceImpl implements RiskMaterialService {
|
||||
|
||||
@Resource
|
||||
private RiskMaterialMapper riskMaterialMapper;
|
||||
|
||||
@Override
|
||||
public void updateRiskMaterial(String riskId, String description) {
|
||||
List<JSONObject> materialList = riskMaterialMapper.findAllMaterials(riskId);
|
||||
if (!materialList.isEmpty()){
|
||||
JSONObject material = materialList.get(0);
|
||||
material.put("refuse_description", description);
|
||||
riskMaterialMapper.update(material);
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in new issue