|
@@ -62,7 +62,7 @@
|
|
|
<result column="pic" property="pic"/>
|
|
|
<result column="service_life" property="serviceLife"/>
|
|
|
<result column="next_indate" property="nextIndate"/>
|
|
|
- <collection property="goodsNos" ofType="com.hssx.pcbms.entity.GoodsNo">
|
|
|
+ <collection property="goodsNosVO" ofType="com.hssx.pcbms.entity.vo.GoodsNoVO">
|
|
|
<id column="nid" property="id"/>
|
|
|
<result column="model_no" property="modelNo"/>
|
|
|
<result column="division_code" property="divisionCode"/>
|
|
@@ -71,6 +71,7 @@
|
|
|
<result column="indate" property="indate"/>
|
|
|
<result column="goods_id" property="goodsId"/>
|
|
|
<result column="user_id" property="userId"/>
|
|
|
+ <result column="username" property="username"/>
|
|
|
</collection>
|
|
|
</resultMap>
|
|
|
<select id="getListBycondition" resultMap="BaseResultMapVO">
|
|
@@ -100,12 +101,14 @@
|
|
|
select
|
|
|
g.id, g.name, g.tag_id, g.model_number, g.unit,g.address, g.factory, g.pic, g.service_life, g.next_indate,
|
|
|
g.is_delete,gn.id nid,
|
|
|
- gn.model_no, gn.division_code, gn.suffix_code, gn.state, gn.indate, gn.goods_id, gn.user_id
|
|
|
+ gn.model_no, gn.division_code, gn.suffix_code, gn.state, gn.indate, gn.goods_id, gn.user_id,u.name username
|
|
|
from
|
|
|
goods g
|
|
|
left join
|
|
|
goods_no gn
|
|
|
on g.id = gn.goods_id
|
|
|
+ left join user u
|
|
|
+ on u.id = gn.user_id
|
|
|
<where>
|
|
|
g.id = #{id}
|
|
|
</where>
|