javascript - ng-true-value='0' picking up wrong values -


for demo see jsfiddle here , click on out of stock checkbox.

it should show stock quantity of 0, picking quantity of 30. think becasue matching against string values.

i assume issue with:

ng-true-value='0' 

what best way fix this? please can provide code example?

make strict value dynamic:

<div ng-repeat="item in inventory | filter: searchinventory:!!searchinventory.qty | orderby:sortorder"> 

note: might messy if have multiple similar criterias

http://jsfiddle.net/wyfs4/648/


Comments

Popular posts from this blog

ios - RestKit 0.20 — CoreData: error: Failed to call designated initializer on NSManagedObject class (again) -

laravel - PDOException in Connector.php line 55: SQLSTATE[HY000] [1045] Access denied for user 'root'@'localhost' (using password: YES) -

java - Digest auth with Spring Security using javaconfig -