Browse Source

feat: [模板管理] 检测板列表

master
memorylkf 2 months ago
parent
commit
906366d5f5
3 changed files with 21 additions and 17 deletions
  1. +0
    -17
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/JcbController.java
  2. +13
    -0
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/PublicController.java
  3. +8
    -0
      hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/impl/JcbServiceImpl.java

+ 0
- 17
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/JcbController.java View File

@ -1,15 +1,9 @@
package com.hxhq.business.controller; package com.hxhq.business.controller;
import java.util.Arrays;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
import com.hxhq.business.domain.Jcb;
import com.hxhq.business.service.IJcbService; import com.hxhq.business.service.IJcbService;
import com.hxhq.common.core.web.controller.BaseController; import com.hxhq.common.core.web.controller.BaseController;
import com.hxhq.common.core.web.domain.AjaxResult;
import com.hxhq.common.core.web.page.TableDataInfo;
/** /**
* 检测板Controller * 检测板Controller
@ -23,15 +17,4 @@ public class JcbController extends BaseController
{ {
@Autowired @Autowired
private IJcbService jcbService; private IJcbService jcbService;
/**
* 查询检测板列表
*/
@GetMapping("/list")
public TableDataInfo list(Jcb jcb)
{
startPage();
List<Jcb> list = jcbService.queryList(jcb);
return getDataTable(list);
}
} }

+ 13
- 0
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/PublicController.java View File

@ -76,6 +76,8 @@ public class PublicController extends BaseController {
public ISysDeptService sysDeptService; public ISysDeptService sysDeptService;
@Autowired @Autowired
public ISystemLogService systemLogService; public ISystemLogService systemLogService;
@Autowired
public IJcbService jcbService;
/** /**
@ -316,4 +318,15 @@ public class PublicController extends BaseController {
systemLogService.saveSimpleInfo(name,nameEn,jcmc,jcmcEn); systemLogService.saveSimpleInfo(name,nameEn,jcmc,jcmcEn);
return success(); return success();
} }
/**
* 查询检测板列表
*/
@GetMapping("/list")
public TableDataInfo list(Jcb jcb)
{
startPage();
List<Jcb> list = jcbService.queryList(jcb);
return getDataTable(list);
}
} }

+ 8
- 0
hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/impl/JcbServiceImpl.java View File

@ -4,6 +4,7 @@ import java.util.List;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.toolkit.Wrappers; import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.hxhq.common.core.utils.DateUtils; import com.hxhq.common.core.utils.DateUtils;
import com.hxhq.common.core.utils.StringUtils;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import com.hxhq.business.mapper.JcbMapper; import com.hxhq.business.mapper.JcbMapper;
import com.hxhq.business.domain.Jcb; import com.hxhq.business.domain.Jcb;
@ -29,6 +30,13 @@ public class JcbServiceImpl extends ServiceImpl implements IJcbS
public List<Jcb> queryList(Jcb jcb) public List<Jcb> queryList(Jcb jcb)
{ {
QueryWrapper<Jcb> queryWrapper = Wrappers.query(); QueryWrapper<Jcb> queryWrapper = Wrappers.query();
if(StringUtils.isNoneBlank(jcb.getBh())){
queryWrapper.like("bh",jcb.getBh());
}
if(StringUtils.isNoneBlank(jcb.getCjr())){
queryWrapper.like("cjr",jcb.getCjr());
}
queryWrapper.orderByDesc("id");
return this.list(queryWrapper); return this.list(queryWrapper);
} }

Loading…
Cancel
Save