@ -64,7 +64,11 @@ public class DcEventImportantServiceImpl implements IDcEventImportantService
@Override
public int updateDcEventImportant(DcEventImportant dcEventImportant)
{
return dcEventImportantMapper.updateDcEventImportant(dcEventImportant);
int i = dcEventImportantMapper.updateDcEventImportant(dcEventImportant);
if (i < 1){
i = dcEventImportantMapper.insertDcEventImportant(dcEventImportant);
}
return i;
/**
@ -105,7 +105,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="chemicalsName != null">chemicals_name = #{chemicalsName},</if>
<if test="leakageLevel != null">leakage_level = #{leakageLevel},</if>
</trim>
where id = #{id}
where event_id = #{eventId}
</update>
<delete id="deleteDcEventImportantByEventId" parameterType="String">