Commit 74b436a2 by huluobin

update 搜索模板

parent c33308ef
......@@ -72,7 +72,7 @@ public class CareerController {
public JsonResult<Page<BaseProduce>> queryWorkTpl(@RequestHeader String token,
@RequestParam Integer pageNum,
@RequestParam Integer pageSize,
@RequestParam String searchKeyWord) {
@RequestParam(required = false) String searchKeyWord) {
Integer technicianId = SessionUtils.getTechnicianId();
Page<BaseProduce> baseProduceList = careerCmdService.queryWorkTpl(technicianId, pageNum, pageSize, searchKeyWord);
return JsonResult.success(baseProduceList);
......
......@@ -109,10 +109,10 @@
SELECT t1.*
from base_produce t1
LEFT JOIN career_works t2 on t1.id = t2.produce_id and t2.technician_id = #{technicianId}
where t1.is_work_tpl = 1
<if test="searchKeyWord != null and searchKeyWord != ''">
and t1.`name` like concat('%',#{searchKeyWord},'%')
</if>
where t1.is_work_tpl = 1
and t2.id is null
</select>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment