增加商品导入的功能

This commit is contained in:
季圣华
2019-01-05 21:33:01 +08:00
parent 8a4d034743
commit 2b7a7bbdeb
11 changed files with 311 additions and 7 deletions

View File

@@ -77,4 +77,22 @@
UnitId = null
where Id = #{id,jdbcType=BIGINT}
</update>
<select id="findByAll" parameterType="com.jsh.erp.datasource.entities.MaterialExample" resultMap="ResultMapList">
select m.*,u.uname unitName, mc.name categoryName
FROM jsh_material m
left JOIN jsh_unit u on m.UnitId = u.id
left JOIN jsh_materialcategory mc on m.CategoryId = mc.id
where 1=1
<if test="name != null">
and m.name like '%${name}%'
</if>
<if test="model != null">
and m.model like '%${model}%'
</if>
<if test="categoryId != 1">
and m.CategoryId in (${categoryIds})
</if>
order by m.id asc
</select>
</mapper>

View File

@@ -45,4 +45,25 @@
and description like '%${description}%'
</if>
</select>
<select id="findByAll" parameterType="com.jsh.erp.datasource.entities.SupplierExample" resultMap="BaseResultMap">
select *
FROM jsh_supplier
where 1=1
<if test="supplier != null">
and supplier like '%${supplier}%'
</if>
<if test="type != null">
and type='${type}'
</if>
<if test="phonenum != null">
and phonenum like '%${phonenum}%'
</if>
<if test="telephone != null">
and telephone like '%${telephone}%'
</if>
<if test="description != null">
and description like '%${description}%'
</if>
</select>
</mapper>