未处理的拒绝TypeError:sequalize

时间:2017-06-14 14:55:16

标签: javascript node.js orm sequelize.js node-modules

我在调用retrieveCart函数时遇到此错误?查询全部查询中的错误是什么。我的cartProducts表中有一个名为productID的外键自动生成sequelize?

  

未处理的拒绝TypeError:无法读取属性' getTableName'的   未定义

private static byte[] CopyAndHash(string source, string target, Action<double> progress, Func<bool> isCanceled)
{
    using(var sha512 = SHA512.Create())
    using (var targetStream = File.OpenWrite(target))
    using (var cryptoStream = new CryptoStream(targetStream, sha512, CryptoStreamMode.Write))
    using (var sourceStream = File.OpenRead(source))
    {
        byte[] buffer = new byte[81920];
        int read;
        while ((read = sourceStream.Read(buffer, 0, buffer.Length)) > 0 && !isCanceled())
        {
            cryptoStream.Write(buffer, 0, read);

            progress?.Invoke((double) sourceStream.Length / sourceStream.Position * 100);
        }

    File.SetAttributes(target, File.GetAttributes(source));

    return sha512.Hash;
   }
}

1 个答案:

答案 0 :(得分:0)

modal:Product更改为model:Product,