全局usdt,trx账户
This commit is contained in:
1 parent
15a80de8a6
commit
2602897c23
5 files changed
+146
-1
No files matched your search
@@ -23,10 +23,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<result property="rotatedAt" column="rotated_at" />
|
||||
<result property="trxNum" column="trx_num" />
|
||||
<result property="tokenAddress" column="token_address" />
|
||||
<result property="usdtBalance" column="usdt_balance" />
|
||||
<result property="trxBalance" column="trx_balance" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectUsdtConfigVo">
|
||||
select id, pay_usdt_num, receive_usdt_num, tron_net_type, version, encryption_algorithm, password_kdf, iterations, encrypted_mnemonic, mnemonic_nonce, encrypted_dek, dek_nonce, key_salt, password_salt, password_hash, rotated_at, trx_num, token_address from usdt_config
|
||||
select id, pay_usdt_num, receive_usdt_num, tron_net_type, version, encryption_algorithm, password_kdf, iterations, encrypted_mnemonic, mnemonic_nonce, encrypted_dek, dek_nonce, key_salt, password_salt, password_hash, rotated_at, trx_num, token_address, usdt_balance, trx_balance from usdt_config
|
||||
</sql>
|
||||
|
||||
<select id="selectUsdtConfigList" parameterType="UsdtConfig" resultMap="UsdtConfigResult">
|
||||
@@ -49,6 +51,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="rotatedAt != null "> and rotated_at = #{rotatedAt}</if>
|
||||
<if test="trxNum != null "> and trx_num = #{trxNum}</if>
|
||||
<if test="tokenAddress != null and tokenAddress != ''"> and token_address = #{tokenAddress}</if>
|
||||
<if test="usdtBalance != null "> and usdt_balance = #{usdtBalance}</if>
|
||||
<if test="trxBalance != null "> and trx_balance = #{trxBalance}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
@@ -77,6 +81,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
where id = #{config.id}
|
||||
and version = #{oldVersion}
|
||||
</update>
|
||||
|
||||
<update id="updateMainWalletBalances">
|
||||
update usdt_config
|
||||
set usdt_balance = #{usdtBalance},
|
||||
trx_balance = #{trxBalance}
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<insert id="insertUsdtConfig" parameterType="UsdtConfig" useGeneratedKeys="true" keyProperty="id">
|
||||
insert into usdt_config
|
||||
@@ -98,6 +109,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="rotatedAt != null">rotated_at,</if>
|
||||
<if test="trxNum != null">trx_num,</if>
|
||||
<if test="tokenAddress != null">token_address,</if>
|
||||
<if test="usdtBalance != null">usdt_balance,</if>
|
||||
<if test="trxBalance != null">trx_balance,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="payUsdtNum != null">#{payUsdtNum},</if>
|
||||
@@ -117,6 +130,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="rotatedAt != null">#{rotatedAt},</if>
|
||||
<if test="trxNum != null">#{trxNum},</if>
|
||||
<if test="tokenAddress != null">#{tokenAddress},</if>
|
||||
<if test="usdtBalance != null">#{usdtBalance},</if>
|
||||
<if test="trxBalance != null">#{trxBalance},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
@@ -140,6 +155,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="rotatedAt != null">rotated_at = #{rotatedAt},</if>
|
||||
<if test="trxNum != null">trx_num = #{trxNum},</if>
|
||||
<if test="tokenAddress != null">token_address = #{tokenAddress},</if>
|
||||
<if test="usdtBalance != null">usdt_balance = #{usdtBalance},</if>
|
||||
<if test="trxBalance != null">trx_balance = #{trxBalance},</if>
|
||||
</trim>
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
Reference in new issue
Block a user