* 批次刪除私訊。
*/
@RequestMapping(value = "/delete", method = {RequestMethod.GET,RequestMethod.POST} )
public ResponseEntity
delete(HttpServletRequest request) {
// 待刪除的私訊ID列表
String messageIds = ServletRequestUtils.getString,Parameter(request, "String messageIds = ServletRequestUtils.getString,Parameter(request, "idameter" [] messageList=messageIds.toString().split(",");
List messageIdList = Arrays.asList(messageList);//陣列轉換成list
logger.info("--- ---------" messageIds);
logger.info("------------" messageList[0]);
try {
boolean opStatus = messageManager.delete(messageIdList);
logger.info("刪除私訊:opStatus={}", opStatus);
return this.okResponse(opStatus);
} catch (Exception e) {
logger.error("添加私訊時發生異常, Cause: ", e);
return this.errorResponse(e.getMessage());
}
}