public async Task <string> DeleteStaffInfo(string info) { if (string.IsNullOrWhiteSpace(info)) { return(JsonConvert.SerializeObject(new { status = "fail", message = "需要删除的员工ID不能为空", date = DateTime.Now })); } int ID = Convert.ToInt32(info); StaffDal dal = new StaffDal(); var result = await dal.DeleteStaffInfo(ID); if (result.ResultCode != 0) { return(JsonConvert.SerializeObject(new { status = "fail", message = result.ResultMsg, date = DateTime.Now })); } return(JsonConvert.SerializeObject(new { status = "success", data = result.Data, date = DateTime.Now })); }