| | |
| | | } |
| | | baseMapper.batchUpdate(btmTypeAttributeDOList); |
| | | return BtmTypeAttributeWrapper.build().listEntityVO(btmTypeAttributeDOList); |
| | | // btmTypeAttributeDOList.stream().forEachOrdered(s -> { |
| | | // btmTypeAttributeDOMapper.insert(s); |
| | | // }); |
| | | } |
| | | return null; |
| | | } |
| | |
| | | import com.vci.ubcs.starter.web.util.VciBaseUtil; |
| | | import org.springblade.core.mp.support.BaseEntityWrapper; |
| | | import org.springblade.core.tool.utils.BeanUtil; |
| | | import org.springblade.core.tool.utils.StringUtil; |
| | | |
| | | import java.util.Date; |
| | | import java.util.List; |
| | |
| | | */ |
| | | public BtmTypeAttribute copyBtmTypeAttributeDTO2Entity(BtmTypeLinkAttributesDTO dto, String btmTypeOid, String creator, Date now){ |
| | | BtmTypeAttribute entity = Objects.requireNonNull(BeanUtil.copy(dto, BtmTypeAttribute.class)); |
| | | if (StringUtil.isBlank(entity.getOid())) { |
| | | entity.setOid(VciBaseUtil.getPk()); |
| | | } |
| | | entity.setBtmName(BtmTypeConstant.BTM_TYPE_ATTRIBUTE); |
| | | entity.setOwner(creator); |
| | | entity.setCreator(creator); |
| | |
| | | pl_omd_btm_type |
| | | </sql> |
| | | <update id="batchUpdate" parameterType="java.util.List"> |
| | | BEGIN |
| | | <foreach collection="records" item="item" index="index" separator=";"> |
| | | |
| | | <foreach collection="records" item="item" index="index" separator=";" open="BEGIN" close=";END;"> |
| | | update <include refid="tableName"/> set |
| | | id = #{item.id,jdbcType=VARCHAR}, |
| | | name = #{item.name,jdbcType=VARCHAR}, |
| | |
| | | ts = #{item.ts,jdbcType=TIMESTAMP} |
| | | where oid = #{item.oid,jdbcType=VARCHAR} |
| | | </foreach> |
| | | ;END; |
| | | |
| | | </update> |
| | | <delete id="batchDelete"> |
| | | delete from |