File was renamed from consum-base/src/main/java/com/consum/base/service/LWhGoodsRecordDetailsService.java |
| | |
| | | package com.consum.base.service; |
| | | package com.consum.base.service.impl; |
| | | |
| | | import com.walker.jdbc.service.BaseServiceImpl; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | import javax.annotation.PostConstruct; |
| | | |
| | | import org.apache.commons.lang3.StringUtils; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | |
| | | import org.springframework.jdbc.core.simple.SimpleJdbcCall; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import javax.annotation.PostConstruct; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | import com.walker.jdbc.service.BaseServiceImpl; |
| | | |
| | | /** |
| | | * @ClassName LWhGoodsRecordDetailsService |
| | |
| | | |
| | | @PostConstruct |
| | | public void init() { |
| | | this.simpleJdbcCall = new SimpleJdbcCall(jdbcTemplate) |
| | | .withCatalogName(dataBaseName) |
| | | .withProcedureName("insert_WH_GOODS_RECORD_DETAILS"); |
| | | this.simpleJdbcCall = new SimpleJdbcCall(jdbcTemplate).withCatalogName(dataBaseName) |
| | | .withProcedureName("insert_WH_GOODS_RECORD_DETAILS"); |
| | | } |
| | | |
| | | |
| | | @Autowired |
| | | public LWhGoodsRecordDetailsService(JdbcTemplate jdbcTemplate) { |
| | |
| | | } |
| | | |
| | | public void sameGoodsInsertMore(List<Long> outGoodsId, long whGoodsRecordId, short thisType) { |
| | | SqlParameterSource in = new MapSqlParameterSource() |
| | | .addValue("WHGOODSIDList", StringUtils.join(outGoodsId, ",")) |
| | | .addValue("WH_GOODS_RECORD_ID", whGoodsRecordId) |
| | | .addValue("THIS_TYPE", thisType); |
| | | SqlParameterSource in = new MapSqlParameterSource().addValue("WHGOODSIDList", StringUtils.join(outGoodsId, ",")) |
| | | .addValue("WH_GOODS_RECORD_ID", whGoodsRecordId).addValue("THIS_TYPE", thisType); |
| | | Map<String, Object> out = simpleJdbcCall.execute(in); |
| | | System.out.println("Procedure result: " + out); |
| | | } |