package com.red.circle.other.adapter.app.user.user;

import com.red.circle.framework.core.dto.AppCommand;
import com.red.circle.framework.web.controller.BaseController;
import com.red.circle.other.app.dto.clientobject.user.user.LoginLoggerCO;
import com.red.circle.other.app.service.user.user.UserLoginLoggerService;
import lombok.AllArgsConstructor;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 用户登录日志信息服务.
 *
 * @author zongpubin on 2023/11/27
 */
@RestController
@RequestMapping("/user")
@AllArgsConstructor
public class UserLoginLoggerRestController extends BaseController {

  private final UserLoginLoggerService userLoginLoggerService;

  /**
   * 查询设备是否用Facebook登录过.
   */
  @GetMapping(value = "/login/logger")
  public LoginLoggerCO getUserInfo(AppCommand cmd) {
    return userLoginLoggerService.getUserInfo(cmd);
  }
}

