|
|
@ -37,7 +37,7 @@ public class AdminController {
|
|
|
|
@Resource
|
|
|
|
@Resource
|
|
|
|
private AddressService addressService;
|
|
|
|
private AddressService addressService;
|
|
|
|
|
|
|
|
|
|
|
|
// 管理员查看用户或者快递员信息
|
|
|
|
// 管理员查看用户或者快递员信息(finish)
|
|
|
|
@GetMapping("/infoList")
|
|
|
|
@GetMapping("/infoList")
|
|
|
|
public Result<Page<User>> getUserList(@RequestParam int page, @RequestParam int pageSize, @RequestParam int mark) {
|
|
|
|
public Result<Page<User>> getUserList(@RequestParam int page, @RequestParam int pageSize, @RequestParam int mark) {
|
|
|
|
if (page <= 0 || pageSize <= 0) {
|
|
|
|
if (page <= 0 || pageSize <= 0) {
|
|
|
@ -55,7 +55,7 @@ public class AdminController {
|
|
|
|
return new Result<>(200, "", pageInfo);
|
|
|
|
return new Result<>(200, "", pageInfo);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// 拉黑删除快递员或者用户
|
|
|
|
// 拉黑删除快递员或者用户(finish)
|
|
|
|
@DeleteMapping("/delete/{id}")
|
|
|
|
@DeleteMapping("/delete/{id}")
|
|
|
|
public Result<String> delete(@PathVariable Long id, @RequestParam @NotNull String operation) {
|
|
|
|
public Result<String> delete(@PathVariable Long id, @RequestParam @NotNull String operation) {
|
|
|
|
User user = userService.getById(id);
|
|
|
|
User user = userService.getById(id);
|
|
|
@ -77,7 +77,7 @@ public class AdminController {
|
|
|
|
return new Result<>(200, "操作成功", "");
|
|
|
|
return new Result<>(200, "操作成功", "");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// 管理员发送消息
|
|
|
|
// 管理员发送消息(finish)
|
|
|
|
@PostMapping("/sendMessage")
|
|
|
|
@PostMapping("/sendMessage")
|
|
|
|
public Result<String> sendMessage(@RequestBody @Validated SendMessageDTO sendMessageDTO) {
|
|
|
|
public Result<String> sendMessage(@RequestBody @Validated SendMessageDTO sendMessageDTO) {
|
|
|
|
Message message = SendMessageUtil.sendMessage(sendMessageDTO);
|
|
|
|
Message message = SendMessageUtil.sendMessage(sendMessageDTO);
|
|
|
@ -85,7 +85,7 @@ public class AdminController {
|
|
|
|
return new Result<>(200, "发送成功", "");
|
|
|
|
return new Result<>(200, "发送成功", "");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// 获取正在留言的人的所有聊天记录
|
|
|
|
// 获取正在留言的人的所有聊天记录(finish)
|
|
|
|
@GetMapping("/allMessage")
|
|
|
|
@GetMapping("/allMessage")
|
|
|
|
public Result<List<List<Message>>> getAllMessage(@RequestParam Long toId) {
|
|
|
|
public Result<List<List<Message>>> getAllMessage(@RequestParam Long toId) {
|
|
|
|
Long meId = GetIdUtil.getId();
|
|
|
|
Long meId = GetIdUtil.getId();
|
|
|
@ -103,7 +103,7 @@ public class AdminController {
|
|
|
|
return new Result<>(200, "", list);
|
|
|
|
return new Result<>(200, "", list);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// 管理员获取所有快递信息
|
|
|
|
// 管理员获取所有快递信息(finish)
|
|
|
|
@GetMapping("/express")
|
|
|
|
@GetMapping("/express")
|
|
|
|
public Result<Page<ExpressListDTO>> getAllExpress(@RequestParam int page, @RequestParam int pageSize) {
|
|
|
|
public Result<Page<ExpressListDTO>> getAllExpress(@RequestParam int page, @RequestParam int pageSize) {
|
|
|
|
Page<Records> recordsPage = new Page<>(page, pageSize);
|
|
|
|
Page<Records> recordsPage = new Page<>(page, pageSize);
|
|
|
|