| | |
| | | <resultMap id="inventoryResultMap" type="org.springblade.modules.InventoryLoss.vo.InventoryVO"> |
| | | <result column="id" property="id"/> |
| | | <result column="strain_name" property="strainName"/> |
| | | <result column="dict_value" property="reasonName"/> |
| | | </resultMap> |
| | | |
| | | |
| | | <select id="selectSalePage" resultMap="inventoryResultMap"> |
| | | select inventory.*, |
| | | strain.strain_name |
| | | strain.strain_name,bdb.dict_value |
| | | from sys_inventory inventory |
| | | LEFT JOIN sys_strain strain on inventory.strain_id = strain.id |
| | | LEFT JOIN blade_dict_biz bdb ON inventory.reason = bdb.dict_key |
| | | where |
| | | <if test="inventory.strainId !=null and inventory.strainId != '' "> |
| | | inventory.strain_id = #{inventory.strainId} AND |
| | | </if> |
| | | is_deleted = 0 |
| | | bdb.code = "lossReason" AND inventory.is_deleted = 0 |
| | | </select> |
| | | |
| | | </mapper> |