|
@@ -22,6 +22,32 @@
|
|
|
SELECT * FROM sys_tenant_account WHERE user_id_ = #{uesrId} for update
|
|
|
</select>
|
|
|
|
|
|
+ <!-- 根据主键查询一条记录 -->
|
|
|
+ <update id="update" parameterType="com.ym.mec.biz.dal.entity.SysTenantAccount">
|
|
|
+ UPDATE sys_tenant_account
|
|
|
+ <set>
|
|
|
+ <if test="status != null">
|
|
|
+ status_ = #{status, typeHandler=com.ym.mec.common.dal.CustomEnumTypeHandler},
|
|
|
+ </if>
|
|
|
+ <if test="userId != null">
|
|
|
+ user_id_ = #{userId},
|
|
|
+ </if>
|
|
|
+ <if test="availableMinutes != null">
|
|
|
+ available_minutes_ = #{availableMinutes},
|
|
|
+ </if>
|
|
|
+ <if test="updateTime != null">
|
|
|
+ update_time_ = #{updateTime},
|
|
|
+ </if>
|
|
|
+ <if test="frozenMinutes != null">
|
|
|
+ frozen_minutes_ = #{frozenMinutes},
|
|
|
+ </if>
|
|
|
+ <if test="createTime != null">
|
|
|
+ create_time_ = #{createTime},
|
|
|
+ </if>
|
|
|
+ </set>
|
|
|
+ WHERE user_id_ = #{userId}
|
|
|
+ </update>
|
|
|
+
|
|
|
<!-- 全查询 -->
|
|
|
<select id="findAll" resultMap="SysTenantAccount">
|
|
|
SELECT * FROM sys_tenant_account
|