| | |
| | | <mapper namespace="org.springblade.modules.InventoryLoss.mapper.InventoryMapper"> |
| | | |
| | | <!-- 通用查询映射结果 --> |
| | | <resultMap id="inventoryResultMap" type="org.springblade.modules.InventoryLoss.entity.Inventory"> |
| | | <resultMap id="inventoryResultMap" type="org.springblade.modules.InventoryLoss.vo.InventoryVO"> |
| | | <result column="id" property="id"/> |
| | | |
| | | <result column="strain_name" property="strainName"/> |
| | | </resultMap> |
| | | |
| | | |
| | | <select id="selectSalePage" resultMap="inventoryResultMap"> |
| | | select * |
| | | from sys_inventory |
| | | select inventory.*, |
| | | strain.strain_name |
| | | from sys_inventory inventory |
| | | LEFT JOIN sys_strain strain on inventory.strain_id = strain.id |
| | | where is_deleted = 0 |
| | | </select> |
| | | |