2023-01-06 15:17:37 +08:00
|
|
|
package com.ai.da.controller;
|
|
|
|
|
|
|
|
|
|
import com.ai.da.common.response.Response;
|
|
|
|
|
import com.ai.da.model.dto.*;
|
|
|
|
|
import com.ai.da.model.vo.AccountLoginVO;
|
|
|
|
|
import com.ai.da.service.AccountService;
|
|
|
|
|
import io.swagger.annotations.Api;
|
|
|
|
|
import io.swagger.annotations.ApiOperation;
|
|
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
|
|
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;
|
|
|
|
|
|
|
|
|
|
import javax.annotation.Resource;
|
|
|
|
|
import javax.servlet.http.HttpServletRequest;
|
|
|
|
|
import javax.validation.Valid;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Api(tags = "Third Party Modules")
|
|
|
|
|
@Slf4j
|
|
|
|
|
@RestController
|
|
|
|
|
@RequestMapping("/api/third/party")
|
|
|
|
|
public class ThirdPartyController {
|
|
|
|
|
|
|
|
|
|
@Resource
|
|
|
|
|
private AccountService accountService;
|
|
|
|
|
|
|
|
|
|
@ApiOperation(value = "Add user information")
|
|
|
|
|
@PostMapping("/addUser")
|
|
|
|
|
public Response<Boolean> addUser(@Valid @RequestBody AccountAddDTO accountAddDTO) {
|
|
|
|
|
return Response.success(accountService.addUser(accountAddDTO));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@ApiOperation(value = "Edit user information")
|
|
|
|
|
@PostMapping("/editUser")
|
|
|
|
|
public Response<Boolean> editUser( @RequestBody AccountEditDTO accountEditDTO) {
|
|
|
|
|
return Response.success(accountService.editUser(accountEditDTO));
|
|
|
|
|
}
|
2023-09-06 14:28:20 +08:00
|
|
|
|
2023-01-06 15:17:37 +08:00
|
|
|
}
|