当传来的参数scene为int类型是,要将它转换成String类型再比较,否则比较结果无效
例如:当传来的参数scene是0时,采用第一种是无效的的,会进入 <otherwise>的判断逻辑,要采用第二种方式
第一种:
<choose>
<when test="scene == 0">
hotel_roomtype c
</when>
<otherwise>
hotel_branchoffice c
</otherwise>
</choose>
第二种
<choose><when test="scene == '0'.toString()">
hotel_roomtype c
</when>
<otherwise>
hotel_branchoffice c
</otherwise>
</choose>