package com.YuyeTech.HeartRate.game.userDeleteLog.controller;

import com.YuyeTech.HeartRate.annotation.Decrypt;
import com.YuyeTech.HeartRate.annotation.Encrypt;
import com.YuyeTech.HeartRate.common.controller.CommonController;
import com.YuyeTech.HeartRate.common.pojo.PageInfo;
import com.YuyeTech.HeartRate.common.pojo.Result;
import com.YuyeTech.HeartRate.game.userDeleteLog.pojo.UserDeleteLog;
import com.YuyeTech.HeartRate.game.userDeleteLog.service.UserDeleteLogService;
import com.YuyeTech.HeartRate.game.userDeleteLog.vo.UserDeleteLogVo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.servlet.ModelAndView;

@RestController
@RequestMapping("/backstage_userDeleteLog/")
public class BackstageUserDeleteLogController extends CommonController<UserDeleteLogVo, UserDeleteLog, String> {
    @Autowired
    private UserDeleteLogService userDeleteLogService;

    /**
     * 前端view跳转,配置菜单路径
     * 设置默认参数
     *
     * @return
     */
    @GetMapping("gotoView")
    public ModelAndView gotoView() {
        ModelAndView modelAndView = new ModelAndView("client/userInfoLog");
        return modelAndView;
    }

    /**
     * 分页查询数据
     *
     * @param vo
     * @return
     */
    @PostMapping("findAll")
    @Decrypt
    @Encrypt
    public Result<PageInfo<UserDeleteLogVo>> findAll(UserDeleteLogVo vo) {
        return userDeleteLogService.page(vo);
    }



}
