public async Task <ApiResult <string> > Delete(string parm, int type = 0) { if (type == 0) { return(await _messageService.DeleteAsync(parm)); } else { return(await _messageService.DeleteAsync(m => true)); } }
public async Task <ApiResult <string> > Delete([FromBody] MessageDeleteDto obj) { if (obj.type == 0) { return(await _messageService.DeleteAsync(obj.parm)); } else { return(await _messageService.DeleteAsync(m => true)); } }
public async Task <IActionResult> Delete([FromBody] MessageDeleteDto obj) { if (obj.type == 0) { return(Ok(await _messageService.DeleteAsync(obj.parm))); } else { return(Ok(await _messageService.DeleteAsync(m => true))); } }