优化
This commit is contained in:
+14
@@ -0,0 +1,14 @@
|
||||
package com.baiyue.lastleg.financefee.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.baiyue.lastleg.financefee.entity.OverseasFeeCommand;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.apache.ibatis.annotations.Select;
|
||||
|
||||
@Mapper
|
||||
public interface OverseasFeeCommandMapper extends BaseMapper<OverseasFeeCommand> {
|
||||
@Select("SELECT * FROM ll_finance_fee_command WHERE operator_id=#{operatorId} AND action=#{action} AND idempotency_key=#{key} LIMIT 1")
|
||||
OverseasFeeCommand find(@Param("operatorId") String operatorId, @Param("action") String action,
|
||||
@Param("key") String key);
|
||||
}
|
||||
+13
@@ -0,0 +1,13 @@
|
||||
package com.baiyue.lastleg.financefee.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.baiyue.lastleg.financefee.entity.OverseasFeeSource;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.apache.ibatis.annotations.Select;
|
||||
|
||||
@Mapper
|
||||
public interface OverseasFeeSourceMapper extends BaseMapper<OverseasFeeSource> {
|
||||
@Select("SELECT * FROM ll_finance_fee_source WHERE source_fee_id=#{sourceFeeId} ORDER BY source_version DESC LIMIT 1 FOR UPDATE")
|
||||
OverseasFeeSource lockCurrent(@Param("sourceFeeId") long sourceFeeId);
|
||||
}
|
||||
Reference in New Issue
Block a user