示例#1
0
 public int Post([FromForm] IFormFile file)
 {
     try
     {
         var newAccount = OFXFileReader.ReadFile(file);
         return(AccountModel.ImportAccountData(newAccount));
     }
     catch (Exception)
     {
         throw new System.Exception("File format error!");
     }
 }
 private async Task <OFXEntity> ReadFile(Stream stream)
 {
     return(await OFXFileReader.ReadFile(stream));
 }