|
|
@ -22,8 +22,13 @@ public class RiskMaterialServiceImpl implements RiskMaterialService {
|
|
|
|
|
|
|
|
|
|
|
|
@Override
|
|
|
|
@Override
|
|
|
|
public void updateRiskMaterial(String riskId, String description) {
|
|
|
|
public void updateRiskMaterial(String riskId, String description) {
|
|
|
|
|
|
|
|
System.out.println("--------------------------------------------------------");
|
|
|
|
|
|
|
|
System.out.println("description: " + description);
|
|
|
|
List<JSONObject> materialList = riskMaterialMapper.findAllMaterials(riskId);
|
|
|
|
List<JSONObject> materialList = riskMaterialMapper.findAllMaterials(riskId);
|
|
|
|
if (!materialList.isEmpty()){
|
|
|
|
System.out.println("--------------------------------------------------------");
|
|
|
|
|
|
|
|
System.out.println("materialList.size: ");
|
|
|
|
|
|
|
|
if (!materialList.isEmpty()) {
|
|
|
|
|
|
|
|
System.out.println(materialList.size());
|
|
|
|
JSONObject material = materialList.get(0);
|
|
|
|
JSONObject material = materialList.get(0);
|
|
|
|
material.put("refuse_description", description);
|
|
|
|
material.put("refuse_description", description);
|
|
|
|
riskMaterialMapper.update(material);
|
|
|
|
riskMaterialMapper.update(material);
|
|
|
|