Quellcode durchsuchen

goods and fireUser

梁彦春 vor 6 Jahren
Ursprung
Commit
4836a33829

+ 18
- 0
src/main/resources/mapper/TaGoodsMapper.xml Datei anzeigen

@@ -0,0 +1,18 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
3
+<mapper namespace="com.huiju.welcome.mapper.TaGoodsMapper">
4
+    <select id="goodsList" resultType="com.huiju.welcome.model.TaGoods">
5
+        select
6
+        *
7
+        from ta_goods
8
+        <where>
9
+            <if test="goodsName !=null and goodsName !=''">
10
+                goodsName LIKE CONCAT('%',#{goodsName},'%')
11
+            </if>
12
+            <if test="typeId !=null and typeId !=''">
13
+                typeId = CONCAT('%',#{typeId},'%')
14
+            </if>
15
+        </where>
16
+    </select>
17
+
18
+</mapper>

+ 1
- 1
src/main/resources/mapper/TdSpecMapper.xml Datei anzeigen

@@ -6,7 +6,7 @@
6 6
         *
7 7
         from td_spec
8 8
         <where>
9
-            <if test="specName !=null and typeName !=''">
9
+            <if test="specName !=null and specName !=''">
10 10
                 specName LIKE CONCAT('%',#{specName},'%')
11 11
             </if>
12 12
         </where>