public async Task <IActionResult> Get([Bind("Id"), FromQuery] long id) { if (id > 0) { var res = await _systemService.GetByIdAsync(id); return(Ok(res)); } else { return(Ok(new SysSystem())); } }
public async Task <SysSystem> GetByIdAsync(long id) { return(await _systemService.GetByIdAsync(id)); }