|
@@ -4,10 +4,7 @@ import com.fdkankan.auth.service.ManageService;
|
|
|
import com.fdkankan.auth.vo.request.ManageLoginRequest;
|
|
import com.fdkankan.auth.vo.request.ManageLoginRequest;
|
|
|
import com.fdkankan.common.response.ResultData;
|
|
import com.fdkankan.common.response.ResultData;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
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;
|
|
|
|
|
|
|
+import org.springframework.web.bind.annotation.*;
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
* @author kong
|
|
* @author kong
|
|
@@ -22,12 +19,19 @@ public class ManageLoginController {
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
* 登录
|
|
* 登录
|
|
|
- * @return
|
|
|
|
|
*/
|
|
*/
|
|
|
@PostMapping("/login")
|
|
@PostMapping("/login")
|
|
|
public ResultData login(@RequestBody ManageLoginRequest param) {
|
|
public ResultData login(@RequestBody ManageLoginRequest param) {
|
|
|
return manageService.login(param.getUserName(),param.getPassword());
|
|
return manageService.login(param.getUserName(),param.getPassword());
|
|
|
}
|
|
}
|
|
|
|
|
+ /**
|
|
|
|
|
+ * 登出
|
|
|
|
|
+ */
|
|
|
|
|
+ @GetMapping("/logout")
|
|
|
|
|
+ public ResultData logout() {
|
|
|
|
|
+ manageService.logout();
|
|
|
|
|
+ return ResultData.ok();
|
|
|
|
|
+ }
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
}
|