package com.ltkj.web.controller.system;
|
|
import java.util.List;
|
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.PathVariable;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RestController;
|
import com.ltkj.common.core.controller.BaseController;
|
import com.ltkj.common.core.domain.AjaxResult;
|
import com.ltkj.hosp.sqlDomain.LtkjPackageHis;
|
import com.ltkj.hosp.service.LtkjPackageHisService;
|
import com.ltkj.common.core.page.TableDataInfo;
|
|
/**
|
* his套餐
|
*/
|
@RestController
|
@RequestMapping("/hosp/packageHis")
|
public class LtkjPackageHisController extends BaseController {
|
@Autowired
|
private LtkjPackageHisService tjPackageHisService;
|
|
/**
|
* 查询his套餐列表
|
*/
|
@GetMapping("/list")
|
public TableDataInfo list(LtkjPackageHis ltkjPackageHis) {
|
startPage();
|
LambdaQueryWrapper<LtkjPackageHis> wq=new LambdaQueryWrapper<>();
|
if (ltkjPackageHis.getPacCode()!=null){
|
wq.like(LtkjPackageHis::getPacCode, ltkjPackageHis.getPacCode());
|
}
|
if (ltkjPackageHis.getPacName()!=null){
|
wq.like(LtkjPackageHis::getPacName, ltkjPackageHis.getPacName());
|
}
|
if (ltkjPackageHis.getPacRemark()!=null){
|
wq.like(LtkjPackageHis::getPacRemark, ltkjPackageHis.getPacRemark());
|
}
|
List<LtkjPackageHis> list = tjPackageHisService.list(wq);
|
return getDataTable(list);
|
}
|
|
/**
|
* 获取his套餐详细信息
|
*/
|
@GetMapping(value = "/{pacId}")
|
public AjaxResult getInfo(@PathVariable("pacId") Long pacId) {
|
return success(tjPackageHisService.getById(pacId));
|
}
|
|
}
|