package com.fs.his.controller;

import com.fs.common.core.controller.BaseController;
import com.fs.common.core.domain.R;
import com.fs.common.core.page.TableDataInfo;
import com.fs.his.domain.FsUserOperationLog;
import com.fs.his.service.IFsUserOperationLogService;
import com.fs.his.vo.FsUserOperationLogParamVo;
import com.fs.his.vo.FsUserOperationLogVo;
import com.hc.openapi.tool.fastjson.JSON;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.ArrayList;
import java.util.List;

/**
 * 用户操作日志对象
 */
@RestController
@RequestMapping("/his/userOperationLog")
public class FsUserOperationLogController extends BaseController {

    @Autowired
    private IFsUserOperationLogService fsUserOperationLogService;

//    @PreAuthorize("@ss.hasPermi('his:userOperationLog:list')")
    @GetMapping("/list")
    public TableDataInfo list(FsUserOperationLog fsUserOperationLog)
    {
        startPage();
        List<FsUserOperationLogVo> list = fsUserOperationLogService.selectFsUserOperationLogByList(fsUserOperationLog);

        return getDataTable(list);
    }

    @GetMapping("/getOperationType")
    public R getOperationType()
    {
        return R.ok().put("data",fsUserOperationLogService.getOperationType());
    }
}
