装修阶段

This commit is contained in:
苏竹红
2024-06-25 15:09:16 +08:00
parent 50ae1f4ce4
commit 06666ea419
18 changed files with 313 additions and 331 deletions

View File

@@ -17,13 +17,28 @@ public class DecorationDesignInfoDAO {
@Resource
DecorationDesignInfoMapper decorationDesignInfoMapper;
private DecorationDesignInfoDO getById(Long id){
public DecorationDesignInfoDO getById(Long id){
if(id == null){
return null;
}
return decorationDesignInfoMapper.selectByPrimaryKey(id);
}
public Integer insertSelective(DecorationDesignInfoDO decorationDesignInfoDO){
return decorationDesignInfoMapper.insertSelective(decorationDesignInfoDO);
}
public Integer updateByPrimaryKey(DecorationDesignInfoDO decorationDesignInfoDO){
return decorationDesignInfoMapper.updateByPrimaryKey(decorationDesignInfoDO);
}
public DecorationDesignInfoDO getByShopId(Long shopId){
if(shopId == null){
return null;
}
return decorationDesignInfoMapper.selectByShopId(shopId);
}

View File

@@ -4,4 +4,13 @@ import com.cool.store.entity.DecorationDesignInfoDO;
import tk.mybatis.mapper.common.Mapper;
public interface DecorationDesignInfoMapper extends Mapper<DecorationDesignInfoDO> {
/**
* 查询店铺的设计数据
* @param shopId
* @return
*/
DecorationDesignInfoDO selectByShopId(Long shopId);
}

View File

@@ -15,4 +15,16 @@
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
<result column="deleted" jdbcType="BIT" property="deleted" />
</resultMap>
<select id="selectByShopId" resultMap="BaseResultMap">
select
*
from decoration_design_info where shop_id = #{shopId} and deleted = 0
</select>
</mapper>

View File

@@ -72,6 +72,7 @@
<if test="request.businessLeaderMobile != null">business_leader_mobile,</if>
<if test="request.financialManagerName != null">financial_manager_name,</if>
<if test="request.financialManagerMobile != null">financial_manager_mobile,</if>
<if test="request.businessLicense != null">business_license,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="request.auditId != null">#{request.auditId},</if>
@@ -103,6 +104,7 @@
<if test="request.businessLeaderMobile != null">#{request.businessLeaderMobile},</if>
<if test="request.financialManagerName != null">#{request.financialManagerName},</if>
<if test="request.financialManagerMobile != null">#{request.financialManagerMobile},</if>
<if test="request.businessLicense != null">#{request.businessLicense},</if>
</trim>
ON DUPLICATE KEY UPDATE
<trim suffixOverrides=",">
@@ -135,6 +137,7 @@
<if test="request.businessLeaderMobile != null">business_leader_mobile = #{request.businessLeaderMobile},</if>
<if test="request.financialManagerName != null">financial_manager_name = #{request.financialManagerName},</if>
<if test="request.financialManagerMobile != null">financial_manager_mobile = #{request.financialManagerMobile},</if>
<if test="request.businessLicense != null">business_license = #{request.businessLicense},</if>
</trim>
</insert>