forked from rongchao/epmet-cloud-rizhao
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
35 lines
1.2 KiB
35 lines
1.2 KiB
5 years ago
|
package com.epmet.controller;
|
||
|
|
||
|
import com.epmet.commons.tools.utils.Result;
|
||
|
import com.epmet.commons.tools.validator.ValidatorUtils;
|
||
|
import com.epmet.dto.form.PaWxCodeFormDTO;
|
||
|
import com.epmet.dto.result.UserTokenResultDTO;
|
||
|
import com.epmet.service.PaUserLoginService;
|
||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||
|
import org.springframework.web.bind.annotation.RestController;
|
||
|
|
||
|
/**
|
||
|
* 描述一下
|
||
|
*
|
||
|
* @author yinzuomei@elink-cn.com
|
||
|
* @date 2020/7/8 18:29
|
||
|
*/
|
||
|
@RestController
|
||
|
@RequestMapping("pa")
|
||
|
public class PaUserLoginController {
|
||
|
|
||
|
@Autowired
|
||
|
private PaUserLoginService paUserLoginService;
|
||
|
|
||
|
@PostMapping(value = "/loginbywxcode")
|
||
|
public Result<UserTokenResultDTO> loginByWxCode(@RequestBody PaWxCodeFormDTO formDTO) {
|
||
|
ValidatorUtils.validateEntity(formDTO, PaWxCodeFormDTO.AddUserInternalGroup.class);
|
||
|
UserTokenResultDTO userTokenResultDTO=paUserLoginService.loginByWxCode(formDTO);
|
||
|
return new Result<UserTokenResultDTO>().ok(userTokenResultDTO);
|
||
|
}
|
||
|
|
||
|
}
|