package com.ruoyi.web.controller.zhang;
|
|
import com.ruoyi.common.annotation.Log;
|
import com.ruoyi.common.core.domain.AjaxResult;
|
import com.ruoyi.common.enums.BusinessType;
|
import com.ruoyi.domain.dto.ZHealthNowDto;
|
import com.ruoyi.service.ZHealthNowService;
|
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.web.bind.annotation.*;
|
|
/**
|
* @Author Jinquan_Ou
|
* @Description
|
* @Date 2023-07-17 13:30
|
* @Version 1.0.0
|
**/
|
@RestController
|
@RequestMapping("/zHealthNow")
|
public class ZHealthNowController {
|
@Autowired
|
ZHealthNowService zHealthNowService;
|
|
/**
|
* 查询数据
|
*/
|
@GetMapping("/all")
|
public AjaxResult listAll(){
|
return zHealthNowService.selectData();
|
}
|
|
/**
|
* 新增或修改记录
|
*/
|
// @PreAuthorize("@ss.hasPermi('system:property:edit')")
|
@Log(title = "健康记录", businessType = BusinessType.UPDATE)
|
@PostMapping
|
public AjaxResult edit(@RequestBody ZHealthNowDto zHealthNowDto)
|
{
|
return zHealthNowService.saveOrUpdateData(zHealthNowDto);
|
}
|
}
|