Skip to content

Commit

Permalink
优化代码
Browse files Browse the repository at this point in the history
  • Loading branch information
yangzongzhuan committed Dec 13, 2022
1 parent f3d1f0a commit 7020592
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -63,11 +63,7 @@ public String profile(ModelMap mmap)
public boolean checkPassword(String password)
{
SysUser user = getSysUser();
if (passwordService.matches(user, password))
{
return true;
}
return false;
return passwordService.matches(user, password);
}

@GetMapping("/resetPwd")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ <h3>测试多行显示</h3>
enableURLhash: true, // Enable selection of the step based on url hash
transition: {
animation: 'none', // Effect on navigation, none/fade/slide-horizontal/slide-vertical/slide-swing
speed: '400', // Transion animation speed
speed: '400', // Transition animation speed
easing:'' // Transition animation easing. Not supported without a jQuery easing plugin
},
toolbarSettings: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -713,7 +713,7 @@ public static BigDecimal toBigDecimal(Object value, BigDecimal defaultValue)
}
if (value instanceof Double)
{
return new BigDecimal((Double) value);
return BigDecimal.valueOf((Double) value);
}
if (value instanceof Integer)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,14 @@ public interface SysConfigMapper
*/
public SysConfig selectConfig(SysConfig config);

/**
* 通过ID查询配置
*
* @param configId 参数ID
* @return 参数配置信息
*/
public SysConfig selectConfigById(Long configId);

/**
* 查询参数配置列表
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</where>
</select>

<select id="selectConfigById" parameterType="Long" resultMap="SysConfigResult">
<include refid="selectConfigVo"/>
where config_id = #{configId}
</select>

<select id="checkConfigKeyUnique" parameterType="String" resultMap="SysConfigResult">
<include refid="selectConfigVo"/>
where config_key = #{configKey} limit 1
Expand Down

0 comments on commit 7020592

Please sign in to comment.