Closed josebailo closed 10 months ago
ok, i will have a look. Thanks for the nice explanation.
@ujjwalguptaofficial did u get a chance to look into it, as I am still facing this issue in 4.7.1 v
sorry, the plan was to change the tests code to run it on typescript code, so that erros like can be known in tests and fixed. But due to big work - it was left.
I will fix this on priority by this week.
Issue is fixed in v - 4.7.2. Please install and let me know.
Really sorry for such a long time on this issue.
Feel free to open it- if its not fixed.
I want to do a select query, in the where clause I want to filter by three different fields using the
or
operator, so if any of the three comparisons are true I get the records. Here is my query:While this works fine in plain Javascript the problem comes when using Typescript. The
or
definition gets this error:The problem is with the definition of the
or
clause in theIWhereQueryOption
interface. It's declared at the same level as the field comparison functions like>
,regex
, etc. I think it should be declared on theIWhereQuery
interface so in the where clause you can set a field's name or theor
clause. The interface could be defined this way:After this change Typescript doesn't complaint about the
or
clause. The only doubt I have is if after this change it's needed theor
clause in theIWhereQueryOption
interface. I wanted to do the change myself and create a PR but I work with wsl and couldn't run the tests and don't have time to deal with it so maybe it's better if you perform the change directly.